LinksGet link click analytics

Get link click analytics

Proxy to the Tinybird pubsub_link_click_analytics pipe for the authenticated location. Returns the raw Tinybird JSON envelope.

curl -X GET "https://mythic-analytics.gulp.workers.dev/client/v1/links/analytics?location_id=example_string&slug=example_string&date_from=example_string&date_to=example_string&limit=42&utm_source=example_string&utm_medium=example_string&utm_campaign=example_string&utm_term=example_string&utm_content=example_string" \
  -H "Content-Type: application/json" \
  -H "X-Location-Id: example_string" \
  -H "Authorization: Bearer YOUR_API_TOKEN"
{
  "meta": [
    {}
  ],
  "data": [
    {}
  ],
  "rows": 42,
  "statistics": {}
}
GET
/links/analytics
GET
Base URLstring

Target server for requests. Edit to use your own host.

Bearer Token
Bearer Tokenstring
Required

Client API key as a bearer token. Use an agency key (ak_..., read-write) or a location secret key (sk_..., read-only). Format: Bearer ak_... or Bearer sk_.... Scoped keys (mcp_) are accepted too and need links:read or links:write. See Using an mcp_ key over HTTP.

Client API key as a bearer token. Use an agency key (ak_..., read-write) or a location secret key (sk_..., read-only). Format: Bearer ak_... or Bearer sk_.... Scoped keys (mcp_) are accepted too and need links:read or links:write. See Using an mcp_ key over HTTP.
query
location_idstring

Target location (client) id. Required when authenticating with an agency key (ak_); alternative to the X-Location-Id header. Ignored for secret keys, which resolve their own location.

query
slugstring

Restrict results to a single link slug.

query
date_fromstring

Start of the date range (forwarded to Tinybird).

query
date_tostring

End of the date range (forwarded to Tinybird).

query
limitinteger

Maximum rows to return (forwarded to Tinybird).

query
utm_sourcestring

Filter by utm_source. An empty string matches clicks with no value for that UTM.

header
X-Location-Idstring

Target location (client) id. Required when authenticating with an agency key (ak_); alternative to the location_id query parameter. Ignored for secret keys.

Request Preview
Response

Response will appear here after sending the request

Authentication

header
Authorizationstring
Required

Bearer token. Client API key as a bearer token. Use an agency key (ak_..., read-write) or a location secret key (sk_..., read-only). Format: Bearer ak_... or Bearer sk_.... Scoped keys (mcp_) are accepted too and need links:read or links:write. See Using an mcp_ key over HTTP.

Query Parameters

location_idstring

Target location (client) id. Required when authenticating with an agency key (ak_); alternative to the X-Location-Id header. Ignored for secret keys, which resolve their own location.

slugstring

Restrict results to a single link slug.

date_fromstring

Start of the date range (forwarded to Tinybird).

date_tostring

End of the date range (forwarded to Tinybird).

limitinteger

Maximum rows to return (forwarded to Tinybird).

utm_sourcestring

Filter by utm_source. An empty string matches clicks with no value for that UTM.

Headers

X-Location-Idstring

Target location (client) id. Required when authenticating with an agency key (ak_); alternative to the location_id query parameter. Ignored for secret keys.

Responses

metaobject[]

Column metadata (name/type per field).

dataobject[]

Result rows.

rowsinteger
statisticsobject