BeoCode/Weather
Archived
6
0
Fork
You've already forked Weather
11

Api key not working #43

Closed
opened 2022年08月17日 13:59:42 +02:00 by amittel · 29 comments

Summary

Not able to use the app, since the API key is supposedly not active

Steps to reproduce

  1. Enter city
  2. Enter API key
  3. Hit Confirm Data

Expected behaviour

Should show me the weather for the selected city

Actual behaviour

Telling me, that my API key is wrong.

But if I test (RESTED in Firefox) it with

http://api.openweathermap.org/data/2.5/forecast?id={API-KEY}

I get data back.

Environment data

  • Android version: 11

  • Device model: Mi9

  • Stock or customized system: crDroid 7.2ß

  • Weather app version: 3.19.1

cc @Beowulf

### Summary Not able to use the app, since the API key is supposedly not active ### Steps to reproduce 1. Enter city 2. Enter API key 3. Hit Confirm Data ### Expected behaviour Should show me the weather for the selected city ### Actual behaviour Telling me, that my API key is wrong. But if I test (RESTED in Firefox) it with ``` http://api.openweathermap.org/data/2.5/forecast?id={API-KEY} ``` I get data back. ### Environment data - Android version: 11 - Device model: Mi9 - Stock or customized system: crDroid 7.2ß - Weather app version: 3.19.1 cc @Beowulf

Hello,

  1. have you recently created your OWM account?
  2. the correct API is: https://api.openweathermap.org/data/2.5/onecall?lat={lat}&lon={lon}&exclude=minutely&appid={API-Key}

Kind regards
Beowulf

Hello, 1. have you recently created your OWM account? 2. the correct API is: `https://api.openweathermap.org/data/2.5/onecall?lat={lat}&lon={lon}&exclude=minutely&appid={API-Key}` Kind regards Beowulf

Same issue on S21 Ultra with all current updates. Tried with VPN on, and disabled. Restarted, etc.
Thanks for the app and support!

Same issue on S21 Ultra with all current updates. Tried with VPN on, and disabled. Restarted, etc. Thanks for the app and support!

@rpotter have you recently created your OWM account and if so, when?

@rpotter have you recently created your OWM account and if so, when?

Thanks for the follow up !

Yes I did, and made two codes, last night at 9:00 pm, or about 17 hours ago. I've since logged back in to confirm that I have the correct codes. Neither works.

If I should provide you with additional (structured) detail , just tell me where to find the format . But it's the same as the OP.

Bob

Thanks for the follow up ! Yes I did, and made two codes, last night at 9:00 pm, or about 17 hours ago. I've since logged back in to confirm that I have the correct codes. Neither works. If I should provide you with additional (structured) detail , just tell me where to find the format . But it's the same as the OP. Bob

Then I think you are unfortunately the first who are affected by the changeover from OWM...
I'm already have a fix for it. I hope to write/implement it on Sunday.

See #34 for more infos.

Then I think you are unfortunately the first who are affected by the changeover from OWM... I'm already have a fix for it. I hope to write/implement it on Sunday. See #34 for more infos.

Many thanks for the quick response. I will check the linked post and look for the update when you have time.

Many thanks for the quick response. I will check the linked post and look for the update when you have time.

I have found myself in the same boat as @rpotter and I appreciate both of you discussing this here. I signed up and got a new API key last night and I have been trying to use this new OpenWeather key on multiple apps, each one failing in the same way. My key works fine with 3.0 in the browser, but when I change it to 2.5 (as all the apps use), it fails.

The OpenWeather website doesn't mention anywhere that the OneCall 1.0/2.5 API will not work with these new keys. Also, it doesn't even mention how new 3.0 is, so as a newcomer, it was pretty hard to track down that the deployment just took place recently that breaks all weather apps' functionality. No other weather app developers are talking about it either, as far as I could find.

Just wanted to say that I appreciate finally understanding what the problem is, and I'll be eager to use this Weather app once the change is made to allow API 3.0 usage!

I have found myself in the same boat as @rpotter and I appreciate both of you discussing this here. I signed up and got a new API key last night and I have been trying to use this new OpenWeather key on multiple apps, each one failing in the same way. My key works fine with 3.0 in the browser, but when I change it to 2.5 (as all the apps use), it fails. The OpenWeather website doesn't mention anywhere that the OneCall 1.0/2.5 API will not work with these new keys. Also, it doesn't even mention how new 3.0 is, so as a newcomer, it was pretty hard to track down that the deployment just took place recently that breaks all weather apps' functionality. No other weather app developers are talking about it either, as far as I could find. Just wanted to say that I appreciate finally understanding what the problem is, and I'll be eager to use this Weather app once the change is made to allow API 3.0 usage!
Author
Copy link

I have an account. I signed up 24h ago.
I have tested to the call from BeoWolf

https://api.openweathermap.org/data/2.5/onecall?lat=33.44&lon=-94.04&exclude=minutely&appid=KEY

and one from the official documentation

https://api.openweathermap.org/data/3.0/onecall?lat=33.44&lon=-94.04&exclude=hourly,daily&appid=KEY

Both do not Work. I always get a

401 Unauthorized

Server: openresty
Date: 2022年8月17日 19:51:23 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 107
Connection: keep-alive
X-Cache-Key: /data/2.5/onecall?exclude=minutely&lat=33.44&lon=-94.04
Access-Control-Allow-Origin: *
Access-Control-Allow-Credentials: true
Access-Control-Allow-Methods: GET, POST
{
 "cod": 401,
 "message": "Invalid API key. Please see http://openweathermap.org/faq#error401 for more info."
}

Since even version 3 does not work, i think may activation process is still in the making...

I have an account. I signed up 24h ago. I have tested to the call from BeoWolf ``` https://api.openweathermap.org/data/2.5/onecall?lat=33.44&lon=-94.04&exclude=minutely&appid=KEY ``` and one from the official [documentation](https://openweathermap.org/api/one-call-3) ``` https://api.openweathermap.org/data/3.0/onecall?lat=33.44&lon=-94.04&exclude=hourly,daily&appid=KEY ``` Both do not Work. I always get a > 401 Unauthorized ``` Server: openresty Date: 2022年8月17日 19:51:23 GMT Content-Type: application/json; charset=utf-8 Content-Length: 107 Connection: keep-alive X-Cache-Key: /data/2.5/onecall?exclude=minutely&lat=33.44&lon=-94.04 Access-Control-Allow-Origin: * Access-Control-Allow-Credentials: true Access-Control-Allow-Methods: GET, POST { "cod": 401, "message": "Invalid API key. Please see http://openweathermap.org/faq#error401 for more info." } ``` Since even version 3 does not work, i think may activation process is still in the making...

The OneCallApi-3 should work, did you copy the Api key correctly?

The OneCallApi-3 should work, did you copy the Api key correctly?
Author
Copy link

Yeah something is wrong.
I just tried the link in their email

http://api.openweathermap.org/data/2.5/weather?q=London,uk&APPID=KEY

and it works.

Have to look at it again tommorrow.

Yeah something is wrong. I just tried the link in their email ``` http://api.openweathermap.org/data/2.5/weather?q=London,uk&APPID=KEY ``` and it works. Have to look at it again tommorrow.

@benS OneCallAPI 3 is about 2-3month old.
I also don't like what OWM has done here, as they touted OneCallApi 1.0 big a few years ago as an alternative to another API and now they are "destroying" it "too"...

@benS OneCallAPI 3 is about 2-3month old. I also don't like what OWM has done here, as they touted OneCallApi 1.0 big a few years ago as an alternative to another API and now they are "destroying" it "too"...

@amittel Your link is for the current weather api: https://openweathermap.org/current

@amittel Your link is for the current weather api: https://openweathermap.org/current

What is the standard limit for you? (https://home.openweathermap.org/subscriptions)
grafik

What is the standard limit for you? (https://home.openweathermap.org/subscriptions) ![grafik](/attachments/9b35cc0b-d7f9-4aee-8a73-02800418a9e6)

What is the standard limit for you? (https://home.openweathermap.org/subscriptions)
grafik

Not sure if you want multiple data points.

Mine was 2000 at first and I manually changed it to 1000. Only 3.0 calls show up in the summary.

> What is the standard limit for you? (https://home.openweathermap.org/subscriptions) > ![grafik](/attachments/9b35cc0b-d7f9-4aee-8a73-02800418a9e6) Not sure if you want multiple data points. Mine was 2000 at first and I manually changed it to 1000. Only 3.0 calls show up in the summary.

@benS OneCallAPI 3 is about 2-3month old.
I also don't like what OWM has done here, as they touted OneCallApi 1.0 big a few years ago as an alternative to another API and now they are "destroying" it "too"...

Very frustrating!

> @benS OneCallAPI 3 is about 2-3month old. > I also don't like what OWM has done here, as they touted OneCallApi 1.0 big a few years ago as an alternative to another API and now they are "destroying" it "too"... Very frustrating!

Ok, then at least that's true. OWM had said that the standard is 2k, but for more than 1k you have to pay.
In my profile for the app, it was already at 1k by default.

Ok, then at least that's true. OWM had said that the standard is 2k, but for more than 1k you have to pay. In my profile for the app, it was already at 1k by default.
Author
Copy link

What is the standard limit for you? (https://home.openweathermap.org/subscriptions)
grafik

Looking at your pictures, I may have to subscribe manually to the plan. I thought that the Free Plan is enough.

grafik

> What is the standard limit for you? (https://home.openweathermap.org/subscriptions) > ![grafik](/attachments/9b35cc0b-d7f9-4aee-8a73-02800418a9e6) Looking at your pictures, I may have to subscribe manually to the plan. I thought that the Free Plan is enough. ![grafik](/attachments/f256902d-be15-47ac-9d4d-b10ada59872e)
110 KiB

@amittel Is the Subscribe button gone when you set the limit to 1000?

@amittel Is the Subscribe button gone when you set the limit to 1000?
Author
Copy link

No.
grafik

No. ![grafik](/attachments/6f164bff-9c32-44c8-aaca-e986598cd4fd)

Strange... 🤔
I'll have to create another account to test....

Strange... 🤔 I'll have to create another account to test....

Have to move this to tomorrow after work as I've just got home from work (9:30pm)...

Have to move this to tomorrow after work as I've just got home from work (9:30pm)...
https://codeberg.org/BeoCode/Weather/issues/34#issuecomment-607621

Okay, I was just emailed by openWeather with the >1000 access issue.

I don't want to pressure you, Beowolf; you are kind enough to provide this free to us, but the problem is still going on. if there is anything anything I can do, let me know?

Also, anyone getting a new key needs to understand it can take a few days to activate the key, and once it's activated, it will most likely be immediately flagged since it is probably sending over 1000 requests per day.

is there any chance that with API-3 or with increased popularity of your app, that they have changed policy and are telling us in the most rude way possible? I know people have looked, but I'll look again...

Okay, I was just emailed by openWeather with the >1000 access issue. I don't want to pressure you, Beowolf; you are kind enough to provide this free to us, but the problem is still going on. if there is anything anything I can do, let me know? Also, anyone getting a new key needs to understand it can take a few days to activate the key, and once it's activated, it will most likely be immediately flagged since it is probably sending over 1000 requests per day. is there any chance that with API-3 or with increased popularity of your app, that they have changed policy and are telling us in the most rude way possible? I know people have looked, but I'll look again...

I don't want to pressure you, Beowolf; you are kind enough to provide this free to us, but the problem is still going on. if there is anything anything I can do, let me know?

The only thing would be to see how often the app makes an API request to the server (I cannot do this, because I don't have a phone currently) - although I know several people who also use the app (with widgets) and have no problems and (often) even share a key.

Also, anyone getting a new key needs to understand it can take a few days to activate the key, and once it's activated, it will most likely be immediately flagged since it is probably sending over 1000 requests per day.

OneCallApi 1.0 is no longer included when creating a new account. The Api-Docs have also been removed.

is there any chance that with API-3 or with increased popularity of your app, that they have changed policy and are telling us in the most rude way possible? I know people have looked, but I'll look again...

I don't think OWM will change its position here. I am still ambivalent about the addition of OneCallApi 3.0, as this actually violates the idea of being free, as you have to provide personal data and a payment method in order to use OCA3. Maybe the aim of the API change is to get more data...
When I asked, they said that the limit for existing customers remained at 1000 requests per day.

> I don't want to pressure you, Beowolf; you are kind enough to provide this free to us, but the problem is still going on. if there is anything anything I can do, let me know? The only thing would be to see how often the app makes an API request to the server (I cannot do this, because I don't have a phone currently) - although I know several people who also use the app (with widgets) and have no problems and (often) even share a key. > Also, anyone getting a new key needs to understand it can take a few days to activate the key, and once it's activated, it will most likely be immediately flagged since it is probably sending over 1000 requests per day. OneCallApi 1.0 is no longer included when creating a new account. The Api-Docs have also been removed. > is there any chance that with API-3 or with increased popularity of your app, that they have changed policy and are telling us in the most rude way possible? I know people have looked, but I'll look again... I don't think OWM will change its position here. I am still ambivalent about the addition of OneCallApi 3.0, as this actually violates the idea of being free, as you have to provide personal data and a payment method in order to use OCA3. Maybe the aim of the API change is to get more data... When I asked, they said that the limit for existing customers remained at 1000 requests per day.

now, this irks me. nothing you've done, and only maybe what they've done. I used to work in RF and had access to anything I'd need to trace my cellphone's transmissions.

I've tried protocol analysis of my phone with my phone before, and it's problematic at best.

ok. next to me would seem to be running android apps on my computer and monitoring that way. fortunately, I use linux and this is easier than with windows.


if this is just a "sales promotion" from them, and we were all chosen just because we have accounts and not because they have really monitored traffic, that's a different kind of issue. time to produce data to study. I love details. on it....

now, this irks me. nothing you've done, and only maybe what they've done. I used to work in RF and had access to anything I'd need to trace my cellphone's transmissions. I've tried protocol analysis of my phone with my phone before, and it's problematic at best. ok. next to me would seem to be running android apps on my computer and monitoring that way. fortunately, I use linux and this is easier than with windows. *** if this is just a "sales promotion" from them, and we were all chosen just because we have accounts and not because they have really monitored traffic, that's a different kind of issue. time to produce data to study. I love details. on it....

maybe you want to support my proposal here.
Open-Meteo could provide an API compatible to OneCallAPI...

https://github.com/open-meteo/open-meteo/issues/116

maybe you want to support my proposal here. Open-Meteo could provide an API compatible to OneCallAPI... https://github.com/open-meteo/open-meteo/issues/116

I don't have a GitHub-Acc 🤷‍♂️

I don't have a GitHub-Acc 🤷‍♂️

If you know any (good) weather api: #46

If you know any (good) weather api: #46

I am closing this because I do not want to add OneCallApi 3.0. Support for other APIs will be there in the new app then.

I am closing this because I do not want to add OneCallApi 3.0. Support for other APIs will be there in the new app then.
Commenting is not possible because the repository is archived.
No Branch/Tag specified
main
translation
3.21-pre1
3.20
3.20-pre2
3.20-pre1
3.19.1
3.19
3.18.1
3.18
3.17
3.17-pre2
3.17-pre1
3.16
3.16-pre1
3.15
3.15-pre1
3.14
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
6 participants Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
BeoCode/Weather#43
Reference in a new issue
BeoCode/Weather
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?