Upsert a webhook

Creates or updates (upserts) a webhook with a specified ID.

SecurityAPI Key: SecretApiKey or HTTP: JWT or HTTP: ApplicationJWT
Request
path Parameters
id
required
string <= 50 characters ^[@~\-\.\w]+$

ID of the resource.

Request Body schema: application/json

Webhook resource.

eventsFilter
Array of strings (GlobalEventType)
Default: []

Array of system event types.

Items Enum: "aml-list-possibly-matched" "application-instance-disabled" "application-instance-enabled" "balance-transaction-settled" "coupon-application-removed" "coupon-applied" "coupon-expiration-modified" "coupon-expired" "coupon-issued" "coupon-modified" "coupon-redeemed" "coupon-redemption-canceled" "credit-memo-applied" "credit-memo-created" "credit-memo-modified" "credit-memo-partially-applied" "credit-memo-voided" "customer-created" "customer-merged" "customer-one-time-password-requested" "customer-redirected-offsite" "customer-returned" "customer-updated" "data-export-completed" "dispute-created" "dispute-modified" "experian-check-performed" "gateway-account-downtime-ended" "gateway-account-downtime-started" "gateway-account-limit-reached" "gateway-account-onboarding-completed" "gateway-account-onboarding-failed" "gateway-account-requested" "hard-usage-limit-reached" "invoice-abandoned" "invoice-created" "invoice-issued" "invoice-modified" "invoice-paid" "invoice-partially-paid" "invoice-partially-refunded" "invoice-past-due" "invoice-past-due-reminder" "invoice-refunded" "invoice-reissued" "invoice-tax-calculation-failed" "invoice-voided" "kyc-document-accepted" "kyc-document-archived" "kyc-document-created" "kyc-document-modified" "kyc-document-rejected" "kyc-document-reviewed" "kyc-request-attempted" "kyc-request-failed" "kyc-request-fulfilled" "kyc-request-partially-fulfilled" "lead-source-changed" "nsf-response-received" "offsite-payment-completed" "order-abandoned" "order-completed" "payment-card-created" "payment-card-expiration-reminder" "payment-card-expired" "payment-instrument-modified" "payout-request-created" "payout-request-modified" "quote-accepted" "quote-canceled" "quote-created" "quote-expired" "quote-issued" "quote-recalled" "quote-rejected" "quote-updated" "renewal-invoice-issued" "renewal-invoice-payment-canceled" "renewal-invoice-payment-declined" "risk-score-changed" "soft-usage-limit-reached" "subscription-activated" "subscription-canceled" "subscription-churned" "subscription-downgraded" "subscription-items-changed" "subscription-modified" "subscription-pause-created" "subscription-pause-modified" "subscription-pause-revoked" "subscription-paused" "subscription-reactivated" "subscription-renewal-reminder" "subscription-renewed" "subscription-resumed" "subscription-trial-converted" "subscription-trial-end-changed" "subscription-trial-end-reminder" "subscription-trial-ended" "subscription-upgraded" "transaction-amount-discrepancy-found" "transaction-declined" "transaction-discrepancy-found" "transaction-process-requested" "transaction-processed" "transaction-reconciled" "transaction-timeout-resolved" "waiting-gateway-transaction-completed" "order-delinquency-reached"
status
string
Default: "active"
Enum: "active" "inactive"
method
required
string
Enum: "GET" "POST" "PUT" "PATCH" "DELETE"
url
required
string <uri>

URL that triggers when a specified event occurs.

Array of objects

Webhook headers.

credentialHash
required
string

Hash from credentials to use for authentication by the specified URL.

body
string or null

Webhook request body. If this value is null, the default payload for the specified event is used. Template placeholders are permitted.

Invalid placeholders render as an empty strings. For example, Hello {{invalid.placeholder}}! is rendered as Hello !.

For more information, see Placeholders.

filter
string or null

Filter that determines whether to send the webhook. This field requires a special format. Use , for multiple allowed values. Use ; for multiple fields.

For more information, see Using filters.

put
/webhooks/{id}
Request samples
application/json
{ "eventsFilter": [ ], "status": "active", "method": "GET", "url": "http://example.com", "headers": [ ], "credentialHash": "string", "body": "string", "filter": "string" }
Responses

200

Webhook updated.

Response Schema: application/json
id
string <= 50 characters

ID of the webhook.

eventsFilter
Array of strings (GlobalEventType)
Default: []

Array of system event types.

Items Enum: "aml-list-possibly-matched" "application-instance-disabled" "application-instance-enabled" "balance-transaction-settled" "coupon-application-removed" "coupon-applied" "coupon-expiration-modified" "coupon-expired" "coupon-issued" "coupon-modified" "coupon-redeemed" "coupon-redemption-canceled" "credit-memo-applied" "credit-memo-created" "credit-memo-modified" "credit-memo-partially-applied" "credit-memo-voided" "customer-created" "customer-merged" "customer-one-time-password-requested" "customer-redirected-offsite" "customer-returned" "customer-updated" "data-export-completed" "dispute-created" "dispute-modified" "experian-check-performed" "gateway-account-downtime-ended" "gateway-account-downtime-started" "gateway-account-limit-reached" "gateway-account-onboarding-completed" "gateway-account-onboarding-failed" "gateway-account-requested" "hard-usage-limit-reached" "invoice-abandoned" "invoice-created" "invoice-issued" "invoice-modified" "invoice-paid" "invoice-partially-paid" "invoice-partially-refunded" "invoice-past-due" "invoice-past-due-reminder" "invoice-refunded" "invoice-reissued" "invoice-tax-calculation-failed" "invoice-voided" "kyc-document-accepted" "kyc-document-archived" "kyc-document-created" "kyc-document-modified" "kyc-document-rejected" "kyc-document-reviewed" "kyc-request-attempted" "kyc-request-failed" "kyc-request-fulfilled" "kyc-request-partially-fulfilled" "lead-source-changed" "nsf-response-received" "offsite-payment-completed" "order-abandoned" "order-completed" "payment-card-created" "payment-card-expiration-reminder" "payment-card-expired" "payment-instrument-modified" "payout-request-created" "payout-request-modified" "quote-accepted" "quote-canceled" "quote-created" "quote-expired" "quote-issued" "quote-recalled" "quote-rejected" "quote-updated" "renewal-invoice-issued" "renewal-invoice-payment-canceled" "renewal-invoice-payment-declined" "risk-score-changed" "soft-usage-limit-reached" "subscription-activated" "subscription-canceled" "subscription-churned" "subscription-downgraded" "subscription-items-changed" "subscription-modified" "subscription-pause-created" "subscription-pause-modified" "subscription-pause-revoked" "subscription-paused" "subscription-reactivated" "subscription-renewal-reminder" "subscription-renewed" "subscription-resumed" "subscription-trial-converted" "subscription-trial-end-changed" "subscription-trial-end-reminder" "subscription-trial-ended" "subscription-upgraded" "transaction-amount-discrepancy-found" "transaction-declined" "transaction-discrepancy-found" "transaction-process-requested" "transaction-processed" "transaction-reconciled" "transaction-timeout-resolved" "waiting-gateway-transaction-completed" "order-delinquency-reached"
status
string
Default: "active"
Enum: "active" "inactive"
method
required
string
Enum: "GET" "POST" "PUT" "PATCH" "DELETE"
url
required
string <uri>

URL that triggers when a specified event occurs.

Array of objects

Webhook headers.

credentialHash
required
string

Hash from credentials to use for authentication by the specified URL.

body
string or null

Webhook request body. If this value is null, the default payload for the specified event is used. Template placeholders are permitted.

Invalid placeholders render as an empty strings. For example, Hello {{invalid.placeholder}}! is rendered as Hello !.

For more information, see Placeholders.

filter
string or null

Filter that determines whether to send the webhook. This field requires a special format. Use , for multiple allowed values. Use ; for multiple fields.

For more information, see Using filters.

createdTime
string <date-time> (CreatedTime)

Date and time which is set automatically when the resource is created.

updatedTime
string <date-time> (UpdatedTime)

Date and time which updates automatically when the resource is updated.

Array of objects (SelfLink)

Related links.

201

Webhook created.

401

Unauthorized access. Invalid credentials used.

403

Access forbidden.

422

Invalid data sent.

Response samples
application/json
{ "id": "hook_0YVBG8S0K0DG59J6S3RMN9K452", "eventsFilter": [ ], "status": "active", "method": "GET", "url": "http://example.com", "headers": [ ], "credentialHash": "string", "body": "string", "filter": "string", "createdTime": "2019-08-24T14:15:22Z", "updatedTime": "2019-08-24T14:15:22Z", "_links": [ ] }