# API Direct Payment
# Request Base URL
Test Environment : https://gateway-sandbox.luxpag.com
Prod Environment : https://gateway.luxpag.com
# EndPoints
/trade/pay
# Request Header
Parameter | Required | Description |
---|---|---|
Content-Type | recommend | application/json |
Authorization | yes | Basic Base64(app_id:secret_key) |
# Request Body (JSON format)
Parameter | Type | Required | Max Length(or Default Value) | Description |
---|---|---|---|---|
app_id | string | yes | 32 | created app's id at dashboard |
timestamp | string | yes | 19 | yyyy-MM-dd HH:mm:ss |
out_trade_no | string | yes | 64 | ID given by the merchant in their system |
method | string | yes | 32 | Payment methods |
channel | string | no | 32 | sub channel(only use at method 'Wallet') |
order_currency | string | yes | 3 | BRL for brazil |
order_amount | decimal | yes | 0.01 ~ 99999999999999.99 | request payment amount |
subject | string | yes | 128 | payment reason or item title |
content | string | no | 255 | payment reason detail or item detail,Khipu fill in truthfully |
notify_url | string | yes | 255 | IPN URL to merchant |
return_url | string | no | 255 | return to merchant URL at checkout page,some channels only support HTTPS (Peru Wallet) |
buyer_id | string | yes | 128 | merchant user's id |
timeout_express | string | no | 90m | m(minutes), h(hours), d(days), c(always end in currency day UTC) |
cancellation_express | string | no | Luxpag active cancel time:m(minutes), h(hours), d(days).The value must be an integar. Ex: 90m The value must be larger than timeout_express,max 3 days | |
token | string | no | credit card token(CreditCard method only),Wallet Paypal token | |
issuer | string | no | issuer of credit card(CreditCard method only) | |
bank | string | no | bank code or bank id required for OpenFinance (get from API), Khipu (get from API), Ecuador Banktransfer (One of bpacifico, internacional, pichincha) | |
customer.name | string | yes | user's name(SPEI less than 10 characters will be rejected) ,can not have emoji,(Pago46:not must) | |
customer.email | string | yes | user's email('+' is not supported)(PIX:not must) | |
customer.phone | string | yes | user's mobile phone number(Khipu,Pago46,OpenFinance,PIX:not must) | |
customer.identify.number | string | yes | user's ID number(Khipu,Pago46,CoDi,OXXO,OXXOPay,SPEI,CASH,BNCR(some channels):not must),need to verify ID format | |
customer.identify.type | string | yes | user's ID type (Khipu,Pago46,CoDi,OXXO,OXXOPay,SPEI,CASH,BNCR(some channels):not must) | |
address.zip_code | string | no | zip code: Boleto and Lottery must | |
address.state | string | no | state | |
address.city | string | no | city | |
address.street_number | string | no | street1 number | |
address.street | string | no | street1 | |
address.neighborhood | string | no | street2 | |
ip | string | no | user's IP address(required for CreditCard) | |
language_code | string | no | language code(Cash,BankTransfer:required for bank query,Mexican cash doesn't need it) | |
installments | int | no | Credit card installments(Default phase 1) | |
fingerprint | string | no | Credit card needs | |
account_number | string | no | 10~18 digits | Wallet Todito Card number needs test data |
account_verification_code | string | no | 4 digits | Wallet Todito PIN needs test data |
region | string | no | region code When the app is Global, it must |
# Request Sample
curl --location --request POST 'https://gateway.gemini-tiger.cn/trade/create' \
--header 'Authorization: Basic Base64(appid:secret_key)' \
--header 'Content-Type: application/json' \
--data-raw '{
"app_id": "app_id",
"content": "content",
"method": "Boleto",
"notify_url": "notify_url",
"order_amount": 10,
"order_currency": "BRL",
"out_trade_no": "{{$randomUUID}}",
"subject": "subject",
"timeout_express": "1h",
"timestamp": "{{datetime}}",
"customer": {
"email": "email"
},
"address": {
"zip_code": "zip_code"
}
}'
# Http Response (JSON format)
Parameter | Type | Description |
---|---|---|
code | string | return code |
msg | string | return msg |
sub_code | string | return sub code(only error) |
sub_msg | string | return sub msg(only error) |
out_trade_no | string | request out_trade_no |
trade_no | string | Luxpag trade NO. |
trade_status | string | |
pay_url | string | checkout success URL:Luxpag payment success page (after successful payment, the merchant can jump to this page), which can support different payment method:PIX、Boleto、DepositExpress、Lottery、OXXO、SPEI、Wallet-AME、PSE、Efecty; PSE、Efecty |
barcode | string | Boleto barcode;only in Boleto |
qr_code | string | only in PIX |
provider_owner | string | only in DepositExpress |
provider_owner_document | string | only in DepositExpress |
provider_agency | string | only in DepositExpress |
provider_number | string | only in DepositExpress |
wallet_url | string | only in Wallet; AME:payment QR code url,PicPay:payment url,Todito、Paypal:no return |
app_link_url | string | only in AME Wallet (for APP use) |
bank_code | string | only in Boleto |
bank_name | string | only in SPEI |
reference | string | only in SPEI |
clabe | string | CLABE ;only in SPEI |
beneficiary_name | string | only in SPEI |
# Return Code (Success)
{
"code": "10000",
"msg": "Success",
"out_trade_no": "{out_trade_no}",
"trade_no": "{trade_no}",
"trade_status": "{trade_status}",
"pay_url": "{pay_url}",
"barcode": "{barcode}",
"qr_code": "{qr_code}",
"provider_owner": "{provider_owner}",
"provider_owner_document": "{provider_owner_document}",
"provider_agency": "{provider_agency}",
"provider_number": "{provider_number}",
"wallet_url": "{wallet_url}",
"app_link_url": "{app_link_url}",
"luxpag_url": "{luxpag_url}"
}
# Return Code (Fail)
{
"code": "40002",
"msg": "Business Failed",
"sub_code": "invalid-signature",
"sub_msg": "invalid signature"
}
# Result Code
Return status when creating an order.
# Complete sample
# PIX

# Boleto

# DepositExpress

# OXXO

# Cash

# SPEI

# PSE


# Efecty

