OpenClaw01-Skill-天气

OpenClaw01-Skill-天气

尝试使用OpenClaw,进行过程记录


1-知识总结

核心要求:使用SKILL.md说明查询天气的技能说明,不进行复杂的说明,可以提供参考的文档说明


2-openClaw如何实现天气查询

使用SKILL.md进行技能说明

- 打印SKILL.md

~/.nvm/versions/node/v22.22.0/lib/node_modules/openclaw/skills/weather/SKILL.md


3-weather/SKILL.md


name: weather

description: Get current weather and forecasts (no API key required).
homepage: https://wttr.in/:help
metadata: { "openclaw": { "emoji": "🌤️", "requires": { "bins": ["curl"] } } }

Weather

Two free services, no API keys needed.

wttr.in (primary)

Quick one-liner:

bash 复制代码
curl -s "wttr.in/London?format=3"
# Output: London: ⛅️ +8°C

Compact format:

bash 复制代码
curl -s "wttr.in/London?format=%l:+%c+%t+%h+%w"
# Output: London: ⛅️ +8°C 71% ↙5km/h

Full forecast:

bash 复制代码
curl -s "wttr.in/London?T"

Format codes: %c condition · %t temp · %h humidity · %w wind · %l location · %m moon

Tips:

  • URL-encode spaces: wttr.in/New+York
  • Airport codes: wttr.in/JFK
  • Units: ?m (metric) ?u (USCS)
  • Today only: ?1 · Current only: ?0
  • PNG: curl -s "wttr.in/Berlin.png" -o /tmp/weather.png

Open-Meteo (fallback, JSON)

Free, no key, good for programmatic use:

bash 复制代码
curl -s "https://api.open-meteo.com/v1/forecast?latitude=51.5&longitude=-0.12&current_weather=true"

Find coordinates for a city, then query. Returns JSON with temp, windspeed, weathercode.

Docs: https://open-meteo.com/en/docs


相关推荐
AC赳赳老秦13 小时前
全链路自动化巡检:用 OpenClaw 实现服务器 - 应用 - 数据库全链路巡检,自动生成报告与整改建议
服务器·数据库·人工智能·深度学习·自动化·deepseek·openclaw
yuezhilangniao14 小时前
中国区- OpenClaw + 飞书 + DeepSeek (千问备用) 部署全流程 (含踩坑实录)-中国区命令行篇
飞书·openclaw
a752066281 天前
OpenClaw 连接阿里云百炼完整图文实操教程
人工智能·阿里云·云计算·ai办公·openclaw·小龙虾·小龙虾一键部署
一个处女座的程序猿2 天前
MultiAgent之OpenClaw:QuantClaw的简介、安装和使用方法、案例应用之详细攻略
llm·openclaw·quantclaw
LeeeX!2 天前
OpenClaw CLI 完整实操笔记
笔记·openclaw
AC赳赳老秦2 天前
数据安全合规:OpenClaw 敏感信息脱敏、操作日志审计、权限精细化管控方案,符合等保要求
网络·数据库·python·安全·web安全·oracle·openclaw
无心水2 天前
【Hermes:实战场景】35、内容创作实战:系列文章、风格固化、子 Agent 并行调研
人工智能·openclaw·养龙虾·hermes·honcho
无心水2 天前
【Hermes:MCP 与工具实战】31、多 Agent 编排:delegate_task 并行机制与安全设计 —— 让智能体组团作战,效率翻倍
人工智能·ai·mcp协议·openclaw·养龙虾·hermes·honcho
AC赳赳老秦2 天前
故障自愈实战:用 OpenClaw 实现服务器日志自动化分析、根因定位、解决方案自动生成
大数据·运维·服务器·自动化·github·deepseek·openclaw
AC赳赳老秦2 天前
可视化方案提效:用 OpenClaw 对接 XMind/ProcessOn,自动生成流程图、架构图、工作脑图
人工智能·深度学习·caffe·xmind·processon·deepseek·openclaw