-
Couldn't load subscription status.
- Fork 2
Description
Hey, I'm using this library and I think something is going wrong with the token that's generated from generateJWT().
I've got all the data in the JWT constructor matching what you've got in the example, but every time I try it, I get a 403 forbidden (access denied) error.
I tried another example in c#, using the same teamID/keyID/private key etc, and the token string it generates works. I can use that token in the dart sample I'm working on, so I know everything else is good except for the token generated in Dart.
I don't really have a lot of experience with JWTs or tokens, so I fully believe I've done something wrong here, but don't know what?
var jwtToken = weather.generateJWT(bundleId: "OpenSkyWeatherKit", teamId: "54P****GDC", keyId: "HL******39", pem: pem, expiresIn: const Duration(hours: 1));
var data = await weather.obtainWeatherData(jwt: jwtToken, language: "en", latitude: 44.96, longitude: -93.39, dataSets: DataSet.forecastDaily, timezone: 'America/Chicago');