data parameter in the webhook is a JSON string containing the following fields:| Field | Type | Description |
|---|---|---|
id | string | Event ID, unique identifier starting with evt_ |
name | string | Event name, format: object.event_type |
data | object | Business object data (PaymentIntent/Subscription/Invoice/Refund/CheckoutSession, etc.) |
{
"id": "evt_79bdd43e4d0f464694fa433a5d467980",
"name": "payment_intent.succeeded",
"data": {
"id": "pi_1234567890",
"object": "payment_intent",
"amount": 10000,
"currency": "USD",
"status": "succeeded",
"customer_id": "cus_abc123",
"payment_method": {
"type": "card",
"card": {
"brand": "visa",
"last4": "4242"
}
},
"created_at": "2024-01-27T10:30:00Z",
"metadata": {}
}
}Business Event Occurs
↓
UseePay System Detects Status Change
↓
Webhook Event Generated
↓
HTTP POST to Your Webhook URL
↓
Your Server Processes Eventevent.id to implement idempotency.data parameter in the webhook request is a URL-encoded JSON string that needs to be decoded and parsed: