# segmentUpdate - admin-graphql - MUTATION Version: 2024-10 ## Description Updates a segment. ### Access Scopes `write_customers` access scope. Also: The user must not have restricted access. ## Arguments * [id](/docs/api/admin-graphql/2024-10/scalars/ID): ID! - Specifies the segment to be updated. * [name](/docs/api/admin-graphql/2024-10/scalars/String): String - The new name for the segment. * [query](/docs/api/admin-graphql/2024-10/scalars/String): String - A precise definition of the segment. The definition is composed of a combination of conditions on facts about customers such as `email_subscription_status = 'SUBSCRIBED'` with [this syntax](https://shopify.dev/api/shopifyql/segment-query-language-reference). ## Returns * [segment](/docs/api/admin-graphql/2024-10/objects/Segment): Segment The updated segment. * [userErrors](/docs/api/admin-graphql/2024-10/objects/UserError): UserError! The list of errors that occurred from executing the mutation. ## Examples