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/"f0daa6227054d4a227de0e5deea81bf8"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: eadb9dd0-58ca-4da3-8d1d-6df1114a4e33
X-Runtime: 0.008443
Content-Length: 139

Status

201 Created

Body

{
  "jwt": "eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOjksImF1ZCI6WyJjdXN0b21lci12MSJdLCJleHAiOjE3MTAyNTQ3NDB9.GBbrU8LyEaCCk73rbBA38aNEm7KrMlWDwo-SrBj3DqU"
}