For the complete documentation index, see llms.txt. This page is also available as Markdown.

User

User information endpoints

Get current user information

get

Returns information about the currently authenticated user including profile data, preferences, and selected address.

Header parameters
X-CookiestringRequired

Use X-Cookie header instead of Cookie header in "try out" section. Use Cookie header while testing in postman or other tools. Some commerce applications may support 'sesionid' instead of 'osessionid'.

Example: osessionid=abc123
Responses
200

User information retrieved

application/json

Information about the currently authenticated user. Contains profile data (name, email, phone), preferences (email/SMS/call permissions), segment information (price list, stock list, currency), selected delivery address, and authentication status. Requires authenticated session cookie.

pkintegerRequiredExample: 42
first_namestringOptionalExample: John
last_namestringOptionalExample: Doe
phonestringOptionalExample: 905551234567
emailstringOptionalExample: john.doe@example.com
email_allowedbooleanOptionalExample: true
sms_allowedbooleanOptionalExample: false
call_allowedbooleanOptionalExample: true
hashed_emailstringOptional

MD5 hash of the email address

Example: 5d41402abc4b2a76b9719d911017c592
date_joinedstring · date-timeOptionalExample: 2024-01-15T10:30:00Z
last_loginstring · date-timeOptionalExample: 2024-10-30T14:20:00Z
genderstring · enumOptionalExample: MPossible values:
date_of_birthstring · dateOptionalExample: 1990-05-15
is_email_verifiedbooleanOptional

Whether the user's email is verified

Example: true
is_social_networks_connectedbooleanOptional

Whether the user has connected social accounts

Example: false
client_typestringOptional

Client type identifier

Example: web
get/current_user/
GET /current_user/ HTTP/1.1
Host: sandbox.akinon.com
X-Cookie: osessionid=abc123
Accept: */*
{
  "pk": 42,
  "first_name": "John",
  "last_name": "Doe",
  "phone": 905551234567,
  "email": "john.doe@example.com",
  "email_allowed": true,
  "sms_allowed": false,
  "call_allowed": true,
  "attributes": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "hashed_email": "5d41402abc4b2a76b9719d911017c592",
  "date_joined": "2024-01-15T10:30:00Z",
  "last_login": "2024-10-30T14:20:00Z",
  "gender": "M",
  "date_of_birth": "1990-05-15",
  "is_email_verified": true,
  "is_social_networks_connected": false,
  "segment": {
    "pk": 1,
    "price_list": 1,
    "stock_list": 1,
    "currency": "TRY"
  },
  "client_type": "web",
  "selected_address": {
    "pk": 1,
    "address_line_1": "text",
    "address_line_2": "text",
    "city": "text",
    "postal_code": "text",
    "country": "text"
  }
}

Last updated

Was this helpful?