Skip to main content
POST
/
abdm
/
v1
/
care-contexts
/
discover
/
link
/
on-init
Discover Link On Init
curl --request POST \
  --url https://api.eka.care/abdm/v1/care-contexts/discover/link/on-init \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "request_id": "<string>",
  "txn_id": "<string>",
  "error": {
    "code": 123,
    "message": "<string>"
  },
  "otp_expiry": "2025-06-15T10:30:00.000Z",
  "ref_num": "<string>"
}
'
{
  "code": 123,
  "error": "<string>",
  "source_error": {
    "code": "<string>",
    "message": "<string>"
  }
}

Documentation Index

Fetch the complete documentation index at: https://developer.eka.care/llms.txt

Use this file to discover all available pages before exploring further.

Call this API in response to the Link Initiation webhook, after you have generated and sent the OTP to the patient. Use the request_id and txn_id from the webhook payload when constructing your response.

Authorizations

Authorization
string
header
required

The API requires a Bearer token (JWT) for authentication.

Headers

X-Pt-Id
string

Eka User ID (OID)

X-Partner-Pt-Id
string

Partner User ID

X-Hip-Id
string

Partner HIP ID

Body

application/json
request_id
string
required

Request ID that is received in the webhook call.

txn_id
string
required

Transaction ID received in the webhook call.

error
object

Error details, if any occurred during the process.

otp_expiry
string

Expiry time of the OTP sent for linking care contexts. Format: 2006-01-02T15:04:05.000Z (ISO 8601 with milliseconds, UTC).

Example:

"2025-06-15T10:30:00.000Z"

ref_num
string

patient reference number.

Response

No Content