银行转账
汇款请求¶
请求付款,并将资金转移到外部银行机构。注意,此汇款方式对方到账时间受银行营业时间影响。
HTTP请求¶
POST /v1/payments/payouts/transfer
Request Headers
{
    "Content-Type": "application/json",
    "Authorization": "Bearer {{access_token}}",
    "x-api-key": "{{api_key}}"
}
Request Body
{
    "idempotencyKey": "idempotency-key",
    "country": "PE",
    "targetName": "Test Name",
    "targetDocument": "0000000",
    "targetDocumentType": "RUC",
    "targetBankAccountId": "0000000001",
    "targetBankAccountType": "SAVINGS",
    "amountInCents": 10000,
    "currency": "PEN",
    "comment": "transfer payout test",
    "callbackUrl": "https://api.client.com/callback/",
    "subMerchantId": "UUID"
}
HTTP Headers 字段说明¶
| Key | Value | 
|---|---|
| Content-Type | application/json | 
| Authorization | "Bearer" + " " + {{access_token}} | 
| x-api-key | {{api_key}} | 
Request Body 字段说明¶
| 参数 | 是否必填 | 类型 | 描述 | 
|---|---|---|---|
| idempotencyKey | String | 此参数用于幂等目的,交易的唯一标识ID 长度不大于128个字节。 | |
| country | String | 用户的国际缩写码,遵循ISO 3166-1 alpha-2 code标准, PE | |
| targetName | String | 目标账号持有人的全名.如果设置了targetLastName,此处只需要填写First Name | |
| targetLastName | String | 目标账号持有人Last Name | |
| targetEmail | String | 目标账户持有人的电子邮箱 | |
| targetPhone | String | 目标账户持有人的电话,格式 +51xxxxxxxxx | |
| targetBirthDate | String | 目标账户持有人的生日信息,格式 yyyy-MM-dd | |
| targetDocument | String | 目标账户持有人的证件号。 | |
| targetDocumentType | String | 目标账户持有人的证件类型。DNI, RUC, PERU_CE, PERU_PASSPORT_ID。 DNI -> National Identity Document RUC -> Unique Taxpayer Registry PERU_CE -> National Identity Card PERU_PASSPORT_ID -> Passport  | 
|
| targetBankAccountId | String | 目标账号的账号ID | |
| targetBankAccountType | String | 目标账户的账户类型。CHECKING,SAVINGS | |
| amountInCents | Long | 汇款金额,注意: 100 = 1PEN | |
| currency | String | 必传。PEN | |
| callbackUrl | String | 接收交易状态变更通知的地址,接收post请求 | |
| subMerchantId | String | 子商户ID。商户类型为PSP时必填。 | |
| riskData | JSON | 支付的风险信息。MERCHANT_APP_NAME 或 MERCHANT_WEBSITE 在riskData中必须填一个。 请参考这里查看更多详情。 | 
创建一个带风控信息的支付¶
请参考这里查看更多详情。
Response Body 字段说明¶
| 参数 | 类型 | 描述 | 
|---|---|---|
| idempotencyKey | String | 交易的唯一标识ID | 
| statusCode | Integer | 此次请求API状态代码,200代表API请求成功, 401 访问受限, 422 参数错误, 500 内部错误 | 
| errorMsg | String | 如果API请求失败,返回的错误信息 | 
| transferStatus | String | 汇款状态,枚举值,"SETTLED", "FAILED", "IN_PROGRESS" 或者 "REJECTED", 交易状态应以transferStatus为准 | 
| transferStatusCode | Integer | 此次交易的状态码, 交易异常码 | 
| transferErrorMsg | String | 此次交易失败原因 | 
支持的银行¶
支持所有拥有 CCI 20 位账户的秘鲁银行