ThingSpeak · AsyncAPI Specification
ThingSpeak MQTT API
Version 1.0
ThingSpeak's MQTT broker at `mqtt3.thingspeak.com`. Devices publish channel updates and subscribe to channel/field feeds using MQTT credentials (Client ID, Username, Password) provisioned in the ThingSpeak portal. Available transports: - TCP on port 1883 (unencrypted) - TCP on port 8883 (TLS) - WebSocket on port 80 (path `/mqtt`, unencrypted) - WebSocket on port 443 (path `/mqtt`, TLS) QoS 0 only. Connections time out after one hour of inactivity.
View Spec
View on GitHub
IoTInternet of ThingsAnalyticsTime SeriesMQTTMATLABSensorsTelemetryAsyncAPIWebhooksEvents
Channels
channels/{channelID}/publish
Publish multi-field updates to a channel. Payload is form-encoded (`field1=value&field2=value&status=...`).
channels/{channelID}/publish/fields/field{fieldNumber}
Publish a single field's value.
channels/{channelID}/subscribe/fields/field{fieldNumber}/{readAPIKey}
Subscribe to a specific field on a channel. Requires the channel's Read API Key in the topic.
channels/{channelID}/subscribe/json/{readAPIKey}
Subscribe to all channel updates as JSON.
Messages
ChannelUpdate
ChannelUpdate
FieldValue
FieldValue
ChannelUpdateJson
ChannelUpdateJson
Servers
mqtt
production-tcp
mqtt3.thingspeak.com:1883
Production MQTT broker (unencrypted TCP).
mqtts
production-tcp-tls
mqtt3.thingspeak.com:8883
Production MQTT broker (TLS TCP).
ws
production-ws
mqtt3.thingspeak.com:80/mqtt
Production MQTT broker (unencrypted WebSocket).
wss
production-wss
mqtt3.thingspeak.com:443/mqtt
Production MQTT broker (TLS WebSocket).