asyncapi: '2.0.0-rc1' id: 'urn:com:solace:iot:event' info: title: IoT Telemetry API version: '1.0.0' description: | The Solace MQTT XDK App publishes sensor readings in regular intervals. Various downstream systems such as analytics & visualization subscribe to these telemetry events via the appropriate topics including wildcards where applicable. See https://github.com/solace-iot-team/iot-platform-api-docs/blob/master/topic.md license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0 servers: - url: broker:port protocol: mqtt description: Clients publish via MQTT QOS0 baseChannel: "" security: - userPassword: [] defaultContentType: application/json channels: CREATE/iot-event/{region}/{location}/{production-line}/device/{deviceId}/metrics: description: Topic to subscribe to connected events parameters: - $ref: '#/components/parameters/region' - $ref: '#/components/parameters/location' - $ref: '#/components/parameters/production-line' - $ref: '#/components/parameters/deviceId' publish: summary: device publishes sensor readings. each event represents a new (create) reading for the timestamp. operationId: publishTelemetry message: $ref: '#/components/messages/telemetryMessage' components: messages: telemetryMessage: name: telemetryMessage title: Telemetry Message summary: Telemetry Message description: "Depending on the mode of the device, the telemetry message can contain all of the sensor readings or only a partial set. For units and ranges please see the datasheet for the XDK. You can find it on this site: https://xdk.bosch-connectivity.com" contentType: application/json payload: $ref: "#/components/schemas/telemetryEvent" schemas: telemetryEvent: type: array items: type: object title: Telemetry Reading/Sample required: - timestamp - deviceId properties: timestamp: type: string title: event timestamp - ISO 8601 Date and Time format default: '' example: '2019-04-06T05:11:38.357Z' deviceId: type: string title: device Id default: '' example: '29dbfgskjrty6809' pattern: ^(.*)$ humidity: type: integer title: humidity default: 0 example: 44 light: type: integer title: light sensor default: 0 example: 457920 temperature: type: number title: temperature in celcius default: 0.0 example: 18.791 acceleratorX: type: integer title: accelerator X value default: 0 example: -19 acceleratorY: type: integer title: accelerator Y value default: 0 example: -22 acceleratorZ: type: integer title: accelerator Z value default: 0 example: 990 gyroX: type: integer title: gyroscope X value default: 0 example: 915 gyroY: type: integer title: gyroscope Y value default: 0 example: 671 gyroZ: type: integer title: gyroscope Z value default: 0 example: -5673 magR: type: integer title: magnetometer R value default: 0 example: 6351 magX: type: integer title: magnetometer X value default: 0 example: -45 magY: type: integer title: magnetometer Y value default: 0 example: 6 magZ: type: integer title: magnetometer Z value default: 0 example: -92 parameters: deviceId: name: deviceId description: The device id. schema: type: string example: 29dbfgskjrty6809 region: name: region description: Region of the device schema: type: string example: - US - EU location: name: location description: Location of the device schema: type: string example: - Boeblingen - Sindelfingen production-line: name: production-line description: The produciton line the device is located in schema: type: string example: "Widget Maker Line" securitySchemes: userPassword: type: userPassword description: User name password authentication