Create a webhook
HTTPPOST
to /v1/webhooks
Request body
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
account_idsarray
The created webhook will exclusively push events which belong to the given account identifiers.
Act as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
Response
idstringrequired
The webhook's unique identifier
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not.
account_typestringrequired
The account's type.
live
test
account_idsarray
The webhook will exclusively push events which belong to account identifiers.
Acts as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
created_atstring (date-time)required
The webhook's creation timestamp.
secretstringrequired
The secret key used to generate the webhook payload HMAC.
Errors
This API operation can return the following errors:400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found
List all webhooks
HTTPGET
to /v1/webhooks
Query parameters
account_idstring
Filter by account identifiers: return webhooks which push events for the given account identifiers.
Response
array
object
You can configure webhook endpoints via the API to be notified about events that occur in your accounts or client accounts.
idstringrequired
The webhook's unique identifier
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not.
account_typestringrequired
The account's type.
live
test
account_idsarray
The webhook will exclusively push events which belong to account identifiers.
Acts as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
created_atstring (date-time)required
The webhook's creation timestamp.
secretstringrequired
The last 4 characters of the secret key used to generate the webhook payload HMAC.
Errors
This API operation can return the following errors:401
429
Get a webhook
HTTPGET
to /v1/webhooks/{id}
Query parameters
idstringrequired
The webhooks's unique identifier
Response
You can configure webhook endpoints via the API to be notified about events that occur in your accounts or client accounts.
idstringrequired
The webhook's unique identifier
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not.
account_typestringrequired
The account's type.
live
test
account_idsarray
The webhook will exclusively push events which belong to account identifiers.
Acts as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
created_atstring (date-time)required
The webhook's creation timestamp.
secretstringrequired
The last 4 characters of the secret key used to generate the webhook payload HMAC.
Errors
This API operation can return the following errors:401
404
429
Update a webhook
HTTPPUT
to /v1/webhooks/{id}
Query parameters
idstringrequired
The webhooks's unique identifier
Request body
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not. Defaults to true
for newly created
webhooks. When updating a webhook and the value is not explicitly specified the existing value
will be used.
account_idsarray
The updated webhook will exclusively push events which belong to the given account identifiers.
If not set, the previous account identifiers filter remains unchanged.
string
An account's unique identifier
Response
You can configure webhook endpoints via the API to be notified about events that occur in your accounts or client accounts.
idstringrequired
The webhook's unique identifier
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not.
account_typestringrequired
The account's type.
live
test
account_idsarray
The webhook will exclusively push events which belong to account identifiers.
Acts as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
created_atstring (date-time)required
The webhook's creation timestamp.
secretstringrequired
The last 4 characters of the secret key used to generate the webhook payload HMAC.
Errors
This API operation can return the following errors:400
api_version_invalid
400
bundle_selection_ratios_invalid
400
bundle_selection_bundle_invalid
400
order_value_invalid
400
bundle_id_invalid
400
id_invalid
400
distance_invalid
400
test_account_name_update_disallowed
400
bundle_selection_ratios_invalid_format
400
address_not_found
Delete a webhook
HTTPDELETE
to /v1/webhooks/{id}
Query parameters
idstringrequired
The webhooks's unique identifier
Errors
This API operation can return the following errors:204
401
404
429
Rotate a webhook secret
HTTPPUT
to /v1/webhooks/{id}/rotate-secret
The existing secret will be invalidated immediately and subsequent webhook payloads will be accompanied by HMACs using the new secret.Query parameters
idstringrequired
The webhooks's unique identifier
Response
idstringrequired
The webhook's unique identifier
urlstring (https-url)required
An HTTPS URL.
The URL must match the following regular expression: ^https:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&\/\/=]*)$
enabledbooleanrequired
Determines if events should be sent to the webhook or not.
account_typestringrequired
The account's type.
live
test
account_idsarray
The webhook will exclusively push events which belong to account identifiers.
Acts as a filter: if not set, events belonging to all the organisation's accounts are pushed.
string
An account's unique identifier
created_atstring (date-time)required
The webhook's creation timestamp.
secretstringrequired
The secret key used to generate the webhook payload HMAC.
Errors
This API operation can return the following errors:401
404
429