--- title: customerPaymentMethodSendUpdateEmail - GraphQL Admin description: Sends a link to the customer so they can update a specific payment method. api_version: 2025-10 api_name: admin type: mutation api_type: graphql source_url: html: https://shopify.dev/docs/api/admin-graphql/latest/mutations/customerpaymentmethodsendupdateemail md: https://shopify.dev/docs/api/admin-graphql/latest/mutations/customerpaymentmethodsendupdateemail.md --- # customer​Payment​Method​Send​Update​Email mutation Requires `write_customers` access scope. Sends a link to the customer so they can update a specific payment method. ## Arguments * customer​Payment​Method​Id [ID!](https://shopify.dev/docs/api/admin-graphql/latest/scalars/ID) required The payment method to be updated. * email [Email​Input](https://shopify.dev/docs/api/admin-graphql/latest/input-objects/EmailInput) Specifies the payment method update email fields. Only the 'from' and 'bcc' fields are accepted for input. *** ## Customer​Payment​Method​Send​Update​Email​Payload returns * customer [Customer](https://shopify.dev/docs/api/admin-graphql/latest/objects/Customer) The customer to whom an update payment method email was sent. * user​Errors [\[User​Error!\]!](https://shopify.dev/docs/api/admin-graphql/latest/objects/UserError) non-null The list of errors that occurred from executing the mutation. *** ## Examples * ### Send an email with only the customer payment method id #### Query ```graphql mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } } ``` #### Variables ```json { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" } ``` #### cURL ```bash curl -X POST \ https://your-development-store.myshopify.com/admin/api/2025-10/graphql.json \ -H 'Content-Type: application/json' \ -H 'X-Shopify-Access-Token: {access_token}' \ -d '{ "query": "mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } }", "variables": { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" } }' ``` #### React Router ```javascript import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } }`, { variables: { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" }, }, ); const json = await response.json(); return json.data; } ``` #### Ruby ```ruby session = ShopifyAPI::Auth::Session.new( shop: "your-development-store.myshopify.com", access_token: access_token ) client = ShopifyAPI::Clients::Graphql::Admin.new( session: session ) query = <<~QUERY mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } } QUERY variables = { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" } response = client.query(query: query, variables: variables) ``` #### Node.js ```javascript const client = new shopify.clients.Graphql({session}); const data = await client.query({ data: { "query": `mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } }`, "variables": { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" }, }, }); ``` #### Response ```json { "customerPaymentMethodSendUpdateEmail": { "customer": { "id": "gid://shopify/Customer/544365967" }, "userErrors": [] } } ``` * ### customerPaymentMethodSendUpdateEmail reference [Open in GraphiQL](http://localhost:3457/graphiql?query=mutation%20sendCustomerPaymentUpdateEmail\(%24customerPaymentMethodId%3A%20ID!\)%20%7B%0A%20%20customerPaymentMethodSendUpdateEmail\(customerPaymentMethodId%3A%20%24customerPaymentMethodId\)%20%7B%0A%20%20%20%20customer%20%7B%0A%20%20%20%20%20%20id%0A%20%20%20%20%7D%0A%20%20%20%20userErrors%20%7B%0A%20%20%20%20%20%20field%0A%20%20%20%20%20%20message%0A%20%20%20%20%7D%0A%20%20%7D%0A%7D\&variables=%7B%0A%20%20%22customerPaymentMethodId%22%3A%20%22gid%3A%2F%2Fshopify%2FCustomerPaymentMethod%2Fb7cc6e3267aace169e516ed48be72dff%22%0A%7D) ```javascript import { authenticate } from "../shopify.server"; export const loader = async ({request}) => { const { admin } = await authenticate.admin(request); const response = await admin.graphql( `#graphql mutation sendCustomerPaymentUpdateEmail($customerPaymentMethodId: ID!) { customerPaymentMethodSendUpdateEmail(customerPaymentMethodId: $customerPaymentMethodId) { customer { id } userErrors { field message } } }`, { variables: { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" }, }, ); const json = await response.json(); return json.data; } ``` ## Input variables JSON ```json { "customerPaymentMethodId": "gid://shopify/CustomerPaymentMethod/b7cc6e3267aace169e516ed48be72dff" } ``` ## Response JSON ```json { "customerPaymentMethodSendUpdateEmail": { "customer": { "id": "gid://shopify/Customer/544365967" }, "userErrors": [] } } ```