Skip to content

feat: add Yandex Weather provider - #22

Merged
sameerasw merged 3 commits into
sameerasw:developfrom
Hikk0o:pr/yandex-weather
Oct 13, 2026
Merged

sameerasw merged 3 commits into
sameerasw:developfrom
Hikk0o:pr/yandex-weather

Conversation

@Hikk0o

@Hikk0o Hikk0o commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Description

Adds Yandex Weather as a forecast source (API v3, GraphQL). The user enters their own free key from https://yandex.ru/pogoda/b2b/console/smarthome.

  • YandexWeatherProvider requests temperature, feels-like, wind, gusts and direction, condition, UV, rain chance and sunrise/sunset, for today and tomorrow.
  • ProviderHttp.post() added for the GraphQL body.
  • humidity and chanceOfRain are now nullable because the free tier returns no humidity; the detail sheet and island hide missing values.
  • Requests stay under 30 a day (50 min between requests, 60 min minimum scheduled refresh).
  • The Yandex attribution text is shown where the provider name appears.

P.s.: For the most part, I created this PR using AI, so please don’t be too strict.

Type of change

  • New feature

UI changes

Provider line shows "Данные предоставлены сервисом Яндекс Погода" for Yandex; humidity and rain chance rows are hidden when missing. No screenshots attached.

Checklist

  • The base branch is set to develop (not main).
  • The app builds cleanly locally with ./gradlew assembleGithubDebug.
  • Unit tests pass (only the template ExampleUnitTest exists).
  • Strings are added to res/values/strings.xml.

Add Yandex Weather (API v3, GraphQL) as a forecast source. It needs the
user's own free key, issued for personal, non-commercial use.

- ProviderHttp gains post() for the GraphQL request body.
- Humidity and rain chance become nullable, and the UI hides them when
  a provider does not return them.
- The provider keeps to the 30 requests a day limit: 50 minutes between
  requests, and at least 60 minutes between scheduled refreshes.
- Show the attribution text required by the Yandex terms.
@Hikk0o
Hikk0o marked this pull request as ready for review October 12, 2026 21:36
@Hikk0o
Hikk0o requested a review from sameerasw as a code owner October 12, 2026 21:36
@sameerasw
sameerasw changed the base branch from main to develop October 13, 2026 09:09
@sameerasw sameerasw added the enhancement New feature or request label Oct 13, 2026

@sameerasw sameerasw left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contributions <3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants