Skip to main content
PUT
/
v1
/
partner
/
webhooks
/
{id}
Update a webhook
curl --request PUT \
  --url https://sandbox.api.acountpay.com/v1/partner/webhooks/{id} \
  --header 'Content-Type: application/json' \
  --header 'X-Partner-Client-Id: <api-key>' \
  --header 'X-Partner-Client-Secret: <api-key>' \
  --data '
{
  "url": "https://your-pos.com/webhooks/acountpay",
  "events": [
    "payment.completed",
    "payment.failed"
  ]
}
'
{
  "id": 1,
  "url": "https://your-pos.com/webhooks/acountpay",
  "events": [
    "payment.completed",
    "payment.failed"
  ],
  "status": "active",
  "secret": "whsec_...",
  "lastTriggeredAt": "2023-11-07T05:31:56Z",
  "createdAt": "2023-11-07T05:31:56Z"
}

Authorizations

X-Partner-Client-Id
string
header
required

Your partner client ID

X-Partner-Client-Secret
string
header
required

Your partner client secret

Path Parameters

id
integer
required

Webhook ID

Body

application/json
url
string<uri>
required

Webhook endpoint URL

Example:

"https://your-pos.com/webhooks/acountpay"

events
enum<string>[]
required

Events to subscribe to

Available options:
merchant.activated,
merchant.deactivated,
payment.completed,
payment.failed
Example:
["payment.completed", "payment.failed"]

Response

Updated webhook

id
number
Example:

1

url
string
Example:

"https://your-pos.com/webhooks/acountpay"

events
string[]
Example:
["payment.completed", "payment.failed"]
status
enum<string>
Available options:
active,
inactive
Example:

"active"

secret
string

Only returned on creation

Example:

"whsec_..."

lastTriggeredAt
string<date-time> | null
createdAt
string<date-time>