v47

latestOpenAPI 3.1.0raw.githubusercontent.com2026-05-012382333.4 MB

Sandbox: Refund a card transaction

Simulates refunding a card transaction. The full value of the original sandbox transaction is refunded.

post/simulations/card_refunds

Request body

amountinteger

The refund amount in cents. Pulled off the pending_transaction or the transaction if not provided.

pending_transaction_idstring

The identifier of the Pending Transaction for the refund authorization. If this is provided, transaction must not be provided as a refund with a refund authorized can not be linked to a regular transaction.

transaction_idstring

The identifier for the Transaction to refund. The Transaction's source must have a category of card_settlement.

Example request

{
  "transaction_id": "transaction_uyrp7fld2ium70oa7oi"
}

Response

Transaction

account_idstring required

The identifier for the Account the Transaction belongs to.

amountinteger required

The Transaction amount in the minor unit of its currency. For dollars, for example, this is cents.

created_atstring date-time required

The ISO 8601 date on which the Transaction occurred.

currency'USD' required

The ISO 4217 code for the Transaction's currency. This will match the currency on the Transaction's Account.

descriptionstring required

An informational message describing this transaction. Use the fields in source to get more detailed information. This field appears as the line-item on the statement.

idstring required

The Transaction identifier.

route_idstring nullable required

The identifier for the route this Transaction came through. Routes are things like cards and ACH details.

route_type'account_number' | 'card' | 'lockbox' nullable required

The type of the route this Transaction came through.

type'transaction' required

A constant representing the object's type. For this resource it will always be transaction.

Example response

{
  "account_id": "account_in71c4amph0vgo2qllky",
  "amount": 100,
  "created_at": "2020-01-31T23:59:59Z",
  "currency": "USD",
  "description": "INVOICE 2468",
  "id": "transaction_uyrp7fld2ium70oa7oi",
  "route_id": "account_number_v18nkfqm6afpsrvy82b2",
  "route_type": "account_number",
  "source": {
    "category": "inbound_ach_transfer",
    "inbound_ach_transfer": {
      "addenda": null,
      "amount": 100,
      "originator_company_descriptive_date": null,
      "originator_company_discretionary_data": null,
      "originator_company_entry_description": "RESERVE",
      "originator_company_id": "0987654321",
      "originator_company_name": "BIG BANK",
      "receiver_id_number": "12345678900",
      "receiver_name": "IAN CREASE",
      "trace_number": "021000038461022",
      "transfer_id": "inbound_ach_transfer_tdrwqr3fq9gnnq49odev"
    }
  },
  "type": "transaction"
}