weather_kit 0.0.3 copy "weather_kit: ^0.0.3" to clipboard
weather_kit: ^0.0.3 copied to clipboard

outdated

A dart library for interfacing with the Apple WeatherKit API.

Weather Kit #

Usage #

To use this plugin, add weather_kit as a dependency in your pubspec.yaml file.

Examples #

Here are small examples that show you how to use the API.

Generate JWT

final weatherKit = WeatherKit();
final token = weatherKit.generateJWT(
  bundleId: 'com.example',
  teamId: 'team id',
  keyId: 'key id',
  pem: 'example.p8',
  expiresIn: const Duration(hours: 1),
);

Obtain current weather

final result = await weatherKit.obtainWeatherData(
  jwt: token,
  language: 'ja',
  latitude: '35.71',
  longitude: '139.811',
  dataSets: 'currentWeather',
);
15
likes
0
pub points
57%
popularity

Publisher

verified publishermafreud.dev

A dart library for interfacing with the Apple WeatherKit API.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

dart_jsonwebtoken, flutter, http

More

Packages that depend on weather_kit