Request a new negotiation
POST/api/negotiations/request
Request a new negotiation
Request
- application/json
Bodyrequired
@typestringrequired
Example:
dspace:ContractRequestMessage
dspace:consumerPidstringrequired
Example:
urn:example:consumerPid
dspace:providerPidstring
Example:
urn:example:providerPid
dspace:callbackAddressstringrequired
Example:
http://example.com/callback
dspace:offer object
Responses
- 201
- application/json
- Schema
- Example (auto)
Schema
@idstringrequired
Example:
3f2592da-ffc9-40cb-a336-a9daa9343ce8
@typestringrequired
Example:
dspace:ContractNegotiation
dspace:consumerPidstringrequired
Example:
urn:example:consumerPid
dspace:providerPidstringrequired
Example:
urn:example:providerPid
dspace:statestringrequired
Example:
REQUESTED
{
"@id": "3f2592da-ffc9-40cb-a336-a9daa9343ce8",
"@type": "dspace:ContractNegotiation",
"dspace:consumerPid": "urn:example:consumerPid",
"dspace:providerPid": "urn:example:providerPid",
"dspace:state": "REQUESTED"
}
Authorization: http
name: bearertype: httpscheme: bearerbearerFormat: VPdescription: Verifiable Presentation needed to communicate between two instances of the control plane.
- curl
- http
- CURL
curl -L 'https://tsg.dataspac.es/api/negotiations/request' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <token>' \
--data-raw '{
"@type": "dspace:ContractRequestMessage",
"dspace:consumerPid": "urn:example:consumerPid",
"dspace:providerPid": "urn:example:providerPid",
"dspace:callbackAddress": "http://example.com/callback",
"dspace:offer": {
"@type": "odrl:Offer",
"odrl:assigner": "urn:example:assigner"
}
}'