Skip to main content

Cancel a funding source

Cancel a funding source with the API. Note that canceling a funding source also cancels the direct debit mandate.

You can cancel a funding source with a project access token. Account members with the canManageAccountMembership permission can also cancel funding sources.

Guide​

  1. Call the cancelFundingSource mutation.
  2. Enter the ID for the funding source you'd like to cancel.
  3. Add the success payload and rejections.

Mutation​

🔎 Open the mutation in API Explorer

mutation CancelSource {
cancelFundingSource(input: { id: "$YOUR_FUNDING_SOURCE_ID" }) {
... on CancelFundingSourceSuccessPayload {
__typename
fundingSource {
statusInfo {
status
}
}
}
... on ForbiddenRejection {
__typename
message
}
... on NotFoundRejection {
id
message
}
}
}

Payload​

The payload shows that the funding source is Canceled and can't be used anymore. The direct debit mandate is also Canceled.

{
"data": {
"cancelFundingSource": {
"__typename": "CancelFundingSourceSuccessPayload",
"fundingSource": {
"statusInfo": {
"status": "Canceled"
}
}
}
}
}