mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-19 06:43:17 +08:00
feat: 路径约定体系 & 自优化管道落地
This commit is contained in:
parent
08df5d580a
commit
df30b5902f
37 changed files with 239 additions and 324 deletions
|
|
@ -2,7 +2,7 @@
|
|||
name: weather
|
||||
description: Get current weather and forecasts (no API key required).
|
||||
homepage: https://wttr.in/:help
|
||||
metadata: {"clawdbot":{"emoji":"🌤️","requires":{"bins":["curl"]}}}
|
||||
metadata: {"clawdbot":{"emoji":"🌤️"}}
|
||||
---
|
||||
|
||||
# Weather
|
||||
|
|
@ -17,6 +17,11 @@ curl -s "wttr.in/London?format=3"
|
|||
# Output: London: ⛅️ +8°C
|
||||
```
|
||||
|
||||
Tool fallback (no curl required):
|
||||
```text
|
||||
web_fetch_clean url="https://wttr.in/London?format=3"
|
||||
```
|
||||
|
||||
Compact format:
|
||||
```bash
|
||||
curl -s "wttr.in/London?format=%l:+%c+%t+%h+%w"
|
||||
|
|
@ -36,6 +41,7 @@ Tips:
|
|||
- Units: `?m` (metric) `?u` (USCS)
|
||||
- Today only: `?1` · Current only: `?0`
|
||||
- PNG: `curl -s "wttr.in/Berlin.png" -o /tmp/weather.png`
|
||||
- If `curl` is unavailable, prefer `web_fetch_clean` for text responses
|
||||
|
||||
## Open-Meteo (fallback, JSON)
|
||||
|
||||
|
|
@ -44,6 +50,11 @@ Free, no key, good for programmatic use:
|
|||
curl -s "https://api.open-meteo.com/v1/forecast?latitude=51.5&longitude=-0.12¤t_weather=true"
|
||||
```
|
||||
|
||||
Tool fallback:
|
||||
```text
|
||||
web_fetch_clean url="https://api.open-meteo.com/v1/forecast?latitude=51.5&longitude=-0.12¤t_weather=true"
|
||||
```
|
||||
|
||||
Find coordinates for a city, then query. Returns JSON with temp, windspeed, weathercode.
|
||||
|
||||
Docs: https://open-meteo.com/en/docs
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue