Authentication API

get token

POST /api/rest/customer/v1/auth

Pass received token to each request to private API as 'token' parameter or 'Authorization' header.

Parameters

Name Description
auth[login] Login
auth[password] Password
auth[cookie_auth] Cookie Auth

Request

Headers

Version: HTTP/1.0
Accept: application/json
Content-Type: application/json
Host: example.org
Cookie: 

Route

POST /api/rest/customer/v1/auth

Body

{"auth":{"login":"login","password":"password"}}

Response

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 0
X-Content-Type-Options: nosniff
X-Download-Options: noopen
X-Permitted-Cross-Domain-Policies: none
Referrer-Policy: strict-origin-when-cross-origin
Content-Type: application/json; charset=utf-8
Vary: Accept
ETag: W/"8479d48413837150cbb8311c59d403c5"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: d1c214a8-025f-4881-90d7-95a4dd704d81
X-Runtime: 0.008506
Content-Length: 139

Status

201 Created

Body

{
  "jwt": "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOjksImF1ZCI6WyJjdXN0b21lci12MSJdLCJleHAiOjE3MzE1Nzg3NjV9.75qL66Z93fLTnXYwkWWf-px-Ug2zdXakJTXABsQpJzc"
}