Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 32 additions & 12 deletions api-contracts/openapi/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,21 +30,23 @@ paths:
schema:
type: string
format: date-time
- name: limit
- name: cursor
required: false
in: query
description: Page size. Defaults to 1000 and cannot exceed 1000.
description: >-
Opaque cursor returned by a previous query page. Current format:
<timestamp>|<sensorId>.
schema:
type: integer
minimum: 1
maximum: 1000
default: 1000
- name: cursor
type: string
- name: limit
required: false
in: query
description: Opaque cursor returned by a previous query page
description: Page size. Defaults to 999 and must be less than 1000.
schema:
type: string
type: integer
minimum: 1
maximum: 999
default: 999
- name: gatewayId
required: false
in: query
Expand Down Expand Up @@ -121,6 +123,15 @@ paths:
text/event-stream media type.
operationId: MeasureController_stream
parameters:
- name: since
required: false
in: query
description: >-
Optional timestamp used to replay historical measures before
switching to real-time events
schema:
type: string
format: date-time
- name: gatewayId
required: false
in: query
Expand Down Expand Up @@ -167,6 +178,13 @@ paths:
data:
{"gatewayId":"gw-1","sensorId":"sensor-1","sensorType":"temperature","timestamp":"2026-03-23T09:58:00.000Z","encryptedData":"enc-3","iv":"iv-3","authTag":"tag-3","keyVersion":1}


data: {"type":"error","reason":"token_expired"}

'401':
description: Unauthorized
'403':
description: Forbidden
summary: Open a live measure stream
tags:
- measures
Expand Down Expand Up @@ -282,6 +300,8 @@ paths:
type: array
items:
$ref: '#/components/schemas/SensorDto'
'400':
description: Bad Request - invalid gatewayId format
'401':
description: Authentication failed
content:
Expand All @@ -302,7 +322,7 @@ paths:
$ref: '#/components/schemas/ErrorResponseDto'
summary: List sensors seen in the last ten minutes
tags:
- sensor
- sensors
info:
title: NoTIP Data API
description: NoTIP Data API OpenAPI specification
Expand Down Expand Up @@ -368,7 +388,7 @@ components:
nextCursor:
type: string
description: Cursor to request the next page, if available
example: '2026-03-23T09:58:00.000Z'
example: 2026-03-23T09:58:00.000Z|sensor-1
hasMore:
type: boolean
description: Whether more pages are available
Expand All @@ -390,7 +410,7 @@ components:
message:
type: string
description: Human-readable error message
example: limit must be less than or equal to 1000
example: limit must be less than 1000
error:
type: string
description: Short HTTP error label when returned by Nest
Expand Down
Loading