List all subscriptions for this user
GET
/subscriptionsAuthorization
AuthorizationBearer token (JWT) · headerrequiredResponses
200Subscriptions found
Array of
subscriptionResponsetypestringrequiredAllowed:
PUBSUBmethodstringrequiredAllowed:
PUSHnamestringrequiredID of the subscription to be referenced in API calls
pathstringrequiredPath of subscription in project
topicobjectrequiredShow propertiesHide properties
idstringrequirednamestringrequiredpathstringrequiredackDeadlineSecondsintegerrequiredmin -9007199254740991 · max 9007199254740991
retryPolicystring | nullserviceAccountstringrequiredurlstringrequiredPublicly accessible URL that should receive the events
contactstringrequiredEmail address to be contacted in case of problems with this subscription
institutionIdstringrequiredID of the institution the current user belongs to
401Missing authentication
messagestringrequirederrorsopenApiErrorItem[]requiredmin items 1
Show propertiesHide properties
Array of
openApiErrorItempathstringrequiredmessagestringrequirederrorCodestringrequiredtracestring | nullrequireddeprecatedAlways null. Deprecated; may be removed in a future release.
403Invalid authorization
messagestringrequirederrorsopenApiErrorItem[]requiredmin items 1
Show propertiesHide properties
Array of
openApiErrorItempathstringrequiredmessagestringrequirederrorCodestringrequiredtracestring | nullrequireddeprecatedAlways null. Deprecated; may be removed in a future release.
500Internal server error
messagestringrequiredtracestring | nullrequireddeprecatedAlways null. Deprecated; may be removed in a future release.
Request
curl -X GET "/subscriptions" \
-H "Authorization: Bearer YOUR_TOKEN"const response = await fetch("/subscriptions", {
method: "GET",
headers: {
"Authorization": "Bearer YOUR_TOKEN"
}
});Response
[
{
"type": "PUBSUB",
"method": "PUSH",
"name": "de.ard.eventhub.subscription.subscription-id",
"path": "projects/ard-eventhub/subscriptions/subscription-name",
"topic": {
"id": "urn:ard:permanent-livestream:topic-id",
"name": "de.ard.eventhub.dev.urn%3Aard%3Apermanent-livestream%3Atopic-id",
"path": "projects/ard-eventhub/topics/topic-name"
},
"ackDeadlineSeconds": 20,
"retryPolicy": null,
"serviceAccount": "name-of-service-account",
"url": "https://example.com/my/webhook/for/this/subscription",
"contact": "my-emergency-and-notifications-contact@ard.de",
"institutionId": "urn:ard:institution:institution-id"
}
]{
"message": "request.headers should have required property 'Authorization'",
"errors": [
{
"path": "string",
"message": "string",
"errorCode": "string"
}
],
"trace": null
}{
"message": "user is missing required permission",
"errors": [
{
"path": "string",
"message": "string",
"errorCode": "string"
}
],
"trace": null
}{
"message": "Internal Server Error",
"trace": null
}