Skip to content

API

On this page

Testing

Exercise the real sandbox invoice and webhook delivery path from the interactive documentation playground.

The Webhook Playground exercises the real Sandbox path. It creates an invoice through the Merchant API, confirms its payment selection, triggers the selected sandbox outcome, and waits for the delivery worker to call your active endpoint.

It does not POST a fabricated event directly to your URL. The same outbox, signing, timeout, retry, and delivery code used by normal Sandbox operations handles the event.

Prerequisites

  • Switch the dashboard to Sandbox.
  • Select a project with at least one enabled test token.
  • Create an active Sandbox Payment API key.
  • Register an active Sandbox webhook endpoint.
  • Make the HTTPS endpoint reachable from the public internet.

Production sending is intentionally disabled in the playground.

Available scenarios

Scenario Resulting event
Exact payment invoice.paid
Overpayment invoice.paid_over
Final underpayment invoice.underpaid
Cancellation invoice.cancelled

Choose Playground above this guide, select a scenario, amount, and currency, then send. The response panel shows the final Merchant API call. Delivery status appears after Paymos observes the webhook attempt.

Diagnose a test

Open Dashboard → Developers → Webhooks to inspect the event and every delivery attempt. Compare these values first:

  1. X-Webhook-Id against the payload event_id.
  2. The received raw body against the bytes passed to your verifier.
  3. The endpoint response status and response time against the delivery policy.
  4. The endpoint's Sandbox secret against the secret used by your server.

After fixing a failed receiver, replay the event from its detail view. Replay keeps the same event ID, so your idempotency guard remains valid.