There is an issue with my YAML format, could a friend help me resolve it?

  • Platform error: sensor - Integration ‘thingskit_integration’ not found.
  • Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘broker’ is an invalid option for ‘mqtt’, check: mqtt->0->broker, please check the docs at https:/ /www.home-assistant.io/integrations/mqtt Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘client_id’ is an invalid option for ‘mqtt’, check: mqtt->0->client_id, please check the docs at MQTT - Home Assistant Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘discovery’ is an invalid option for ‘mqtt’, check: mqtt->0->discovery, please check the docs at MQTT - Home Assistant Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘password’ is an invalid option for ‘mqtt’, check: mqtt->0->password, please check the docs at https:/ /www.home-assistant.io/integrations/mqtt Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘port’ is an invalid option for ‘mqtt’, check: mqtt->0->port, please check the docs at https:/ /www.home-assistant.io/integrations/mqtt Invalid config for ‘mqtt’ at configuration.yaml, line 16: ‘username’ is an invalid option for ‘mqtt’, check: mqtt->0->username, please check the docs at https:/ /www.home-assistant.io/integrations/mqtt.
    my yaml:

Where did you get the format for setting up the integration from? Because if I look at the documentation, the integration should bet setup from the GUI and there’s no yaml setup described (at least now that I saw). Could it be from an old source that is no longer valid? I would follow the instructions from the link that is at the bottom of the error message:

In addition to what @Edwin_D pointed out, searching for thingskit_integration shows no results in google, which is saying a lot.

Where exactly did you get that part of your config from?

And this

“The thingskit_integration integration is one that I have developed myself, and it also seems to be an error for now. However, the current error appears to be an issue with the YAML file format.”

“The thingskit_integration integration is one that I have developed myself, and it also seems to be an error for now. However, the current error appears to be an issue with the YAML file format.”

Yes, your yaml is wrong. That is because the mqtt integration (the broker part) is defined through the UI, not in configuration.yaml. I told you that in my previous post. Did you ask ChatGPT or another llm how to do this? If so, please stop doing that because it is a waste of both our times.

You set up the mqtt broker in the user interface. Remove this part and check the documentation I linked to to add it the proper way. the mqtt: configuration part is meant to define entities, not to specify the broker.

Also, the yaml definition for your own integration seems unlikely. So that is wrong too. Not because of the yaml file format, but of the thing you tried to describe in the yaml file format. So to repeat, is this your effort, or ChatGPT’s? I’m willing to help you, but I’m not willing to turn AI ramblings into working code.

No problem, I previously made a mistake while configuring my public MQTT server in the UI, so I asked ChatGPT how to configure MQTT. Now I’ve found that I’ve successfully configured my LAN MQTT server in the UI. Thank you for the reminder. However, I still haven’t resolved the issue of connecting to a public IoT cloud platform using HA’s MQTT integration.Thank you very much again!

Unless you have a credentials and mqtt client that can connect to their MQTT server, it won’t work. Your MQTT server cannot connect out to them, and they won’t reach out to connect to yours so there’s no point in having your MQTT server exposed to the internet and create a security hole.

If you have credentials to connect to theirs, you can use the docs I pointed to to define sensors that listen to their topics. If this is for thingskit, then you do not need to write an integration for it, you can just use MQTT.

I’ve discovered that the IoT cloud platform I want to connect to can only be connected via mqtt://, but it seems that Home Assistant (HA) is based on websocket:// connections, which is why the connection was unsuccessful. For this newly emerged issue, do you have any new ideas? Thank you.

No, sorry. But afaik these protocols are not the same level interface, so I doubt it is either or - how services connect and how messages are structured are different things. MQTT can run over websockets. But if the server did not enable websocket, I see why that could pose a problem. But again, looking at the docs, the mqtt client in HA seems to support connections without websocket.

USING WEBSOCKETS AS TRANSPORT

You can select websockets as transport method if your MQTT broker supports it. When you select websockets and click NEXT, …

Emphasis mine: So that suggest, don’t do that and you’re not using websockets.