fix(skills): weather skill uses keyless wttr.in instead of key-gated APIs#351
Closed
initializ-mk wants to merge 1 commit into
Closed
fix(skills): weather skill uses keyless wttr.in instead of key-gated APIs#351initializ-mk wants to merge 1 commit into
initializ-mk wants to merge 1 commit into
Conversation
…APIs (#349) The bundled weather skill allowed egress only to api.openweathermap.org and api.weatherapi.com — both require an API key — yet declared no key env at all, so it was dead on arrival. Its tool bodies were also prose only, with no runnable command. Repoint it at wttr.in (free, keyless, accepts a city name directly so it maps 1:1 to the location input) and ship two runnable scripts: - scripts/weather-current.sh '{"location":"Tokyo"}' - scripts/weather-forecast.sh '{"location":"Tokyo","days":3}' Both use curl + jq, need no API key, validate input, check the HTTP status, and emit shaped JSON. egress_domains is now [wttr.in]. Kept in sync: the egress-wizard domain hints (egress_step.go), the scanner test fixture, and the weather example in .claude/skills/forge.md. Verified live against wttr.in (current + forecast); scripts are shellcheck-clean; forge-skills and forge-cli/internal/tui suites green.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #349.
Problem
The bundled
weatherembedded skill could never work as shipped: itsegress_domainsallowed onlyapi.openweathermap.org+api.weatherapi.com(both key-gated), yet it declared no API-key env at all — so the two hosts the egress gate permitted were exactly the two that reject an unauthenticated request. Its tool sections were also prose-only, with no runnable command.Fix
Repoint the skill at wttr.in — free, keyless, and it takes a city name directly, so it maps 1:1 to the existing
location (string)input with no geocoding step (the issue’s recommended option; also already the endpoint our own Skill Builder UI suggests atapp.js:2902).egress_domains: [wttr.in];env.required: []stays empty because none is needed; addedjqtobins.tavily-searchconvention — JSON arg in, shaped JSON out):scripts/weather-current.sh ${apos}{"location":"Tokyo"}${apos}scripts/weather-forecast.sh ${apos}{"location":"Tokyo","days":3}${apos}jq. No API key, no env.SKILL.mdtool sections with runnablecurl/script bodies and an accurate output schema (forecast documented as capped at 3 days, wttr.in’s free limit).Kept in sync (issue blast-radius)
forge-cli/internal/tui/steps/egress_step.gowttr.in: "weather skill"forge-skills/local/scanner_test.gowttr.in.claude/skills/forge.mdbins: [curl, jq],required: [],egress_domains: [wttr.in])Verification
shellcheck-clean;bash -nclean; committed100755.gofmt+golangci-lintclean on the touched packages;forge-skills/...andforge-cli/internal/tui/...suites green.Note
This unblocks the
forge tryhero interaction in #350 (Phase 1 requires a keyless weather demo). #350’s transcript illustrates Open-Meteo; wttr.in is the simpler drop-in for a city-name skill. If a structured multi-day (7-day) forecast is later wanted, Open-Meteo + its geocoding host is the documented alternative in #349.