Properties
Optional ca
ca: string | string[] | Buffer | Buffer[]
Optional cert
cert: string | string[] | Buffer | Buffer[]
Optional clean
clean: undefined | false | true
Optional clientId
clientId: undefined | string
Optional connectTimeout
connectTimeout: undefined | number
fromId
fromId: string
Optional host
host: undefined | string
Optional hostname
hostname: undefined | string
Optional incomingStore
incomingStore: Store
Optional keepalive
keepalive: undefined | number
Optional key
key: string | string[] | Buffer | Buffer[] | Object[]
Optional outgoingStore
outgoingStore: Store
Optional password
password: undefined | string
Optional path
path: undefined | string
Optional port
port: undefined | number
Optional properties
properties: undefined | { authenticationData?: Buffer; authenticationMethod?: undefined | string; maximumPacketSize?: undefined | number; receiveMaximum?: undefined | number; requestProblemInformation?: undefined | false | true; requestResponseInformation?: undefined | false | true; sessionExpiryInterval?: undefined | number; topicAliasMaximum?: undefined | number; userProperties?: Object }
Optional protocol
protocol: "wss" | "ws" | "mqtt" | "mqtts" | "tcp" | "ssl" | "wx" | "wxs"
Optional protocolId
protocolId: undefined | string
Optional protocolVersion
protocolVersion: undefined | number
Optional publishEndpoint
publishEndpoint: undefined | string
Optional queueQoSZero
queueQoSZero: undefined | false | true
Optional reconnectPeriod
reconnectPeriod: undefined | number
Optional rejectUnauthorized
rejectUnauthorized: undefined | false | true
Optional reschedulePings
reschedulePings: undefined | false | true
Optional resubscribe
resubscribe: undefined | false | true
Optional servers
servers: Array<{ host: string; port: number; protocol?: "wss" | "ws" | "mqtt" | "mqtts" | "tcp" | "ssl" | "wx" | "wxs" }>
Optional subscribeEndpoint
subscribeEndpoint: undefined | string
toId
toId: string
Optional transformWsUrl
transformWsUrl: undefined | ((url: string, options: IClientOptions, client: MqttClient) => string)
Optional username
username: undefined | string
Optional will
will: undefined | { payload: Buffer | string; properties?: undefined | { contentType?: undefined | string; correlationData?: Buffer; messageExpiryInterval?: undefined | number; payloadFormatIndicator?: undefined | false | true; responseTopic?: undefined | string; userProperties?: Object; willDelayInterval?: undefined | number }; qos: QoS; retain: boolean; topic: string }
Optional wsOptions
wsOptions: undefined | {}
Optionally override the trusted CA certificates in PEM format