PUT
/
webhooks
/
{endpoint}
curl --request PUT \
  --url https://api.notchpay.co/webhooks/{endpoint} \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
  "url": "https://example.com/webhooks",
  "description": "Webhook principal mis à jour",
  "events": [
    "payment.created"
  ]
}'
{
  "code": 202,
  "status": "Accepted",
  "message": "Webhook endpoint updated successfully",
  "endpoint": {
    "id": "wh_123456789",
    "url": "https://example.com/webhooks",
    "description": "Webhook principal",
    "events": [
      "payment.complete"
    ],
    "created_at": "2023-01-01T12:00:00.000Z",
    "updated_at": "2023-01-02T12:00:00.000Z"
  }
}

Authorizations

Authorization
string
header
required

Path Parameters

endpoint
string
required

Unique identifier of the webhook

Body

application/json

Response

202
application/json
Webhook endpoint updated

The response is of type object.