← Back to Documentation

API reference overview

Conventions

  • Base URL: https://app.include.co.id/api/v1
  • User authentication: Authorization: Bearer <access_token>, obtained from POST /auth/login.
  • Device authentication: device token, only for /device/* and /{token}/* routes.
  • Success response: { data, meta }. Error response: { error, message }.
  • Almost all data lives inside a group (group_id) in your organisation.

Main endpoints

  • GET /devices, GET /devices/:id, PATCH /devices/:id: list and edit devices.
  • POST /devices/claim: claim a device by ID or token.
  • POST /devices/custom: register your own device (BYOD).
  • POST /devices/:id/command: send a command to an actuator.
  • GET /telemetry/:deviceId: latest values.
  • GET /telemetry/:deviceId/history: history, with startTime, endTime, limit.
  • POST /telemetry/:deviceId/import: import historical data (Pro plan and above; does not trigger alarms).
  • GET /telemetry/stream: real-time stream (Server-Sent Events).
  • GET /alarms, PATCH /alarms/:id/acknowledge, PATCH /alarms/:id/resolve: manage alarms.
  • POST /devices/:id/thresholds: set optimal, warning, and critical thresholds per parameter.
  • GET /rule-chains, POST /rule-chains, POST /rule-chains/test: automations, including a dry run against sample values.

Need API access for an ERP or other system? Talk to our team.