2.1.38 Inquiry on bank card detail-v2
Path:/v2/openapi/card/bank/details
Method:POST
Content-Type:application/json
Response Content-Type:application/json
Description:
This is the upgraded version of API 2.1.7.
If Ways to obtain bank card details=1(
card_detail_obtain_way=1
), can only call this interfaceThis interface also supports the case of
card_detail_obtain_way=0
, for details, refer to the content of the interface response
Example Request:
{
"card_id": "00003454323400000028888",
"pub_key": "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC37by7wUaaPgE0ljdw3F/8OX6qzcX6rKzcmCtn2cKHbuZ+ynPGgFZX5lqlEEKdXI8sBEuqtxU+0G+eRlmTtSAqqytF0K0rM50mKGfF2hPw//Z4ajKymsRghdiUPXJ6AxN8oyY15l1uMZcD0Ru0/OQp7VdSLNtZmKDOMhm9GeodAwIDAQAB"
}
Request Parameter:
Parameter Name | Type | Required | Description |
---|---|---|---|
card_id | string | true | Card ID |
pub_key | string | true | Public key(PKCS8);We will use this public key as key for RSA encryption to encrypt the card detail inside the respond |
API Response:
Parameter Name | Type | Description |
---|---|---|
code | string | Error code |
data | Card information | Data response |
encoded_card_detail | string | Encrypted card information; Will using the pub_key to do the encryption, and the result encoded into base64 format. Decrypted data structure: 1. When card_detail_obtain_way=1: {"url":"https://www.test.com/card?card?8888888888888888", "password":"888888"} 2. When card_detail_obtain_way=0 and card_type=1: {"cvv":"123","card_number":"1001022400001101","expire":"04/2025"} 3. When card_detail_obtain_way=0 and card_type=2: {"card_number":"123456789101212"} 4、When card_detail_obtain_way=2 and card_type=1:{"cvv":"please check in email","card_number":"1001022400001101","expire":"please check in email"} |
pub_key | string | Public key; same with request pub_key |
card_id | string | Card ID; same with request card_id |
card_detail_obtain_way | integer | Ways to obtain bank card details; 0: Obtain through the API interface, 1: Obtain by encryption (the user opens the page and enters the password to query the card number), 2: Obtain through email |
card_type | integer | Bank card type; 1 virtual card, 2 physical card |
msg | string | Error message |
Example Response:
{
"code": "00000",
"data": {
"encoded_card_detail": "RJQh36jdCnPQhZpsbe/43LSpFDykr/aGoYgXmYQwepqKxyQnF2tM9/es0jy5WKNhMGETH/qAHHn41A/aHDE1/wyiz/fxxHrrsP1R+0aoVXs3BH+VTHqBYwqXUQMJEN0MMCaGNFFAn+HvxcO38NZeqsyXJyoKpvPqF0G1196q75A=",
"pub_key": "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC37by7wUaaPgE0ljdw3F/8OX6qzcX6rKzcmCtn2cKHbuZ+ynPGgFZX5lqlEEKdXI8sBEuqtxU+0G+eRlmTtSAqqytF0K0rM50mKGfF2hPw//Z4ajKymsRghdiUPXJ6AxN8oyY15l1uMZcD0Ru0/OQp7VdSLNtZmKDOMhm9GeodAwIDAQAB",
"card_id": "00003454323400000028888",
"card_detail_obtain_way" : 0,
"card_type": 1
},
"msg": "ok"
}