潮汐

平台: API iOS Android

未来10天全球潮汐数据,包括满潮、干潮高度和时间,逐小时潮汐数据。

请求URL

https://api.qweather.com/v7/ocean/tide

请求参数

请求参数包括必选和可选参数,参数之间使用&进行分隔。

  • location(必选)需要查询的潮汐站点,请填写潮汐站点的LocationID,LocationID可通过POI搜索服务获取。例如 location=P2951
  • date(必选)选择日期,最多可选择未来10天(包含今天)的数据。日期格式为yyyyMMdd,例如 date=20200531

请求示例

curl -X GET --compressed \
-H 'Authorization: Bearer your_token' \
'https://api.qweather.com/v7/ocean/tide?location=P2951&date=20210206'

请将your_token替换为你的JWT或了解身份认证

返回数据

返回数据是JSON格式并进行了Gzip压缩

{
  "code": "200",
  "updateTime": "2021-02-04T05:02+08:00",
  "fxLink": "https://www.qweather.com",
  "tideTable": [
    {
      "fxTime": "2021-02-06T03:48+08:00",
      "height": "2.17",
      "type": "H"
    },
    {
      "fxTime": "2021-02-06T10:12+08:00",
      "height": "0.21",
      "type": "L"
    },
    {
      "fxTime": "2021-02-06T16:53+08:00",
      "height": "2.47",
      "type": "H"
    },
    {
      "fxTime": "2021-02-06T23:22+08:00",
      "height": "0.73",
      "type": "L"
    }
  ],
  "tideHourly": [
    {
      "fxTime": "2021-02-06T00:00+08:00",
      "height": "1.02"
    },
    {
      "fxTime": "2021-02-06T01:00+08:00",
      "height": "1.42"
    },
    {
      "fxTime": "2021-02-06T02:00+08:00",
      "height": "1.82"
    },
    {
      "fxTime": "2021-02-06T03:00+08:00",
      "height": "2.10"
    },
    {
      "fxTime": "2021-02-06T04:00+08:00",
      "height": "2.16"
    },
    {
      "fxTime": "2021-02-06T05:00+08:00",
      "height": "2.01"
    },
    {
      "fxTime": "2021-02-06T06:00+08:00",
      "height": "1.68"
    },
    {
      "fxTime": "2021-02-06T07:00+08:00",
      "height": "1.23"
    },
    {
      "fxTime": "2021-02-06T08:00+08:00",
      "height": "0.77"
    },
    {
      "fxTime": "2021-02-06T09:00+08:00",
      "height": "0.39"
    },
    {
      "fxTime": "2021-02-06T10:00+08:00",
      "height": "0.21"
    },
    {
      "fxTime": "2021-02-06T11:00+08:00",
      "height": "0.29"
    },
    {
      "fxTime": "2021-02-06T12:00+08:00",
      "height": "0.60"
    },
    {
      "fxTime": "2021-02-06T13:00+08:00",
      "height": "1.07"
    },
    {
      "fxTime": "2021-02-06T14:00+08:00",
      "height": "1.60"
    },
    {
      "fxTime": "2021-02-06T15:00+08:00",
      "height": "2.07"
    },
    {
      "fxTime": "2021-02-06T16:00+08:00",
      "height": "2.38"
    },
    {
      "fxTime": "2021-02-06T17:00+08:00",
      "height": "2.47"
    },
    {
      "fxTime": "2021-02-06T18:00+08:00",
      "height": "2.34"
    },
    {
      "fxTime": "2021-02-06T19:00+08:00",
      "height": "2.05"
    },
    {
      "fxTime": "2021-02-06T20:00+08:00",
      "height": "1.66"
    },
    {
      "fxTime": "2021-02-06T21:00+08:00",
      "height": "1.25"
    },
    {
      "fxTime": "2021-02-06T22:00+08:00",
      "height": "0.91"
    },
    {
      "fxTime": "2021-02-06T23:00+08:00",
      "height": "0.74"
    }
  ],
  "refer": {
    "sources": [
      "qweather.com"
    ],
    "license": [
      "QWeather Developers License"
    ]
  }
}
  • code 请参考状态码
  • updateTime 当前API的最近更新时间
  • fxLink 当前数据的响应式页面,便于嵌入网站或应用
  • tideTable.fxTime 满潮或干潮时间
  • tideTable.height 海水高度,单位:米
  • tideTable.type 满潮(H)或干潮(L)
  • tideHourly.fxTime 逐小时预报时间
  • tideHourly.height 海水高度,单位:米。对于一些地点,此数据可能为空
  • refer.sources 原始数据来源,或数据源说明,可能为空
  • refer.license 数据许可或版权声明,可能为空