How can we subscribe to over 200 million api calls per month? from WeatherKit api documentation, the max is 200m calls/month
WeatherKit
RSS for tagBring weather information to your apps and services through a wide range of data that can help people stay up to date, safe, and prepared.
Posts under WeatherKit tag
68 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
My code was running with with the version before Xcode 26 RC. I recompiled one last time. Now I'm getting the error: A server with the specified hostname could not be found
let now = Calendar.current.date(byAdding: .hour, value: 1, to: Date())!
let nextWeek = Calendar.current.date(byAdding: .day, value: 14, to: Date())!
do
{
let (dailyForecast, hourlyForecast, currentWeather, alertWeather) =
try await weatherService.weather(for: thisLocation, including: .daily, .hourly(startDate: now, endDate: nextWeek), .current, .alerts)
Suggestions?
Weatherkit stopped again providing next hour rain data for United kingdom and ireland
Does WeatherKit have Hourly Agriculture Forecast endpoint? we are specifically looking for the following weather variables:
soil moisture,
soil temperature,
evapotranspiration,
temperatureInversion
Next hour rain data for the last 12 hours for United Kingdom is not loading.
Does WeatherKit Rest api have the following forecast endpoints?
Pollen and Flu
Air quality
Radar forecast served through a REST API?
Hail
Solar energy
Frost Potential Index
In the availability and pricing section, we have reviewed the plans and we will be upgrading to 50 or 100 million calls/month but before we do, we have a couple questions.
Does the API have rate limit or throttling?
Do you have additional weather forecast endpoints like hail, radar, or pollen forecast? I see in this thread https://developer.apple.com/forums/thread/795642 that air quality is not available
Thanks
I found that only ConditionCode in the current Weather is a field related to weather description, but it is just an enumeration of weather predictions. I want to present different weather descriptions to users in different languages.What should I display to the user based on?
Why can't Weatherkit return the corresponding language's ConditionCode based on Langular
Hello,
We’re using the Apple WeatherKit API in our application and would like to better understand how the conditionCode field is determined in the hourly data.
In particular, we have encountered cases where both rain and strong winds occurred within the same hour, but the conditionCode returned was related to wind (e.g. windy), even though rain was present and more relevant to our use case.
Could you please clarify:
What is the logic or prioritization used by WeatherKit when selecting the conditionCode for an hourly period that includes multiple weather events?
Is rain ever prioritized over wind in this field? If so, under what conditions?
Since precipitation has more impact for our analyses and decision-making than wind, understanding how this field is computed is important for us.
Thank you in advance for your help.
Best regards,
Please refer to Feedback Assistant ID FB18967784
1.In which locations you would like to see air quality.
[Ans] Base on user's location information(GPS).
2.What air quality data you would like to see: pollutant concentrations, official air quality scales used in each country, health information related to air quality, etc.
[Ans] Official air quality scales used in each country.
Generally calculated from O3, PM2.5, PM10, CO, SO2, NO2.
3.If possible, how you would like to use air quality information. This can help us ensure the right data is available to best support your use.
[Ans] Please refer to the screenshot. I plan to add AQI to this screen.
It's a screenshot in the development stage.
Thank you!
Does WeatherKit provide any AQI(Air Quality index) information?
Thank you.
In Availability and pricing section, there's a 500,000 API calls a month per Apple Developer Program membership limitation.
Is this just to limit the number of calls for developer in development stage?
After the app is uploaded to App store, users download and start to use this app.
Will Weather API calls of general App users be included in 500,000 API calls?
Thanks.
Hi all,
I have WeatherKit working on iOS and watchOS, but am having problems getting it to work on macOS. I have all entitlements enabled and everything seems to checkout, but I get the following error:
"WARNING: error = 3→(76) INVALID_PERSONA; It is undefined behavior to look up a container with a persona other than personal or data separated. Please adopt a persona first. Assuming personal. given persona = (<MCMUserIdentity: 0xb3d0288c0; posixUser = (501|20|danuff|/Users/danuff), identifier = 501, personaType = unspecific, personaUniqueString = E90578C5-AAE4-44DD-9E41-CC3F97B34F0C, kernelPersonaID = 1001>)
Message from debugger: killed
Any ideas?
Hi, my server in Melbourne Australia is getting weather forecasts from a few places around Australia. When I look at the daily timesteps that I get back, they might be something like this:
"days": [
{
"forecastStart": "2025-06-25T00:00:00Z",
"forecastEnd": "2025-06-26T00:00:00Z",
"daytimeForecast": {
"forecastStart": "2025-06-25T07:00:00Z",
"forecastEnd": "2025-06-25T19:00:00Z",
"overnightForecast": {
"forecastStart": "2025-06-25T19:00:00Z",
"forecastEnd": "2025-06-26T07:00:00Z",}
It doesn't matter where I ask for - Melbourne, Darwin, Perth, it always comes back the same.
The documentation says that daytimeForecast is 7 am to 7 pm local and overnightForecast is 7pm to 7 am local.
However, in a place like Perth 7-19Z is 3 pm to 3 am, not 7 pm to 7 am like advertised.
I can see that for any given date, there are 3 maximum temperature forecasts, a 24 hour max, a daytime max and an overnight max and they differ from each other.
Can anyone help me understand what's happening here?
And furthermore in the example above, the 24 hour forecasts that have, for example this:
"forecastStart": "2025-06-25T00:00:00Z" ... Can the 00:00:00Z be trusted literally? Or is it more the case that it's "2025-06-25" but the HMS got tacked on in a conversion?
One of my apps includes a free weather forecast using WeatherKit. Recently, it started to get more downloads and almost reached the limits of the free tier.
I've removed the forecast in newer versions but there's still a substantial amount of users who do not update their apps.
Is it possible to somehow remove the capability from existing apps?
Thank you!
I’m hitting a WeatherKit JWT failure (WDSJWTAuthenticatorServiceListener Code = 2) at runtime even though the entitlement is present in both the signed binary and the embedded provisioning profile.
Environment
Team ID
5SZLQLQ9MD
Bundle ID
ParkProfessor.ParkProfessorDisneyland
Device / OS
iPhone 15 Pro · iOS 17.4.1 (hardware, not simulator)
Xcode
15.3 (15E204a)
Console output
Failed to generate jwt token for: com.apple.weatherkit.authservice
Error Domain=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors Code=2 "(null)"
Entitlement & profile snippets
codesign -d --entitlements :- WeatherKitTest.app | grep -A2 weatherkit
com.apple.developer.weatherkit
security cms -D -i embedded.mobileprovision | grep -A2 weatherkit
com.apple.developer.weatherkit
What I’ve already tried
Regenerated a new development certificate and a new iOS App Development provisioning profile with WeatherKit enabled.
Confirmed the capability is selected in Certificates ▸ Identifiers ▸ Profiles and added in Xcode target settings.
WeatherKit Terms of Service accepted in the portal.
Deleted the app, removed any device management profiles, rebooted the phone, clean-built & ran again.
Reproduced the issue in a minimal SwiftUI app that calls: WeatherService.shared.weather(for: CLLocation(latitude: 33.8121, longitude: -117.9190), including: .current) – same Code 2 error.
Request
It looks like the App ID may need a backend entitlement sync. Could someone from the WeatherKit team please check the status for Team 5SZLQLQ9MD, Bundle ID ParkProfessor.ParkProfessorDisneyland and enable WeatherKit token generation?
Thanks!
My app AirCompare has been in the app store and successfully using WeatherKit to fetch weather since it became available. Now some (not all) users are encountering the following errors:
Failed to generate jwt token for: com.apple.weatherkit.authservice with error: Error Domain=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors Code=2 "(null)"
Encountered an error when fetching weather data subset; location=<+42.40865786,-88.96911526> +/- 0.00m (speed -1.00 mps / course -1.00) @ 6/23/25, 2:56:47 PM Central Daylight Time, error=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors 2 Error Domain=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors Code=2 "(null)"
Others are reporting this same problem here in the forums. We need a solution!
We have a subscription WeatherKit app which has been on the App Store since December 2023.
I am getting intermittent JWT auth failures on customer devices. In the great majority of cases, the request succeeds, but sometimes it fails, and sometimes it fails and never recovers. I’m working with a customer right now who is unable to get any weather data at all, and the logs he sends me show
WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors error 2
The app uses the WeatherKit SDK (we are not using the REST API directly). We know we have the project setup as it has been working since launch, and I can verify weatherkit using
security cms -D -i embedded.mobileprovision
It it not a problem with the specific query, since I can get data for the dates and locations they are requesting. I can’t replicate the problem on my test devices.
In case there is a rate limit issue: this app is a bit unusual and downloads an unusual amount of data at once using multiple queries in parallel using a TaskGroup. When the user creates a location, the app downloads a 10 day block of weather (7 days in the past + 3 day forecast) using
WeatherService.shared.weather(
for: location,
including: WeatherQuery.daily(
startDate: startDate,
endDate: endDate
),
WeatherQuery.hourly(
startDate: startDate,
endDate: endDate
)
)
It also downloads about 2 months of daily precipitation data using multiple parallel calls to dailySummary in 10 day blocks:
WeatherService.shared.dailySummary(
for: location,
forDaysIn: DateInterval(start: startDate, end: endDate),
including: .precipitation
)
In almost every case, including on my test devices, this works. But some users get WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors error 2 on every request.
The two users yesterday that had this problem were both on iOS 18.5 for what that's worth, though the app supports 17.2+
Is anyone else seeing this? And can anyone suggest anything else to explore? It's obviously a terrible experience for customers who pay for the service and are unable to get any data.
I did submit this info to Apple as FB18276275
I have an app using weatherkit and its currently live and up on the app store, recently I had some users report to me that they had been receiving errors loading weather data, I had error handling built in and it reported an issue with apples authentication server
Failed to generate jwt token for: com.apple.weatherkit.authservice with error: Error Domain=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors Code=2 "(null)"
I have not come across this during the development lifecycle of my project, there where no codebase changes, it just stopped functioning.
The app entitlements are valid and correct, Weatherkit is enabled in both xcode and across my Certs, identifiers and profiles.
I was not experiencing this issue until I reinstalled the app from the app store completly by first removing it and then re-installing fresh.
Hard reboots do not help and I do not want to start suggesting to my users to factory reset their devices.
We are using WeatherKit in both our main app and widget, relying entirely on Apple’s framework for authentication and token management.
We do not generate or inject our own JWT tokens; all token handling is managed by WeatherKit.
We have implemented a debug menu with the following actions:
Clear WeatherKit JWT tokens from the keychain
Clear all related UserDefaults key
Clear all app group data and all UserDefaults.
Perform a “nuclear” cache clear (removes all app data, keychain, and cached files).
We log all WeatherKit fetch attempts and failures, including authentication errors, both in the app and widget and get nothing but code 2.
We have attempted all of the above steps, but continue to experience issues with WeatherKit JWT authentication
We would appreciate any guidance or insight into what else could be causing persistent WeatherKit JWT/authentication issues, or if there are any additional steps we should try.
P.S. - Tested and experiencing the same issues on an iPhone 15 Pro Max and iPhone 15
The Pro Max is on the iOS 26 Beta // and the 15 is on the latest iOS 18