# Mqtt JWT password setting

**URL:** <https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145>\
**Category:** Community Support\
**Created:** [July 1, 2022, 9:37am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145 "2022-07-01T09:37:17Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 1, 2022, 9:37am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/1 "2022-07-01T09:37:17Z")

</div>

I installed chat21-widget using source code, but when I finished installing chat21-server, I found that the user password for connecting MQTT in chat21-widget is dynamically generated according to user id, in this case how should I set jwt in mqtt User’s password?

---

<div class="post-metadata">

**Author:** ![andreasponziello](https://avatars.discourse-cdn.com/v4/letter/a/13edae/32.png) [@andreasponziello](https://tiledesk.discourse.group/u/andreasponziello)\
**Post date:** [July 1, 2022, 5:59pm UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/2 "2022-07-01T17:59:13Z")

</div>

Hi haha

Can you please provide more details about your issue? Some code snippet, configuration snippet, log snippet or screenshots, so we can better understand your issue?

Thanks,

Andrea

---

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 4, 2022, 12:39am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/3 "2022-07-04T00:39:16Z")

</div>

> [@andreasponziello](#):
>
> can better underst

 ![截屏2022-07-04 上午8.34.20](https://global.discourse-cdn.com/free1/uploads/tiledesk/original/1X/beea30ed16096bf6b6885a26e80f726ea0a9be93.png)  
in chat21-web-widget /src/assets/js/chat21client.js , when i want to connect to my chat-21-server. and i was going to found the password of the user JWT, but it is changing everytime after refresh the web page.

---

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 4, 2022, 12:45am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/4 "2022-07-04T00:45:04Z")

</div>

![截屏2022-07-04 上午8.41.02](https://global.discourse-cdn.com/free1/uploads/tiledesk/original/1X/6960b99abe0b7451956a6c1e073c6865e13fa9cf.png)  
Uploading: 截屏2022-07-04 上午8.41.14.png…

Eventually I found out that the JWT user’s password is the token value generated in ‘/createCustomToken’ in /channels/chat21/nativeauth.js of tiledesk-server, but it is dynamic

---

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 4, 2022, 12:48am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/5 "2022-07-04T00:48:08Z")

</div>

and in chat21-ionic has the same

looking forward to your reply

---

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 4, 2022, 2:46am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/6 "2022-07-04T02:46:03Z")

</div>

the screenshoot error & the token log

 ![截屏2022-07-04 上午8.41.14](https://global.discourse-cdn.com/free1/uploads/tiledesk/original/1X/7d062ba6a3e3de495d7cedc15d08e6eb0d539e11.png)  
Uploading: 截屏2022-07-04 上午9.08.56.png…

---

<div class="post-metadata">

**Author:** ![haha](https://avatars.discourse-cdn.com/v4/letter/h/59ef9b/32.png) [@haha](https://tiledesk.discourse.group/u/haha)\
**Post date:** [July 4, 2022, 3:23am UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/7 "2022-07-04T03:23:53Z")

</div>

![截屏2022-07-04 上午9.08.56](https://global.discourse-cdn.com/free1/uploads/tiledesk/original/1X/a09486b66ad24d57c4e53a2b1aa03853c7af3b42.png)  
the token log

---

<div class="post-metadata">

**Author:** ![andreasponziello](https://avatars.discourse-cdn.com/v4/letter/a/13edae/32.png) [@andreasponziello](https://tiledesk.discourse.group/u/andreasponziello)\
**Post date:** [July 11, 2022, 12:58pm UTC](https://tiledesk.discourse.group/t/mqtt-jwt-password-setting/145/8 "2022-07-11T12:58:59Z")

</div>

Hi,

In this forum we only provide high level support for installing and configuring the platform, mainly using the docker compose distribution (available here)

If you need support on specifc Tiledesk components, we are putting a great effort in providing better documentation on general architecture and code design, actually a work in progress.

Anyway we can provide you some support on specific, very focused questions, using the issue tracking on github, in this case specific to chat21. Please refer to the modules that I understand are involved in your question, but please try to let us understand better the context (what are you trying to achieve, the installation goal, the final design and involved components you have in mind etc.).

Initially you can start creating an issue on the main chat21 server component available here:

> **[Issues · chat21/chat21-server](https://github.com/chat21/chat21-server/issues)**
>
> Chat Server (RabbitMQ Observer). Contribute to chat21/chat21-server development by creating an account on GitHub.

Hope this helps,

Andrea
