Data push url not received

@IntegrationSupport

While calling “https://dev.abdm.gov.in/gateway/v0.5/health-information/cm/request”, we are getting /v0.5/health-information/hiu/on-request but data push url (https://medbot.demoap.com/api/Webhook/ReceiveMedBotWebhookRawData/data/push) not called back. We assured that tried patient is having health record in kidney hospital.

We found that the health records are displaying in NHA HIU application (https://dev.ndhm.gov.in/hiu#/)

Execution steps are as follows :

  1. consent request

  2. consent approval

  3. HIU Notify callback (/v0.5/consents/hiu/notify)

  4. HIU On Notify (https://dev.abdm.gov.in/gateway/v0.5/consents/hiu/on-notify)

  5. Consent Fetch (https://dev.abdm.gov.in/gateway/v0.5/consents/fetch)

  6. Consent On Fetch Call Back (/v0.5/consents/on-fetch)

  7. Health Info Request (cm request) - https://dev.abdm.gov.in/gateway/v0.5/health-information/cm/request

  8. Health info request call back ( /v0.5/health-information/hiu/on-request)

  9. /data/push - mentioned issue is happening here

@dhanyathanmayi

Please share " /v0.5/health-information/cm/request" API payload.

@IntegrationSupport

@Sachin

Url= https://dev.abdm.gov.in/gateway/v0.5/health-information/cm/request

Request :

{“requestId”:“97be4303-dd9b-4a73-aae7-9c703a143366”,“timestamp”:“2024-01-30T08:56:20.0571783”,“hiRequest”:{“consent”:{“id”:“120a0fa8-0bcd-4575-b247-341e7638e2f4”},“dateRange”:{“from”:“2024-01-01T08:55:03.0000000”,“to”:“2024-01-28T08:55:03.0000000”},“dataPushUrl”:“https://medbot.demoap.com/api/Webhook/ReceiveMedBotWebhookRawData/data/push",“keyMaterial”:{“cryptoAlg”:“ECDH”,“curve”:“Curve25519”,“dhPublicKey”:{“expiry”:“2024-03-12T18:30:00.0000000”,“parameters”:"Curve25519/32byte random key”,“keyValue”:“BFTahuFVsPMzbUpo3iM0CSGWZ/B5pJRgEBwjahG11p+/TJBWI8E+9AW1eKDYKn/LF5G6SzqDIXfV+8Ajm78nWP0=”},“nonce”:“xN6UVwDo704xjVMEZi8PnzE3MDQ3ODQyMjU=”}}}

@dhanyathanmayi

Here I am providing the sample cURL, please try with this.

Usually we didn’t receive the data when the date range is not correct or the format is not correct or the key material is not correct.

please pass the time format link the bundle below and make sure you are passing correct key material.

Sample Curl

curl --location ‘https://dev.abdm.gov.in/gateway/v0.5/health-information/cm/request
–header ‘accept: /’
–header ‘X-CM-ID: sbx’
–header ‘Content-Type: application/json’
–header ‘Authorization: Bearer eyJhBQ’
–data ‘{
“requestId”: “dc6969e4-3e80-4f51-9f81-f53a9f63d1d4”,
“timestamp”: “2024-01-18T11:10:25.894000”,
“hiRequest”: {
“consent”: {
“id”: “bc218ba1-9fca-4f96-8f2b-72cd092d1752”
},
“dateRange”: {
“from”: “2022-01-01T14:30:29.592Z”,
“to”: “2024-01-18T16:33:29.592Z”
},
“dataPushUrl”: “https://webhook.site/10cbec5f-2f9d-430c-a01a-89e7dfe5f829/atul/data/push”,
“keyMaterial”: {
“cryptoAlg”: “ECDH”,
“curve”: “Curve25519”,
“dhPublicKey”: {
“expiry”: “2025-06-17T12:23:08.224Z”,
“parameters”: “Curve25519/32byte random key”,
“keyValue”: “BBPoAgnzdznWzET9Br6eawQ+f6y2rrJgEwSNN/VK2WZNW6tm5MF2iWs3IYKC8fw0T/YKDKroimq8LO2Cy+2c7tE=”,
“x509PublicKey”: “MIIBMTCB6gYHKoZIzj0CATCB3gIBATArBgcqhkjOPQEBAiB/////////////////////////////////////////7TBEBCAqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqYSRShRAQge0Je0Je0Je0Je0Je0Je0Je0Je0Je0Je0JgtenHcQyGQEQQQqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq0kWiCuGaG4oIa04B7dLHdI0UySPU1+bXxhsinpxaJ+ztPZAiAQAAAAAAAAAAAAAAAAAAAAFN753qL3nNZYEmMaXPXT7QIBCANCAARzDxcCe7FZtrb+gvbjb/FJnS/zc7Ooq9A+1bTW3uHSdF33GViSWumNHfFbkuLf85ksgoGCjQVa+5CHPeV4PGOP”
},
“nonce”: “/c2f+fyhiI0SI8fBqGft54pEmcRPoBpF6v80pZHTCZs=”
}
}
}’

x509PublicKey is optional here.

@IntegrationSupport

@Sachin

We tried with the date format you specified but, getting an error ‘Date Range given is invalid’.

Health Info Request

Url= https://dev.abdm.gov.in/gateway/v0.5/health-information/cm/request

Request

{“requestId”:“7c40689f-4a98-4e4a-bd54-fff30f960a18”,“timestamp”:“2024-01-30T12:11:54.4878672”,“hiRequest”:{“consent”:{“id”:“e7a56692-00d7-4a14-9900-69406c59a389”},“dateRange”:{“from”:“2024-01-02T14:30:29.592Z”,“to”:“2024-01-28T14:30:29.592Z”},“dataPushUrl”:“https://medbot.demoap.com/api/Webhook/ReceiveMedBotWebhookRawData/data/push",“keyMaterial”:{“cryptoAlg”:“ECDH”,“curve”:“Curve25519”,“dhPublicKey”:{“expiry”:“2024-02-20T14:30:29.592Z”,“parameters”:"Curve25519/32byte random key”,“keyValue”:“BFTahuFVsPMzbUpo3iM0CSGWZ/B5pJRgEBwjahG11p+/TJBWI8E+9AW1eKDYKn/LF5G6SzqDIXfV+8Ajm78nWP0=”},“nonce”:“xN6UVwDo704xjVMEZi8PnzE3MDQ3ODQyMjU=”}}}

On request call back

{
“requestId”: “6690399c-ce53-4b57-b7df-08128c563713”,
“timestamp”: “2024-01-30T12:11:53.806108”,
“hiRequest”: null,
“error”: {
“code”: 1418,
“message”: “Date Range given is invalid”
},
“resp”: {
“requestId”: “7c40689f-4a98-4e4a-bd54-fff30f960a18”
}
}