API reference
Log in a customer and return access tokens
Exchanges the customer's credentials for access tokens. The storefront normally keeps the session in an HttpOnly cookie rather than handing the token to page scripts.
POST
/v1/customer/loginExchanges the customer's credentials for access tokens. The storefront normally keeps the session in an HttpOnly cookie rather than handing the token to page scripts.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X POST "https://example.com/v1/customer/login" \ -H "Content-Type: application/json" \ -d '{ "email": "string", "password": "string" }'{ "accessToken": "string", "refreshToken": null, "expiresIn": 0, "tokenType": "string", "customer": null}