martykan / forecastie

A simple, opensource weather app for Android.
Other
872 stars 339 forks source link

Consider OWM's new One Call API #499

Open FridoDeluxe opened 4 years ago

FridoDeluxe commented 4 years ago

OpenWeatherMap provides a new API called One Call API: https://openweathermap.org/api/one-call-api. Hourly forecast for 48 hours and daily forecast for seven days looks promising. I assume that this new API is backed by appropriate data instead of plain interpolation and it's worth considering to use it. What do you think?

But first we need to check if Forecastie's unrestricted API key is also unrestricted for the new One Call API calls (otherwise it makes no sense to implement it and force every user to enter their own API key).

robinpaulson commented 4 years ago

It's definitely worth investigating. Good point on the API key.

FridoDeluxe commented 4 years ago

Detailed OWM data gathered via the One Call API would enable us to work on certain requested features (like #334, #493, #497).

FridoDeluxe commented 4 years ago

Concerning the unlimited API key: If I understood #182 correctly OWM lifted Forecastie's API key to the Startup plan (promised for 1 year, but now three years later it's still working :smile:). The startup plan includes 2000 One Call API calls per day. Although the One Call API might reduce the number of calls since it can download several data parts in one call (hence the name), this will not be enough for the Forecastie user base. Just Google Play has already 10.000+ Forecastie installations.

We could optionally include the new One Call API features for users that entered a custom API key. But it's quite some work to redesign everything (source code and user interface) to work with both API options.

robinpaulson commented 4 years ago

But it's quite some work to redesign everything (source code and user interface) to work with both API options.

I think implementing both API methods is too much work. 10,000+ Google installations could well be 40,000, given how Google displays these milestones.

Perhaps we wait, it is a new service, they may increase the allowance as it becomes more popular?

robinpaulson commented 3 years ago

According to OWM, they are deprecating the UV API (see #581), and folding it into One Call. The current UV API will still exist but not be supported. This forces a decision, options as follows:

  1. Continue using the unsupported UV API and assume it will not break in any way we cannot fix
  2. Ask OWM nicely to give us a free upgrade to a plan which has more than 2,000 One Call API calls per day (we are currently on the Startup plan, at no cost, as we are Free/Libre software)
  3. Drop UV forecasts completely from Forecsatie
  4. Wait until OWM upgrades their plans to include more One Call API Calls
  5. Each user has their own API key
  6. Some other ideas I haven't thought of
woheller69 commented 3 years ago

Regarding increased limit I was already in contact with OWM and got the answer " that FOSS access does not and will not be increasing limits for One Call API." They only offer this for other APIs.

woheller69 commented 3 years ago

So option 6 is that each user has have his own key.

robinpaulson commented 3 years ago

"FOSS access does not and will not be increasing limits for One Call API."

ech, that's irritating.

i wonder if this is a usable option: On install, the user is guided through a simple, semi-automatic process to create and enter their own API key. I'm sure there are T&C clauses which prevent automatically creating API keys, but I'm equally sure we can stick to the letter and the spirit of those clauses while making it painless to create individual keys.

As an aside, if we do this, are we assisting OWM to access vast amounts of individualised data, tied to an email address and location. If so, how ethical is that?

I've not looked up what OWM say they do with the data they collect on individual users, I guess that's the starting point.

woheller69 commented 3 years ago

In my Radarweather I am guiding the users to the link where they can create their own key. Afterwards they have to enter the key in the app.

I also would not want to collect the user data inside my app...

robinpaulson commented 3 years ago

I also would not want to collect the user data inside my app...

I was talking about enabling/assisting OWM collecting data, not Forecastie. But no, I wouldn't want to collect that either.

woheller69 commented 3 years ago

here is what they do with the data:

https://openweather.co.uk/privacy-policy#use_personal_data

I tried to open the Privacy Center

https://home.openweathermap.org/privacy_centre

but it returns : We're sorry, but something went wrong.

robinpaulson commented 3 years ago

This is key: "We will get your express opt-in consent before we share your personal data with any company outside the OpenWeather Ltd group of companies for marketing purposes or potential investors."

but of course: "If we are selling all or parts of our business we may have to share your personal data with potential buyers and investors after they sign non-disclosure and non-compete agreement."

Nothing is forever, an ethical OWM now may become unethical tomorrow, when they are sold to Facebook/the remaining Koch Brother/Blackwater/Goldman Sachs.

woheller69 commented 3 years ago

When you are logged in there is also a privacy center in your profile and there are only option for messages from OWM.

So I think for now this is ok, as long as they are not asking for "express opt-in consent"...