Skip to content

Latest commit

 

History

History
40 lines (27 loc) · 1.33 KB

get_offered_resource_granted.md

File metadata and controls

40 lines (27 loc) · 1.33 KB

Get offered resource after access is granted

When you have finished negotiation, you can query for resource again to see if we get artifact data.

Postman collection will preset required fields from previous request.

Multipart Form - Artifact Request Message
curl --location -k --request POST 'http://localhost:8184/proxy' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic aWRzVXNlcjpwYXNzd29yZA==' \
--data-raw '{
    "multipart": "form",
    "Forward-To": "http://ecc-provider:8889/data",
    "messageType":"ArtifactRequestMessage",
    "requestedArtifact": "{{contract_artifact}}",
    "transferContract": "{{transfer_contract}}",
    "payload" : ""
}'

If you have done everything correctly, you should get response with requested artifact, like in our example. Expected response is json document containing information about requested resource.

Artifact Request Message - Example response

{"firstName":"John","lastName":"Doe","address":"591  Franklin Street, Pennsylvania","checksum":"ABC123 2023/06/27 12:26:08","dateOfBirth":"2023/06/27 12:26:08"}

The appeariance of "John Doe" signifies the successful exchange with this contract.