唤醒 API 对接文档
API 基础信息
- 所有 API 请求都应在请求正文中以 JSON 格式 发送(对于 POST)。
- 所有回复都将采用 JSON 格式。
- 字符编码采用 UTF-8 编码。
- 发送的 POST 请求 Content-Type 采用 Content-Type: application/json; charset=utf-8
- 参数规范 唤醒金额:默认为 INR 1:1
- API 基本 URL https://api.aelopay.org
API 提交-加密-回调加密
- 将所有需要签名的字段按 ASCII 码升序排序,并按 a=b&c=d 的格式连接成一个字符串
- 然后使用 &secret=api_token(api_token 是商户的api-token)拼接商户的api-token,生成待签名的字符串。
- 除了 sign 以外不为空的参数都需要参与签名
- 使用 MD5 对 待签名的字符串 进行加密,生成小写签名字符串 sign
1. 代收下单接口
请求URL:
POST /v1/payin/transaction
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 必选 | 描述 |
|---|---|---|---|
| mid | String | Yes | 商户号 |
| sign | String | Yes | 签名 |
| order_id | String | Yes | 商户单号 6-40位 |
| amount | Integer | Yes | 金额(INR) |
| mobile | String | Yes | 手机号(10位数字) |
| name | String | Yes | 姓名(英文字母) |
请求示例:
POST https://api.aelopay.org/v1/payin/transaction
Content-Type: application/json
{
"mid": "312000",
"amount": 100,
"order_id": "1234567890",
"sign": "xxxxxxxxxxx",
"mobile": "8545785478",
"name": "Apus Yut"
}
成功返回示例:
{
"status": "true",
"message": "success",
"pay_url": "https://translate.google.com/",
"transaction_id": "111111111111"
}
失败返回示例:
{
"status": "false",
"message": "reason"
}
2. 代收查单接口
唤醒请求URL:
POST /v1/payin/transaction/status
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 必选 | 描述 |
|---|---|---|---|
| mid | String | Yes | 商户号 |
| sign | String | Yes | 签名 |
| order_id | String | Yes | 商户单号 6-40位 |
请求示例:
POST https://api.aelopay.org/v1/payin/transaction/status
Content-Type: application/json
{
"mid": "312000",
"order_id": "1234567890",
"sign": "xxxxxxxxxxxx"
}
成功返回示例:
{
"status": "true",
"message": "success",
"rrn": "5656565656",
"txnstatus": "success", //failed success pending
"transaction_id": "1111111111111111",
"order_id": "2222222222222",
"amount": 100,
}
失败返回示例:
{
"status": "false",
"message": "reason"
}
返回参数说明:
| 参数 | 类型 | 描述 |
|---|---|---|
| status | String | 响应状态:true=成功,false=失败 |
| message | String | 描述 |
| txnstatus | String | 订单状态-failed- success- pending |
| transaction_id | Integer | 平台单号 |
| order_id | String | 商户单号 |
| amount | int | 实际支付金额 |
| rrn | String | UTR |
3. 代收回调通知
请求URL:
POST 你的回调地址
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 描述 |
|---|---|---|
| txnstatus | String | 订单状态-failed- success- pending |
| mid | String | 商户号 |
| transaction_id | Integer | 平台单号 |
| order_id | String | 商户单号 |
| amount | int | 实际支付金额 |
| rrn | String | UTR |
| sign | String | 签名 |
请求示例:
POST 你的回调地址
Content-Type: application/json
{
"rrn": "5656565656",
"txnstatus": "success", //failed success pending
"transaction_id": "1111111111111111",
"order_id": "2222222222222",
"mid": "321000",
"amount": 100,
"sign": "xxxxxxxxxxxxxxxxxxx",
}
收到参数处理返回:
成功返回 SUCCESS
失败返回 FAILED
4. 代付下单请求
请求URL:
POST /v1/payout/transaction
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 必选 | 描述 |
|---|---|---|---|
| mid | String | Yes | 商户号 |
| sign | String | Yes | 签名 |
| order_id | String | Yes | 商户单号 6-40位 |
| amount | Integer | Yes | 金额 |
| bank_account | String | Yes | 卡号 |
| bank_ifsc | String | Yes | IFSC |
| bank_name | String | Yes | 姓名 |
| mobile | String | Yes | 手机号(10位不带91) |
| String | Yes | 邮箱 |
请求示例:
POST https://api.aelopay.org/v1/payout/transaction
{
"mid": "3100000",
"amount": "100",
"order_id": "123456",
"bank_account": "456456",
"bank_ifsc": "SDSS84545101",
"bank_name": "Yuis ds",
"mobile": "5485478962",
"email": "sddsda@gmail.com",
"sign": "xxxxxxxxxxxxxx"
}
成功返回示例:
{
"status": "true",
"message": "pending",
"txnstatus": "pending", //success failed pending reversal
"transaction_id": "TransactionId",
}
失败返回示例:
{
"status": "false",
"message": "reason",
}
5. 代付查单接口
请求URL:
POST /v1/payout/transaction/status
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 必选 | 描述 |
|---|---|---|---|
| mid | String | Yes | 商户号 |
| sign | String | Yes | 签名 |
| order_id | String | Yes | 商户单号 6-40位 |
请求示例:
POST https://api.aelopay.org/v1/payout/transaction/status
Content-Type: application/json
{
"mid": "312000",
"order_id": "1234567890",
"sign": "xxxxxxxxxxxxxx"
}
成功返回示例:
{
"status": "true",
"message": "success",
"rrn": "5656565656",
"txnstatus": "success", //订单状态:success=成功,pending=处理中,failed=失败 ,reversal=冲正
"transaction_id": "1111111111111111",
"order_id": "2222222222222",
"amount": 100,
}
失败返回示例:
{
"status": "false",
"message": "reason"
}
返回参数说明:
| 参数 | 类型 | 描述 |
|---|---|---|
| status | String | 响应状态:true=成功,false=失败 |
| message | String | 描述 |
| txnstatus | String | 订单状态:success=成功,pending=处理中,failed=失败 ,reversal=冲正 |
| transaction_id | Integer | 平台单号 |
| order_id | String | 商户单号 |
| amount | int | 实际支付金额 |
| rrn | String | UTR |
6. 代付回调通知
请求URL:
POST 你的回调地址
Request Format:
所有请求都应以 JSON 格式发送。
请求参数 (JSON Body):
| 参数 | 类型 | 描述 |
|---|---|---|
| txnstatus | String | 订单状态:success=成功,pending=处理中,failed=失败 ,reversal=冲正 |
| mid | String | 商户号 |
| transaction_id | Integer | 平台单号 |
| order_id | String | 商户单号 |
| amount | int | 实际支付金额 |
| rrn | String | UTR |
| message | String | 描述 |
| sign | String | 签名 |
请求示例:
POST 你的回调地址
Content-Type: application/json
{
"rrn": "5656565656",
"txnstatus": "success",
"transaction_id": "1111111111111111",
"order_id": "2222222222222",
"mid": "321000",
"amount": 100,
"message": "success",
"sign": "xxxxxxxxxxxxxxxxxxxx"
}
收到参数处理返回:
成功返回 SUCCESS
失败返回 FAILED
7. 接口余额查询
请求URL:
POST /v1/balance/check
参数 (Body - JSON):
| 参数 | 类型 | 必选 | 描述 |
|---|---|---|---|
| sign | String | Yes | 签名 |
| mid | String | Yes | 商户号 |
请求示例:
POST https://api.aelopay.org/v1/balance/check
Content-Type: application/json
{
"mid": "30121212",
"sign":"xxxxxxxxxxxxxxxxxxx"
}
成功返回示例:
{
"payout_wallet": 100,
"payin_wallet": 0,
"status":"true",
"message":"success"
}
失败返回示例:
{
"status":"false",
"message":"reason"
}
返回参数说明:
| 参数 | 类型 | 描述 |
|---|---|---|
| status | String | 响应状态:true=成功,false=失败 |
| message | String | 描述 |
| payout_wallet | Integer | 代付钱包金额 |
| payin_wallet | Integer | 代收钱包金额 |