Send Presentation request
As a relying party (e.g Verifier), you want to validate user or company attestations. The verifier needs to initiate de communication by sending a presentation request.
From the Verifier wallet
In this example, you will request a presentation of the attestation you created previously
Create a new request with the Method POST and the value {{base_URL}}/presentations/send-request
Rename this request "Send presentation request"
Select the tab
Body
, then selectraw
and copy/paste this json request (replace the connectionId by the Id you received in the webhook):
{
"connectionId": "0f42f1da-ab2d-41da-91e1-167c31d966a9",
"attributes": {
"type": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Test Attestation publique XXX:1.0"
},
"size": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Test Attestation publique XXX:1.0"
},
"price": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Test Attestation publique XXX:1.0"
}
},
"predicates": {}
}
Save the request and click
SEND
you will get a response "Status 204 No Content"
at the same time, you will receive a webhook
{
"event": "PRESENTATION_REQUEST_SENT",
"connectionId": "988f8949-ef29-4701-9e56-748a4da2ab63",
"presentationId": "482ba620-e406-4af2-b4e4-368c1a8db0c4"
}
curl -X 'POST' \
'https://connect-api.sandbox.archipels.io/presentations/send-request' \
-H 'accept: */*' \
-H 'Authorization: Bearer EROGEDSORGgogroefvooedrgGREIGERigIgrOQZEPG=' \
-H 'Content-Type: application/json' \
-d '{
"connectionId": "bcef7121-016c-4945-ba86-f3a8afeeee52",
"attributes": {
"type": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Attestation de Test non publique:1.0"
},
"size": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Attestation de Test non publique:1.0"
},
"price": {
"schemaId": "1uYeHCcPjzRVGFQcFPMsg:2:Attestation de Test non publique:1.0"
}
},
"predicates": {}
}'
Dernière mise à jour
Cet article vous a-t-il été utile ?