Request (Запрос от клиента)
POST /api/login HTTP/1.1
Host: some-site.com
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) ...
Accept: application/json
Content-Type: application/json
Authorization: Bearer a1b2c3d4e5f6...
Cookie: sessionId=abcdef123456
Content-Length: 56
{
"email": "user@example.com",
"password": "super_secret"
}
Response (Ответ от сервера)
HTTP/1.1 200 OK
Date: Wed, 17 Sep 2025 13:01:00 GMT
Server: Nginx/1.18.0
Content-Type: application/json; charset=utf-8
Set-Cookie: authToken=xyz987...; HttpOnly; Secure
Cache-Control: no-cache, no-store, must-revalidate
Content-Length: 128
{
"status": "success",
"data": {
"userId": "user-1122",
"authToken": "xyz987..."
}
}