Creates a new subscription for a data service consumer at a data service provider. This method results in a subscription with status
set to active
. (see Lifecycle of a Subscription for more information)
Excerpt |
---|
|
Panel |
---|
panelIconId | 2705 |
---|
panelIcon | :white_check_mark: |
---|
panelIconText | ✅ |
---|
bgColor | #FFF0B3 |
---|
| DSGO.Basis : Data service providers MUST support a POST call to a /subscriptions endpoint to create a new subscription
|
|
...
The data service provider is responsible for determining a suitable authorisation policy for their subscriptions resources. See Autorisatie for more information.
...
For information about the parameters that are common to the trust framework’s API’s see Generic API Requirements, and for parameters common to all subscriptions methods, see /subscriptions. The HTTP body must contain a subscription resource, in accordance to the subscription as defined by the data service provider.
Excerpt |
---|
|
Panel |
---|
panelIconId | 2705 |
---|
panelIcon | :white_check_mark: |
---|
panelIconText | ✅ |
---|
bgColor | #FFF0B3 |
---|
| DSGO.Basis : Data service providers MUST validate that the HTTP body of a POST request to a /subscriptions endpoint contains the following parameters, with content as defined in the subscription resource:
resource_type
start_date (optional)
end_date (optional)
event_type
webhook_url
|
Panel |
---|
panelIconId | 2705 |
---|
panelIcon | :white_check_mark: |
---|
panelIconText | ✅ |
---|
bgColor | #FFF0B3 |
---|
| DSGO.Basis : Data service providers MUST validate that a POST request to /subscriptions endpoint complies with their data service specific subscription requirements
|
|
...
Excerpt |
---|
|
Panel |
---|
panelIconId | 2705 |
---|
panelIcon | :white_check_mark: |
---|
panelIconText | ✅ |
---|
bgColor | #FFF0B3 |
---|
| DSGO.Basis : Data service providers MUST respond with a 201 Created to a successful POST call to a /subscriptions endpoint
|
Panel |
---|
panelIconId | 2705 |
---|
panelIcon | :white_check_mark: |
---|
panelIconText | ✅ |
---|
bgColor | #FFF0B3 |
---|
| DSGO.Basis : Data service providers MUST include the created subscription resource in the HTTP body of the response to a successful POST call to the /subscriptions endpoint
|
|
Expand |
---|
title | Example response body for a succesful POST /subscriptions call |
---|
|
Code Block |
---|
| {
"id": "sub_123",
"resource_type": "subscription",
"href": "/subscriptions/sub_123",
"created_date": "2022-09-21T10:23:37Z1663752217",
"start_date": "2022-09-21T23:59:59Z1663801199",
"end_date": "2023-09-21T23:59:59Z1663801199",
"consumer_id": "EU.EORI.NL000123456",
"provider_id": "EU.EORI.NL000345678",
"description": "detailed description of the subscription",
"event_type": ["Modified"],
"status": "active",
"webhook_url": "https://example.com/notifications"
} |
|
...