Cancel virtual cards
Cancel virtual cards with the API. Consent isn't required to cancel cards.
cancellation is irreversible
Canceling a virtual card is an irreversible action that immediately and permanently invalidates the card. All physical and digital cards associated to the virtual card are also canceled.
Learn more about virtual card cancellation on the virtual cards homepage.
Guide​
- Call the
cancelCard
mutation. - Add the virtual
cardId
for the card you're canceling (line 2). - Add the success payload, including any information you'd like to review (line 3).
- Add rejections (not shown).
Mutation​
🔎 Open the mutation in API Explorer
mutation CancelVirtualCard {
cancelCard(input: { cardId: "$YOUR_CARD_ID" }) {
... on CancelCardSuccessPayload {
__typename
card {
statusInfo {
status
}
}
}
}
}
Payload​
The payload confirms that the virtual card is Canceled
.
{
"data": {
"cancelCard": {
"__typename": "CancelCardSuccessPayload",
"card": {
"statusInfo": {
"status": "Canceled"
}
}
}
}
}