Skip to main content
Version: 2019-05-29 (Current)

Retrieve a transaction

Returns the transaction matching the provided ID. Use this endpoint to retrieve detailed information about a specific transaction for reconciliation or audit purposes.


๐Ÿ”‘API Credentials

Request Parametersโ€‹

Required - 1 fieldRequired Parameters
โ–ผ
`id`STRING(required)
Transaction identifier. Format: trxn_test_[0-9a-z]+ for test mode or trxn_[0-9a-z]+ for live mode.
Example:"trxn_test_5fzo4nqrnop03djdde1"

Responsesโ€‹

200

Successful request

Returns the transaction object matching the provided ID.

Transaction object contains:
  • id - Transaction identifier (e.g., trxn_test_5fzo4nqrnop03djdde1)
  • object - String value "transaction"
  • amount - Transaction amount in smallest currency unit
  • currency - Three-letter ISO 4217 currency code
  • direction - Direction of funds (credit or debit)
  • key - Related object that triggered the transaction
  • origin - Original source of the transaction
  • transferable_at - ISO 8601 datetime when funds become transferable
  • created_at - Transaction creation timestamp (ISO 8601)
  • livemode - Boolean indicating live or test mode
  • location - API path to retrieve this transaction

401

Unauthorized

Authentication failed. Invalid or missing API key.

Common causes:
  • Missing Authorization header
  • Invalid secret key
  • Using public key instead of secret key
  • Incorrect HTTP Basic Auth format

404

Not found

Transaction not found.

Common causes:
  • Invalid transaction ID
  • Transaction ID from different account
  • Mixing test and live mode IDs

Code samplesโ€‹

curl https://api.omise.co/transactions/trxn_test_5fzo4nqrnop03djdde1 \
-u skey_test_5xuy4w91xqz7d1w9u0t:

Try it outโ€‹

Required - 1 fields
โ–ผ