修改实体卡密码
每张实体卡都有一个用于授权交易的密码,必要时可以更新。
要更新卡片密码,卡片状态必须为**Active(有效)或Temporary block(临时封锁)**类型。(有关状态的详细信息,请参阅此处)
注意
出于安全原因,更新密码时需谨慎,因为这可能影响卡片的授权。
请制定规则以提高密码授权的安全性,例如不使用生日日期、重复数字(如:3333)等。
Request
ENDPOINT
/prepaid/card/CARD_KEY/passwordMÉTODO
PATCH路径参数
| 字段 | 类型 | 描述 | 字符数 |
|---|---|---|---|
CARD_KEY * | string | 卡片识别密钥。 | uuid |
Request Body
{
"pin": "2143"
}
请求体参数
| 字段 | 类型 | 描述 | 字符数 |
|---|---|---|---|
pin * | string | 用于授权交易的卡片密码。 | 4 |
Response
STATUS SUCCESS
200错误
STATUS
4XXResponse Body
{
"title": "Bad Request",
"description": "We're sorry, but the card could not be update password. Please try again later.",
"translation": "Unexpected error update password card",
"code": "CARD000024"
}
| Code | Status code | 描述 |
|---|---|---|
| QIT000001 | 400 | Invalid Json schema. |
| CARD000011 | 404 | It was not possible to fetch the Card for the card_key {card_key}. |
| CARD000023 | 406 | The card type is invalid for this operation. Only plastic cards are allowed. |
| CARD000024 | 400 | We're sorry, but the card could not be update password. Please try again later. |
| CARD000025 | 406 | The status {status} is invalid for the operation. |
Webhook
WEBHOOK_TYPE
baas.prepaid_card.card.updated.passwordWebhook Body
{
"webhook_type": "baas.prepaid_card.card.updated.password",
"event_datetime": "2023-07-25T12:00:00.000Z",
"data": {
"card_key": "9bd93e97-bb6d-410f-8981-06b2765f12a1"
}
}