Skip to main content
Cresora Commerce
Getting Started

First Payment

Process a complete test payment with a test card and verify the webhook event.

A complete payment flow in Cresora involves three steps: charge the card, receive the webhook event, and confirm the state.

Test cards

Use these test PANs in the sandbox. Do not use real card numbers.

PANResult
4111111111111111Approval
4000000000000002Soft decline (NSF)
4000000000000069Hard decline
Any exp date in the future, any CVV
Warning

These are the authoritative test PANs per PRD §7.2. The Stripe-origin 4242 4242 4242 4242 card does not work on this platform.

Process the payment

curl -X POST https://sandbox-api.cresoracommerce.com/api/v1/transactions/sale \
  -H "Authorization: Bearer csk_test_xxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: idem_$(uuidgen)" \
  -d '{
    "amount": "50.00",
    "currency": "USD",
    "payment_method": "card",
    "merchant_id": "mrch_xxxxxxxxxx",
    "capture_method": "automatic",
    "card": {
      "number": "4111111111111111",
      "exp_month": 12,
      "exp_year": 2028,
      "cvv": "123"
    }
  }'

Verify the webhook event

After a successful payment, Cresora delivers a payment.captured event to your registered endpoint. If you haven't set up a webhook receiver yet, see Webhooks → Setup first.

The event payload looks like:

{
  "event": "payment.captured",
  "payment": {
    "id": "pay_xxxxxxxxxxxxxxxxxx",
    "status": "captured",
    "amount": "50.00",
    "test_mode": true
  }
}

Transaction states

A payment moves through these states:

requires_actionauthorizedcapturedsettled

Plus terminal states: voided, refunded, disputed, ach_returned.

See Transaction Types for detailed state transition rules.

Next

You have a working sandbox integration. Proceed to the Go-live checklist → when you're ready to move toward production.