onchain-pay-open-api by binance/binance-skills-hub
npx skills add https://github.com/binance/binance-skills-hub --skill onchain-pay-open-api通过自动 RSA SHA256 请求签名调用 Binance Onchain-Pay Open API 端点。
此技能设计用于以下场景:
使用时机:用户希望用法币购买加密货币并直接发送到外部链上钱包地址
关键 API:trading-pairs → payment-method-list → estimated-quote → pre-order
使用时机:用户在 Binance 账户中持有加密货币并希望发送到外部地址
关键 API:带有 SEND_PRIMARY 自定义配置的
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
pre-order使用时机:用户需要在一条链上购买加密货币并转移到另一条网络
关键 API:crypto-network → 带有网络选择的 pre-order
使用时机:为电子商务或服务集成加密货币支付网关
关键 API:带有 externalOrderId 跟踪的 pre-order
使用时机:在一笔交易中购买加密货币并执行智能合约
关键 API:带有 ON_CHAIN_PROXY_MODE 自定义配置的 pre-order
使用时机:检查订单状态、可用网络或支付方式
关键 API:order、crypto-network、trading-pairs、payment-method-list
| 端点 | API 路径 | 必需参数 | 可选参数 |
|---|---|---|---|
| 支付方式列表 (v1) | papi/v1/ramp/connect/buy/payment-method-list | fiatCurrency, cryptoCurrency, totalAmount, amountType | network, contractAddress |
| 支付方式列表 (v2) | papi/v2/ramp/connect/buy/payment-method-list | (无) | lang |
| 交易对 | papi/v1/ramp/connect/buy/trading-pairs | (无) | (无) |
| 预估报价 | papi/v1/ramp/connect/buy/estimated-quote | fiatCurrency, requestedAmount, payMethodCode, amountType | cryptoCurrency, contractAddress, address, network |
| 预下单 | papi/v1/ramp/connect/gray/buy/pre-order | externalOrderId, merchantCode, merchantName, ts | fiatCurrency, fiatAmount, cryptoCurrency, requestedAmount, amountType, address, network, payMethodCode, payMethodSubCode, redirectUrl, failRedirectUrl, redirectDeepLink, failRedirectDeepLink, customization, destContractAddress, destContractABI, destContractParams, affiliateCode, gtrTemplateCode, contractAddress |
| 获取订单 | papi/v1/ramp/connect/order | externalOrderId | (无) |
| 加密货币网络 | papi/v1/ramp/connect/crypto-network | (无) | (无) |
| P2P 交易对 | papi/v1/ramp/connect/buy/p2p/trading-pairs | (无) | fiatCurrency |
除非用户另有指定,否则使用默认账户(prod)。您需要:
使用 .local.md 中标记为 (default) 的账户。
根据用户指定的参数构建一个紧凑的 JSON 请求体。移除用户未提供的任何参数。
重要:地址和网络验证
address(目标钱包地址)和 network(区块链网络)是所有预下单请求的必需参数.local.md 中配置了 Default Address 和 Default Network,则自动使用它们bash <skill_path>/scripts/sign_and_call.sh \
"<BASE_URL>" \
"<API_PATH>" \
"<CLIENT_ID>" \
"<API_KEY>" \
"<PEM_PATH>" \
'<JSON_BODY>'
以可读格式向用户显示 JSON 响应。
完整签名详情请参阅 references/authentication.md。
摘要:
JSON_BODY + TIMESTAMP(毫秒)X-Tesla-ClientId、X-Tesla-SignAccessToken、X-Tesla-Signature、X-Tesla-Timestamp、Content-Type: application/jsonbuy/payment-method-list)| 参数 | 类型 | 必需 | 描述 |
|---|---|---|---|
| fiatCurrency | string | 是 | 法币货币代码(例如 USD、EUR、BRL、UGX) |
| cryptoCurrency | string | 是 | 加密货币代码(例如 BTC、USDT、USDC、SEI) |
| totalAmount | number | 是 | 金额数值 |
| amountType | number | 是 | 1 = 法币金额,2 = 加密货币金额 |
| network | string | 否 | 区块链网络(例如 BSC、ETH、SOL、BASE、SEI) |
| contractAddress | string | 否 | 代币合约地址(非原生代币必需) |
v2/buy/payment-method-list)无需指定法币/加密货币参数即可获取所有可用支付方式。v1 的简化版本。
| 参数 | 类型 | 必需 | 描述 |
|---|---|---|---|
| lang | string | 否 | 用于本地化支付方式名称的语言代码(例如 en、cn、es) |
与 v1 的区别:
响应格式:与 v1 相同,返回支付方式列表及其限制和属性。
buy/estimated-quote)| 参数 | 类型 | 必需 | 描述 |
|---|---|---|---|
| fiatCurrency | string | 是 | 法币货币代码 |
| cryptoCurrency | string | 否 | 加密货币代码(如果提供了 contractAddress 则为可选) |
| requestedAmount | number | 是 | 金额数值 |
| payMethodCode | string | 是 | 支付方式(例如 BUY_CARD、BUY_GOOGLE_PAY、BUY_P2P、BUY_WALLET) |
| amountType | number | 是 | 1 = 法币金额,2 = 加密货币金额 |
| network | string | 是 * | 区块链网络(可使用 .local.md 中的默认值) |
| contractAddress | string | 否 | 代币合约地址 |
| address | string | 是 * | 接收加密货币的目标钱包地址 |
.local.md 中的默认值。如果不存在默认值,请在继续之前询问用户。buy/pre-order)创建购买预订单并返回用于支付的跳转链接。
| 参数 | 类型 | 必需 | 描述 |
|---|---|---|---|
| externalOrderId | string | 是 | 合作伙伴的唯一订单 ID(必须唯一) |
| merchantCode | string | 是 | 商户代码(例如 connect-gray) |
| merchantName | string | 是 | 商户显示名称(例如 GrayTest) |
| ts | number | 是 | 当前时间戳(毫秒) |
| fiatCurrency | string | 否* | 法币货币代码(例如 TWD、USD、EUR) |
| fiatAmount | number | 否* | 要花费的法币金额 |
| cryptoCurrency | string | 否* | 要购买的加密货币(例如 USDT、BTC、ETH) |
| requestedAmount | number | 否* | 金额数值(根据 amountType 确定是法币还是加密货币) |
| amountType | number | 否* | 1 = 法币金额,2 = 加密货币金额 |
| address | string | 否 | 接收加密货币的目标钱包地址 |
| network | string | 否 | 区块链网络(例如 BSC、ETH、SOL) |
| payMethodCode | string | 否 | 支付方式代码(例如 BUY_CARD、BUY_P2P、BUY_GOOGLE_PAY、BUY_APPLE_PAY、BUY_PAYPAL、BUY_WALLET、BUY_REVOLUT) |
| payMethodSubCode | string | 否 | 支付方式子代码(例如 card、GOOGLE_PAY、WECHAT) |
| redirectUrl | string | 否 | 成功跳转 URL |
| failRedirectUrl | string | 否 | 失败跳转 URL |
| redirectDeepLink | string | 否 | 成功时的深度链接(移动应用) |
| failRedirectDeepLink | string | 否 | 失败时的深度链接(移动应用) |
| customization | object | 否 | 自定义配置对象(见下文自定义部分) |
| destContractAddress | string | 否 | 目标合约地址(用于 Onchain-Pay Easy 模式) |
| destContractABI | string | 否 | 合约 ABI 名称(用于 Onchain-Pay Easy 模式) |
| destContractParams | object | 否 | 合约参数(用于 Onchain-Pay Easy 模式) |
| affiliateCode | string | 否 | 佣金跟踪的联盟代码 |
| gtrTemplateCode | string | 否 | GTR 模板代码(例如 OTHERS) |
| contractAddress | string | 否 | 代币合约地址(用于非原生代币) |
fiatAmount 或(requestedAmount + amountType)。如果未提供 fiatCurrency,系统将自动选择可用的法币货币。响应示例:
{
"code": "000000",
"message": "success",
"data": {
"link": "https://app.binance.com/uni-qr/ccnt?...",
"linkExpireTime": 1772852565045
},
"success": true
}
order)| 参数 | 类型 | 必需 | 描述 |
|---|---|---|---|
| externalOrderId | string | 是 | 要查询的外部订单 ID |
预下单 API 中的 customization 字段接受各种标志以自定义购买流程行为。每个商户必须在 db.merchant_info 表中配置相应的权限。
| 标志 | 代码 | 类型 | 可用性 | 描述 | 使用场景 |
|---|---|---|---|---|---|
LOCK_ORDER_ATTRIBUTES | 1 | array | Open API ✓ | 锁定特定订单属性,使用户无法修改它们。值:1=法币货币,2=加密货币,3=金额,4=支付方式,5=网络,6=地址,7=法币金额,8=加密货币金额 | 固定参数订单 |
SKIP_CASHIER | 2 | boolean | Open API ✓ | 跳过收银台页面,直接进入支付。减少结账流程中的用户摩擦。 | 简化的支付体验 |
AUTO_REDIRECTION | 3 | boolean | Open API ✓ | 订单完成后自动跳转到 redirectUrl,不显示成功页面。 | 无缝用户体验 |
HIDE_SEND | 6 | boolean | Open API ✓ | 在 UI 中隐藏“发送”标签。仅需要购买流程时很有用。 | 仅购买集成 |
SEND_PRIMARY | 7 | boolean | Open API ✓ | 启用发送加密货币功能。如果用户的 Binance 余额不足,则自动触发购买流程。 | 发送加密货币到外部地址 |
MERCHANT_DISPLAY_NAME | 8 | string | Open API ✓ | 覆盖在 UI 中向用户显示的显示名称。 | 自定义品牌 |
NET_RECEIVE | 9 | boolean | Open API ✓ | 用户收到扣除所有费用后的净额。总成本更透明。 | 显示最终收到金额的更好用户体验 |
P2P_EXPRESS | 10 | boolean | Open API ✓ | 启用 P2P 快速模式以加快 P2P 订单匹配。 | 快速 P2P 交易 |
OPEN_NETWORK | 11 | boolean | 仅限 Web3 | 允许用户选择不同的网络。默认锁定为预选网络。注意:目前仅适用于 Web3 入口,不适用于 Open API。 | 多网络支持(仅限 Web3) |
ON_CHAIN_PROXY_MODE | 12 | boolean | Open API ✓ | 启用 Onchain-Pay Easy 模式。购买加密货币后,Onchain-Pay 将执行智能合约交互,而不是直接提现到用户钱包。需要 destContractAddress、destContractABI 和 destContractParams。 | 法币到智能合约集成 |
SEND_PRIMARY_FLEXIBLE | 13 | boolean | Open API ✓ | 具有更多选项的灵活发送优先模式。 | 高级发送加密货币场景 |
示例 1:基本卡支付
{
"customization": {}
}
示例 2:Onchain-Pay Easy(链上代理)
{
"customization": {
"ON_CHAIN_PROXY_MODE": true,
"NET_RECEIVE": true,
"SEND_PRIMARY": true
},
"destContractAddress": "0x128...974",
"destContractABI": "depositFor",
"destContractParams": {
"accountType": 2
}
}
示例 3:发送加密货币
{
"customization": {
"SEND_PRIMARY_FLEXIBLE": true,
"SEND_PRIMARY": true
}
}
示例 4:带自动跳转的 P2P
{
"customization": {
"AUTO_REDIRECTION": true,
"P2P_EXPRESS": true
}
}
示例 5:锁定订单属性
{
"customization": {
"LOCK_ORDER_ATTRIBUTES": [2, 3, 6, 7, 8],
"MERCHANT_DISPLAY_NAME": "My Custom Brand"
}
}
锁定属性代码:
2 = 加密货币3 = 金额6 = 地址7 = 法币金额8 = 加密货币金额示例 6:净接收模式
{
"customization": {
"NET_RECEIVE": true,
"SEND_PRIMARY": true
}
}
示例 7:隐藏发送标签
{
"customization": {
"HIDE_SEND": true
}
}
示例 8:跳过收银台(直接支付)
{
"customization": {
"SKIP_CASHIER": true
}
}
MERCHANT_DISPLAY_NAME 为 null)将返回 ILLEGAL_CUSTOMIZATION_VALUE 错误。NET_RECEIVE + SEND_PRIMARY),而其他标志是独立的。connect-gray)测试自定义标志。OPERATION(代码 4)和 SKIP_WITHDRAW(代码 5)仅供内部使用,不应从商户端传递。2zefb...06h).local.md 中配置的 Base URL 之外的 URL。凭据存储在技能目录的 .local.md 文件中。此文件是用户特定的,不应分发。
从与此 SKILL.md 相同的目录读取 .local.md 文件以加载凭据。
如果 .local.md 不存在或未找到请求的账户,请要求用户提供:
然后提供将它们保存到 .local.md 以供将来使用的选项。
.local.md 格式## Onchain-Pay Accounts
### prod (default)
- Base URL: https://api.commonservice.io
- Client ID: your-client-id
- API Key: your-api-key
- PEM Path: /absolute/path/to/your/private.pem
- Default Network: your-preferred-network
- Default Address: your-wallet-address
- Description: Production account
标记为 (default) 的账户会自动使用。您可以定义多个账户,并通过告诉 Claude 账户名称来切换。
包含 User-Agent 头部,使用以下字符串:onchain-pay-open-api/0.1.0 (Skill)
scripts/sign_and_call.sh 执行请求为 ts 参数和 externalOrderId 生成时间戳时,请使用以下方法以确保跨平台兼容性:
# 生成毫秒时间戳(适用于 macOS、Linux、BSD)
TIMESTAMP=$(($(date +%s) * 1000))
# 生成唯一订单 ID
ORDER_ID="order$(date +%s)"
不要使用 date +%s%3N 或 date +%s000,因为这些不可移植:
date +%s%3N 在 macOS 上不起作用(输出字面量 'N')date +%s000 只是附加 '000',没有实际的毫秒精度externalOrderId 必须是不含特殊字符的有效字符串。推荐格式:
order1773744500(简单数字后缀)order_1773744500(带下划线分隔符)txn-abc123(带字母数字的自定义前缀)避免:order_${TIMESTAMP} 其中 TIMESTAMP 包含 shell 变量语法错误
# 创建预下单的正确方式
TIMESTAMP=$(($(date +%s) * 1000))
ORDER_ID="order$(date +%s)"
bash /path/to/scripts/sign_and_call.sh \
"https://api.commonservice.io" \
"papi/v1/ramp/connect/gray/buy/pre-order" \
"connect-gray" \
"your-api-key" \
"/path/to/private.pem" \
"{\"externalOrderId\":\"$ORDER_ID\",\"merchantCode\":\"connect-gray\",\"merchantName\":\"YourMerchant\",\"ts\":$TIMESTAMP,\"fiatCurrency\":\"USD\",\"requestedAmount\":100,\"cryptoCurrency\":\"BNB\",\"amountType\":1,\"address\":\"0x...\",\"network\":\"BSC\",\"payMethodCode\":\"BUY_CARD\"}"
每周安装数
466
仓库
GitHub 星标数
516
首次出现
7 天前
安全审计
安装于
codex451
opencode451
kimi-cli448
amp448
github-copilot448
cursor448
Call Binance Onchain-Pay Open API endpoints with automatic RSA SHA256 request signing.
This skill is designed for the following scenarios:
When to use : User wants to buy crypto with fiat currency and send directly to an external on-chain wallet address
Key APIs : trading-pairs → payment-method-list → estimated-quote → pre-order
When to use : User has crypto in Binance account and wants to send to external address
Key APIs : pre-order with SEND_PRIMARY customization
When to use : User needs to buy crypto on one chain and transfer to another network
Key APIs : crypto-network → pre-order with network selection
When to use : Integrate crypto payment gateway for e-commerce or services
Key APIs : pre-order with externalOrderId tracking
When to use : Buy crypto and execute smart contract in one transaction
Key APIs : pre-order with ON_CHAIN_PROXY_MODE customization
When to use : Check order status, available networks, or payment methods
Key APIs : order, crypto-network, trading-pairs, payment-method-list
| Endpoint | API Path | Required Params | Optional Params |
|---|---|---|---|
| Payment Method List (v1) | papi/v1/ramp/connect/buy/payment-method-list | fiatCurrency, cryptoCurrency, totalAmount, amountType | network, contractAddress |
| Payment Method List (v2) | papi/v2/ramp/connect/buy/payment-method-list | (none) | lang |
| Trading Pairs | papi/v1/ramp/connect/buy/trading-pairs | (none) | (none) |
| Estimated Quote | papi/v1/ramp/connect/buy/estimated-quote |
Use the default account (prod) unless the user specifies otherwise. You need:
Use the account marked (default) in .local.md.
Build a compact JSON body from user-specified parameters. Remove any parameters the user did not provide.
IMPORTANT: Address and Network Validation
address (destination wallet address) and network (blockchain network) are REQUIRED for all pre-order requestsDefault Address and Default Network in .local.md, use them automaticallybash <skill_path>/scripts/sign_and_call.sh \
"<BASE_URL>" \
"<API_PATH>" \
"<CLIENT_ID>" \
"<API_KEY>" \
"<PEM_PATH>" \
'<JSON_BODY>'
Display the JSON response to the user in a readable format.
See references/authentication.md for full signing details.
Summary:
JSON_BODY + TIMESTAMP (milliseconds)X-Tesla-ClientId, X-Tesla-SignAccessToken, X-Tesla-Signature, X-Tesla-Timestamp, Content-Type: application/jsonbuy/payment-method-list)| Parameter | Type | Required | Description |
|---|---|---|---|
| fiatCurrency | string | Yes | Fiat currency code (e.g., USD, EUR, BRL, UGX) |
| cryptoCurrency | string | Yes | Crypto currency code (e.g., BTC, USDT, USDC, ) |
v2/buy/payment-method-list)Get all available payment methods without specifying fiat/crypto parameters. Simplified version of v1.
| Parameter | Type | Required | Description |
|---|---|---|---|
| lang | string | No | Language code for localized payment method names (e.g., en, cn, es) |
Differences from v1 :
Response Format : Same as v1, returns list of payment methods with their limits and properties.
buy/estimated-quote)| Parameter | Type | Required | Description |
|---|---|---|---|
| fiatCurrency | string | Yes | Fiat currency code |
| cryptoCurrency | string | No | Crypto currency code (optional if contractAddress provided) |
| requestedAmount | number | Yes | Amount value |
| payMethodCode | string | Yes | Payment method (e.g., BUY_CARD, BUY_GOOGLE_PAY, BUY_P2P, BUY_WALLET) |
.local.md for defaults. If no defaults exist, ask user before proceeding.buy/pre-order)Create a buy pre-order and return the redirect link for payment.
| Parameter | Type | Required | Description |
|---|---|---|---|
| externalOrderId | string | Yes | Partner's unique order ID (must be unique) |
| merchantCode | string | Yes | Merchant code (e.g., connect-gray) |
| merchantName | string | Yes | Merchant display name (e.g., GrayTest) |
| ts | number | Yes | Current timestamp in milliseconds |
| fiatCurrency | string | No* | Fiat currency code (e.g., TWD, , ) |
fiatAmount or (requestedAmount + amountType) should be provided. If fiatCurrency is not provided, the system will auto-select available fiat currencies.Response Example :
{
"code": "000000",
"message": "success",
"data": {
"link": "https://app.binance.com/uni-qr/ccnt?...",
"linkExpireTime": 1772852565045
},
"success": true
}
order)| Parameter | Type | Required | Description |
|---|---|---|---|
| externalOrderId | string | Yes | The external order ID to query |
The customization field in pre-order API accepts various flags to customize the buy flow behavior. Each merchant must have the corresponding permission configured in db.merchant_info table.
| Flag | Code | Type | Availability | Description | Use Case |
|---|---|---|---|---|---|
LOCK_ORDER_ATTRIBUTES | 1 | array | Open API ✓ | Lock specific order attributes so users cannot modify them. Values: 1=fiat currency, 2=crypto currency, 3=amount, 4=payment method, 5=network, 6=address, =fiat amount, =crypto amount |
Example 1: Basic Card Payment
{
"customization": {}
}
Example 2: Onchain-Pay Easy (On-Chain Proxy)
{
"customization": {
"ON_CHAIN_PROXY_MODE": true,
"NET_RECEIVE": true,
"SEND_PRIMARY": true
},
"destContractAddress": "0x128...974",
"destContractABI": "depositFor",
"destContractParams": {
"accountType": 2
}
}
Example 3: Send Crypto
{
"customization": {
"SEND_PRIMARY_FLEXIBLE": true,
"SEND_PRIMARY": true
}
}
Example 4: P2P with Auto Redirection
{
"customization": {
"AUTO_REDIRECTION": true,
"P2P_EXPRESS": true
}
}
Example 5: Lock Order Attributes
{
"customization": {
"LOCK_ORDER_ATTRIBUTES": [2, 3, 6, 7, 8],
"MERCHANT_DISPLAY_NAME": "My Custom Brand"
}
}
Lock attribute codes:
2 = Crypto currency3 = Amount6 = Address7 = Fiat amount8 = Crypto amountExample 6: Net Receive Mode
{
"customization": {
"NET_RECEIVE": true,
"SEND_PRIMARY": true
}
}
Example 7: Hide Send Tab
{
"customization": {
"HIDE_SEND": true
}
}
Example 8: Skip Cashier (Direct Payment)
{
"customization": {
"SKIP_CASHIER": true
}
}
null for MERCHANT_DISPLAY_NAME) will return ILLEGAL_CUSTOMIZATION_VALUE error.NET_RECEIVE + SEND_PRIMARY), while others are independent.connect-gray) for testing customization flags before production.OPERATION (code 4) and SKIP_WITHDRAW (code 5) are internal use only and should NOT be passed from merchant side.2zefb...06h).local.md.Credentials are stored in a .local.md file in the skill directory. This file is user-specific and should NOT be distributed.
Read the .local.md file from the same directory as this SKILL.md to load credentials.
If .local.md does not exist or the requested account is not found, ask the user to provide:
Then offer to save them to .local.md for future use.
.local.md Format## Onchain-Pay Accounts
### prod (default)
- Base URL: https://api.commonservice.io
- Client ID: your-client-id
- API Key: your-api-key
- PEM Path: /absolute/path/to/your/private.pem
- Default Network: your-preferred-network
- Default Address: your-wallet-address
- Description: Production account
The account marked (default) is used automatically. You can define multiple accounts and switch by telling Claude the account name.
Include User-Agent header with the following string: onchain-pay-open-api/0.1.0 (Skill)
scripts/sign_and_call.shWhen generating timestamps for the ts parameter and externalOrderId, use the following approach for cross-platform compatibility:
# Generate millisecond timestamp (works on macOS, Linux, BSD)
TIMESTAMP=$(($(date +%s) * 1000))
# Generate unique order ID
ORDER_ID="order$(date +%s)"
DO NOT USE date +%s%3N or date +%s000 as these are not portable:
date +%s%3N doesn't work on macOS (outputs literal 'N')date +%s000 just appends '000' without actual millisecond precisionThe externalOrderId must be a valid string without special characters. Recommended formats:
order1773744500 (simple numeric suffix)order_1773744500 (with underscore separator)txn-abc123 (custom prefix with alphanumeric)Avoid : order_${TIMESTAMP} where TIMESTAMP contains shell variable syntax errors
# Correct way to create a pre-order
TIMESTAMP=$(($(date +%s) * 1000))
ORDER_ID="order$(date +%s)"
bash /path/to/scripts/sign_and_call.sh \
"https://api.commonservice.io" \
"papi/v1/ramp/connect/gray/buy/pre-order" \
"connect-gray" \
"your-api-key" \
"/path/to/private.pem" \
"{\"externalOrderId\":\"$ORDER_ID\",\"merchantCode\":\"connect-gray\",\"merchantName\":\"YourMerchant\",\"ts\":$TIMESTAMP,\"fiatCurrency\":\"USD\",\"requestedAmount\":100,\"cryptoCurrency\":\"BNB\",\"amountType\":1,\"address\":\"0x...\",\"network\":\"BSC\",\"payMethodCode\":\"BUY_CARD\"}"
Weekly Installs
466
Repository
GitHub Stars
516
First Seen
7 days ago
Security Audits
Gen Agent Trust HubPassSocketPassSnykFail
Installed on
codex451
opencode451
kimi-cli448
amp448
github-copilot448
cursor448
飞书OpenAPI Explorer:探索和调用未封装的飞书原生API接口
15,500 周安装
| fiatCurrency, requestedAmount, payMethodCode, amountType |
| cryptoCurrency, contractAddress, address, network |
| Pre-order | papi/v1/ramp/connect/gray/buy/pre-order | externalOrderId, merchantCode, merchantName, ts | fiatCurrency, fiatAmount, cryptoCurrency, requestedAmount, amountType, address, network, payMethodCode, payMethodSubCode, redirectUrl, failRedirectUrl, redirectDeepLink, failRedirectDeepLink, customization, destContractAddress, destContractABI, destContractParams, affiliateCode, gtrTemplateCode, contractAddress |
| Get Order | papi/v1/ramp/connect/order | externalOrderId | (none) |
| Crypto Network | papi/v1/ramp/connect/crypto-network | (none) | (none) |
| P2P Trading Pairs | papi/v1/ramp/connect/buy/p2p/trading-pairs | (none) | fiatCurrency |
SEI| totalAmount | number | Yes | Amount value |
| amountType | number | Yes | 1 = fiat amount, 2 = crypto amount |
| network | string | No | Blockchain network (e.g., BSC, ETH, SOL, BASE, SEI) |
| contractAddress | string | No | Token contract address (required for non-native tokens) |
| amountType | number | Yes | 1 = fiat amount, 2 = crypto amount |
| network | string | Yes * | Blockchain network (can use default from .local.md) |
| contractAddress | string | No | Token contract address |
| address | string | Yes * | Destination wallet address for receiving crypto |
USDEUR| fiatAmount | number | No* | Fiat amount to spend |
| cryptoCurrency | string | No* | Crypto currency to buy (e.g., USDT, BTC, ETH) |
| requestedAmount | number | No* | Amount value (fiat or crypto based on amountType) |
| amountType | number | No* | 1 = fiat amount, 2 = crypto amount |
| address | string | No | Destination wallet address for receiving crypto |
| network | string | No | Blockchain network (e.g., BSC, ETH, SOL) |
| payMethodCode | string | No | Payment method code (e.g., BUY_CARD, BUY_P2P, BUY_GOOGLE_PAY, BUY_APPLE_PAY, BUY_PAYPAL, BUY_WALLET, BUY_REVOLUT) |
| payMethodSubCode | string | No | Payment method sub-code (e.g., card, GOOGLE_PAY, WECHAT) |
| redirectUrl | string | No | Success redirect URL |
| failRedirectUrl | string | No | Failure redirect URL |
| redirectDeepLink | string | No | Deep link for success (mobile apps) |
| failRedirectDeepLink | string | No | Deep link for failure (mobile apps) |
| customization | object | No | Custom configuration object (see Customization section below) |
| destContractAddress | string | No | Destination contract address (for Onchain-Pay Easy mode) |
| destContractABI | string | No | Contract ABI name (for Onchain-Pay Easy mode) |
| destContractParams | object | No | Contract parameters (for Onchain-Pay Easy mode) |
| affiliateCode | string | No | Affiliate code for commission tracking |
| gtrTemplateCode | string | No | GTR template code (e.g., OTHERS) |
| contractAddress | string | No | Token contract address (for non-native tokens) |
78| Fixed-parameter orders |
SKIP_CASHIER | 2 | boolean | Open API ✓ | Skip the cashier page and proceed directly to payment. Reduces user friction in the checkout flow. | Streamlined payment experience |
AUTO_REDIRECTION | 3 | boolean | Open API ✓ | Automatically redirect to redirectUrl after order completion without showing success page. | Seamless user experience |
HIDE_SEND | 6 | boolean | Open API ✓ | Hide the "Send" tab in the UI. Useful when only buy flow is needed. | Buy-only integration |
SEND_PRIMARY | 7 | boolean | Open API ✓ | Enable Send Crypto feature. If user's Binance balance is insufficient, auto-trigger buy flow first. | Send crypto to external address |
MERCHANT_DISPLAY_NAME | 8 | string | Open API ✓ | Override the display name shown to users in the UI. | Custom branding |
NET_RECEIVE | 9 | boolean | Open API ✓ | User receives net amount after deducting all fees. Total cost is more transparent. | Better UX for showing final received amount |
P2P_EXPRESS | 10 | boolean | Open API ✓ | Enable P2P Express mode for faster P2P order matching. | Quick P2P transactions |
OPEN_NETWORK | 11 | boolean | Web3 only | Allow users to select different networks. Default is locked to pre-selected network. Note : Currently only available for Web3 entrance, not available for Open API. | Multi-network support (Web3 only) |
ON_CHAIN_PROXY_MODE | 12 | boolean | Open API ✓ | Enable Onchain-Pay Easy mode. After buying crypto, Onchain-Pay will execute smart contract interaction instead of direct withdrawal to user wallet. Requires destContractAddress, destContractABI, and destContractParams. | Fiat to Smart Contract integration |
SEND_PRIMARY_FLEXIBLE | 13 | boolean | Open API ✓ | Flexible Send Primary mode with more options. | Advanced send crypto scenarios |