Missing official OpenWeatherMap Integration example

Can someone please post an example of how to integrate Openwaethermap Integration into HomeAssistant?
I have managed for so much integrations now to include into HA, but this integration seems to be integrated within HA without higher priority on documentation.

On
https://www.home-assistant.io/integrations/openweathermap/#configuration
I cannot really see how to integrate the OWM integration into my configuration.yaml.

I ended up to pick the following code from this community

weather:
  - platform: openweathermap
    api_key: 4c8111bxxxxxxxxxxabfcf6e32f1
    name: xxxx_owm

and

sensor:
  - platform: rest
    name: openweather_report
    json_attributes_path: "$.daily[0]" # 0=today
    json_attributes:
      - temp
    value_template: "{{ value_json['current']['dt'] | timestamp_custom('%Y-%m-%d %H:%M', true) }}"
    resource: https://api.openweathermap.org/data/2.5/onecall?lat=5x.xx3679&lon=1x.xx6408&appid=4c8111bc7xxxxxbfcf6e32f1&units=metric&lang=nl
    scan_interval: 3600

and further down, I have several template sensors:

   - platform: template
    sensors:
      openweather_maxtemp_today:
        value_template: "{{ states.sensor.openweather_report.attributes.temp.max }}"

The fault in my log shown is

The openweathermap platform for the weather integration does not support platform setup. Please remove it from your config.

So maybe I have issues with my OWM config?
I really would appreciate, if the a.m. Integration page of OWM can be added with some more examples on how to add it to the configuration.yaml. Only the basic setup. I burned huge amount of hours at this point.

Regards,
Jörg

You are mixing up two things here, the Openweathermap weather integration and the Rest integration. They are different ways to query OWM.

I would recommend removing the Openweathermap platform from configuration.yaml, restart and just add OWM through Settings > Integrations.

1 Like

Oops, thanks.
Will try that.