Skip to main content
POST

Authorizations

Authorization
string
header
required

ProxyLayer API key. See the API Overview for key modes and scopes.

Scopes

rest:orders:write

Access to orders:write REST operations

Headers

Idempotency-Key
string<uuid>

Optional UUID; must match clientOperationId if both are sent. UUID for this purchase.

Body

application/json

Purchase or top-up payload and paymentMethod (stripe, crypto, or balance).

purchase
object
required
paymentMethod
enum<string>
default:stripe

stripe: hosted checkout URL; crypto: deposit address + paymentUrl; balance: debits prepaid wallet immediately.

Available options:
stripe,
crypto,
balance
cryptoCurrency
string

Coin for crypto payments (default: USDT).

Required string length: 1 - 24
Pattern: ^[A-Z0-9]+$
cryptoNetwork
string

Network for cryptoCurrency (default: TRON for USDT/USDC).

Required string length: 1 - 32
Pattern: ^[A-Z0-9_-]+$
clientOperationId
string<uuid>

Body alternative to Idempotency-Key. Reuse on retries; must match header if both are sent.

Response

Checkout session with paymentUrl (stripe/crypto) or completed orderId (balance).

checkoutSessionId
string
required

Session ID to poll with GET /api/v1/checkouts/{id}.

paymentMethod
enum<string>
required
Available options:
stripe,
crypto,
balance
status
enum<string>
required
Available options:
pending,
completed
currency
enum<string>
required
Available options:
USD
amountCents
integer
required

Total checkout amount in integer USD cents.

Required range: x > 0
paymentUrl
string | null

Hosted payment link for stripe or crypto checkouts; null for balance.

expiresAt
string<date-time> | null

ISO 8601 expiry time for pending checkouts.

orderId
string | null

Order ID, set immediately on balance purchases.

balanceCents
integer | null

Remaining prepaid balance in USD cents after a balance purchase.

Required range: x >= 0
crypto
object

Crypto deposit details, present when paymentMethod is 'crypto'.