Skip to main content
POST
/
webhooks
Create a webhook
curl --request POST \
  --url https://api.notchpay.co/webhooks \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "url": "https://example.com/webhooks",
  "events": [
    "payment.created"
  ],
  "description": "Webhook principal"
}
'
{
  "code": 201,
  "status": "Created",
  "message": "Webhook endpoint created successfully",
  "endpoint": "<unknown>"
}

Authorizations

Authorization
string
header
required

Body

application/json
url
string
required
Example:

"https://example.com/webhooks"

events
enum<string>[]
required
Available options:
payment.created,
payment.complete,
payment.failed,
payment.canceled,
payment.expired,
transfer.created,
transfer.complete,
transfer.failed,
customer.created,
customer.updated,
customer.deleted,
customer.blocked,
customer.unblocked
description
string
Example:

"Webhook principal"

Response

Webhook endpoint created

code
integer
required
Example:

201

status
string
required
Example:

"Created"

message
string
required
Example:

"Webhook endpoint created successfully"

endpoint
any
required