Affiliate API · view data

View your AFFILIFY data via API

Fetch the same statistics, conversions, brands and tracking links you see in the dashboard — into spreadsheets, BI tools, or your own scripts. You read data out. You do not send operator postbacks here.

Personal key

Create once in Settings → API access. Shown only once.

Your data only

Scoped to your account. Brand names match the app.

Dashboard metrics

The metrics behind Statistics, Conversions and Links. Totals can include conversions later rejected.

Endpoints at a glance
  • GET/api/v1/stats/summary
    Period totals + previous period
  • GET/api/v1/stats/series
    Daily breakdown for a date range
  • GET/api/v1/stats/hourly
    Last 24 hours by hour
  • GET/api/v1/stats/geo
    Clicks by country
  • GET/api/v1/conversions
    Recent conversion events
  • GET/api/v1/brands
    Active brands you can promote
  • GET/api/v1/brands/{id}/landings
    Landings for a brand
  • GET/api/v1/links
    Your tracking links
  • POST/api/v1/links
    Create a tracking link
  • GET/api/v1/links/{id}
    One tracking link
  • DELETE/api/v1/links/{id}
    Soft-delete a link
  • POST/api/v1/links/{id}/restore
    Restore a deleted link
1

Quick start

  1. Sign in → Settings → API access → generate a key. Copy it immediately (shown once).
  2. Call any endpoint below with Authorization: Bearer YOUR_KEY over HTTPS.
  3. Parse the JSON — every success body has ok: true.
curl
curl -H "Authorization: Bearer affa_…" \
  "https://affilify.partners/api/v1/stats/summary?days=30"
2

Authentication

Keys start with affa_. We store only a hash — if you lose the raw key, revoke it and create a new one.

Pass the key with either header (both work):

Headers
Authorization: Bearer affa_…
# or
X-API-Key: affa_…

Do not put the key in public front-end code or shared repos.

3

Summary stats

Totals for the last N days, plus a previous window of equal length (for deltas). Matches the Statistics page.

GEThttps://affilify.partners/api/v1/stats/summary?days=30
ParamRequiredDescription
daysNoLookback window, 1–366. Default 30.
Response
{
  "ok": true,
  "days": 30,
  "has_revshare": true,
  "clicks": 24,
  "registrations": 1,
  "ftds": 0,
  "deposits_count": 0,
  "deposits_sum": 0,
  "ngr": 0,
  "conversions": 1,
  "commission": 0,
  "previous": { "clicks": 8, "registrations": 0, "ftds": 0, "…" : "…" }
}
4

Daily series

Inclusive date range with per-day rows — same chart data as the dashboard date picker.

GEThttps://affilify.partners/api/v1/stats/series?from=2026-06-01&to=2026-07-18
ParamRequiredDescription
fromNoStart date YYYY-MM-DD. Default: 30 days ago.
toNoEnd date YYYY-MM-DD. Default: today (UTC).

Response includes totals, previous, and daily[] with date, clicks, registrations, ftds, ngr, commission. Max range 366 days.

5

Hourly (last 24 hours)

Last 24 hours in UTC hour buckets. Use this for the same “24h” view as Statistics.

GEThttps://affilify.partners/api/v1/stats/hourly

Returns totals, previous (prior 24h), and hourly[] where each row has ts (bucket start) plus metrics.

6

GEO stats

Click volume by country for a lookback window, plus proxy share.

GEThttps://affilify.partners/api/v1/stats/geo?days=30
ParamRequiredDescription
daysNo1–366. Default 30.
Response
{
  "ok": true,
  "days": 30,
  "total_clicks": 24,
  "proxy_clicks": 17,
  "countries": 3,
  "top_countries": [
    { "country": "GB", "clicks": 17 },
    { "country": "CY", "clicks": 5 },
    { "country": "DE", "clicks": 2 }
  ]
}
7

Conversions

Recent events on your links — registrations, FTDs, deposits, NGR, etc. Brand/operator company names are not included; link + campaign id are.

GEThttps://affilify.partners/api/v1/conversions?limit=50
ParamRequiredDescription
limitNo1–500. Default 100.
event_typeNoregistration | ftd | deposit | ngr | purchase | subscription | lead | custom
include_testNotrue or 1 to include test events. Default false.
Response
{
  "ok": true,
  "count": 1,
  "conversions": [{
    "id": "…",
    "event_type": "registration",
    "amount": 0,
    "currency": "USD",
    "status": "approved",
    "created_at": "2026-07-07T16:24:23Z",
    "is_test": false,
    "sub_ids": { "sub_id1": "…", "sub_id2": null },
    "link": { "id": "…", "code": "6c1ia02o", "name": "goon", "campaign_id": "…" }
  }]
}
8

Brands & landings

Active brands you can promote (same catalogue as Brands in the app), and GEO/landing rows used when creating a link.

GEThttps://affilify.partners/api/v1/brands
GEThttps://affilify.partners/api/v1/brands/{campaign_id}/landings

Landings return id, country, name (no raw destination URLs). Pass a landing id when creating a link.

Landings response
{
  "ok": true,
  "campaign_id": "…",
  "landings": [
    { "id": "…", "country": "GB", "name": "Bonus", "sort_order": 2, "is_default": false }
  ]
}
10

Errors

All bodies are JSON with an ok flag.

HTTPerrorMeaning
401missing_api_keyNo Bearer / X-API-Key header
401invalid_keyUnknown or revoked key
403account_inactiveAccount closed, banned, or suspended
403insufficient_scopeKey lacks stats or links scope
403link_gateCreate blocked (application / KYC / CPA)
403link_blockedThe link was deactivated by AFFILIFY and can't be deleted or restored
400bad_days / bad_rangeInvalid query window (from/to must be real YYYY-MM-DD dates)
400bad_limitlimit is not a number from 1 to 500
400bad_event_typeUnknown event_type filter
400bad_idAn id is not in the expected format
400invalid_jsonRequest body is not a JSON object
400missing_campaign_idCreate without campaign_id
400campaign_inactiveBrand is not active
400no_destinationBrand has no landing URL to link to
404not_found / unknown_campaign, unknown_landingLink id not found / brand or landing id not found
500query_failedTemporary server error, retry
500create_failedThe link could not be created

Operator postbacks (sending conversions into AFFILIFY) are documented separately at /docs.