入门
在 Duaer 里查香港天气
在 Duaer 里:香港天文台:香港各区当前气温与天气警告,或未来 9 天预报。一次成功查询用 1 额度。
能拿到什么
Duaer 数据市场里的「香港天气」:香港天文台:香港各区当前气温与天气警告,或未来 9 天预报。查到结果时用 1 额度,结果交给数字组织的下一个节点。
从节点创建器选 Duaer 数据 → 香港天气,或打开 数据市场。相关:天气预报、海浪预报。
适合做什么
- 展示香港当前气温与天气警告。
- 用 9 天预报安排户外活动。
在画布里检索
- 打开节点创建器,选 Duaer 数据 → Hong Kong weather。
- 填 View(current 或 forecast);Language(zh-Hans 或 zh-Hant)可选。
- Limit 默认 10,最大 20。执行。
查到结果才扣 1 额度;没有结果、输入有误或上游失败都不扣。
用 API 调用
- GET https://api.duaer.com/v1/data/hk-weather?view=current
- Authorization: Bearer <Duaer key>
下方是与数据市场「复制技能」相同的英文技能,含参数、示例与返回字段。
调用技能(英文)
与数据市场「复制技能」一致。
---
name: duaer-hk-weather
description: >-
Duaer Hong Kong weather. Hong Kong Observatory: current temperatures and warnings across Hong Kong, or the 9-day forecast.
One successful search uses 1 Duaer credit.
---
# Duaer Hong Kong weather
Duaer Hong Kong weather reads Hong Kong Observatory open data in English, Simplified Chinese, or Traditional Chinese.
## When to use
- Show current Hong Kong temperatures and warnings.
- Plan an outdoor event with the 9-day forecast.
## When not to use
- Weather anywhere else. Use https://skills.duaer.com/weather.md.
- Past weather. Use https://skills.duaer.com/weather-history.md.
## Call
`GET https://api.duaer.com/v1/data/hk-weather?view=current`
Header: `Authorization: Bearer <Duaer key>`
Use an account key or a model API key.
Get a Duaer key: https://skills.duaer.com/keys.md
## Parameters
Provide `view`.
- `view` — `current` or `forecast`. Default current.
- `language` — Optional. `en`, `zh-Hans`, or `zh-Hant`. Default en.
- `limit` — Optional. Rows to return, from 1 to 20. Default 10.
## Examples
- `GET https://api.duaer.com/v1/data/hk-weather?view=current` — temperatures now, the Observatory first.
- `GET https://api.duaer.com/v1/data/hk-weather?view=forecast&language=zh-Hans` — the 9-day forecast in Simplified Chinese.
## Result
The response is `{ "items": [...] }`. Each item has `source`, `title`, `url`, and `summary`, plus:
- `place`, `temperatureC`, `updated` — station, temperature, and observation time.
- `humidityPct`, `uvIndex`, `warnings` — on the Observatory row.
- `date`, `weekday`, `minTempC`, `maxTempC`, `weather`, `wind`, `rainChance` — on forecast rows.
- `outlook` — the general situation, on the first forecast row.
Fields without a value are left out.
## Credits
A search that returns at least one row uses 1 credit.
An empty search, a search that finds nothing, or a failed search uses 0.
Wrong input returns 400 with a message and uses 0.
No remaining credits returns 402 and does not search.
A missing key returns 401.
## Related
- https://skills.duaer.com/weather.md — Duaer Weather forecast
- https://skills.duaer.com/marine.md — Duaer Marine forecast
常见问题
Duaer 的香港天气检索扣多少额度?
查到结果时扣 1 额度;没有结果或出错不扣。
Duaer 香港天气支持中文吗?
支持。language 填 zh-Hans 为简体中文,zh-Hant 为繁体中文。
同组