MQTT Relay Authorization Denied

Good day everyone, I am new to TagoIO, I’m on a free TagoIO account. I followed the tutorial on the official video https://youtu.be/mKU73B24Osg on this topic. I keep getting the error:
[2025-10-16T07:45:55Z INFO info] Config file loaded successfully
[2025-10-16T07:45:55Z INFO network] Verifying network token for relay: self-hosted
[2025-10-16T07:45:56Z ERROR network] Failed to verify network token for relay self-hosted: Status: 400 Bad Request, Body: {“status”:false,“message”:“Authorization denied”}, Message: Request failed with status: 400 Bad Request
[2025-10-16T07:45:56Z ERROR network] Failed to verify relay self-hosted: Status: 400 Bad Request, Body: {“status”:false,“message”:“Authorization denied”}, Message: Request failed with status: 400 Bad Request

This happens when I try to start the relay.

What is the common cause for this?

Hello @khoza.valiantr

I tested all the steps described in the README.md from the repository tago-io/mqtt-relay (v1.4.0), following exactly the same procedure shown in the video, using a Free account — everything worked as expected with the EMQX.

The error message you’re seeing indicates that the network token you used is incorrect. Please review the section in the video between minutes 3:21 and 4:52 to make sure you copied the token from the correct place.

Also, don’t forget to include the authorization_token.
You can follow this documentation to generate it:
:backhand_index_pointing_right: Authorization Token Documentation

Both values must be added to the file:

~/.config/.tagoio-mqtt-relay.toml

Let me know if you still face any issues after checking this.

Hello Mateus,

Thank you so much. I figured the issue was also that I’m on the EU server so the API url on the docs is for the US server.

Much appreciate the help!

Thanks.

:movie_camera:Discover smart tech strategies for business growth – Watch Advannotech on YouTube

Thank you, Valiant, for your feedback! I really appreciate it.

I’ve opened a pull request to improve the documentation in the repository, adding a note about the URL region in the credentials file.