Skip to main content
POST
/
webhooks
Create a webhook
curl --request POST \
  --url https://api.synctera.com/v1/webhooks \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "enabled_events": [],
  "is_enabled": true,
  "url": "<string>",
  "description": "<string>",
  "metadata": {},
  "tenant": "abcdef_ghijkl"
}
'
{
  "enabled_events": [],
  "is_enabled": true,
  "url": "<string>",
  "creation_time": "2023-11-07T05:31:56Z",
  "description": "<string>",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "last_updated": "2023-11-07T05:31:56Z",
  "last_updated_time": "2023-11-07T05:31:56Z",
  "metadata": {},
  "tenant": "abcdef_ghijkl"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Webhook to create

Webhook object

enabled_events
enum<string>[]
required

A list of the events that will trigger the webhook. Subscribing to a wildcard event, e.g. ACCOUNT.*, will send all webhooks for all events that match that pattern. Note that this can include new event types added after the subscription was created.

Available options:
ADVERSE_ACTION.*,
APPLICATION.*,
CARD.*,
CRR.*,
DISPUTE.*,
DOCUMENT_VERIFICATION_SESSION.*,
EDD.*,
EXTERNAL_CARD.*,
EXTERNAL_CARD_TRANSFER.*,
INTERNAL_TRANSFER.*,
SPEND_CONTROL.*,
STATEMENT.*,
TRANSACTION.*
is_enabled
boolean
required

Set the webhook to be enabled or disabled

url
string<uri>
required

URL that the webhook will send request to

Maximum string length: 1000
description
string

A description of what the webhook is used for

metadata
object

Additional information stored to the webhook

tenant
string

The id of the tenant containing the resource.

Example:

"abcdef_ghijkl"

Callbacks

POST
{$request.body#/url}WebhookRequest

Body

application/json

Request body for webhook http request

event_time
string<date-time>
required

Timestamp of the current event raised

metadata
string
required

Metadata that stored in the webhook subscription

Maximum string length: 1024
type
enum<string>
required

All the webhook event types

Available options:
ADVERSE_ACTION.CREATED,
APPLICATION.CREATED,
APPLICATION.UPDATED,
CARD.CREATED,
CARD.DIGITALWALLETTOKEN.CREATED,
CARD.DIGITALWALLETTOKEN.UPDATED,
CARD.IMAGE.CREATED,
CARD.IMAGE.UPDATED,
CARD.UPDATED,
CRR.CREATED,
DISPUTE.CREATED,
DISPUTE.UPDATED,
DOCUMENT.CREATED,
DOCUMENT.DELETED,
DOCUMENT.RETRIEVED,
DOCUMENT.UPDATED,
DOCUMENT_VERIFICATION_SESSION.CREATED,
DOCUMENT_VERIFICATION_SESSION.UPDATED,
EDD.CREATED,
EDD.DELETED,
EXTERNAL_CARD.CREATED,
EXTERNAL_CARD.DELETED,
EXTERNAL_CARD.UPDATED,
EXTERNAL_CARD_TRANSFER.CREATED,
EXTERNAL_CARD_TRANSFER.UPDATED,
INTERNAL_TRANSFER.SUCCEEDED,
SPEND_CONTROL.CREATED,
SPEND_CONTROL.UPDATED,
SPEND_CONTROL.VIOLATED,
STATEMENT.CREATED,
TRANSACTION.CREATED,
TRANSACTION.UPDATED
url
string<uri>
required

URL that you specified for the webhook and where this request will be sent

Maximum string length: 1000
webhook_id
string<uuid>
required

Id of the Webhook the current request belongs to

changed_fields
string

Json string of object associated with the event related to a resource change. This only contains those fields that have value changed on the event, and the field values are prior to the resource change event.

resource
string

Json string of object associated with the event. For example, if your event is ACCOUNT.CREATED, You can refer to Acccount to parse the account event to obtain the ID, status etc.

Response

200

Your server returns this code if it accepts the webhook request object

Response

Created webhook

Webhook object

enabled_events
enum<string>[]
required

A list of the events that will trigger the webhook. Subscribing to a wildcard event, e.g. ACCOUNT.*, will send all webhooks for all events that match that pattern. Note that this can include new event types added after the subscription was created.

Available options:
ADVERSE_ACTION.*,
APPLICATION.*,
CARD.*,
CRR.*,
DISPUTE.*,
DOCUMENT_VERIFICATION_SESSION.*,
EDD.*,
EXTERNAL_CARD.*,
EXTERNAL_CARD_TRANSFER.*,
INTERNAL_TRANSFER.*,
SPEND_CONTROL.*,
STATEMENT.*,
TRANSACTION.*
is_enabled
boolean
required

Set the webhook to be enabled or disabled

url
string<uri>
required

URL that the webhook will send request to

Maximum string length: 1000
creation_time
string<date-time>
read-only

Webhook creation timestamp in RFC3339 format

description
string

A description of what the webhook is used for

id
string<uuid>
read-only

The unique ID of the webhook

last_updated
string<date-time>
read-only

Timestamp that this webhook was created or the last time any field was changed

last_updated_time
string<date-time>
read-only

Timestamp of the last Webhook modification in RFC3339 format

metadata
object

Additional information stored to the webhook

tenant
string

The id of the tenant containing the resource.

Example:

"abcdef_ghijkl"