Skip to content

eugeneslin/weatherclaw

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Weatherclaw

Weatherclaw is an OpenClaw plugin that exposes first-class weather report tools backed by wttr.in. It is intentionally small: no API key, no secrets, and no provider account setup.

This is useful as both:

  • a practical weather integration for locked-down OpenClaw agents; and
  • a reference plugin showing OpenClaw tool registration, package metadata, agent tool allowlisting, and runtime verification.

Why a plugin instead of a weather skill?

OpenClaw already has weather-oriented skills and public skill examples that tell agents how to call wttr.in with shell tools such as curl. Weatherclaw is different: it registers typed OpenClaw tools, so sandboxed/minimal agents can retrieve weather without broad exec access.

Benefits:

  • first-class weather_current and weather_forecast tools
  • typed parameters and structured output
  • least-privilege allowlisting by tool name
  • no shell/curl requirement for the agent
  • no need to grant broad exec, shell, or curl access to sandboxed agents

Tools

  • weather_current — concise current weather report from wttr.in.
  • weather_forecast — text forecast report from wttr.in, 1-3 days.

Both tools accept either:

  • location: place name, airport code, or address, such as Seattle, WA; or
  • latitude and longitude: numeric coordinates.

Optional parameters:

  • units: metric or imperial (metric by default)
  • days: forecast length for weather_forecast, clamped to 1-3 (3 by default; wttr.in text reports support up to 3 days)

The tools return a structured payload containing:

  • summary: first useful line of the wttr.in report, suitable for quick agent replies
  • report: raw wttr.in text report
  • location, units, source, and url

Requirements

  • OpenClaw 2026.4.24 or newer
  • Node.js compatible with the installed OpenClaw runtime
  • Outbound HTTPS access to https://wttr.in

No API keys, secrets, or local config are required.

Development

npm install
npm run verify

npm run verify cleans the repo, builds TypeScript, and runs the Node test suite.

To verify the package contents before sharing or publishing:

npm run verify:package

Install from a local checkout

From this repository:

npm install
npm run build
openclaw plugins install . --force
openclaw plugins enable weather
openclaw plugins inspect weather --json

If your OpenClaw config uses an explicit plugins.allow list, make sure it includes weather; otherwise OpenClaw will discover the plugin but block activation.

Then confirm OpenClaw can see the plugin:

openclaw plugins list --verbose
openclaw plugins doctor

If your gateway is already running, restart or reload it if plugin changes are not visible:

openclaw gateway restart

Using with sandboxed agents

Weatherclaw is designed to work well with agents that have OpenClaw sandboxing enabled. Install and enable the plugin normally, then allow the weather tools for the agent that should use them:

openclaw plugins enable weather

If your OpenClaw config uses explicit tool allowlists, include these tools for the target agent:

  • weather_current
  • weather_forecast

The agent does not need exec, shell, or curl permissions to retrieve weather reports through this plugin.

Install from a packaged archive

Build and pack the plugin:

npm install
npm run verify
npm pack

Install the generated archive from another checkout or OpenClaw host:

openclaw plugins install ./weatherclaw-0.1.0.tgz --force
openclaw plugins enable weather
openclaw plugins inspect weather --json

Runtime smoke test

After installing, ask an agent with access to the plugin tools one of:

  • "Use weather_current to get the weather for Seattle, WA."
  • "Use weather_forecast for San Francisco for 2 days in imperial units."

Expected behavior: the tool returns a payload from wttr.in with summary, report, source: "wttr.in", and a https://wttr.in/... URL.

Example prompts

  • "What's the weather in Seattle right now?"
  • "Will it rain in San Francisco this weekend?"
  • "Give me a 2-day forecast for 37.7749,-122.4194 in imperial units."

Troubleshooting

  • Plugin not listed: run openclaw plugins inspect weather --json and openclaw plugins doctor; rebuild with npm run build, reinstall with --force, then restart the gateway if needed.
  • Tools not visible to a sandboxed agent: confirm the plugin is enabled and the target agent's tool allowlist includes weather_current and weather_forecast.
  • Network/DNS errors: the sandbox must allow outbound HTTPS to https://wttr.in.
  • Rate limits: wttr.in may return HTTP 429. Retry later or reduce repeated weather checks.
  • Empty report: retry with a more specific location or coordinates.

Privacy and network access

The plugin sends requested location names or coordinates to wttr.in. No API keys or credentials are used.

Support and status

Weatherclaw is maintained in this repository and is not bundled with OpenClaw.

License

MIT. See LICENSE.

About

OpenClaw plugin that safely gives sandboxed agents weather reports without shell access.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors