Fleet integrations

MQTT mode

The same contract over MQTT instead of HTTP.

Markdown

MQTT mode carries the same state, commands and events as HTTP, over a broker Robot.com runs. Select it with transport: "mqtt" in PATCH /fleet.

Topics

TopicYouPayloadNotes
fleet/{namespace}/bot/{bot_id}/statePublishBotStateQoS 1, retained. Publish whenever something meaningful changes.
fleet/{namespace}/bot/{bot_id}/eventPublishBotEventQoS 1, not retained. Optional.
fleet/{namespace}/bot/{bot_id}/commandSubscribeBotCommandREMI publishes at QoS 2, not retained.

Connections

  • Open one connection per bot, with client id fleet-{namespace}-{bot_id}-hb. REMI takes connected from that connection, not from the payload.
  • Username fleet_{namespace}, with the password and broker address you get at onboarding.

Commands without a reply

There is no answer to a command message. Confirm it by putting its id in current_command of the bot's next state, or reject it there with state: rejected. An unconfirmed command is published again with the same id every 10 seconds, 3 times in total.