# CustomerErrorCode Possible error codes that can be returned by customer mutations. ## Enum Definition ```graphql enum CustomerErrorCode { INVALID_CREDENTIALS UNIDENTIFIED_CUSTOMER TOKEN_EXPIRED TOKEN_INVALID TOO_MANY_ATTEMPTS EMAIL_TAKEN INVALID_EMAIL INVALID_PASSWORD PASSWORD_MISMATCH LOGIN_DISABLED REGISTRATION_DISABLED BLANK INVALID } ``` ## Values | Value | Description | |-------|-------------| | `INVALID_CREDENTIALS` | The email or password is incorrect | | `UNIDENTIFIED_CUSTOMER` | The customer could not be identified | | `TOKEN_EXPIRED` | The access token has expired | | `TOKEN_INVALID` | The access token is invalid | | `TOO_MANY_ATTEMPTS` | Too many login attempts. Please try again later. | | `EMAIL_TAKEN` | The email address is already registered | | `INVALID_EMAIL` | The email address is invalid | | `INVALID_PASSWORD` | The password does not meet requirements | | `PASSWORD_MISMATCH` | The password and password confirmation do not match | | `LOGIN_DISABLED` | Customer login is disabled for this store | | `REGISTRATION_DISABLED` | Customer registration is disabled for this store | | `BLANK` | A required field is blank | | `INVALID` | The supplied value is invalid | ## Example ```graphql mutation LoginCustomer($email: String!, $password: String!) { customerLogin(input: {email: $email, password: $password}) { customer { id email } errors { code message } } } ``` When this mutation fails, the `errors` field may contain a `code` value of type `CustomerErrorCode`, such as `INVALID_CREDENTIALS` or `EMAIL_TAKEN`. ## Related Types - `Customer` - `CustomerInput` - `CustomerError` - `CustomerLoginPayload` - `CustomerCreatePayload` - `CustomerUpdatePayload`