Query of Card Balance

Brief Description

Card Balance Query

API Description

Environmental Information

Test environment domain name: https://sbx-card-api.alchemypay.org

Production environment domain name: https://card-api.alchemypay.org

Request URL

/open/merchant/api/findUserCardBalance

Request Method

  • post
  • Content-Type: application/json

Request Parameters

ParameterSignatureRequiredTypeLengthDescription
cardIdYesYesstring64Card ID
appIdYesYesstring32Merchant appid
signNoYesstring512Signature

Note: "Signature" indicates whether the parameter needs to be included in the signature calculation.

Request Example:

{
    "cardId": "c_590c6c4cc0f6471b979b",
    "appId": "qmamnbodyqzbdr0w",
    "sign": "8979EEB59CF15246A04E033962CA4084973A9D0F2F5CC08F07B99E9D0338F4486ED7700CF78F6365C2E399ED593B3EF9059F2EC808B5107CED8CC17BA0475962"
}

Response Parameters

ParameterTypeDescription
codestringCode - code description for details
msgstringReturn information
+modelobjectReturned when successful
└ currencystringCurrency
└ balancedoubleCard balance
└ topUpBalancedoubleRechargeable amount
traceIdstringNo description available
successbooleanSuccess status
errorbooleanFailure status

Success Response Example:

{
    "code":"0",
    "msg":"success",
    "model":{
        "currency":"EUR",
        "balance":100.01,
        "topUpBalance":9989.99
    },
    "traceId":"64461f5414909b4b1e05a58fd7e818d1",
    "error":false,
    "success":true
}

Failure Response Example:

{
    "code": "1002",
    "msg": "User card information does not exist c_590c6c4cc0f6471b979b ",
    "model": null,
    "traceId": "6566f01975d31fa30b55fb9a2a5c5516",
    "error": true,
    "success": false
}

Note:

For more error codes, please refer to the error code description on the homepage.