鏈接數據
GET https://ja-t.net/api/statistics/{link_id}
參數 | 詳情 | 描述 |
---|---|---|
start_date | 必須 | Y-m-d 格式的開始日期 |
end_date | 必須 | Y-m-d 格式的結束日期 |
type | 可選 | 要返回的數據類型。 允許的值為:overview 、referrer_host 、referrer_path 、country_code 、city_name 、< code>os_name、browser_name 、device_type 、browser_language 、utm_source 、utm_medium ,utm_campaign 。 默認為 overview |
country_code | 可選 | 參數僅適用於 city_name 類型 |
utm_source | 可選 | 參數僅適用於 utm_medium 和 utm_campaign 類型 |
utm_medium | 可選 | 參數僅適用於 utm_campaign 類型 |
curl --request GET \
--url 'https://ja-t.net/api/statistics/{link_id}?start_date=2020-01-01&end_date=2021-01-01' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://ja-t.net/api/statistics/{link_id}?start_date=2020-01-01&end_date=2021-01-01' \
--header 'Authorization: Bearer {api_key}' \
{
"data": [
{
"pageviews": 20,
"visitors": 5,
"formatted_date": "2021-01"
},
{
"pageviews": 35,
"visitors": 10,
"formatted_date": "2021-02"
},
{
"pageviews": 50,
"visitors": 25,
"formatted_date": "2021-03"
}
]
}