API Reference
1. Info
- Title: gRPC API
- Version: 1.0.0
- Description: This documentation is generated from protobuf files using protoc-gen-doc.
2. Paths
BankBridge
CreateBankWalletInfo
- Summary: 创建用户虚拟收款账号
- Method:
CreateBankWalletInfo - Endpoint:
bank_bridge.BankBridge/CreateBankWalletInfo - Request:
- Content-Type:
application/grpc - Schema: CreateBankWalletInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: CreateBankWalletInfoResponse
- Content-Type:
GetBankWalletInfo
- Summary: 查询用户虚拟收款账号
- Method:
GetBankWalletInfo - Endpoint:
bank_bridge.BankBridge/GetBankWalletInfo - Request:
- Content-Type:
application/grpc - Schema: GetBankWalletInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: GetBankWalletInfoResponse
- Content-Type:
BatchGetBankWalletInfo
- Summary: 批量查询wallet信息,若查不到则创建返回
- Method:
BatchGetBankWalletInfo - Endpoint:
bank_bridge.BankBridge/BatchGetBankWalletInfo - Request:
- Content-Type:
application/grpc - Schema: BatchGetBankWalletInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: BatchGetBankWalletInfoResponse
- Content-Type:
CreateBankInfo
- Summary: 创建银行信息
- Method:
CreateBankInfo - Endpoint:
bank_bridge.BankBridge/CreateBankInfo - Request:
- Content-Type:
application/grpc - Schema: CreateBankInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: CreateBankInfoResponse
- Content-Type:
GetBankInfo
- Summary: 查询银行信息
- Method:
GetBankInfo - Endpoint:
bank_bridge.BankBridge/GetBankInfo - Request:
- Content-Type:
application/grpc - Schema: GetBankInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: GetBankInfoResponse
- Content-Type:
CreateBankCardInfo
- Summary: 创建银行卡信息
- Method:
CreateBankCardInfo - Endpoint:
bank_bridge.BankBridge/CreateBankCardInfo - Request:
- Content-Type:
application/grpc - Schema: CreateBankCardInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: CreateBankCardInfoResponse
- Content-Type:
GetBankCardInfo
- Summary: 获取银行卡信息
- Method:
GetBankCardInfo - Endpoint:
bank_bridge.BankBridge/GetBankCardInfo - Request:
- Content-Type:
application/grpc - Schema: GetBankCardInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: GetBankCardInfoResponse
- Content-Type:
GetBankAgentInfo
- Summary: 查询中转银行信息
- Method:
GetBankAgentInfo - Endpoint:
bank_bridge.BankBridge/GetBankAgentInfo - Request:
- Content-Type:
application/grpc - Schema: GetBankAgentInfoRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: GetBankAgentInfoResponse
- Content-Type:
OnTransactionReceived
- Summary: 入金/出金回调
- Method:
OnTransactionReceived - Endpoint:
bank_bridge.BankBridge/OnTransactionReceived - Request:
- Content-Type:
application/grpc - Schema: OnTransactionReceivedRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: OnTransactionReceivedResponse
- Content-Type:
InitiateWithdrawal
- Summary: 出金
- Method:
InitiateWithdrawal - Endpoint:
bank_bridge.BankBridge/InitiateWithdrawal - Request:
- Content-Type:
application/grpc - Schema: InitiateWithdrawalRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: InitiateWithdrawalResponse
- Content-Type:
OnWithdrawalRequested
- Summary: 出金回调
- Method:
OnWithdrawalRequested - Endpoint:
bank_bridge.BankBridge/OnWithdrawalRequested - Request:
- Content-Type:
application/grpc - Schema: OnWithdrawalRequestedRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: OnWithdrawalRequestedResponse
- Content-Type:
BindBankCard
- Summary: 绑定用户银行卡
- Method:
BindBankCard - Endpoint:
bank_bridge.BankBridge/BindBankCard - Request:
- Content-Type:
application/grpc - Schema: BindBankCardRequest
- Content-Type:
- Response:
- Content-Type:
application/grpc - Schema: BindBankCardResponse
- Content-Type:
3. Components
3.1 Schemas
BankAgentInfo
中转银行信息
| Field | Type | Description |
|---|---|---|
| bankId | int64 | bankId |
| bankName | string | 银行名称 |
| bankCountry | string | 银行国家 |
| bankAddress | string | 银行地址 |
| bankNo | string | 银行账号 |
| bankSwift | string | 银行SWIFT |
BankCardInfo
银行卡信息
| Field | Type | Description |
|---|---|---|
| bankCardNo | string | 银行卡号 |
| cardType | string | 卡类型 |
| idRealName | string | 真实姓名 |
| idCardNo | string | 身份证号 |
| bankCardName | string | 卡名 |
| BankInfo | BankInfo | 银行信息 |
BankInfo
银行信息
| Field | Type | Description |
|---|---|---|
| bankId | int64 | bankId |
| bankName | string | 银行名称 |
| bankCountry | string | 银行国家 |
| bankAddress | string | 银行地址 |
| bankNo | string | 银行账号 |
| bankSwift | string | 银行SWIFT |
| bankAgentInfo | BankAgentInfo | 中转银行信息 |
BatchGetBankWalletInfoRequest
批量查询wallet信息请求
| Field | Type | Description |
|---|---|---|
| userId | string | 用户ID列表 |
BatchGetBankWalletInfoResponse
批量查询wallet信息响应
| Field | Type | Description |
|---|---|---|
| list | GetBankWalletInfoResponse | wallet信息列表 |
BindBankCardRequest
绑定银行卡请求
| Field | Type | Description |
|---|---|---|
| userId | string | 用户ID |
| idRealName | string | 姓名 |
| idCardNo | string | 证件号码 |
| bankCardNo | string | 虚拟账号 |
BindBankCardResponse
绑定银行卡响应
| Field | Type | Description |
|---|---|---|
| walletId | int64 | 钱包ID |
CreateBankCardInfoRequest
创建银行卡信息请求
| Field | Type | Description |
|---|---|---|
| bankId | int64 | 银行ID |
| bankCardInfos | BankCardInfo | 银行卡信息 |
CreateBankCardInfoResponse
创建银行卡信息响应
| Field | Type | Description |
|---|---|---|
| bankCardId | int64 | 银行卡ID |
CreateBankInfoRequest
创建银行信息请求
| Field | Type | Description |
|---|---|---|
| bankName | string | 银行名称 |
| bankCountry | string | 银行国家 |
| bankAddress | string | 银行地址 |
| bankNo | string | 银行账号 |
| bankSwift | string | 银行SWIFT |
CreateBankInfoResponse
创建银行信息响应
| Field | Type | Description |
|---|---|---|
| bankId | int64 | 银行ID |
CreateBankWalletInfoRequest
创建虚拟收款账号请求
| Field | Type | Description |
|---|---|---|
| userId | string | 用户ID |
| idRealName | string | 姓名 |
| idCardNo | string | 证件号码 |
CreateBankWalletInfoResponse
创建虚拟收款账号响应
| Field | Type | Description |
|---|---|---|
| walletId | int64 | 钱包ID |
GetBankAgentInfoRequest
查询中转银行信息请求
| Field | Type | Description |
|---|---|---|
| bankId | int64 | 银行ID |
GetBankAgentInfoResponse
查询中转银行信息响应
| Field | Type | Description |
|---|---|---|
| info | BankAgentInfo | 中转银行信息 |
GetBankCardInfoRequest
获取银行卡信息请求
| Field | Type | Description |
|---|---|---|
| bankCardId | int64 | 银行卡ID |
GetBankCardInfoResponse
获取银行卡信息响应
| Field | Type | Description |
|---|---|---|
| bankCardInfos | BankCardInfo | 银行卡信息 |
GetBankInfoRequest
获取银行信息请求
| Field | Type | Description |
|---|---|---|
| bankId | int64 | 银行ID |
GetBankInfoResponse
获取银行信息响应
| Field | Type | Description |
|---|---|---|
| bankInfo | BankInfo | 银行信息 |
GetBankWalletInfoRequest
查询虚拟收款账号请求
| Field | Type | Description |
|---|---|---|
| userId | string | 用户ID |
GetBankWalletInfoResponse
查询虚拟收款账号响应
| Field | Type | Description |
|---|---|---|
| userId | string | 用户id |
| walletId | int64 | wallet id |
| remark | string | 附言 |
| bankCardId | int64 | 银行卡Id |
| walletType | string | 钱包类型 |
| bankCardInfo | BankCardInfo | 银行卡信息 |
InitiateWithdrawalRequest
出金请求
| Field | Type | Description |
|---|---|---|
| userId | string | userId |
| transaforInfo | InitiateWithdrawalRequest.TransaforInfo | 转账信息 |
TransaforInfo
| Field | Type | Description |
|---|---|---|
| accountOpenBank | string | 付款方信息 收款人开户行 |
| agentBank | string | 收款人开户行之代理行,汇款类别是swift为必须 |
| bankCharge | string | 扣费方式 <br> 1:OUR--所有的业务费用由汇款客户负担 <br> 2:BEN--所有的业务费用由收益客户负担 <br> 3:SHA--发报方的业务费用由汇款客户负担 收报行的业务费用由收益客服负担,默认3 |
| feeAccount | string | 扣费账号 |
| payeeAccount | string | 收款人账号 |
| payeeAddress1 | string | 收款人地址1 |
| payeeAddress2 | string | 收款人地址2 |
| payeeAddress3 | string | 收款人地址3 |
| payeeCountry | string | 收款人国别 |
| payeeName | string | 收款人名称 |
| payerAccount | string | 母账号 |
| remittanceAmount | string | 汇款金额(单元:分) |
| remittanceCurrency | string | 汇款币别 |
| remittancePurpose | string | 汇款目的 |
| remittancePurposes | string | 汇款用途 |
| remittanceRemark1 | string | 汇款附言1 |
| remittanceRemark2 | string | 汇款附言2 |
| remittanceRemark3 | string | 汇款附言3 |
| remittanceRemark4 | string | 汇款附言4 |
| remittanceType | string | 汇款类别:"SW:发送swift,CH:发送chats" |
| serialNumber | string | 流水号唯一值 |
| subAccount | string | 虚拟子账户 |
InitiateWithdrawalResponse
出金响应
| Field | Type | Description |
|---|---|---|
| retCode | string | AC0000-成功 <br> AC1000-银行处理中 <br> AC0010-限额检查异常 <br> AC0011-超过渠道转出限额 <br> AC0012-超过商户单笔转出限额 <br> AC0013-超过商户单日累计限额 <br> AC0015-超过月累计限额 <br> AC0016-重复请求 <br> AC0017-非法请求 <br> AC0018-不符合同名出金校验 <br> AC0021-子账户不存在 <br> AC0022-账户签约状态异常 <br> AC0025-母账户状态异常 <br> AC0026-子账户与母账户信息不匹配或已销户 <br> AC0028-账号不是母账号 <br> AC0032-暂不支持该转账方式 <br> AC0033-虚拟子账户开户成功后,需要间隔%s分钟才能出金 <br> AC0034-查询账户信息异常 <br> AC0035-费用账户不存在 <br> AC0036-费用账户异常 <br> AC0037-暂不支持该币种 <br> AC0038-余额不足 <br> AC0039-账户不存在 <br> AC0040-账户受限 |
| retMsg | string | 返回信息 |
OnTransactionReceivedRequest
入金/出金回调请求
| Field | Type | Description |
|---|---|---|
| reqBody | bytes | 回调请求体 |
OnTransactionReceivedResponse
入金/出金回调响应
| Field | Type | Description |
|---|
OnWithdrawalRequestedRequest
出金回调请求
| Field | Type | Description |
|---|---|---|
| reqBody | bytes | 回调请求体 |
OnWithdrawalRequestedResponse
出金回调响应
| Field | Type | Description |
|---|
TransactionBody
The TransactionBody message definition
| Field | Type | Description |
|---|---|---|
| userId | string | userId |
| body | TransactionBody.Body | 交易信息 |
Body
交易信息
| Field | Type | Description |
|---|---|---|
| accountNo | string | 对方帐号 |
| accountName | string | 对方账号名称 |
| bankCode | string | 对方银行编码:如果渠道是chats或swift,返回的是swiftcode |
| crdrFlag | string | 借贷标记:D:出金 C:入金 |
| currency | string | 交易币种 |
| fee | string | none |
| journalNo | string | 银行核心流水号 |
| merchantSequenceNo | string | 商户端流水号 |
| mmo | string | C01 对公转账转出 轉賬 transfer <br> C03 对公批量转账转出 批量轉賬 batch transfer <br> C04 对公发薪 支付薪金 payroll <br> C05 FPS转出 轉數快轉賬 FPS transfer <br> C18 网银一对多批量转账收款方入账 轉賬 transfer <br> C19 企业账户批量转账退回入账 批量轉賬退回 Transfer returned <br> C20 企业账户發薪退回入账 發薪退回 Payroll returned <br> C21 活期過渡戶轉出(發薪) 發薪轉出 Payroll withdrawal <br> C22 活期過渡戶轉入(發薪) 發薪轉入 Payroll Inward <br> C23 FPS转出 轉數快轉賬 FPS transfer <br> C24 虚拟子账户行内转出 本地轉賬 Local transfer <br> C25 虚拟子账户行内转入 存入 Inward fund transfer <br> C26 FPS商戶入賬 存入 Inward fund transfer <br> C27 FPS商戶扣費 存入服務收費 Service fee <br> C28 活期過渡戶轉出(批量轉賬) 批量轉賬轉出 Batch transfer withdrawal <br> C29 活期過渡戶轉入(批量轉賬) 批量轉賬轉入 Batch transfer Inward <br> C30 对公开户费用 開戶手續費 Account opening fee <br> C31 对公代扣转出场景 簽約代扣轉出 eDDA Auto debit <br> C32 对公代扣转入场景 簽約代扣轉入 eDDA Auto credit <br> C33 貸款放款 放款 Drawdown <br> C34 銀行貸款手續费 銀行貸款手續费 Arrangement Fee <br> C35 貸款放款 延遲提款手續費 Commitment Fee <br> C36 貸款償還本金 償還本金 Principal Paid <br> C37 貸款償還利息 償還利息 Interest Paid <br> C38 貸款償還逾期利息 償還逾期利息 Late Interest Paid <br> C39 貸款年審费 年審费 Credit Facilities Review Fee <br> C40 虚拟子账户行内转出 本地轉賬 Local transfer <br> C41 虚拟子账户行内转入 存入 Inward fund transfer <br> C42 提前還款手續費 提前還款手續費 Prepayment Fee <br> C43 資金中斷費 資金中斷費 Interest Compensation <br> C44 eDDA扣費 eDDA收費 eDDA Service fee <br> C45 DDI扣費 DDI收費 DDI Service fee <br> C46 網上銀行月費 網上銀行月費 Internet Banking Monthly Fee <br> C47 FPS匯出收費 FPS匯出收費 FPS Outward Transfer Fee <br> C48 設立VA收費 設立VA收費 VA Creation Fee <br> C49 API月費 API月費 API monthly management fee <br> C50 更改/取消轉賬費用 更改/取消轉賬費用 Payment Amendment/Cancellation Fee <br> C51 公司查冊費用 公司查冊費用 Company Search Fee <br> C52 修訂公司資料費用 修訂公司資料費用 Company Information Amendment Fee <br> C53 銀行確認資料供核數費用 審計詢證費 Audit Confirmation Fee <br> C55 行内二维码商户转入 二維碼存入 QR fund in <br> C56 FPS轉賬失敗 轉數快轉賬退回 FPS transfer reversal <br> C57 貸款設置費 貸款設置費 Loan set-up fee <br> C58 貸款設置費退回 貸款設置費退回 Loan set-up fee refund <br> C59 貸款重檢費 貸款年檢費 Loan review fee <br> C60 貸款重檢費non-sfgs 額度重檢費 Review Fee <br> C61 中小企融資擔保費 中小企融資擔保費 SME Financing Guarantee Fee <br> C62 对公对客credit 貨幣兌換 Currency Exchange <br> C63 对公对客debit 貨幣兌換 Currency Exchange <br> C64 FPS跨境轉入 「轉數快」跨境轉入 FPS Cross-border Fund In <br> C65 逾期利息退回 逾期利息退回 Overdue Interest refund <br> C66 利息退回 利息退回 Interest refund <br> C67 預繳費用退回 預繳費用退回 Prepayment fee refund <br> C68 貸款續期 貸款續期 Rollover <br> C69 抵押贖回盈餘退回 抵押贖回盈餘退回 Redemption surplus refund <br> C70 抵押贖回逆差費用 抵押贖回逆差費用 Redemption shortfall recovery <br> C71 中小企融資擔保費退回 中小企融資擔保費退回 Guarantee fee refund <br> C72 貸款重檢費退回 貸款重檢費退回 Loan review fee refund <br> C73 CHATS批量轉賬轉出 CHATS批量轉賬 CHATS Batch Fund Transfer <br> C74 RM開戶費用 開戶費 Account opening Fee <br> C75 E-onboarding開戶費用 開戶費 Account opening Fee <br> C76 RM開戶公司查冊費用 公司查冊費 Company search Fee <br> C77 E-onboarding開戶公司查冊費用 公司查冊費 Company search Fee <br> C78 FPS批量轉賬轉出 「轉數快」批量轉賬 FPS Batch Fund Transfer <br> RTD 轉帳轉入沖正 轉入沖正 Inward fund transfer reversal <br> PIA 活期利息收入 活期利息 Interest <br> RTW 轉帳轉出沖正 轉出沖正 Fund transfer reversal <br> TFD 轉帳轉入 轉入 Inward fund transfer <br> D02 二維碼存入 二維碼存入 QR fund in <br> D05 存入chats 存入 Inward fund transfer <br> D06 存入fps 存入 Inward fund transfer <br> D07 存入薪金 存入薪金 Salary income <br> D11 匯款存入 匯款存入 Inward remittance <br> D14 匯款存入 匯款存入 Inward remittance <br> D20 人工SWIFT轉入 匯款存入 Inward remittance <br> D21 人工CHATS轉入 存入 Inward fund transfer <br> F00 轉出手續費支出 轉賬服務收費 Service fee <br> F01 轉入手續費支出 存入服務收費 Service fee <br> FEE 人工 公司查冊費 Company Search Fee <br> T14 人工chats 本地轉賬 Local transfer <br> T15 人工fps 本地轉賬 FPS transfer <br> T39 人工swift 匯款 Remittance <br> TFW 人工 本地轉賬 Local transfer <br> CTN 人工退款 轉賬退款 Transfer Refund |
| primaryAccount | string | 母账户 |
| primaryAccountName | string | 母账户名 |
| remark | string | 备注 |
| tradeDate | string | 交易日期:格式: YYYYMMDD |
| tradeTime | string | 交易时间:格式: hhmmss |
| transferAmount | double | 交易金额 |
| transferStatus | string | 交易状态:0000成功 |
| virtualAccountNo | string | 子账户号 |
| virtualAccountName | string | 子账户名 |
| bankName | string | 银行名称 |
| bankNo | string | 银行编号 |
| bankUniqueSerialNo | string | 银行唯一流水号 |
WithdrawalBody
| Field | Type | Description |
|---|---|---|
| merchantSequenceNo | string | 商户端流水号,需要查证的商户端流水号 |
| tradeDate | string | 交易日期,格式YYYYMMDD |
| journalNo | string | 银行流水号 |
| fee | string | 服务费用 |
| transferStatus | string | 处理结果 <br> 0000-成功 <br> 9999-失败 <br> 6666-状态未明 <br> 7777-已冲正 |
3.2 Enums
4. Scalar Value Types
| Proto Type | Go Type | C++ Type | Java Type | Python Type | Notes |
|---|---|---|---|---|---|
| double | float64 | double | double | float | |
| float | float32 | float | float | float | |
| int32 | int32 | int32 | int | int | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. |
| int64 | int64 | int64 | long | int/long | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. |
| uint32 | uint32 | uint32 | int | int/long | Uses variable-length encoding. |
| uint64 | uint64 | uint64 | long | int/long | Uses variable-length encoding. |
| sint32 | int32 | int32 | int | int | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. |
| sint64 | int64 | int64 | long | int/long | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. |
| fixed32 | uint32 | uint32 | int | int | Always four bytes. More efficient than uint32 if values are often greater than 2^28. |
| fixed64 | uint64 | uint64 | long | int/long | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. |
| sfixed32 | int32 | int32 | int | int | Always four bytes. |
| sfixed64 | int64 | int64 | long | int/long | Always eight bytes. |
| bool | bool | bool | boolean | boolean | |
| string | string | string | String | str/unicode | A string must always contain UTF-8 encoded or 7-bit ASCII text. |
| bytes | []byte | string | ByteString | str | May contain any arbitrary sequence of bytes. |
