{"id":27121062,"url":"https://github.com/brycejohnston/ex_weatherkit","last_synced_at":"2026-07-08T14:31:10.976Z","repository":{"id":151939702,"uuid":"624624520","full_name":"brycejohnston/ex_weatherkit","owner":"brycejohnston","description":"An Apple WeatherKit REST API client for Elixir","archived":false,"fork":false,"pushed_at":"2023-09-17T13:50:07.000Z","size":12,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-04-13T22:00:12.042Z","etag":null,"topics":["weather","weatherkit","weatherkit-rest-api"],"latest_commit_sha":null,"homepage":"","language":"Elixir","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/brycejohnston.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-04-06T22:18:39.000Z","updated_at":"2024-06-05T17:40:26.856Z","dependencies_parsed_at":"2023-09-23T01:22:51.768Z","dependency_job_id":null,"html_url":"https://github.com/brycejohnston/ex_weatherkit","commit_stats":{"total_commits":6,"total_committers":2,"mean_commits":3.0,"dds":"0.33333333333333337","last_synced_commit":"8ebce41bf80cc05b3cea78c81ed70bf1f7a6479d"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brycejohnston%2Fex_weatherkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brycejohnston%2Fex_weatherkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brycejohnston%2Fex_weatherkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brycejohnston%2Fex_weatherkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brycejohnston","download_url":"https://codeload.github.com/brycejohnston/ex_weatherkit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247640557,"owners_count":20971555,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["weather","weatherkit","weatherkit-rest-api"],"created_at":"2025-04-07T10:51:31.746Z","updated_at":"2026-07-08T14:31:10.964Z","avatar_url":"https://github.com/brycejohnston.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ExWeatherkit\n\n[![hex.pm](https://img.shields.io/hexpm/v/ex_weatherkit.svg)](https://hex.pm/packages/ex_weatherkit)\n[![Hex Docs](https://img.shields.io/badge/hex-docs-lightgreen.svg)](https://hexdocs.pm/ex_weatherkit/)\n[![hex.pm](https://img.shields.io/hexpm/dt/ex_weatherkit.svg)](https://hex.pm/packages/ex_weatherkit)\n[![hex.pm](https://img.shields.io/hexpm/l/ex_weatherkit.svg)](https://hex.pm/packages/ex_weatherkit)\n\nAn Apple WeatherKit REST API client for Elixir\n\n## Installation\n\nThe package can be installed by adding `ex_weatherkit` to your list of dependencies in `mix.exs`:\n\n```elixir\ndef deps do\n  [\n    {:ex_weatherkit, \"~\u003e 0.1.2\"}\n  ]\nend\n```\n\nYou will need an Apple Developer Program membership to [create a private key for WeatherKit access and a Service ID](https://developer.apple.com/documentation/weatherkitrestapi/request_authentication_for_weatherkit_rest_api) to access the WeatherKit REST API.\n\nOnce you have those along with your ADP membership Team ID, add the required values to your config file (preferable to load values from env variables)\n\n```elixir\nconfig :ex_weatherkit,\n  key_id: \"ABCDEF1234\"\n  service_id: \"com.example.weatherkitclient\"\n  team_id: \"ZYXWVU8765\"\n  private_key: \"\"\"-----BEGIN PRIVATE KEY-----....\"\"\"\n```\n\n## Usage\n\n### Current weather\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.current_weather(39.183608, -96.571669)\n\n{:ok,\n %{\n   \"currentWeather\" =\u003e %{\n     \"asOf\" =\u003e \"2023-09-17T13:28:23Z\",\n     \"cloudCover\" =\u003e 0.13,\n     \"cloudCoverHighAltPct\" =\u003e 0.0,\n     \"cloudCoverLowAltPct\" =\u003e 0.2,\n     \"cloudCoverMidAltPct\" =\u003e 0.0,\n     \"conditionCode\" =\u003e \"MostlyClear\",\n     \"daylight\" =\u003e true,\n     \"humidity\" =\u003e 0.83,\n     \"metadata\" =\u003e %{\n       \"attributionURL\" =\u003e \"https://developer.apple.com/weatherkit/data-source-attribution/\",\n       \"expireTime\" =\u003e \"2023-09-17T13:33:23Z\",\n       \"latitude\" =\u003e 39.184,\n       \"longitude\" =\u003e -96.572,\n       \"readTime\" =\u003e \"2023-09-17T13:28:23Z\",\n       \"reportedTime\" =\u003e \"2023-09-17T12:13:09Z\",\n       \"units\" =\u003e \"m\",\n       \"version\" =\u003e 1\n     },\n     \"name\" =\u003e \"CurrentWeather\",\n     \"precipitationIntensity\" =\u003e 0.0,\n     \"pressure\" =\u003e 1019.47,\n     \"pressureTrend\" =\u003e \"rising\",\n     \"temperature\" =\u003e 13.49,\n     \"temperatureApparent\" =\u003e 13.08,\n     \"temperatureDewPoint\" =\u003e 10.73,\n     \"uvIndex\" =\u003e 0,\n     \"visibility\" =\u003e 23615.8,\n     \"windDirection\" =\u003e 18,\n     \"windGust\" =\u003e 10.27,\n     \"windSpeed\" =\u003e 5.1\n   }\n }, 200}\n```\n\n### Daily forecast\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.forecast_daily(39.183608, -96.571669)\n```\n\n### Hourly forecast\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.forecast_hourly(39.183608, -96.571669)\n```\n\n### Next hour forecast\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.forecast_next_hour(39.183608, -96.571669)\n```\n\n### Weather alerts\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.weather_alerts(39.183608, -96.571669)\n```\n\n### Multiple weather datasets\n\n```elixir\n{:ok, weather, _status} = ExWeatherkit.weather_multi(39.183608, -96.571669, [\"currentWeather\", \"forecastDaily\"])\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrycejohnston%2Fex_weatherkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrycejohnston%2Fex_weatherkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrycejohnston%2Fex_weatherkit/lists"}