Skip to main content

Documentation Index

Fetch the complete documentation index at: https://www.smartretry.com/docs/llms.txt

Use this file to discover all available pages before exploring further.

A sale authorizes and captures a payment in one request. Use this endpoint when you want to immediately charge the customer without a separate capture step.
Safe retries for this POST endpoint use the Idempotency-Key header. Reuse the same key only when retrying the exact same request body. See Idempotency.
curl --request POST \
  --url https://api.smartretry.com/v1/payments/sale/ABC123 \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --header 'Idempotency-Key: sale-order-20260331-001' \
  --data '{
    "merchant_transaction_id": "order-20260331-001",
    "amount": 49.99,
    "currency": "USD",
    "order": {
      "merchant_order_id": "my-order-20260331-001",
      "payment_instrument": {
        "card_number": "4111111111111111",
        "expiry_month": 12,
        "expiry_year": 2027,
        "payment_method": "cards",
        "card_cardholder_name": "Jane Doe"
      },
      "payer": {
        "first_name": "Jane",
        "last_name": "Doe",
        "email": "jane.doe@example.com"
      },
      "description": "Order #20260331-001"
    },
    "cvv": "123"
  }'
{
  "transaction_id": "TX8A3F2C",
  "order_id": "OR7B9E1D",
  "merchant_transaction_id": "order-20260331-001",
  "accepted": true
}

Path parameters

terminal_friendly_id
string
required
Your terminal identifier. Exactly 6 characters.

Request body

merchant_transaction_id
string
required
Your unique identifier for this transaction. Use this to correlate SmartRetry transactions with your own records. Maximum 100 characters.
amount
number
required
Amount to charge in major currency units (e.g., 49.99 for $49.99). Minimum 1, maximum 999999999.
currency
string
required
Three-letter ISO 4217 currency code (e.g., USD, EUR, GBP).
order
object
Order details, including payer identity and payment instrument.
token
string
Stored payment token (88 characters). Use this instead of order.payment_instrument.card_number for repeat customers.
cvv
string
Card verification value (CVV/CVC). Optional but recommended for card-not-present transactions.
The CVV is never stored by SmartRetry and cannot be used in tokenized or retry flows.
description
string
Human-readable description of the transaction. Maximum 500 characters.
order_id
string
SmartRetry order ID (exactly 8 characters). Provide this to associate the transaction with an existing order.
payer_request_ip_address
string
IPv4 address of the payer making the request. Used for fraud detection.
device_profile
object
Device and browser details for 3DS and fraud scoring.
ship_indicator
string
Shipping indicator for 3DS authentication.
delivery_address_usage_indicator
string
Indicates how long the shipping address has been associated with the customer. Used for 3DS.
delivery_timeframe
string
Indicates the delivery timeframe for the order. Used for 3DS.
shipping_recipient
object
Shipping recipient details. Used for 3DS and fraud checks.

Response

transaction_id
string
required
SmartRetry’s unique identifier for this transaction. Exactly 8 characters. Use this in subsequent capture, refund, or void requests.
order_id
string
required
SmartRetry’s unique identifier for the order. Exactly 8 characters.
merchant_transaction_id
string
required
The merchant_transaction_id you provided in the request, echoed back for confirmation.
accepted
boolean
required
true if the transaction was accepted for processing. A value of true does not guarantee approval - poll the status endpoint to confirm the final outcome.
accepted: true means SmartRetry has accepted the transaction for processing. To confirm whether the payment was approved by the issuer, fetch the transaction status using the returned transaction_id.