Check transaction status

For some payment methods, the result of the transaction is fetched asynchronously, and you can check the final result of the payment after initiating the transaction via this API.

Check transaction status

POST /svc/payment/api/v1/openapi/transactions/check

For some payment methods, the result of the transaction is fetched asynchronously, and you can check the final result of the payment after initiating the transaction via this API.

Request

  • application/json

Body

order objectrequired

number Wonder order number (string)

reference_number Your order number (string)

transaction objectrequired

uuid transaction uuid (string)required

transaction uuid

Responses

  • 200

Response Headers

  • application/json

  • Schema

  • Example (auto)

Schema

code numberrequired

message stringrequired

data objectrequired

transaction objectrequired

type Transaction Type (string)required

Possible values: [Sales, Authorization, Refund, Capture]

Example: Sales

uuid Wonder transaction uuid (string)required

Wonder transaction uuid

currency transaction currency (string)required

transaction currency

amount transaction amount (number)required

transaction amount

success success (boolean)required

if transaction successful

is_pending booleanrequired

for async payment,if transaction still pending

captured booleanrequired

for card pure-auth,if transaction captured

allow_void booleanrequired

if transaction allowed to void

allow_refund booleanrequired

if transaction allowed to refund

void_is_pending booleanrequired

if void still pending

payment_method stringrequired

which payment method

note stringnullable

transaction remark

payment_data objectrequired

related to payment method

acquirer_name stringrequired

acquirer_type stringrequired

auth_code string

brn stringrequired

card_number_len integer

card_read_mode string

credit_card_type string

first_6_digits string

last_4_digits string

merchant_id string

new_gateway_txn_id stringrequired

payment_method stringrequired

receipt_id stringrequired

rrn string

transaction_state stringrequired

token string

When payment_method equals payment_token, the token returns data

holder_name string

exp_month string

exp_year string

resp_code string

resp_msg string

error_code stringdeprecated

not recommend

error_desc stringdeprecated

not recommend

consumer_country_code string

original_transaction_uuid original transacation uuid (string)nullable

original transacation uuid

reference_id string

original_transaction_reference_id string

device_sn string

original_device_sn string

{ "code": 0, "message": "string", "data": { "transaction": { "type": "Sales", "uuid": "string", "currency": "string", "amount": 0, "success": true, "is_pending": true, "captured": true, "allow_void": true, "allow_refund": true, "void_is_pending": true, "payment_method": "string", "note": "string", "payment_data": { "acquirer_name": "string", "acquirer_type": "string", "auth_code": "string", "brn": "string", "card_number_len": 0, "card_read_mode": "string", "credit_card_type": "string", "first_6_digits": "string", "last_4_digits": "string", "merchant_id": "string", "new_gateway_txn_id": "string", "payment_method": "string", "receipt_id": "string", "rrn": "string", "transaction_state": "string", "token": "string", "holder_name": "string", "exp_month": "string", "exp_year": "string", "resp_code": "string", "resp_msg": "string", "consumer_country_code": "string" }, "original_transaction_uuid": "string", "reference_id": "string", "original_transaction_reference_id": "string", "device_sn": "string", "original_device_sn": "string" } } }
  • csharp

  • curl

  • dart

  • go

  • http

  • java

  • javascript

  • kotlin

  • c

  • nodejs

  • objective-c

  • ocaml

  • php

  • powershell

  • python

  • r

  • ruby

  • rust

  • shell

  • swift

  • HTTPCLIENT

  • RESTSHARP

var client = new HttpClient(); var request = new HttpRequestMessage(HttpMethod.Post, "https://developer.wonder.today/svc/payment/api/v1/openapi/transactions/check"); request.Headers.Add("Accept", "application/json"); var content = new StringContent("{\n \"order\": {\n \"number\": \"string\",\n \"reference_number\": \"string\"\n },\n \"transaction\": {\n \"uuid\": \"string\"\n }\n}", null, "application/json"); request.Content = content; var response = await client.SendAsync(request); response.EnsureSuccessStatusCode(); Console.WriteLine(await response.Content.ReadAsStringAsync());

Request Collapse all

Body

{ "order": { "number": "string", "reference_number": "string" }, "transaction": { "uuid": "string" } }