跳到主要内容

执行 TED 批量交易

QI Tech 提供通过单次 API 调用执行多笔 TED 交易的功能。在此系统中,交易以异步方式执行。如果初始调用返回 http status 4xx,则不会执行任何交易。请求后,集成合作伙伴将为每笔交易收到一个 Webhook,告知尝试的最终状态,可能为 rejectedsent

请求

ENDPOINT
/account/ACCOUNT_KEY/ted_batch
方法
POST
{
"request_control_key": "6e4fc980-f8a1-4462-b6e2-d8a49f0ac055",
"teds": [
{
"request_control_key": "0c3d2a3e-c121-464e-b5a4-8e69e0c17bbd",
"target_account": {
"account_branch": "0001",
"account_number": "92796",
"account_digit": "1",
"owner_document_number": "23599885000192",
"owner_name": "Titular da Conta",
"ispb": "12345678",
"account_type": "checking_account"
},
"transaction_amount": 8.86
}
]
}

Path Params

字段类型描述字符数
account_keyuuidv4账户的唯一标识键。36

Body Params

字段类型描述字符数
request_control_key *uuidv4客户使用的 uuid v4 格式的请求唯一标识键。36
teds *array与批次关联的 TED 对象列表。列表 Objeto ted

Objeto ted

字段类型描述字符数
request_control_key *string客户使用的 uuid v4 格式的请求唯一标识键。36
target_account *object目标账户Objeto target_account
transaction_amount *float转账金额10

Objeto target_account

字段类型描述字符数
account_branch *string银行代码(机构代码)。4
account_digit *string账户校验码1
account_number *string账户号码。20
owner_document_number *string账户持有人的 CPF 或 CNPJ(仅数字)。14
owner_name *string账户持有人姓名。50
account_type *string账户类型。Enumerador account_type
ispb *string基于金融机构 CNPJ(8 位数字)。8

Enumerador account_type

枚举值翻译
checking_account活期账户
deposit_account存款账户
guaranteed_account担保账户
investment_account投资账户
payment_account付款账户
saving_account储蓄账户

响应

STATUS
201
Response Body: 已批准批量转账
{
"request_control_key": "b6804f32-101e-4702-8fbc-c2dbc4c2caec",
"ted_batch_key": "8cb70dea-9fb0-4a68-9572-99a72849c8d6",
"ted_batch_status": "approved"
}

Enumerador ted_batch_status

枚举值描述
approved批量转账已批准,交易正在执行中。
rejected批量转账已拒绝
pending_2fa_approval批量调度待双因素身份验证批准
cancelled批量转账已取消
STATUS
4xx
Response Body: 已拒绝批次
{
"title": "titulo",
"description": "description in English",
"translation": "descrição em portugues",
"code": "codigo",
"extra_fields": {
"ted_batch_data": {
"request_control_key": "b6804f32-101e-4702-8fbc-c2dbc4c2caec",
"ted_batch_key": "8cb70dea-9fb0-4a68-9572-99a72849c8d6",
"ted_batch_status": "rejected"
}
}
}
STATUS
4xx
Response Body: Error
{
"title": "titulo",
"description": "description in English",
"translation": "descrição em portugues",
"code": "codigo",
"extra_fields": {}
}
信息

此端点也可能返回 TED 转账 中列出的错误。