技能 效率工具 获取实时天气和预报

获取实时天气和预报

v20260803
weather
本技能通过查询wttr.in等公共天气API,获取指定地点的实时天气状况和未来多日预报。它可以提供多种格式的输出,包括文本摘要、详细JSON数据和图片。适用于用户日常询问某一地点的天气、气温或预报需求,无需API密钥。
获取技能
297 次下载
概览

Weather Skill

Get current weather conditions and forecasts.

Meta-Skill Entrypoint

Meta-skills can run this skill as skill_exec for a bounded JSON forecast without spawning an LLM sub-agent. The entrypoint extracts DESTINATION: from planner contracts, queries wttr.in, and returns compact current, forecast, seasonal_hint, and errors fields. Network failures are reported in errors while preserving a usable seasonal hint.

Location

Always include a city, region, or airport code in weather queries.

Commands

Current Weather

# One-line summary
curl "https://wttr.in/London?format=3"

# Detailed current conditions
curl "https://wttr.in/London?0"

# Specific city
curl "https://wttr.in/New+York?format=3"

Forecasts

# 3-day forecast
curl "https://wttr.in/London"

# Week forecast
curl "https://wttr.in/London?format=v2"

# Specific day (0=today, 1=tomorrow, 2=day after)
curl "https://wttr.in/London?1"

Format Options

# One-liner
curl "https://wttr.in/London?format=%l:+%c+%t+%w"

# JSON output
curl "https://wttr.in/London?format=j1"

# PNG image
curl "https://wttr.in/London.png"

Format Codes

  • %c — Weather condition emoji
  • %t — Temperature
  • %f — "Feels like"
  • %w — Wind
  • %h — Humidity
  • %p — Precipitation
  • %l — Location

Quick Responses

"What's the weather?"

curl -s "https://wttr.in/London?format=%l:+%c+%t+(feels+like+%f),+%w+wind,+%h+humidity"

"Will it rain?"

curl -s "https://wttr.in/London?format=%l:+%c+%p"

"Weekend forecast"

curl "https://wttr.in/London?format=v2"

Notes

  • No API key needed (uses wttr.in)
  • Rate limited; don't spam requests
  • Works for most global cities
  • Supports airport codes: curl https://wttr.in/ORD
信息
Category 效率工具
Name weather
版本 v20260803
大小 3.66KB
更新时间 2026-08-04
语言