Skip to main content
WEBHOOK
payment.pending
{
  "id": "msg_xxxxxxxxxxxxxxxxxxxxxxxx",
  "api_version": "v1",
  "timestamp": "2025-01-01T00:00:00.000Z",
  "type": "payment.pending",
  "data": {
    "id": "pay_xxxxxxxxxxxxxx",
    "status": "draft",
    "substatus": "auto_refunded",
    "refundable": true,
    "retryable": true,
    "created_at": "2023-12-01T05:00:00.401Z",
    "paid_at": "2023-12-01T05:00:00.401Z",
    "last_payment_attempt": "2023-12-01T05:00:00.401Z",
    "dispute_alerted_at": "2023-12-01T05:00:00.401Z",
    "refunded_at": "2023-12-01T05:00:00.401Z",
    "plan": {
      "id": "plan_xxxxxxxxxxxxx"
    },
    "product": {
      "id": "prod_xxxxxxxxxxxxx",
      "title": "<string>",
      "route": "<string>"
    },
    "user": {
      "id": "user_xxxxxxxxxxxxx",
      "name": "<string>",
      "username": "<string>",
      "email": "<string>"
    },
    "membership": {
      "id": "mem_xxxxxxxxxxxxxx",
      "status": "trialing"
    },
    "member": {
      "id": "<string>",
      "phone": "<string>"
    },
    "company": {
      "id": "biz_xxxxxxxxxxxxxx",
      "title": "<string>",
      "route": "<string>"
    },
    "promo_code": {
      "id": "promo_xxxxxxxxxxxx",
      "code": "<string>",
      "amount_off": 6.9,
      "base_currency": "usd",
      "promo_type": "percentage",
      "number_of_intervals": 42
    },
    "voidable": true,
    "currency": "usd",
    "total": 6.9,
    "subtotal": 6.9,
    "usd_total": 6.9,
    "refunded_amount": 6.9,
    "auto_refunded": true,
    "amount_after_fees": 6.9,
    "card_brand": "<string>",
    "card_last4": "<string>",
    "billing_address": {
      "name": "<string>",
      "line1": "<string>",
      "line2": "<string>",
      "city": "<string>",
      "state": "<string>",
      "postal_code": "<string>",
      "country": "<string>"
    },
    "payment_method_type": "<string>",
    "billing_reason": "<string>",
    "failure_message": "<string>"
  }
}

Headers

webhook-signature
string
required

The signature of the webhook request with the webhook version prepended

Example:

"v1,BASE64ENCODEDSIGNATURE"

webhook-timestamp
string
required

The timestamp in seconds since the Unix epoch that the webhook was sent at on the server

Example:

"1727606400"

Body

application/json
id
string
required

A unique ID for every single webhook request

Example:

"msg_xxxxxxxxxxxxxxxxxxxxxxxx"

api_version
string
required

The API version for this webhook

Allowed value: "v1"
Example:

"v1"

timestamp
string<date-time>
required

The timestamp in ISO 8601 format that the webhook was sent at on the server

Example:

"2025-01-01T00:00:00.000Z"

type
string
required

The webhook event type

Allowed value: "payment.pending"
Example:

"payment.pending"

data
object
required

An object representing a receipt for a membership.

Response

200

Return a 200 status to indicate that the data was received successfully

I