Unable to create Health facility with v1.5/facility/basic-information

Greetings,

We’re currently unable to find why our API requests to v1.5/facility/basic-information are failing by always returning status code 400. Please help us resolve this issue:

CURL:
curl --location --request POST ‘https://facilitysbx.ndhm.gov.in/v1.5/facility/basic-information’ \

–header ‘Accept: application/json’ \

–header ‘Content-Type: application/json’ \

–header ‘Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJBbFJiNVdDbThUbTlFSl9JZk85ejA2ajlvQ3Y1MXBLS0ZrbkdiX1RCdkswIn0.eyJleHAiOjE2NTQ2Njk1OTMsImlhdCI6MTY1NDY2ODk5MywianRpIjoiMTRmN2I3ZGEtN2VlYy00ZDU5LTk0ZGQtMGNlNDk4ZjZkODFiIiwiaXNzIjoiaHR0cHM6Ly9kZXYubmRobS5nb3YuaW4vYXV0aC9yZWFsbXMvY2VudHJhbC1yZWdpc3RyeSIsImF1ZCI6ImFjY291bnQiLCJzdWIiOiIxZjQ0ODUyYy04N2ZlLTQ1MjgtYWUzMC02ZmRhYjYwNTZiZDgiLCJ0eXAiOiJCZWFyZXIiLCJhenAiOiJTQlhfMDAxNTk1Iiwic2Vzc2lvbl9zdGF0ZSI6IjlmNDI2MmM5LTViNTMtNGIyMy1iNTJjLTdiNTY1MTYxM2QyMCIsImFjciI6IjEiLCJhbGxvd2VkLW9yaWdpbnMiOlsiaHR0cDovL2xvY2FsaG9zdDo5MDA3Il0sInJlYWxtX2FjY2VzcyI6eyJyb2xlcyI6WyJIaWRJbnRlZ3JhdGVkUHJvZ3JhbSIsImhpdSIsIm9mZmxpbmVfYWNjZXNzIiwiaGVhbHRoSWQiLCJwaHIiLCJPSURDIiwiaGVhbHRoX2xvY2tlciIsImhpcCIsImhwX2lkIl19LCJyZXNvdXJjZV9hY2Nlc3MiOnsiU0JYXzAwMTU5NSI6eyJyb2xlcyI6WyJ1bWFfcHJvdGVjdGlvbiJdfSwiYWNjb3VudCI6eyJyb2xlcyI6WyJtYW5hZ2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jdblOGbIiVTRiCHqcWFhp1psLUSS5fKO9KX4gUqu2Np3RLNcq652QPcy0ecLZW_UxvrmF-NBLc3X3k0rGr5gYDtzPC9linoEFB2yz0qdUs1oCC6imqxHI-UbT1k4lgpxgA_ojFucPgQ4DuLhRE_Sc7z4mp-2H08sPOJOmig5sSXt05Nzw’ \

–header ‘Cookie: JSESSIONID=29EABEA0B2F1275A13E5521BE7C6E3F6; JSESSIONID=29EABEA0B2F1275A13E5521BE7C6E3F6; TS01b6eee2=01115a1c9014e8ab6c2f53e6b0c4a9c8683b81ff7b89c96a7e88e081565ecc835e329871acef7cb628f1b8e5e0e94f87d10679ba743c2746af56cf8dbc1d6ed9d52f054c08’ \

–data-raw '{

"facilityName": "testing-hfr",

"ownershipCode": "P",

"stateLGDCode": "568",

"address": "No. 326, Baba nagar, Villivakkam",

"pincode": "600049",

"lattitude": "88.0002",

"longitude": "82.003"

}’

@Govind_Deshmukh Kindly Check

Hey @Haripriya,

Apparently @Govind_Deshmukh is occupied. Can we have someone else assigned to this issue?

Hi @Hari,
Please need to be check with @srinivas.t and Team.

Thanks,
Govind D.

@VSrinivas Check this issue

@Haripriya,please assign this to someone from HFR team.
It is not HID issue.

Update:

After some debugging, the current response is 500.

CURL:

curl -X POST
https://facilitysbx.abdm.gov.in/v1.5/facility/basic-information
–header ‘User-Agent: Thunder Client (https://www.thunderclient.com)’
–header ‘Accept: application/json’
–header ‘x-hprid-auth: eyJhbGciOiJSUzUxMiJ9.eyJzdWIiOiI1Ni0yMjcxLTcyMzQtMDEzNyIsImhwcklkTnVtYmVyIjoiNTYtMjI3MS03MjM0LTAxMzciLCJtb2JpbGUiOiI3NTUwMTc1MjM0IiwiaHBySWQiOiJkZXYubmludG8uaGZyQGhwci5uZGhtIiwiZXhwIjoxNjU0ODU1ODcxLCJpYXQiOjE2NTQ4NTQwNzF9.lTBlR6UYUNWWXZuAxUgIg7fZ6sWGmfu4EKtlUz3BpKowLWX93fnUXAsRYh65-lCUcTCL5huMC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jZV9hY2Nlc3MiOnsiU0JYXzAwMTU5NSI6eyJyb2xlcyI6WyJ1bWFfcHJvdGVjdGlvbiJdfSwiYWNjb3VudCI6eyJyb2xlcyI6WyJtYW5hZ2UtYWNjb3VudCIsIm1hbmFnZS1hY2NvdW50LWxpbmtzIiwidmlldy1wcm9maWxlIl19fSwic2NvcGUiOiJvcGVuaWQgZW1haWwgcHJvZmlsZSIsImNsaWVudElkIjoiU0JYXzAwMTU5NSIsImNsaWVudEhvc3QiOiIxMC4yMzMuNjguODUiLCJlbWFpbF92ZXJpZmllZCI6ZmFsc2UsInByZWZlcnJlZF91c2VybmFtZSI6InNlcnZpY2UtYWNjb3VudC1zYnhfMDAxNTk1IiwiY2xpZW50QWRkcmVzcyI6IjEwLjIzMy42OC44NSJ9.iwYq31O6mzwuD_xnv_AlnNQFyJKr3KeStC4qjmkVNx3Q_djHiAZlTwTs9LEP8FeDALxeRc239J4yI_UuHPnWmYumo_EBWypDh49p_P9yRf3YGpPY7EiBRlzl1MXKOj1Lj9P57Z5D2W1bKdDbmH8calEgmvBb1w6j45cksDA4UL5To1zuVlEgeyqB2ammohXFl0coLegaXpwN1xqduktSsbvyxrUJDGpKJ5dysZGpwdx0t8KiqQWTghen85heAZKVnoRNR6lvkZmY9bzStcfvFzgxiM1j2H9G2sadllTYsIRWVDztFha2aAYLgR9_IaicksBeEl5L1xtmqP6_ihTSEg’
–data-raw ‘{
“trackingId”: “string”,
“facilityInformation”: {
“facilityName”: “surya clinic”,
“ownershipCode”: “G”,
“ownershipSubTypeCode”: “S”,
“facilityAddressDetails”: {
“stateLGDCode”: “33”,
“districtLGDCode”: “568”,
“subDistrictLGDCode”: “5700”,
“country”: “India”,
“addressLine1”: “Address One”,
“pincode”: “600123”,
“latitude”: “12.3900”,
“longitude”: “12.4252”
},
“facilityContactInformation”: {
“facilityContactNumber”: “string”,
“facilityEmailId”: “string”,
“facilityLandlineNumber”: “string”,
“facilityStdCode”: “string”,
“websiteLink”: “string”
},
“systemOfMedicineCode”: “M,D,H”,
“facilityTypeCode”: “39”,
“facilitySubType”: “41”,
“specialityTypeCode”: “SINGLE”,
“typeOfServiceCode”: “OPD”,
“facilityOperationalStatus”: “F”,
“facilityUploads”: {
“facilityBoardPhoto”: {
“name”: “string”,
“value”: “string”
},
“facilityBuildingPhoto”: {
“name”: “string”,
“value”: “string”
}
},
“facilityAddressProof”: [
{
“addressProofType”: “string”,
“addressProofAttachment”: {
“name”: “string”,
“value”: “string”
}
}
],
“timingsOfFacility”: [
{
“workingDays”: “MON”,
“openingHours”: “10:00 am - 9:00 pm”
}
],
“abdmCompliantSoftware”: [
{
“anyOther”: “test”
}
]
}
}’

@Ramandeep1 @Haripriya Any updates?

@selvaganesh Kindly check

@Hari Please provide the proper body tags in response body. From you request body, some tags are missing(like ownershipSubTypeCode2). Please find the attached sample code.{
“trackingId”: “”,
“facilityInformation”: {
“facilityName”: “gbn5hy”,
“ownershipCode”: “G”,
“ownershipSubTypeCode”: “C”,
“ownershipSubTypeCode2”: “MOA”,
“facilityAddressDetails”: {
“country”: “India”,
“stateLGDCode”: “10”,
“districtLGDCode”: “189”,
“subDistrictLGDCode”: “1477”,
“facilityRegion”: “”,
“villageCityTownLGDCode”: “”,
“addressLine1”: “Sai Ganesh Pune”,
“addressLine2”: “”,
“pincode”: “415001”,
“latitude”: “18.539053”,
“longitude”: “73.873137”
},
“facilityContactInformation”: {
“facilityContactNumber”: “”,
“facilityEmailId”: “”,
“facilityLandlineNumber”: “”,
“facilityStdCode”: “”,
“websiteLink”: “”
},
“systemOfMedicineCode”: “M”,
“facilityTypeCode”: “9”,
“facilitySubType”: “”,
“specialityTypeCode”: “”,
“typeOfServiceCode”: “”,
“facilityOperationalStatus”: “F”,
“facilityUploads”: {
“facilityBuildingPhoto”: {
“name”: “”,
“value”: “”
},
“facilityBoardPhoto”: {
“name”: “”,
“value”: “”
}
},
“facilityAddressProof”: [
{
“addressProofType”: null,
“addressProofAttachment”: {
“name”: “”,
“value”: “”
}
}
],
“timingsOfFacility”: [
{
“workingDays”: “mon”,
“openingHours”: “10:00 AM - 1:00 PM”
},
{
“workingDays”: “tue”,
“openingHours”: “11:00 AM - 1:00 PM”
},
{
“workingDays”: “wed”,
“openingHours”: “12:00 AM - 1:00 PM”
}
],
“abdmCompliantSoftware”: [
{
“existingSoftwares”: [],
“anyOther”: “india.com
}
]
}
}

Still facing the Same Issue can some body post the sample json for creating HFR using basic registration API as in my case it is throwing abdm compliant software Issue as I don’t what to put in that mandatory field.


Any One know how to register HFR resource to the Server Please tell and also paste the WORKING JSON

here is my curl request :
curl -X POST “https://facilitysbx.abdm.gov.in/v1.5/facility/basic-information” -H “accept: application/json” -H “Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJBbFJiNVdDbThUbTlFSl9JZk85ejA2ajlvQ3Y1MXBLS0ZrbkdiX1RCdkswIn0.eyJleHAiOjE2Njc4MjQ1OTMsImlhdCI6MTY2NzgyMzk5MywianRpIjoiY2JkYmFiMzItMzM2YS00ZGIwLThkMDQtMTM5ZDZlNzFmMjEyIiwiaXNzIjoiaHR0cHM6Ly9kZXYubmRobS5nb3YuaW4vYXV0aC9yZWFsbXMvY2VudHJhbC1yZWdpc3RyeSIsImF1ZCI6ImFjY291bnQiLCJzdWIiOiI4OGMyMDlmZC01N2ZmLTRmODgtYTY5Mi03ZGM0NjRiOWU3NjkiLCJ0eXAiOiJCZWFyZXIiLCJhenAiOiJWT0xMT01PTkRfNDI2ODI5Iiwic2Vzc2lvbl9zdGF0ZSI6IjY1ZmJkMmQ1LWNhMzctNDVjYy1hOTA0LTQ3ZGY3NDk5YjI5NSIsImFjciI6IjEiLCJhbGxvd2VkLW9yaWdpbnMiOlsiaHR0cDovL2xvY2FsaG9zdDo5MDA3Il0sInJlYWxtX2FjY2VzcyI6eyJyb2xlcyI6WyJoZnIiLCJoaXUiLCJIZWFsdGhJRF9DcmVhdGUiLCJvZmZsaW5lX2FjY2VzcyIsIm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CI6MTY2NzgyNDUxMH0.RfoIh4TDhQurqekbDb-u-vcjzrnNdEN6GfAlWAsYlc61w5923PpYU5PHkSIWrHvn8u3NwKabb9R7sXoAtBi8g6lPmUotUnFnOSzovoRcIQJXGJ_uJ18NA69zJFKMRWdzOAjcF1h8bEnyl32isHBqxF0yrL71tzDzqYlJcoCG3UROIF2_qsoOySslPv8WxW45jAJ0T8u9HWol0Na6JtFO_jEfc8a94jOEDx5X1PYSHSxOQyqITajIq1jaZLqzUJoidec7abX7TY1lhnrH-kX67ehCmvVRYftIDxTFwSZaXmX9dchIG0sFSL5IZMvzTn7O4_AbxMMCvMKYR-Mo5Ich7g” -H “Content-Type: application/json” -d “{“trackingId”: “”,“facilityInformation”: {“facilityName”: “gbn5hy”,“ownershipCode”: “G”,“ownershipSubTypeCode”: “C”,“ownershipSubTypeCode2”: “MOA”,“facilityAddressDetails”: {“country”: “India”,“stateLGDCode”: “10”,“districtLGDCode”: “189”,“subDistrictLGDCode”: “1477”,“facilityRegion”: “”,“villageCityTownLGDCode”: “”,“addressLine1”: “Sai Ganesh Pune”,“addressLine2”: “”,“pincode”: “415001”,“latitude”: “18.539053”,“longitude”: “73.873137”},“facilityContactInformation”: {“facilityContactNumber”: “”,“facilityEmailId”: “”,“facilityLandlineNumber”: “”,“facilityStdCode”: “”,“websiteLink”: “”},“systemOfMedicineCode”: “M”,“facilityTypeCode”: “9”,“facilitySubType”: “”,“specialityTypeCode”: “”,“typeOfServiceCode”: “”,“facilityOperationalStatus”: “F”,“facilityUploads”: {“facilityBuildingPhoto”: {“name”: “”,“value”: “”},“facilityBoardPhoto”: {“name”: “”,“value”: “”}},“facilityAddressProof”: [{“addressProofType”: null,“addressProofAttachment”: {“name”: “”,“value”: “”}}],“timingsOfFacility”: [{“workingDays”: “mon”,“openingHours”: “10:00 AM - 1:00 PM”},{“workingDays”: “tue”,“openingHours”: “11:00 AM - 1:00 PM”},{“workingDays”: “wed”,“openingHours”: “12:00 AM - 1:00 PM”}],“abdmCompliantSoftware”: [{“existingSoftwares”: [],“anyOther”: “india.com 4”}]}}}”

What is x-hprid-auth in this API “basic-information” ?

Which token is passed as x-hprid-auth?