Golioth OTAEvents API

The OTAEvents API from Golioth — 2 operation(s) for otaevents.

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

golioth-otaevents-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Golioth Management Access OTAEvents API
  version: '1.0'
  description: 'Golioth IoT Device Management REST API. Authenticate with project-scoped API keys passed in the x-api-key header. Upstream OpenAPI: https://api.golioth.io/openapi.json'
servers:
- url: https://api.golioth.io
security:
- API Key: []
  Bearer: []
tags:
- name: OTAEvents
paths:
  /v1/organizations/{organizationId}/projects/{projectId}/ota-events:
    get:
      operationId: OTAEvents_List
      parameters:
      - in: path
        name: organizationId
        required: true
        schema:
          type: string
      - in: path
        name: projectId
        required: true
        schema:
          type: string
      - in: query
        name: cohortId
        schema:
          type: string
      - in: query
        name: packageId
        schema:
          type: string
      - in: query
        name: deviceId
        schema:
          type: string
      - in: query
        name: eventType
        schema:
          type: string
      - in: query
        name: status
        schema:
          format: int32
          type: integer
      - in: query
        name: startTime
        schema:
          format: date-time
          type: string
      - description: leave out end to get all events up to now
        in: query
        name: endTime
        schema:
          format: date-time
          type: string
      - in: query
        name: limit
        schema:
          format: int64
          type: integer
      - in: query
        name: pageToken
        schema:
          type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/goliothListOTAEventsResponse'
          description: A successful response.
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/rpcStatus'
          description: An unexpected error response.
      tags:
      - OTAEvents
  /v1/organizations/{organizationId}/projects/{projectId}/ota-events/stats:
    get:
      operationId: OTAEvents_ListStats
      parameters:
      - in: path
        name: organizationId
        required: true
        schema:
          type: string
      - in: path
        name: projectId
        required: true
        schema:
          type: string
      - in: query
        name: cohortId
        schema:
          type: string
      - in: query
        name: deviceId
        schema:
          type: string
      - in: query
        name: startTime
        schema:
          format: date-time
          type: string
      - description: leave out end to get all events up to now
        in: query
        name: endTime
        schema:
          format: date-time
          type: string
      - in: query
        name: limit
        schema:
          format: int64
          type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/goliothListOTAEventStatsResponse'
          description: A successful response.
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/rpcStatus'
          description: An unexpected error response.
      tags:
      - OTAEvents
components:
  schemas:
    protobufAny:
      additionalProperties: {}
      properties:
        '@type':
          type: string
      type: object
    goliothOTAEvent:
      properties:
        currentVersion:
          type: string
        deviceId:
          type: string
        eventType:
          type: string
        message:
          type: string
        packageId:
          type: string
        status:
          format: int32
          type: integer
        targetVersion:
          type: string
        timestamp:
          format: date-time
          type: string
      type: object
    goliothOTAStatsEventTypeEntry:
      properties:
        duration:
          format: int64
          type: integer
        stats:
          items:
            $ref: '#/components/schemas/goliothOTAStatsEventTypeCount'
          type: array
        timestamp:
          format: date-time
          type: string
      type: object
    goliothListOTAEventsResponse:
      properties:
        list:
          items:
            $ref: '#/components/schemas/goliothOTAEvent'
          type: array
        nextPageToken:
          title: Token to get the next page
          type: string
        prevPageToken:
          title: Token to get the previous page
          type: string
      type: object
    goliothOTAStatsEventTypeCount:
      properties:
        count:
          format: int64
          type: integer
        eventType:
          type: string
      type: object
    goliothListOTAEventStatsResponse:
      properties:
        endTime:
          format: date-time
          type: string
        list:
          items:
            $ref: '#/components/schemas/goliothOTAStatsEventTypeEntry'
          type: array
        startTime:
          format: date-time
          type: string
      type: object
    rpcStatus:
      properties:
        code:
          format: int32
          type: integer
        details:
          items:
            $ref: '#/components/schemas/protobufAny'
          type: array
        message:
          type: string
      type: object
  securitySchemes:
    API Key:
      in: header
      name: x-api-key
      type: apiKey
    Bearer:
      in: header
      name: Authorization
      type: apiKey
externalDocs:
  description: golioth API
  url: https://docs.golioth.io