customerCreate
Creates a new customer account and returns an access token.
Authentication
Authentication Required: Secret API key with scope
customer:write
Mutation Structure
mutation {
customerCreate(input: CustomerCreateInput!) {
customer
customerAccessToken
customerUserErrors
}
}Input Arguments
Return Type
CustomerCreatePayload - Payload returned by the customerCreate mutation. Contains the created customer, customer access token, and any errors that occurred during the operation.
Example
mutation {
customerCreate(input: {
firstName: "John"
lastName: "Doe"
email: "john.doe@example.com"
password: "SecurePassword123!"
}) {
customer {
id
email
firstName
lastName
}
customerAccessToken {
accessToken
expiresAt
}
customerUserErrors {
code
field
message
}
}
}