格点每日天气预报
基于数值模式的天气预报数据,提供全球指定坐标的每日天气预报,分辨率3-5公里。
提示: 格点天气预报是基于数值预报模型生成,不适宜与观测站数据对比。如需基于观测站的城市天气,请使用城市每日天气API。格点天气采用UTC 0时区表示时间。
请求路径#
GET /v7/grid-weather/{days}参数#
路径参数
-
days(必选) 预报天数,可选3d或7d。
查询参数
-
location(必选) 需要查询地区的以英文逗号分隔的经度,纬度坐标(十进制,最多支持小数点后两位)。例如location=116.41,39.92 -
lang多语言设置,请阅读多语言文档,了解我们的多语言是如何工作、如何设置以及数据是否支持多语言。 -
unit数据单位,可选m(公制,默认)或i(英制)。
请求示例#
curl -X GET --compressed \
-H 'Authorization: Bearer your_token' \
'https://your-api-host/v7/grid-weather/3d?location=116.41%2C39.92&lang=zh&unit=m'
请将your_token替换为你的JWT身份认证,将your_api_host替换为你的API Host
返回数据#
{
"code": "200",
"updateTime": "2021-12-16T18:30+08:00",
"fxLink": "https://www.qweather.com",
"daily": [
{
"fxDate": "2021-12-16",
"tempMax": "2",
"tempMin": "-7",
"iconDay": "104",
"iconNight": "154",
"textDay": "阴",
"textNight": "阴",
"wind360Day": "344",
"windDirDay": "西北风",
"windScaleDay": "4-5",
"windSpeedDay": "9",
"wind360Night": "304",
"windDirNight": "西北风",
"windScaleNight": "4-5",
"windSpeedNight": "6",
"humidity": "36",
"precip": "0.0",
"pressure": "1026"
},
{
"fxDate": "2021-12-17",
"tempMax": "-1",
"tempMin": "-8",
"iconDay": "104",
"iconNight": "154",
"textDay": "阴",
"textNight": "阴",
"wind360Day": "28",
"windDirDay": "东北风",
"windScaleDay": "5-6",
"windSpeedDay": "15",
"wind360Night": "55",
"windDirNight": "东北风",
"windScaleNight": "4-5",
"windSpeedNight": "7",
"humidity": "44",
"precip": "0.0",
"pressure": "1028"
},
{
"fxDate": "2021-12-18",
"tempMax": "4",
"tempMin": "-8",
"iconDay": "100",
"iconNight": "150",
"textDay": "晴",
"textNight": "晴",
"wind360Day": "10",
"windDirDay": "北风",
"windScaleDay": "5-6",
"windSpeedDay": "17",
"wind360Night": "48",
"windDirNight": "东北风",
"windScaleNight": "3-4",
"windSpeedNight": "5",
"humidity": "61",
"precip": "0.0",
"pressure": "1016"
}
],
"refer": {
"sources": [
"https://developer.qweather.com/attribution.html"
],
"license": [
"QWeather Developers License"
]
}
}
-
fxLinkuri 当前数据的响应式页面,便于嵌入网站或应用 -
dailyarray 每日预报数据列表-
fxDatestring 预报日期 -
tempMaxstring 最高温度 -
tempMinstring 最低温度 -
textDaystring 白天天气状况文字描述,包括阴晴雨雪等天气状态的描述 -
textNightstring 晚间天气状况文字描述,包括阴晴雨雪等天气状态的描述 -
humiditystring 相对湿度,百分比数值 -
precipstring 预报当天总降水量,默认单位:毫米 -
pressurestring 站点气压,默认单位:百帕
-
-
referobject 数据来源和许可信息-
sourcesarray 原始数据来源,或数据源说明,可能为空 -
licensearray 数据许可或版权声明,可能为空
-