Skip to main content
GET
/
reports
/
v2
/
rs
/
{reportId}
Get report for the given site Ids
curl --request GET \
  --url https://z52mnqg347.execute-api.eu-west-3.amazonaws.com/main/reports/v2/rs/{reportId} \
  --header 'Authorization: Bearer <token>' \
  --header 'content-type: <content-type>' \
  --header 'x-session-token: <x-session-token>'
{
  "data": {
    "id": 1,
    "status": 1,
    "name": "Document Name",
    "type": 1,
    "comment": "Comment on the report",
    "checkDate": "2024-12-01T12:34:56.000Z",
    "updatedAt": "2024-12-09T14:23:00.000Z",
    "createdAt": "2024-01-15T08:45:00.000Z",
    "presignedUrl": "https://example.com/presigned-url",
    "archivedAt": "2024-12-10T10:00:00.000Z",
    "establishmentCell": {
      "establishment": {
        "id": 1,
        "establishmentSiteId": 5,
        "name": "Main site",
        "count": 123
      },
      "cell": {
        "id": 1,
        "name": "Main site",
        "count": 123
      }
    },
    "rule": {
      "id": 1,
      "name": "Annual Safety Check",
      "type": 1,
      "rrule": "FREQ=YEARLY;BYMONTH=12;BYMONTHDAY=1",
      "workflowType": 1,
      "complianceType": 1
    },
    "rulesCount": 123,
    "rulesRrule": [
      "FREQ=YEARLY;BYMONTH=12;BYMONTHDAY=1"
    ],
    "technicalInstallations": [
      {
        "id": 1,
        "name": "establishment_informations.installation_ascenseurs",
        "presignedUrl": "https://example.com/presigned-url"
      }
    ],
    "anomalyStats": {
      "unreviewed": 5,
      "pending": 3,
      "resolved": 10
    },
    "commission": {
      "id": 1,
      "visitType": 1,
      "signedBy": "Signatory",
      "decision": 1,
      "signedDate": "2024-12-01T12:34:56.000Z",
      "commissionDate": "2024-12-01T12:34:56.000Z",
      "buildingWork": {
        "id": 1,
        "authorizationNumber": "Authorization number"
      }
    },
    "intervention": {
      "id": 1,
      "providerName": "Provider name",
      "type": 1,
      "subType": 1,
      "assignedTo": {
        "type": 123,
        "id": 1,
        "name": "John Doe",
        "email": "test@mail.com"
      }
    },
    "createdBy": {
      "id": 1,
      "firstName": "John",
      "lastName": "Doe"
    },
    "equipment": {
      "id": 1,
      "name": "Equipment Name",
      "archivedAt": "2024-12-01T12:34:56.000Z"
    },
    "equipmentsCount": 123,
    "equipments": [
      {
        "id": 1,
        "name": "Equipment Name"
      }
    ],
    "equipmentIds": [
      1
    ],
    "actions": {
      "canBeUpdated": true,
      "canBeDeleted": true
    },
    "updatableFields": {
      "comment": true,
      "name": true,
      "siteIds": true,
      "ruleIds": true,
      "equipmentIds": true
    },
    "ruleIds": [
      1
    ],
    "anomalyIds": [
      1
    ],
    "anomalyItIds": [
      1,
      2,
      3
    ]
  }
}

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"

content-type
string
required

Content type, must be "application/json".

Allowed value: "application/json"

Path Parameters

reportId
integer
required

Unique identifier of the report.

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

1

Query Parameters

extend
enum<string>[]

Extend options:

  • "establishment-cell": Get information about the establishment cell

  • "rules": Get information about the rules linked to the intervention

  • "technical-installations": Get information about technical installations linked to the report

  • "anomaly-stats": Get information about anomalies in reports

  • "origin": Give information about the origin of the report (commission or intervention)

  • "created-by": Get information about the person that created the report

  • "equipments": Get information about the equipments linked to the intervention

  • "equipments-details": Get id and name for equipments linked to the intervention

  • "equipment-ids": Get ids of the equipments linked to the intervention

  • "actions-info": Give information about actions that can be done on reports

  • "updatable-fields": Get information about the field that can be updated

  • "equipment-ids": Get ids of the equipments linked to the intervention

  • "rule-ids": Get information about the rules ids linked to the report

  • "anomaly-ids": Get information about anomalies in reports

  • "anomaly-it-ids": Get information about anomalies in reports

Available options:
establishment-cell,
rules,
technical-installations,
anomaly-stats,
origin,
created-by,
equipments,
equipments-details,
equipment-ids,
actions-info,
updatable-fields,
rule-ids,
anomaly-ids,
anomaly-it-ids

Response

200 - application/json

List of reports

data
object
required