UNPKG

@asyncapi/specs

Version:
72 lines (71 loc) 2.23 kB
{ "$schema": "http://json-schema.org/draft-07/schema#", "$id": "http://asyncapi.com/bindings/mqtt/0.1.0/server.json", "title": "MQTT server bindings object", "description": "This object contains information about the server representation in MQTT.", "type": "object", "additionalProperties": false, "patternProperties": { "^x-[\\w\\d\\.\\x2d_]+$": { "$ref": "http://asyncapi.com/definitions/3.0.0/specificationExtension.json" } }, "properties": { "clientId": { "type": "string", "description": "The client identifier." }, "cleanSession": { "type": "boolean", "description": "Whether to create a persistent connection or not. When 'false', the connection will be persistent." }, "lastWill": { "type": "object", "description": "Last Will and Testament configuration.", "properties": { "topic": { "type": "string", "description": "The topic where the Last Will and Testament message will be sent." }, "qos": { "type": "integer", "enum": [0,1,2], "description": "Defines how hard the broker/client will try to ensure that the Last Will and Testament message is received. Its value MUST be either 0, 1 or 2." }, "message": { "type": "string", "description": "Last Will message." }, "retain": { "type": "boolean", "description": "Whether the broker should retain the Last Will and Testament message or not." } } }, "keepAlive": { "type": "integer", "description": "Interval in seconds of the longest period of time the broker and the client can endure without sending a message." }, "bindingVersion": { "type": "string", "enum": [ "0.1.0" ], "description": "The version of this binding. If omitted, 'latest' MUST be assumed." } }, "examples": [ { "clientId": "guest", "cleanSession": true, "lastWill": { "topic": "/last-wills", "qos": 2, "message": "Guest gone offline.", "retain": false }, "keepAlive": 60, "bindingVersion": "0.1.0" } ] }