Cancel physical cards
If a physical card is lost, stolen, damaged, or hasn't been delivered, call the cancelPhysicalCard
mutation to cancel the card.
cancellation is irreversible
Canceling a physical card is a permanent action that can't be reversed. This guide explains how to cancel a physical card and how it impacts connected digital and virtual cards.
Guide​
- Call the
cancelPhysicalCard
mutation. - Add the
cardId
for the physical card you're canceling (line 2) - Select the reason for cancelling the card. (line 2).
- Add the
CancelPhysicalCardSuccessPayload
, including any information you'd like to review (line 3). - Add rejections (not shown).
Mutation​
🔎 Open the mutation in API Explorer
mutation MyMutation {
cancelPhysicalCard(input: { cardId: "$YOUR_CARD_ID", reason: Lost }) {
... on CancelPhysicalCardSuccessPayload {
__typename
physicalCard {
statusInfo {
... on PhysicalCardCanceledStatusInfo {
__typename
status
reason
}
}
}
}
}
}
Payload​
The payload confirms that the physical card is Canceled
(line 8) because it was reported as Lost
(line 9).
{
"data": {
"cancelPhysicalCard": {
"__typename": "CancelPhysicalCardSuccessPayload",
"physicalCard": {
"statusInfo": {
"__typename": "PhysicalCardCanceledStatusInfo",
"status": "Canceled",
"reason": "Lost"
}
}
}
}
}
Digital and virtual cards​
When a physical card is canceled, digital cards linked to the physical card will also be canceled. Virtual cards will not be affected.
tip
Swan recommends only digitizing virtual cards for a safer experience.
Refer to the guides for digital and virtual cards if you need to cancel those as well.