Create data agreement
POST {{cloudagent}}/v1/data-agreements?draft=false
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
draft | boolean | Draft or not | |
existing_schema_id | string | Existing schema identifier |
Request Body
{"@context"=>"https://raw.githubusercontent.com/decentralised-dataexchange/automated-data-agreements/main/interface-specs/data-agreement-schema/v1/data-agreement-schema-context.jsonld", "data_controller_name"=>"The Retail Company (Germany)", "data_controller_url"=>"https://igrant.io/policy.html", "data_policy"=>{"data_retention_period"=>6, "geographic_restriction"=>"Europe", "industry_sector"=>"Retail", "jurisdiction"=>"London, GB", "policy_URL"=>"https://igrant.io/policy_default.html", "storage_location"=>"Europe"}, "dpia"=>{"dpia_date"=>"2023-04-21T06:42:14.703+00:00", "dpia_summary_url"=>"https://privacyant.se/dpia_results.html"}, "lawful_basis"=>"consent", "method_of_use"=>"data-using-service", "personal_data"=>[{"restrictions"=>[{"schema_id"=>"RvdgpPhwrvwPouuX5kJmL2:2:Marketing and campaign:1.0.0", "cred_def_id"=>"RvdgpPhwrvwPouuX5kJmL2:3:CL:200:default"}], "attribute_name"=>"Customer name", "attribute_description"=>"Customer name"}], "purpose"=>"Verify marketing and campaign", "purpose_description"=>"Verify marketing and campaign"}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: Created
{"data_agreement_id":"3e794d2d-8ef2-4c21-bada-b8ee1fbf7db7","state":"PREPARATION","method_of_use":"data-using-service","data_agreement":{"@context":"https://raw.githubusercontent.com/decentralised-dataexchange/automated-data-agreements/main/interface-specs/data-agreement-schema/v1/data-agreement-schema-context.jsonld","template_id":"3e794d2d-8ef2-4c21-bada-b8ee1fbf7db7","template_version":1,"data_controller_name":"The Retail Company (Germany)","data_controller_url":"https://igrant.io/policy.html","purpose":"Verify marketing and campaign","purpose_description":"Verify marketing and campaign","lawful_basis":"consent","method_of_use":"data-using-service","data_policy":{"data_retention_period":6,"policy_URL":"https://igrant.io/policy_default.html","jurisdiction":"London, GB","industry_sector":"Retail","geographic_restriction":"Europe","storage_location":"Europe"},"personal_data":[{"attribute_id":"03781ec0-3b4f-4922-ac24-6af2ec4a433d","attribute_name":"Customer name","attribute_description":"Customer name"}],"dpia":{"dpia_date":"2023-04-21T06:42:14.703+00:00","dpia_summary_url":"https://privacyant.se/dpia_results.html"}},"publish_flag":true,"delete_flag":false,"schema_id":null,"cred_def_id":null,"presentation_request":{"name":"Verify marketing and campaign","comment":"Verify marketing and campaign","version":"1.0.0","requested_attributes":{"additionalProp1":{"name":"Customer name","restrictions":[{"schema_id":"RvdgpPhwrvwPouuX5kJmL2:2:Marketing and campaign:1.0.0","cred_def_id":"RvdgpPhwrvwPouuX5kJmL2:3:CL:200:default"}]}},"requested_predicates":{}},"is_existing_schema":false,"created_at":1682059372,"updated_at":1682059372}