Skip to main content
POST
/
v1
/
webhooks
curl
curl -X POST https://api.paybridgenp.com/v1/webhooks \
  -H "Authorization: Bearer pk_sandbox_your_key" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://yourapp.com/webhooks/paybridge",
    "events": ["payment.succeeded", "payment.failed"]
  }'
{
  "id": "we_01j9x2k3m4n5p6q7r8s9t0u1v2",
  "livemode": true,
  "url": "https://yourapp.com/webhooks/paybridge",
  "events": [
    "payment.succeeded",
    "payment.failed"
  ],
  "enabled": true,
  "createdAt": "2023-11-07T05:31:56Z",
  "signing_secret": "whsec_live_abc123..."
}

Documentation Index

Fetch the complete documentation index at: https://docs.paybridgenp.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Your PayBridge API key. Obtain one from the dashboard under Settings → API Keys. Prefix: pk_sandbox_ for testing, pk_live_ for production.

Body

application/json
url
string<uri>
required

Public HTTPS URL. Private/local addresses are rejected.

Example:

"https://yourapp.com/webhooks/paybridge"

events
string[]

Event types to subscribe to. Pass an empty array to receive all events.

Example:
[
"payment.succeeded",
"payment.failed",
"payment.refunded"
]

Response

Webhook endpoint registered.

id
string
Example:

"we_01j9x2k3m4n5p6q7r8s9t0u1v2"

livemode
boolean

true when created with a live key, false for sandbox.

url
string<uri>
Example:

"https://yourapp.com/webhooks/paybridge"

events
string[]

Event types this endpoint receives. Empty array = all events.

Example:
["payment.succeeded", "payment.failed"]
enabled
boolean
createdAt
string<date-time>
signing_secret
string

HMAC-SHA256 signing secret. Only returned once — save it now.

Example:

"whsec_live_abc123..."