Not getting response of Auto Approve Policy

Hello @IntegrationSupport,

When we send this request, it always responding Token Verification failed. You can see the CURL for reference

curl --location ‘https://dev.abdm.gov.in/cm/consents/auto-approve
–header ‘accept: application/json’
–header ‘X-AUTH-TOKEN: eyJhbGciOiJSUzUxMiJ9.eyJwaW5jb2RlIjpudWxsLCJzdWIiOiJoaW1hbnNodTQ1NEBzYngiLCJjbGllbnRJZCI6IlBIUi1XRUIiLCJyZXF1ZXN0ZXJJZCI6IlBIUi1XRUIiLCJnZW5kZXIiOiJNIiwiZGlzdHJpY3ROYW1lIjoiR0hBWklBQkFEIiwibW9iaWxlIjoiOTk1MzQ4MDkzNiIsImZ1bGxOYW1lIjoiSGltYW5zaHUgU2luZ2giLCJhZGRyZXNzTGluZSI6IkMvTyBCYWx3YW50IFNpbmdoIEFsbWl5YSBNLTY1LUIgU2FuamF5IE5hZ2FyIFNlY3Rvci0yMyBHaGF6aWFiYWQiLCJoZWFsdGhJZE51bWJlciI6bnVsbCwibW9udGhPZkJpcnRoIjoiMiIsInN5c3RlbSI6IkFCSEEtQSIsInN0YXRlTmFtZSI6IlVUVEFSIFBSQURFU0giLCJkYXlPZkJpcnRoIjoiNSIsInBock1vYmlsZSI6Ijk5NTM0ODA5MzYiLCJleHAiOjE2ODY2NjkyNDMsImlhdCI6MTY4NjY2MjA0MywicGhyQWRkcmVzcyI6ImhpbWFuc2h1NDU0QHNieCIsImVtYWlsIjpudWxsLCJ0eG5JZCI6IjU2MzMzNWM5LTgwMTYtNDBjMy05NTIxLWExM2MxNjQ3OWJmOSIsInllYXJPZkJpcnRoIjoiMTk5NiJ9.Q_8ufRvXeL6uEaSC3cdWT8YFRu53qUhysZ_ztrAoXJwtWkuomdq4bvk8rLjKUYIqTbwbBkfFgFBhBKAA1NpHcsYkaenH7TFkUxU18CYs64NHDG0Phgl0PMAf8S3sz_K8zTNggIDLVXwN43IF4CmdjBUx2btocaTb9RUruVlrALn9MwwKHkKG476JmRrqz-rWzr2Vgt6Z3RppZAfDTzwMl0kMnqYNQwvdm8yZeUtIDWvm7NJchB9t1YT7Yg1_Aya4bfe8sfVkQiA1LihEwiTrsMA1lWn8ggKFdoffMKuZv1vPTbjpEqf9KaWCXqxQsg2sQI0aewfcTypQE94c2ClS4w’
–header ‘Content-Type: application/json’
–header ‘Cookie: TS011c04bd=01445fed0485fe746a7427f38adb5b9d314a77ece5ef8e05c8ee4f33972405f43e4a0e06008c0c7dcc23f70975b349528ea70e4240’
–data ‘{
“isApplicableForAllHIPs”: true,
“hiu”: {
“id”: “Yore_Locker_HIU”,
“name”: “YoreCare Locker HIU Facility”
},
“includedSources”: [
{
“hiTypes”: [
“DiagnosticReport”,
“Prescription”,
“ImmunizationRecord”,
“DischargeSummary”,
“OPConsultation”,
“HealthDocumentRecord”,
“WellnessRecord”
],
“purpose”: {
“code”: “PATRQT”,
“text”: “Self Requested”
},
“hip”: {
“id”: “Yore_Locker_HIP”,
“name”: “YoreCare Locker HIP Facility”
},
“period”: {
“from”: “2023-06-13T13:19:16.464Z”,
“to”: “2025-06-13T13:09:14.513Z”
}
}
],
“excludedSources”: [
{
“hiTypes”: [
“Prescription”
],
“purpose”: {
“code”: “PATRQT”,
“text”: “Self Requested”
},
“hip”: {
“id”: “Yore_Locker_HIP”,
“name”: “YoreCare Locker HIP Facility”
}
}
]
}’

Response
{
“error”: {
“code”: 1401,
“message”: “Token verification failed”
}
}

Kindly help with it.

Regards,
Himanshu Singh

@himanshu0502 For Autoapproving consents, Scope should be consent.autoapprove in verify-pin request payload

then,

Note :-
Scope :
–> consentrequest.approve for Grant Consent
–> consent.revoke for Revoke Consent
–> profile.changepin for Change PIN
–> consent.autoaprove for Autoapprove all consents for HIU

Thanks

But in the sandbox, you mentioned this payload

@IntegrationSupport, but you mentioned this payload in the sandbox