Export

BASE  https://api.rii.link/v1AUTH: BEARER → AUTHENTICATION

Download every link your API manages, or the per-click log for a time range, as one streamed file. Both calls cover the links created through the API in the key’s environment — the set GET /v1/links lists. For the whole workspace, dashboard links included, use Settings → Export in the dashboard.

GET/v1/export/request-logs

Export the click log

Every request to your live API-created links in the window, one row per click, known bots included and marked in is_bot. The start is clamped to your plan’s analytics retention — 30 days on Free, 1 year on Premium, unlimited on Enterprise — and the response headers say which window you got.

PARAMETERS
formatstring

json (default) or csv. The file is rii-request-logs-{workspace}-{date}.json or .csv.

from / totimestamp

Bounds of the window; timestamps without an offset are read as UTC. from defaults to the start of your retention and is clamped to it; to defaults to now.

domainstring

Only clicks on this host.

TEST KEYS GET AN EMPTY EXPORT · IP ADDRESSES ARE EXPORTED AS STORED, ALREADY TRUNCATED

REQUEST
curl -D - -o clicks.csv "https://api.rii.link/v1/export/request-logs?format=csv&from=2026-01-01T00:00:00Z" \
-H "Authorization: Bearer $RII_KEY"
RESPONSE · 200 (FREE PLAN, CLAMPED)
HTTP/2 200
content-type: text/csv; charset=utf-8
content-disposition: attachment; filename="rii-request-logs-acme-2026-09-28.csv"
x-export-from: 2026-08-29T09:20:00+00:00
x-export-to: 2026-09-28T09:20:00+00:00
x-export-requested-from: 2026-01-01T00:00:00+00:00
x-export-clamped: true
x-export-retention-days: 30
timestamp,host,path,query_string,method,status_code,response_time_ms,link_id,rule_matched,is_bot,is_qr,ip_address,country_code,device_type,browser,os,protocol,accept_language,user_agent,referer,referrer_host,utm_source,utm_medium,utm_campaign,utm_term,utm_content,dest_utm_source,dest_utm_medium,dest_utm_campaign,dest_utm_term,dest_utm_content
…