更新状态
Request
ENDPOINT
/wallet/WALLET_KEY/card/CARD_KEYMÉTODO
PATCH路径参数
| 字段 | 类型 | 描述 | 字符数 |
|---|---|---|---|
WALLET_KEY * | string | 钱包识别密钥。 | uuid |
CARD_KEY * | string | 卡片识别密钥。 | uuid |
Request Body
{
"status": "blocked"
}
请求体参数
| 字段 | 类型 | 描述 | 字符数 |
|---|---|---|---|
status * | string | 卡片状态。 | 枚举值 |
card_status 枚举值
| 枚举值 | 说明 | 类型 |
|---|---|---|
| created | 已申请创建 | Initial |
| building | 创建中 | Initial |
| active | 可进行交易 | Active |
| embossing | 生产中 | Temporary block |
| blocked | 已封锁 | Temporary block |
| warning | 有可疑情况 | Temporary block |
| pending | 待处理 | Temporary block |
| lost | 已丢失 | Terminated |
| robbed | 被抢劫 | Terminated |
| fraud | 欺诈 | Terminated |
| canceled | 已取消 | Terminated |
| theft | 被盗 | Terminated |
错误
STATUS
4XX Response Body
{
"title": "Not Acceptable",
"description": "The operation is not valid for the current status of the card [canceled]",
"translation": "Unable to transition",
"code": "CARD000014"
}
| Code | Status code | 描述 |
|---|---|---|
| QIT000001 | 400 | Invalid Json schema. |
| CARD000011 | 404 | It was not possible to fetch the Card for the card_key {card_key}. |
| CARD000013 | 406 | Unable to transition from {old_status} to {new_status}. |
| CARD000014 | 406 | The operation is not valid for the current status of the card [{card_status}]. |
| CARD000015 | 400 | We're sorry, but the card could not be update. Please try again later |
Webhook
WEBHOOK_TYPE
baas.pospaid_card.cardWebhook Body
{
"webhook_type": "baas.pospaid_card.card",
"event_datetime": "2023-07-25T12:00:00.000Z",
"data": {
"card_key": "9bd93e97-bb6d-410f-8981-06b2765f12a1",
"type": "virtual",
"status": "active",
"old_status": "created"
}
}