Anchor to section titled 'undefined'

customerPaymentMethodRevoke
mutation

Requires write_customers access scope. Also: Requires write_customer_payment_methods scope.

Revokes a customer's payment method.


Anchor to customerPaymentMethodId
customerPaymentMethodId
required

The ID of the customer payment method to be revoked.


Was this section helpful?

The ID of the revoked customer payment method.

The list of errors that occurred from executing the mutation.


Was this section helpful?
Hide code
Mutation reference
Copy
mutation customerPaymentMethodRevoke($customerPaymentMethodId: ID!) {
  customerPaymentMethodRevoke(customerPaymentMethodId: $customerPaymentMethodId) {
    revokedCustomerPaymentMethodId
    userErrors {
      field
      message
    }
  }
}
Hide code
Input
Copy
{
  "customerPaymentMethodId": "gid://shopify/<objectName>/10079785100"
}