Account

Create a webhook configuration

Changed on

This POST endpoint is used to create a new webhook configuration for your account. <br> To set up a webhook, provide a target url and an array of event_types that the webhook should listen to. <br> Upon successful creation, the response will include a unique webhook_token associated with the newly registered webhook as well as webhook_secret which will be used to encrypt the incoming payloads. <br> This token can be used for future management of the webhook.

post/payout/account/webhooks

Request

Request body

webhook_urlstring required

The URL that will receive the webhook payloads

event_typesstring[] required

The type of events the webhook will receive notifications for

Example request

{
  "webhook_url": "https://www.masspay.io/webhooks"
}

Response

Created

webhook_tokenstring required

The token associated with this webhook configuration

webhook_secretstring required

The secret this webhook's payloads are signed with: HMAC-SHA512 over <t>|<body>, sent in the X-MassPay-Signature header (see the Webhooks guide). The payload itself is not encrypted. The secret is returned only at creation: store it now.

Example response

{
  "webhook_token": "webhook_a0d7d26f-3d77-474e-9053-c4235032f37a",
  "webhook_secret": "29f67213-29a9-44d3-abf6-c4441ad07bc9"
}

Changes

    • info

      added the new avs.completed enum value to the request property /

    • info

      added the new file_upload_req.created enum value to the request property /

    • info

      added the new file_upload_req.status enum value to the request property /

    • info

      added the new file_upload_req.verified enum value to the request property /

    • info

      added the new payin_deposit.return_completed enum value to the request property /

    • info

      added the new payin_deposit.returned enum value to the request property /