It is currently April 27th, 2024, 5:29 am

Open-Meteo Weather API

Weather skins
ZXCVBOT

Re: Open-Meteo Weather API

Post by ZXCVBOT »

Got it. But, MeterLocation one is not about beauty per se. Rather, it is related to clipping of text done wrongly due to code.
Edit: I did it again.. The previous responses were not from your first skin, rather: Bonus ~ Win10 Widgets Open-Meteo skin... Sorry, if any inconvenience was caused by me.
User avatar
ravv3
Posts: 47
Joined: January 23rd, 2024, 12:55 am
Location: London

Re: Open-Meteo Weather API

Post by ravv3 »

I'm using a widget where the weather element does not work. It uses the old api.weather.com variable. It is called 'Meenimal'. It hasn't been updated for the past 2 years.
I was wondering if anyone could look into the configuration settings of this, and let me know how I could incorporate an Open-Meteo api into it?
The variables don't seem to be in the same format as the suggested methods posted here, so I was a bit stuck with how to proceed. :???:
I am new to all this btw, but willing to learn, and make the necessary config changes in order to get this working.
I really like the look and integration of this widget and the bits that are still working, so unwilling to change it for a different one.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5407
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Open-Meteo Weather API

Post by eclectic-tech »

ravv3 wrote: January 23rd, 2024, 1:14 am I'm using a widget where the weather element does not work. It uses the old api.weather.com variable. It is called 'Meenimal'. It hasn't been updated for the past 2 years.
I was wondering if anyone could look into the configuration settings of this, and let me know how I could incorporate an Open-Meteo api into it?
The variables don't seem to be in the same format as the suggested methods posted here, so I was a bit stuck with how to proceed. :???:
I am new to all this btw, but willing to learn, and make the necessary config changes in order to get this working.
I really like the look and integration of this widget and the bits that are still working, so unwilling to change it for a different one.
You simply need to update the APIKey variable value.
Open Meenimal.ini in your text editor.

Locate the [Variables] section.
Find the line
APIKey=d522aa97197fd864d36b418f39ebb323

edit the line to
APIKey=21d8a80b3d6b444998a80b3d6b1449d3
or
APIKey=71f92ea9dd2f4790b92ea9dd2f779061

Save the file and refresh the skin.
User avatar
ravv3
Posts: 47
Joined: January 23rd, 2024, 12:55 am
Location: London

Re: Open-Meteo Weather API

Post by ravv3 »

eclectic-tech wrote: January 23rd, 2024, 3:28 am You simply need to update the APIKey variable value.
Open Meenimal.ini in your text editor.

Locate the [Variables] section.
Find the line
APIKey=d522aa97197fd864d36b418f39ebb323

edit the line to
APIKey=21d8a80b3d6b444998a80b3d6b1449d3
or
APIKey=71f92ea9dd2f4790b92ea9dd2f779061

Save the file and refresh the skin.
I thought it was as simple as that with this skin, I did try other API Keys like Ctrl + U on weather.com site, looking for "v3_API_Key", and copy/pasting that value into the variables section of Meenimal.ini.
However like the keys you posted - while it is actually displaying info (although wrong), the widget does not update. I've refreshed Rainmeter, and refreshed the skin.
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5407
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Open-Meteo Weather API

Post by eclectic-tech »

ravv3 wrote: January 23rd, 2024, 12:16 pm I thought it was as simple as that with this skin, I did try other API Keys like Ctrl + U on weather.com site, looking for "v3_API_Key", and copy/pasting that value into the variables section of Meenimal.ini.
However like the keys you posted - while it is actually displaying info (although wrong), the widget does not update. I've refreshed Rainmeter, and refreshed the skin.
The weather info is based on the location values you enter in the 'Meenimal\Settings\Weather.ini' skin.
Enter your city and region info in the 'Location' box of that skin, press 'Enter', and then refresh that skin to update.
meenimal.png
You do not have the required permissions to view the files attached to this post.
User avatar
ravv3
Posts: 47
Joined: January 23rd, 2024, 12:55 am
Location: London

Re: Open-Meteo Weather API

Post by ravv3 »

I was just just playing about with that setting. :) I put in London and it seems out compared to other forecasts - like it's reporting 15°C when it's actually reported as 10°C elsewhere. I tried 'London, England' and 'London, UK' but same output. And it doesn't seem to refresh. (I am using one of your API keys btw).
I did try inputting a number of regions in the US and the temp changed, and random European cities changed too - it's just the updating i think, unless i'm not leaving it long enough, which i doubt because when I had it set to London previously for a while it didn't update.

Is it to do with something in this code from Meenimal.ini? I was thinking the 'wx-forecast-daily-3day' part:

Code: Select all

APIKey=71f92ea9dd2f4790b92ea9dd2f779061
URLSite=https://api.weather.com/v3/aggcommon/v3-wx-observations-current;v3-wx-forecast-daily-3day;v3alertsHeadlines;v3-location-point?format=json&geocode=#Latitude#,#Longitude#&units=#Units#&language=#Language#&apiKey=#APIKey#
Appreciating your help.
User avatar
Yincognito
Rainmeter Sage
Posts: 7175
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Open-Meteo Weather API

Post by Yincognito »

ravv3 wrote: January 23rd, 2024, 1:30 pm I was just just playing about with that setting. :) I put in London and it seems out compared to other forecasts - like it's reporting 15°C when it's actually reported as 10°C elsewhere. I tried 'London, England' and 'London, UK' but same output. And it doesn't seem to refresh. (I am using one of your API keys btw).
I did try inputting a number of regions in the US and the temp changed, and random European cities changed too - it's just the updating i think, unless i'm not leaving it long enough, which i doubt because when I had it set to London previously for a while it didn't update.

Is it to do with something in this code from Meenimal.ini? I was thinking the 'wx-forecast-daily-3day' part:

Code: Select all

APIKey=71f92ea9dd2f4790b92ea9dd2f779061
URLSite=https://api.weather.com/v3/aggcommon/v3-wx-observations-current;v3-wx-forecast-daily-3day;v3alertsHeadlines;v3-location-point?format=json&geocode=#Latitude#,#Longitude#&units=#Units#&language=#Language#&apiKey=#APIKey#
Appreciating your help.
London is a big city and temps might differ depending on the neighborhood, not to mention that weather providers might offer slightly different values too. Also, it makes no sense for a weather skin to update and poll the site excessively only to measure a temperature that is not changing every minute anywhere on the planet. Just saying...
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
User avatar
eclectic-tech
Rainmeter Sage
Posts: 5407
Joined: April 12th, 2012, 9:40 pm
Location: Cedar Point, Ohio, USA

Re: Open-Meteo Weather API

Post by eclectic-tech »

Meenimal weather's update rate is every 5 minutes. It parses 3 items from the website: cloudcoverphrase, max temperature, and city.

So, it does update, but as Yincognito explained those values depend on a specific latitude and longitude, while describing a much larger general area and may not be the same in every part of say 'London'...
User avatar
ravv3
Posts: 47
Joined: January 23rd, 2024, 12:55 am
Location: London

Re: Open-Meteo Weather API

Post by ravv3 »

eclectic-tech wrote: January 23rd, 2024, 1:53 pm Meenimal weather's update rate is every 5 minutes. It parses 3 items from the website: cloudcoverphrase, max temperature, and city.

So, it does update, but as Yincognito explained those values depend on a specific latitude and longitude, while describing a much larger general area and may not be the same in every part of say 'London'...
Maybe i'ts because it's set to Max Temp and not something like Current Temp that it's a different reading to the other places i've looked at, like Microsoft's on the desktop or Yahoo's website? Although yes, it could well be they're reporting different regions of London.
I have currently got it set to a random city, and watching for any changes during the day. I'll keep you guys posted.
User avatar
Yincognito
Rainmeter Sage
Posts: 7175
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Open-Meteo Weather API

Post by Yincognito »

eclectic-tech wrote: January 23rd, 2024, 1:53 pmIt parses 3 items from the website: cloudcoverphrase, max temperature, and city.
ravv3 wrote: January 23rd, 2024, 2:38 pmMaybe i'ts because it's set to Max Temp and not something like Current Temp
Yeah, looking at the code, I think that is the problem: it gives the max temp for the current day, when the user normally expects the current temperature. Just tested the skin myself and it is indeed off because of that. The solution would be to change:

Code: Select all

RegExp=(?siU)"cloudCoverPhrase":"(.*)".*{"calendarDayTemperatureMax":\[(.*),.*"city":"(.*)".*
in [MeasureWeather] to:

Code: Select all

RegExp=(?siU)"cloudCoverPhrase":"(.*)".*"temperature":(.*),.*"city":"(.*)".*
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth