Skip to main content
GET
/
sites
/
v2
/
rs
List sites for the given site Ids
curl --request GET \
  --url https://z52mnqg347.execute-api.eu-west-3.amazonaws.com/main/sites/v2/rs \
  --header 'Authorization: Bearer <token>' \
  --header 'x-session-token: <x-session-token>'
{
  "data": [
    {
      "id": 1,
      "name": "Main site",
      "types": [
        1,
        1
      ],
      "classifications": [
        "ERT",
        "ERP"
      ],
      "isEstablishment": true,
      "establishmentId": 10,
      "serialNumber": "123456",
      "sortOrder": 1,
      "archivedAt": "2024-12-10T10:00:00.000Z",
      "deletedAt": "2024-12-15T10:00:00.000Z",
      "updatedAt": "2024-12-09T14:23:00.000Z",
      "createdAt": "2024-01-15T08:45:00.000Z",
      "tags": [
        {
          "id": 1,
          "name": "at the office",
          "color": "#FF5733",
          "type": {
            "id": 1,
            "name": "brands",
            "type": 1
          }
        }
      ],
      "establishment": {
        "id": 1,
        "address": "123 Main Street",
        "name": "Main site",
        "zipCode": 75001,
        "city": "Paris",
        "country": "France",
        "classifications": [
          0,
          2
        ],
        "isGroupment": true
      },
      "actions": {
        "canBeUpdated": true,
        "canBeDeleted": true
      }
    }
  ],
  "totalCount": 100,
  "pagination": {
    "page": 1,
    "pageSize": 50
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-session-token
string
required

Session token used for authenticating the request.

Example:

"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySWQiOiIxMjM0NTY3ODkwIiwic2Vzc2lvbklkIjoiYWJjZGVmMTIzNDU2IiwiaWF0IjoxNjA1MDk3ODk5LCJleHAiOjE2MDUxODQyOTl9.4XRQ1iXDyvEj5LgPZHbmTmzOZs98M3YPOzgf3MhxjaI"

x-sites
string

List of site IDs.

Example:

"['1', '2']"

Query Parameters

extend
enum<string>[]

Extend options:

  • "tags": Get the tags of all sites

  • "establishment": Get the establishment information of the site

  • "actions-info": Give information about actions that can be performed on the site

Available options:
tags,
establishment,
actions-info
whereName
string

Filter by site name

Example:

"string"

whereSerialNumber
string

Filter by site serial number

Example:

"string"

whereTypes
integer[]

Filter by site type

Required range: -9007199254740991 <= x <= 9007199254740991
Example:
[1, 2, 3]
whereIsEstablishment
boolean

Filter by establishment status

Example:

true

whereEstablishmentId
integer[]

Filter by establishment ID

Required range: -9007199254740991 <= x <= 9007199254740991
Example:
[1, 2, 3]
whereTags
integer[]

Filter by tags

Required range: -9007199254740991 <= x <= 9007199254740991
Example:
[1, 2, 3]
whereCreatedAt
string

Filter by createdAt date

Example:

"2021-01-01T00:00:00.000Z"

whereUpdatedAt
string

Filter by updatedAt date

Example:

"2021-01-01T00:00:00.000Z"

whereIsArchived
boolean

Filter by isArchived flag

Example:

true

whereArchivedAt
string

Filter by archivedAt date

Example:

"2021-01-01T00:00:00.000Z"

whereText
string

Filter by global text in report

Example:

"string"

whereTechnicalInstallationIds
integer[]

Filter by technical installation IDs

Required range: -9007199254740991 <= x <= 9007199254740991
Example:
[1, 2, 3]
whereRuleIds
integer[]

Filter by rule IDs

Required range: -9007199254740991 <= x <= 9007199254740991
Example:
[1, 2, 3]
whereNotPositioned
boolean

Filter by sites without position

Example:

true

whereRuleId
integer

Filter by rule ID

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

1

whereInterventionId
integer

Filter by intervention ID

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

1

orderBy
object[]
includeCount
boolean
default:false

Include total count in response.

Example:

true

page
integer
default:1

Page number.

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

1

pageSize
integer
default:50

Page size.

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

50

findId
integer

Get the page where the item with this id is located.

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

1

subPageSize
integer
default:10

Sub page size for grouping items.

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

10

Response

200 - application/json

List of sites

data
object[]
required
totalCount
integer

Total count of items.

Required range: -9007199254740991 <= x <= 9007199254740991
Example:

100

pagination
object

Pagination information.