Skip to content

Start a new API session

Request

When provided with a valid username/email address and password, starts a new API session, returning the associated key.

Security
SessionKey(Required scopes: publiccustomeradministrator)
Bodyapplication/json
identificationstringrequired

The username or email address of the account starting the session

passwordstring, (password)required

The password of the account starting the session

curl -i -X POST \
  https://docs.ticketingevents.com/_mock/openapi/sessions \
  -H 'Content-Type: application/json' \
  -H 'X-API-Key: YOUR_API_KEY_HERE' \
  -d '{
    "identification": "mothers.milk",
    "password": "Dxath2$up3$"
  }'

Responses

Indicates that the session was started successfully

Bodyapplication/json
selfstring, (uri)

URI of the session resource

idinteger

Unique ID number of the session resource

openboolean

True if the session is currently active, false otherwise

startedstring, (date-time)

Time at which the session was created

keystring

The key associated to this session resource. Include this token in the 'X-API-Key' Header to authenticate requests as the associated user account

accountobject

User account for which the session was opened

Response
{ "self": "/sessions/7c69fb3eeb3c910f049d9d72bec05e0d", "id": 16881177390522, "open": true, "started": "2023-06-30 10:35:39", "key": "7c69fb3eeb3c910f049d9d72bec05e0d", "account": { "self": "/accounts/MO-6A39EE8D", "number": "MO-6A39EE8D", "username": "mothers.milk", "email": "marvin.milk@usmc.gov", "role": "customer", "verified": false, "activated": true, "firstName": "Marvin", "lastName": "Milk", "title": "Mr.", "dateOfBirth": "14-09-1974", "phone": "+1 (268) 555 0123", "country": "Antigua and Barbuda", "firstAddressLine": "Jennings New Extension", "secondAddressLine": "", "city": "Jennings", "state": "Saint Mary's" } }