Create Event Subscription
Create an Event Subscription.
Request
POST /event_subscriptions
Example Request
Parameters
Name | Type | Description |
---|
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSourceReplace | Sources containing the types for which this event subscription will trigger |
destination_ids | List<string> | A list of Event Destination IDs which should be used for this Event Subscription. |
EventSourceReplace parameters
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
Response
Returns a 201 response on success
Example Response
Fields
Name | Type | Description |
---|
id | string | Unique identifier for this Event Subscription. |
uri | string | URI of the Event Subscription API resource. |
created_at | string | When the Event Subscription was created (RFC 3339 format). |
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSource | Sources containing the types for which this event subscription will trigger |
destinations | Ref | Destinations to which these events will be sent |
EventSource fields
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
uri | string | URI of the Event Source API resource. |
Ref fields
Name | Type | Description |
---|
id | string | a resource identifier |
uri | string | a uri for locating a resource |
Delete Event Subscription
Delete an Event Subscription.
Request
DELETE /event_subscriptions/{id}
Example Request
Response
Returns a 204 response with no body on success
Get Event Subscription
Get an Event Subscription by ID.
Request
GET /event_subscriptions/{id}
Example Request
Response
Returns a 200 response on success
Example Response
Fields
Name | Type | Description |
---|
id | string | Unique identifier for this Event Subscription. |
uri | string | URI of the Event Subscription API resource. |
created_at | string | When the Event Subscription was created (RFC 3339 format). |
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSource | Sources containing the types for which this event subscription will trigger |
destinations | Ref | Destinations to which these events will be sent |
EventSource fields
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
uri | string | URI of the Event Source API resource. |
Ref fields
Name | Type | Description |
---|
id | string | a resource identifier |
uri | string | a uri for locating a resource |
List Event Subscriptions
List this Account's Event Subscriptions.
Request
GET /event_subscriptions
Example Request
Response
Returns a 200 response on success
Example Response
Fields
Name | Type | Description |
---|
event_subscriptions | EventSubscription | The list of all Event Subscriptions on this account. |
uri | string | URI of the Event Subscriptions list API resource. |
next_page_uri | string | URI of next page, or null if there is no next page. |
EventSubscription fields
Name | Type | Description |
---|
id | string | Unique identifier for this Event Subscription. |
uri | string | URI of the Event Subscription API resource. |
created_at | string | When the Event Subscription was created (RFC 3339 format). |
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSource | Sources containing the types for which this event subscription will trigger |
destinations | Ref | Destinations to which these events will be sent |
EventSource fields
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
uri | string | URI of the Event Source API resource. |
Ref fields
Name | Type | Description |
---|
id | string | a resource identifier |
uri | string | a uri for locating a resource |
Update Event Subscription
Update an Event Subscription.
Request
PATCH /event_subscriptions/{id}
Example Request
Parameters
Name | Type | Description |
---|
id | string | Unique identifier for this Event Subscription. |
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSourceReplace | Sources containing the types for which this event subscription will trigger |
destination_ids | List<string> | A list of Event Destination IDs which should be used for this Event Subscription. |
EventSourceReplace parameters
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
Response
Returns a 200 response on success
Example Response
Fields
Name | Type | Description |
---|
id | string | Unique identifier for this Event Subscription. |
uri | string | URI of the Event Subscription API resource. |
created_at | string | When the Event Subscription was created (RFC 3339 format). |
metadata | string | Arbitrary customer supplied information intended to be machine readable. Optional, max 4096 chars. |
description | string | Arbitrary customer supplied information intended to be human readable. Optional, max 255 chars. |
sources | EventSource | Sources containing the types for which this event subscription will trigger |
destinations | Ref | Destinations to which these events will be sent |
EventSource fields
Name | Type | Description |
---|
type | string | Type of event for which an event subscription will trigger |
uri | string | URI of the Event Source API resource. |
Ref fields
Name | Type | Description |
---|
id | string | a resource identifier |
uri | string | a uri for locating a resource |