API for registering and managing HTTP webhooks and subscriptions.
- Update subscription with specific IDs
Webhook API - v1beta1 (v1beta1)
https://global.api.greenlake.hpe.com/
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/event/public/openapi/webhook-v1beta1/webhook-v1beta1-nbapi/
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/event/public/openapi/webhook-v1beta1/webhook-v1beta1-nbapi/events/v1beta1/subscriptions
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X POST \
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '[
{
"eventType": "com.hpe.greenlake.sample-publisher.v1beta1.sample-event1",
"webhook": {
"resourceUri": "/events/v1beta1/webhooks/123e4567-e89b-12d3-a456-426614174000"
}
}
]'[ { "id": "0908777a-788f-45da-afb8-295c626e4d14", "type": "events/subscription", "serviceManager": "00000000-0000-0000-0000-000000000000", "apiGroup": "Sample Publisher", "eventType": "com.hpe.greenlake.sample-publisher.v1beta1.sample-event1", "friendlyName": "Sample Event", "description": "Custom Role Created", "resourceUri": "/events/v1beta1/subscriptions/3fa85f64-5717-4562-b3fc-2c963f66afa6", "webhook": { … }, "hpePrincipal": "user:<opaque-global-id>", "createdBy": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedBy": "string", "updatedAt": "2019-08-24T14:15:22Z", "generation": 1, "eventFilter": "createdAt lt 2021-05-12T07:20:00.00Z" } ]
Filter subscriptions events using an OData V4 formatted filter string.
Returns subscriptions for a user within a particular webhook.
Specifies the number of results to be returned. The default value is 10.
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/event/public/openapi/webhook-v1beta1/webhook-v1beta1-nbapi/events/v1beta1/subscriptions
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X GET \
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Subscriptions retrieved successfully.
An array of subscription objects, each representing a unique subscription.
Monotonically increasing update counter to track the subscription version.
The number of subscription objects returned in the items array for the current request.
The zero-based index in the complete list of retrieved subscriptions that marks the beginning of the response.
{ "items": [ { … } ], "count": 0, "offset": 0, "total": 0 }
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/event/public/openapi/webhook-v1beta1/webhook-v1beta1-nbapi/events/v1beta1/subscriptions
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X DELETE \
'https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions?id=id%3D0908777a-788f-45da-afb8-295c626e4d14' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions
- Mock server
https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/event/public/openapi/webhook-v1beta1/webhook-v1beta1-nbapi/events/v1beta1/subscriptions
- curl
- JavaScript
- Node.js
- Python
- Java
- Go
- C#
- PHP
curl -i -X PATCH \
https://global.api.greenlake.hpe.com/events/v1beta1/subscriptions \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/merge-patch+json' \
-d '[
{
"subscriptionId": "string",
"eventType": "com.hpe.greenlake.sample-publisher.v1beta1.sample-event1",
"webhook": {
"resourceUri": "/events/v1beta1/webhooks/123e4567-e89b-12d3-a456-426614174000"
}
}
]'[ { "id": "0908777a-788f-45da-afb8-295c626e4d14", "type": "events/subscription", "serviceManager": "00000000-0000-0000-0000-000000000000", "apiGroup": "Sample Publisher", "eventType": "com.hpe.greenlake.sample-publisher.v1beta1.sample-event1", "friendlyName": "Sample Event", "description": "Custom Role Created", "resourceUri": "/events/v1beta1/subscriptions/3fa85f64-5717-4562-b3fc-2c963f66afa6", "webhook": { … }, "hpePrincipal": "user:<opaque-global-id>", "createdBy": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedBy": "string", "updatedAt": "2019-08-24T14:15:22Z", "generation": 1, "eventFilter": "createdAt lt 2021-05-12T07:20:00.00Z" } ]