Payments
Transaction status
Retrieve the current status and details of any transaction.
GET
/
v1
/
payments
/
status
/
{terminal_friendly_id}
/
{transaction_id}
cURL
curl --request GET \
--url https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id} \
--header 'x-api-key: <api-key>'import requests
url = "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"transaction_id": "<string>",
"type": "sale",
"status": {
"reasonCode": "<string>",
"name": "<string>",
"status": "APPROVED",
"domain": "SYSTEM",
"reason": "<string>",
"description": "<string>",
"field": {
"pointer": "<string>"
}
},
"order": {
"order_id": "<string>",
"merchant_order_id": "<string>",
"provider_order_id": "<string>",
"payer": {
"friendly_id": "<string>",
"full_name": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email_username": "<string>",
"email_domain": "<string>",
"phone_number": "<string>",
"national_id": "<string>"
},
"payment_instrument": {
"token": "<string>",
"payment_method": "cards",
"card_cardholder_name": "<string>",
"card_card_last_four_digit": "<string>",
"card_bin": "<string>",
"expiration_date": "<string>",
"card_profile": {
"fingerprint": "<string>",
"brand": {
"name": "<string>"
},
"issuer": {
"name": "<string>",
"description": "<string>"
},
"category": "<string>",
"cardType": "DEBIT",
"panLength": 16,
"cardUsage": "<string>"
}
},
"description": "<string>"
},
"created_at": "<string>",
"updated_at": "<string>",
"authorization_code": "<string>",
"arn": "<string>",
"amount": 123,
"currency": "<string>",
"attempt_number": 123,
"risk_decision": {
"success": true,
"allowed": true,
"blockedBy": [
{
"type": "blocklist",
"policyId": 123,
"policyName": "<string>",
"details": "<string>"
}
],
"bypassedChecks": [
{
"vipMode": "payer",
"bypassedChecks": [
"blocklist"
]
}
],
"evaluatedPolicies": [
{
"policyId": 123,
"policyName": "<string>",
"description": "<string>"
}
],
"error": "<string>"
},
"retry": {
"plan_id": "<string>",
"state": "PENDING",
"expires_at": "<string>"
},
"pending_payer_actions": [
{
"action": "UPDATE_CARD_NUMBER"
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}Fetch the current transaction record by its
transaction_id.
Status values
Thestatus.status field indicates the current state of the transaction:
APPROVED, PROCESSING, DECLINED, ERROR, CANCELLED, INFO, or UNKNOWN.
Status domains
Thestatus.domain field identifies which system was responsible for the status outcome:
SYSTEM, VALIDATION, RISK, ROUTING, AUTH, PROCESSOR, PAYMENT_METHOD, or
PAYER_ACCOUNT.Authorizations
Path Parameters
The unique identifier of the transaction.
Required string length:
8Pattern:
^[\dA-Za-z]{8}$The unique identifier of the terminal.
Required string length:
6Pattern:
^[\dA-Za-z]{6}$Response
Default Response
Required string length:
8Pattern:
^[\dA-Za-z]{8}$Available options:
sale, preauth, account_verification, recurring_init, recurring, payout, capture, refund, void Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
- Option 1
- Option 2
- Option 3
- Option 4
- Option 5
- Option 6
- Option 7
Show child attributes
Show child attributes
⌘I
cURL
curl --request GET \
--url https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id} \
--header 'x-api-key: <api-key>'import requests
url = "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://terminal.smartretry.com/v1/payments/status/{terminal_friendly_id}/{transaction_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"transaction_id": "<string>",
"type": "sale",
"status": {
"reasonCode": "<string>",
"name": "<string>",
"status": "APPROVED",
"domain": "SYSTEM",
"reason": "<string>",
"description": "<string>",
"field": {
"pointer": "<string>"
}
},
"order": {
"order_id": "<string>",
"merchant_order_id": "<string>",
"provider_order_id": "<string>",
"payer": {
"friendly_id": "<string>",
"full_name": "<string>",
"first_name": "<string>",
"last_name": "<string>",
"email_username": "<string>",
"email_domain": "<string>",
"phone_number": "<string>",
"national_id": "<string>"
},
"payment_instrument": {
"token": "<string>",
"payment_method": "cards",
"card_cardholder_name": "<string>",
"card_card_last_four_digit": "<string>",
"card_bin": "<string>",
"expiration_date": "<string>",
"card_profile": {
"fingerprint": "<string>",
"brand": {
"name": "<string>"
},
"issuer": {
"name": "<string>",
"description": "<string>"
},
"category": "<string>",
"cardType": "DEBIT",
"panLength": 16,
"cardUsage": "<string>"
}
},
"description": "<string>"
},
"created_at": "<string>",
"updated_at": "<string>",
"authorization_code": "<string>",
"arn": "<string>",
"amount": 123,
"currency": "<string>",
"attempt_number": 123,
"risk_decision": {
"success": true,
"allowed": true,
"blockedBy": [
{
"type": "blocklist",
"policyId": 123,
"policyName": "<string>",
"details": "<string>"
}
],
"bypassedChecks": [
{
"vipMode": "payer",
"bypassedChecks": [
"blocklist"
]
}
],
"evaluatedPolicies": [
{
"policyId": 123,
"policyName": "<string>",
"description": "<string>"
}
],
"error": "<string>"
},
"retry": {
"plan_id": "<string>",
"state": "PENDING",
"expires_at": "<string>"
},
"pending_payer_actions": [
{
"action": "UPDATE_CARD_NUMBER"
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"reason_code": "<string>",
"instance": "<string>",
"context": {}
}