Skip to main content
Beta FeatureThe Transaction Simulations feature is currently in beta. API endpoints and behavior may change as we continue to refine the product. Simulation endpoints are available in development environments only β€” production returns 404 Not Found.
Trigger a card authorization exactly as if a merchant had initiated it. Use this in sandbox to test authorization flows, webhook handling, and decline scenarios end-to-end. When the merchant currency differs from the billing currency (USD), the system applies FX conversion using current market rates plus applicable fees. To test how your integration handles declines, specify a decline reason in your request.

Endpoint

The card must be active and belong to your tenant. Cards in locked, canceled, or unactivated status cannot be used for simulation.

Headers

Body

Example request

Response

A successful response returns the transaction ID and status.
200 OK β€” Approved
200 OK β€” Declined
The transaction triggers the same webhooks as a real authorization:
  • transaction.requested β€” Sent when the authorization request arrives.
  • transaction.created β€” Sent when the authorization is approved.
See the transaction webhook reference for payload schemas.

Decline reasons

Use the declineReason field to simulate declined authorizations:
Example declined authorization

Cross-currency transactions

When the currency differs from USD (the billing currency), the system applies FX conversion:
  1. The merchant amount is converted to USD using current market rates.
  2. A Visa foreign exchange fee (1%) is applied.
  3. A Rain foreign exchange fee is applied (default 2%, or your tenant-specific rate if configured).
The billingAmount in the transaction record reflects the total USD amount after all conversions and fees.

Errors

Behavior notes

  • No real funds move. Simulations are fully mocked β€” the processor interaction is simulated internally.
  • The transaction record is real. The simulation creates a real transaction record, queryable via the transactions API, that fires the same webhooks as a real authorization.
  • Network is always VISA. Simulated authorizations use the VISA network regardless of the actual card network.

Example