Query a transaction

Request

Queries a transaction with a specified ID.

The query interacts with the related gateway account to obtain the result, amount, and currency. If after analysis, the transaction must be updated, see Update a transaction status.

Security
SecretApiKey or JWT
Path
idstring, <= 50 characters^[@~\-\.\w]+$required

ID of the resource.

curl -i -X POST \
  'https://www.rebilly.com/_mock/catalog/all/transactions/{id}/query' \
  -H 'REB-APIKEY: YOUR_API_KEY_HERE'

Responses

Transaction queried.

Headers
Locationstring, (uri)

Location of the related resource.

Example:"https://api.rebilly.com/example"
Rate-Limit-Limitinteger

Maximum number of requests available at one time for this rate limit. For more information, see Rate limits.

Example:500
Rate-Limit-Remaininginteger

Number of requests still available for this rate limit. For more information, see Rate limits.

Example:499
Bodyapplication/json
transactionIdstring, <= 50 characters(TransactionId)

ID of the transaction.

Example:"txn_0YVDTQJ8YWDGQACV2N2N5SPWQ0"
resultstringread-only

Result of the transaction.

Enum:"abandoned""approved""canceled""declined""unknown"
statusstringread-only

Status of the transaction.

Enum:"completed""conn-error""disputed""never-sent""offsite""partially-refunded""pending""refunded""sending""suspended"
amountnumber, (double)read-only

Amount of the transaction.

currencystring, = 3 characters(CurrencyCode)read-only

Currency code in ISO 4217 format.

Example:"USD"
Response
{ "transactionId": "txn_0YVDTQJ8YWDGQACV2N2N5SPWQ0", "result": "abandoned", "status": "completed", "amount": 0.1, "currency": "USD" }