List of locations
GET /locations/

Get a list of all locations connected to the account.

Request

  curl https://api.qminder.com/v1/locations/
  -H "X-Qminder-REST-API-Key: KEY"
          

Response

  {
    "statusCode": 200,
    "data": [
      {
        "id": 4052,
        "name": "Clockwise Dental Center",
        "latitude": 57.441983450650305,
        "longitude": 21.7197265625
      }
    ]
  } 
These fields are wrapped in a data object:
Response field Type Description
id Number A unique location ID
name String Mobile name of a location
Location details
GET /locations/ id

Get details of a location.

Request

  curl https://api.qminder.com/v1/locations/4052
  -H "X-Qminder-REST-API-Key: KEY"
          

Response

 {
    "statusCode": 200,
    "id": 4052,
    "name": "Clockwise Dental Center",
    "timezoneOffset": 120
  } 
Response field Type Description
id Number A unique location ID
name String Name of a location
timezoneOffset Number Offset from UTC timezone in minutes
List of lines
GET /locations/ id /lines

Get list of lines for specified location.

Request

  curl https://api.qminder.com/v1/locations/4052/lines
  -H "X-Qminder-REST-API-Key: KEY"
          

Response

 {
    "statusCode": 200,
    "data": [
      {
        "id": 1827,
        "name": "Registration"
      },
      {
        "id": 1828,
        "name": "Info"
      }
    ]
  } 
These fields are wrapped in a data object:
Response field Type Description
id Number A unique line ID
name String Name of a line
List of users
GET /locations/ id /users

Get list of users for specified location.

Request

  curl https://api.qminder.com/v1/locations/4052/users
  -H "X-Qminder-REST-API-Key: KEY"
          

Response

 {
    "statusCode": 200,
    "data": [
      {
        "id": 127,
        "email": "madli@example.com",
        "firstName": "Madli",
        "lastName": "Maasikas",
        "picture": [
          {
            "size": "medium",
            "url": "http://www.google.com"
          }
        ]
      },
      {
        "id": 245,
        "email": "kristjan@example.com",
        "firstName": "Kristjan",
        "lastName": "Kask",
        "picture": [
          {
            "size": "medium",
            "url": "http://www.google.com"
          }
        ]
      }
    ]
  } 
These fields are wrapped in a data object:
Response field Type Description
id Number A unique user ID
email String E-mail address
firstName String First name
lastName String Last name
picture.size String The size indicator of the picture, currently limited to "medium"
picture.url String The URL of the picture
List of desks
GET /locations/ id /desks

Get list of desks for specified location.

Request

  curl https://api.qminder.com/v1/locations/4052/desks
  -H "X-Qminder-REST-API-Key: KEY"
          

Response

 {
    "statusCode": 200,
    "desks": [
      {
        "name": "1"
      },
      {
        "name": "2"
      },
      {
        "name": "3"
      },
      {
        "name": "4"
      }
    ]
  } 
These fields are wrapped in a desks object:
Response field Type Description
name String Name of a desk
Creating a line
POST /locations/ id /lines

Creates a new line. If it is not possible to create a line because there is no available ticket range left, server responds with HTTP status code 409 and line will not be created.

Request

  curl -X POST https://api.qminder.com/v1/locations/4052/lines
  -H "X-Qminder-REST-API-Key: SECRET_KEY"
  --data "name=My New Cool Service"
          
Request parameter Description
name Name of the line. Up to 30 characters long.

Response

 {
    "statusCode": 200,
    "id": 827
  } 
Response field Type Description
id Number ID of a created line