GET https://api.kertennet.com/weather/sunriseSunset
用于根据指定的经纬度和时区,获取对应地点的日出和日落时间。
GET
| 参数名 | 类型 | 是否必填 | 说明 |
|---|---|---|---|
lat | float | 是 | 纬度,例如:24.35325 |
lng | float | 是 | 经度,例如:116.6966 |
timezone | string | 是 | 时区,示例:UTC、Asia/Shanghai 等 |
{
"code": 200,
"data": {
"sunrise": "日出时间",
"sunset": "日落时间"
}
}| 字段名 | 类型 | 说明 |
|---|---|---|
code | int | 状态码,200表示请求成功 |
data | object | 包含日出与日落时间的数据对象 |
sunrise | string | 日出时间,格式为 HH:mm 或 ISO 时间格式 |
sunset | string | 日落时间,格式为 HH:mm 或 ISO 时间格式 |
GET https://api.kertennet.com/weather/sunriseSunset?lat=24.35325&lng=116.6966&timezone=UTC
请确保提供的经纬度是合法有效的浮点数。
时区需使用标准时区格式,例如 UTC、Asia/Shanghai 等。
返回时间格式可能依赖于所提供的 timezone。
上一篇:音频剪辑API
上一篇:音频剪辑API
扫一扫,关注我们