Skip to main content
POST
/
charge
Charge the saved card
curl --request POST \
  --url https://ringup.dev/api/tools/charge \
  --header 'Content-Type: application/json' \
  --header 'X-Caller-Number: <x-caller-number>' \
  --header 'X-Ringup-Merchant: <x-ringup-merchant>' \
  --data '
{
  "amount_cents": 8500,
  "description": "Front brake pads, 2022 Toyota Highlander"
}
'
{
  "ok": true,
  "status": "COMPLETED",
  "order_id": "ord_x",
  "payment_id": "pay_x",
  "confirmation": "2PJJZY",
  "charged": {
    "brand": "VISA",
    "last_4": "5858",
    "amount_cents": 8500
  }
}

Headers

X-Caller-Number
string
required

The caller's phone number in E.164, templated from the platform's caller-ID variable. Never model-generated.

Example:

"+14155550142"

X-Ringup-Merchant
string
required

The dialed number in E.164 (resolved to a merchant server-side) or an explicit merchant id.

Example:

"tonys-pizza"

X-Call-Id
string

The platform's call id. Used for charge idempotency: retries within a call can never double-charge.

Body

application/json
amount_cents
number
required

Order total in cents.

description
string

Short order description for the receipt.

Response

200 - application/json

The charge result. Only a COMPLETED status with a payment id and confirmation code proves a payment.

ok
boolean
status
string

COMPLETED on success.

order_id
string
payment_id
string
confirmation
string

Short code the wrap-up speaks back to the caller.

charged
object