天气预报
获取天气预报

接口地址: https://api.52hyjs.com/api/qweather

返回格式: json

请求方式: get/post

请求示例: https://api.52hyjs.com/api/qweather?d=天数&location=位置&key=天气key

请求参数说明:

名称 必填 类型 说明
d string 天数
location string 位置
key string 天气key

返回参数说明:

名称 类型 说明

返回示例:

{
	"code": "200",
	"updateTime": "2023-12-11T18:00+08:00",
	"fxLink": "https://www.qweather.com",
	"daily": [{
		"fxDate": "2023-12-11",
		"tempMax": "4",
		"tempMin": "-1",
		"iconDay": "102",
		"iconNight": "152",
		"textDay": "少云",
		"textNight": "少云",
		"wind360Day": "10",
		"windDirDay": "北风",
		"windScaleDay": "3",
		"windSpeedDay": "17",
		"wind360Night": "7",
		"windDirNight": "北风",
		"windScaleNight": "2",
		"windSpeedNight": "8",
		"humidity": "77",
		"precip": "1.76",
		"pressure": "1015",
		"cloud": "52"
	}, {
		"fxDate": "2023-12-12",
		"tempMax": "4",
		"tempMin": "-1",
		"iconDay": "100",
		"iconNight": "152",
		"textDay": "晴",
		"textNight": "少云",
		"wind360Day": "32",
		"windDirDay": "东北偏北风",
		"windScaleDay": "1",
		"windSpeedDay": "4",
		"wind360Night": "57",
		"windDirNight": "东北偏东风",
		"windScaleNight": "1",
		"windSpeedNight": "3",
		"humidity": "85",
		"precip": "0.03",
		"pressure": "1017",
		"cloud": "17"
	}, {
		"fxDate": "2023-12-13",
		"tempMax": "4",
		"tempMin": "1",
		"iconDay": "100",
		"iconNight": "305",
		"textDay": "晴",
		"textNight": "小雨",
		"wind360Day": "41",
		"windDirDay": "东北风",
		"windScaleDay": "2",
		"windSpeedDay": "11",
		"wind360Night": "26",
		"windDirNight": "东北偏北风",
		"windScaleNight": "3",
		"windSpeedNight": "13",
		"humidity": "90",
		"precip": "5.00",
		"pressure": "1014",
		"cloud": "81"
	}],
	"refer": {
		"sources": ["QWeather"],
		"license": ["CC BY-SA 4.0"]
	}
}

错误码格式说明:

名称 类型 说明

代码示例:

暂无演示代码,正在拼命添加中...