Access affiliate performance data from your Inflektion account and enroll new affiliates programmatically. Pull summary reports, conversion-level logs, and affiliate details, and create affiliates directly in your program.
Overview
The Brand Metrics API gives brands programmatic access to the affiliate performance data flowing through Inflektion. It is organized around REST principles and uses standard HTTP verbs, status codes, and JSON request/response bodies.
The API is organized into the following capabilities:
- Summary Reporting: Aggregate metrics grouped by affiliate, date, geography, or other dimensions. Ideal for leaderboards and time-series charts.
- Conversion Log: Transaction-level detail for every conversion and (optionally) on-site event. Ideal for daily syncs into a data warehouse or BI tool.
- Edit Conversion: Update the sale amount on an existing conversion. Revenue and payout are adjusted automatically when applicable.
- Delete Conversion: Remove a conversion from the record.
- Affiliate Details: Active affiliate roster with contract tier, join date, and referral tree data.
- Single Affiliate Details: The same affiliate record, looked up by affiliate ID and returned as a single object.
- Create Affiliate: Enroll a new affiliate directly into your program under a specific offer.
- Check Vanity Slug Availability: Pre-check whether a vanity URL slug is available before creating an affiliate.
- Region Lookup: Valid region_code values for a given country, for use in Create Affiliate.
- Country Lookup: Valid country_code values, for use in Create Affiliate.
- Timezone Lookup: The full reference list of supported timezone IDs.
Authentication
All requests must be authenticated with a Bearer token in the Authorization header. Your API key is provided by your Inflektion account manager if you're on the Growth or Enterprise plans.
Authorization: Bearer YOUR_API_KEY
IMPORTANT: Keep your API key secret. Do not expose it in client-side code, public repositories, or browser requests. If you believe your key has been compromised, contact your Inflektion account manager immediately for a rotation.
Base URL
All requests are made over HTTPS to https://brand-api.inflektion.io
Request bodies (where applicable) must be JSON with the "Content-Type" header set to "application/json".
Pagination
Endpoints that return lists include a "paging" object in the response body:
{
"paging": {
"page": 2,
"page_size": 50,
"total_count": 150
}
}Pages are 1-indexed (the first page is 1, not 0). When no pagination parameters are specified, the API returns the first page with a default page_size of 50. The maximum page size is 2000 unless an endpoint specifies otherwise.
To request a specific page, include page and page_size as query string parameters on GET endpoints, or as fields in the JSON body on POST endpoints.
Timezones
Every reporting request must include a timezone_id to anchor date ranges correctly. Common timezone IDs:
| TIMEZONE | ID |
| America/New_York | 80 |
| America/Chicago | 85 |
| America/Denver | 87 |
| America/Phoenix | 89 |
| America/Los_Angeles | 90 |
| UTC | 67 |
For the full reference list, see the Timezone Lookup section below. If you need a timezone ID that is not listed there, contact your Inflektion account manager.
Summary Reporting
POST /api/reporting/entityReturns aggregate performance metrics grouped by one or more dimensions, similar to a pivot table. Use this endpoint to build leaderboards, time-series charts, or summary dashboards.
Request Body
| FIELD | TYPE | REQUIRED | DESCRIPTION |
| from | string | Yes | Start date in YYYY-MM-DD format. |
| to | string | Yes | End date in YYYY-MM-DD format. |
| timezone_id | integer | Yes | See Timezones section above. |
| currency_id | string | Yes | ISO 4217 currency code (e.g. "USD"). |
| columns | array | Yes | One to ten grouping columns. See available columns below. |
| query.filters | array | No | Array of filter objects to narrow results. |
| query.search_terms | array | No | Free-text search terms. |
Available Columns
| COLUMN | GROUPS BY |
| affiliate_id | Affiliate ID |
| country | Country name of the purchaser |
| country_code | ISO country code of the purchaser |
| date | Day of the conversion |
| week | Week of the year |
| month | Month |
CONSTRAINT: Date ranges are limited to a maximum span of one year. Requests exceeding this limit will return an error.
Response Structure
The response contains three objects:
summary: Aggregate metrics for the entire date range across all groupings.
performance: Time-series data for building aggregate charts. The granularity adapts to the date range automatically:
- 1 day — 96 intervals of 15 minutes
- 2–3 days — 1-hour intervals
- 4–7 days — 6-hour intervals
- 8–14 days — 12-hour intervals
- >14 days — Daily intervals
table: Aggregate metrics broken down by the requested grouping column(s). Limited to 10,000 rows. Ideal for leaderboard/dashboard views.
Example Request
View aggregate data, grouped by affiliate_id, for the months of August through November 2025.
curl --request POST 'https://brand-api.inflektion.io/api/reporting/entity' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
"from": "2025-08-01",
"to": "2025-11-30",
"timezone_id": 90,
"currency_id": "USD",
"query": {
"filters": [],
"search_terms": []
},
"columns": [
{ "column": "affiliate_id" }
]
}'TIP: Use the performance object for time-series charts and the table object for affiliate leaderboards. The summary object is useful for top-level KPI cards (total clicks, revenue, commissions, etc.).
Conversion Log
POST /api/reporting/conversionsReturns transaction-level data for individual conversions and (optionally) on-site events such as Add to Cart. Results are paginated.
RECOMMENDED USAGE: Call this endpoint once per day for the prior day's date range. This gives you a complete, log-level feed suitable for syncing into a data warehouse or BI tool.
Request Body
| FIELD | TYPE | REQUIRED | DESCRIPTION |
| from | string | Yes | Start date (YYYY-MM-DD). |
| to | string | Yes | End date (YYYY-MM-DD). |
| timezone_id | integer | Yes | See Timezones section above. |
| currency_id | string | Yes | ISO 4217 currency code. |
| show_conversions | boolean | Yes | Set to true to include purchase conversions. |
| show_events | boolean | Yes | Set to true to include non-conversion events (e.g. Add to Cart). |
| show_only_vt | boolean | No | Filter to view-through conversions only. |
| show_only_ct | boolean | No | Filter to click-through conversions only. |
Example Request
curl --request POST 'https://brand-api.inflektion.io/api/reporting/conversions' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
"show_conversions": true,
"show_events": false,
"show_only_vt": false,
"show_only_ct": false,
"from": "2025-11-30",
"to": "2025-11-30",
"timezone_id": 90,
"currency_id": "USD",
"query": {
"filters": [],
"search_terms": []
}
}'Example Response
{
"conversions": [
{
"conversion_id": "9008277d544441a7bc0c64533ccbbad8",
"conversion_unix_timestamp": 1764489640,
"cost_type": "RPS",
"cost": 8.09,
"session_user_ip": "203.0.113.42",
"conversion_user_ip": "203.0.113.42",
"country": "United States",
"region": "California",
"city": "Los Angeles",
"dma": 0,
"carrier": "",
"platform": "iOS",
"os_version": "",
"device_type": "Phone",
"brand": "Apple",
"browser": "Safari",
"language": "en",
"http_user_agent": "Mozilla/5.0 ...",
"is_event": false,
"transaction_id": "41c9b30abde3434db512025fab386952",
"click_unix_timestamp": 1764489486,
"event": "Purchase",
"currency_id": "USD",
"isp": "",
"adv1": "",
"adv2": "",
"adv3": "",
"adv4": "couponcode",
"adv5": "",
"sale_amount": 53.91,
"relationship": {
"offer": {
"network_offer_id": 123,
"network_id": 888,
"name": "Your Brand",
"offer_status": "active"
},
"events_count": 0,
"affiliate_id": 123456,
"affiliate": {
"network_affiliate_id": 123456,
"network_id": 888,
"name": "Sample Affiliate",
"account_status": "active"
},
"sub1": "",
"sub2": "",
"sub3": "",
"sub4": "",
"sub5": "",
"source_id": "",
"offer_url": null
},
"coupon_code": "brand-affiliate"
}
],
"paging": {
"page": 1,
"page_size": 50,
"total_count": 271
}
}Suggested Fields to Log
When ingesting Conversion Log data into your own systems, we recommend storing at minimum the following fields:
| FIELD | DESCRIPTION |
| conversion_id | Inflektion's globally unique conversion identifier. |
| conversion_unix_timestamp | UNIX timestamp of the conversion event. |
| click_unix_timestamp | UNIX timestamp of the originating click. |
| transaction_id | Inflektion's globally unique click ID. |
| event | Human-readable funnel event name (e.g. Purchase, Add to Cart). |
| sale_amount | Purchase subtotal (excludes tax/shipping, net of discounts). |
| cost | Commission cost for this conversion. Returns 0 for non-conversion events. |
| currency_id | ISO 4217 currency code. |
| relationship.affiliate_id | The affiliate ID credited with the sale. |
| country | Country name of the converting user. |
| session_user_ip | IP address at click time. |
| conversion_user_ip | IP address at conversion time. |
| http_user_agent | The purchaser's user agent string. |
| adv4 | Typically contains the coupon code used (if any). |
| coupon_code | The coupon code applied to the order. |
Edit Conversion
PUT /api/reporting/conversions/{conversion_id}/saleamountUpdates the sale amount on an existing conversion. Revenue and payout are adjusted automatically when applicable.
RECOMMENDED USAGE: Use this endpoint to reconcile conversions whose order totals changed after the initial post (partial refunds, upsells, or post-checkout adjustments). Look up the target conversion_id via the Conversion Log endpoint first.
Query Parameters
| PARAMETER | TYPE | REQUIRED | DESCRIPTION |
| conversion_id | string | Yes | The ID of the conversion. See the Conversion Log section. |
Request Body
| FIELD | TYPE | REQUIRED | DESCRIPTION |
| sale_amount | float | Yes | The new sale amount. |
Example Request
curl --location --request PUT 'https://brand-api.inflektion.io/api/reporting/conversions/{conversion_id}/saleamount' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
"sale_amount": 199.00
}'Delete Conversion
DELETE /api/reporting/conversions/{conversion_id}Deletes a conversion from the record.
IMPORTANT: Deletion is permanent. Downstream revenue and payout figures tied to this conversion will be reversed. If you only need to correct a sale amount, use the Edit Conversion endpoint instead.
Query Parameters
| PARAMETER | TYPE | REQUIRED | DESCRIPTION |
| conversion_id | string | Yes | The ID of the conversion. See the Conversion Log section. |
Example Request
curl --location --request DELETE 'https://brand-api.inflektion.io/api/reporting/conversions/{conversion_id}' \
--header 'Authorization: Bearer YOUR_API_KEY'Affiliate Details
GET /api/affiliates?page={page}&page_size={page_size}Returns a paginated list of all active affiliates in your program, including their contract tier, join date, and referral chain.
Query Parameters
| PARAMETER | TYPE | REQUIRED | DESCRIPTION |
| page | integer | No | Page number (1-indexed). Defaults to 1. |
| page_size | integer | No | Results per page. Defaults to 50, max 2000. |
Response Fields
| FIELD | DESCRIPTION |
| network_affiliate_id | The affiliate's unique ID. |
| name | Affiliate display name. |
| emails | An array of one or more email addresses that are on the affiliate's account. |
| time_created | UNIX timestamp of when the affiliate joined the program. |
| time_loggedin | UNIX timestamp of when the affiliate last logged in. |
| contract_name | Current payout contract tier. |
| type | The type of partner that you've categorized this partner as. |
| referrer_id | Affiliate ID of the referring affiliate. Null if none. Use the referrer_id field to reconstruct the referral tree and track sales by recruit. |
| primary_url | The primary vanity URL for that partner. |
| primary_qr | A link to the QR code of the affiliate's primary vanity URL (links to a 500x500px PNG) |
| primary_url_direct | If you're set up with direct links, this will be the primary direct link for that partner. |
| primary_code | That partner's main discount/coupon code. |
| payment_added | true/false. True if they've added their payout information on file. False otherwise. |
| personalization_added | true/false. True if they've added personalizations (e.g. testimonial, etc.). False otherwise. |
Example Request
curl --request GET 'https://brand-api.inflektion.io/api/affiliates?page=1&page_size=10' \
--header 'Authorization: Bearer YOUR_API_KEY'Example Response
{
"affiliates": [
{
"network_affiliate_id": 17759,
"name": "Biohacker Bob",
"emails": [
"bob@superpopgummies.com",
"anotheremail@sugarpopgummies.com"
],
"time_created": 1749178472,
"time_loggedin": 1776422397,
"contract_name": "15% Revshare",
"type": "Affiliate",
"referrer_id": null,
"primary_url": "https://sugarpopgummies.com/biohackerbob",
"primary_qr": "https://assets.inflektion.ai/qr/https%3A%2F%2Fsugarpopgummies.com%2Fbiohackerbob",
"primary_url_direct": null,
"primary_code": "BIOHACKERBOB",
"payment_added": true,
"personalization_added": true
},
{
"network_affiliate_id": 17760,
"name": "FitJess 50+",
"emails": [
"jess@superpopgummies.com"
],
"time_created": 1749179125,
"time_loggedin": 1768488140,
"contract_name": "15% Revshare",
"type": "Influencer",
"referrer_id": 17759,
"primary_url": "https://sugarpopgummies.com/fitjess",
"primary_qr": "https://assets.inflektion.ai/qr/https%3A%2F%2Fsugarpopgummies.com%2Ffitjess",
"primary_url_direct": null,
"primary_code": "FITJESS",
"payment_added": false,
"personalization_added": false
}
],
"paging": {
"page": 1,
"page_size": 1000,
"total_count": 5
}
}Single Affiliate Details
GET /api/affiliates/{affiliate_id}Returns the details for one affiliate, looked up by their affiliate ID. This is the single-record version of the Affiliate Details endpoint: the response is a single affiliate object rather than an array, and no "paging" object is returned.
Query Parameters
| PARAMETER | TYPE | REQUIRED | DESCRIPTION |
| affiliate_id | integer | Yes | The affiliate's unique ID. This is the same value returned as network_affiliate_id by the Affiliate Details endpoint and as relationship.affiliate_id by the Conversion Log endpoint. |
Response Fields
The response returns the same fields as the Affiliate Details endpoint above, for a single affiliate:
Example Request
curl --location 'https://brand-api.inflektion.io/api/affiliates/17759' \
--header 'Authorization: Bearer YOUR_API_KEY'Example Response
{
"network_affiliate_id": 17759,
"name": "Biohacker Bob",
"emails": [
"bob@superpopgummies.com",
"anotheremail@sugarpopgummies.com"
],
"time_created": 1749178472,
"time_loggedin": 1776422397,
"contract_name": "15% Revshare",
"type": "Affiliate",
"referrer_id": null,
"primary_url": "https://sugarpopgummies.com/biohackerbob",
"primary_qr": "https://assets.inflektion.ai/qr/https%3A%2F%2Fsugarpopgummies.com%2Fbiohackerbob",
"primary_url_direct": null,
"primary_code": "BIOHACKERBOB",
"payment_added": true,
"personalization_added": true
}Create Affiliate
POST /api/affiliatesEnrolls a new affiliate directly into your program under a specific offer. All validation runs before anything is created: a vanity slug, coupon code, or storefront redirect that is already taken fails immediately with no side effects.
IMPORTANT: The offer_uuid identifies which of your offers/brands the affiliate is being created for. This is provided to you directly by your Inflektion account manager — there is no endpoint to look it up yourself.
Request Body
| FIELD | TYPE | REQUIRED | DESCRIPTION |
| offer_uuid | string | Yes | The offer this affiliate joins. Provided by your Inflektion account manager. |
| string | Yes | The affiliate's email address. | |
| first_name | string | Yes | The affiliate's first name. |
| last_name | string | Yes | The affiliate's last name. |
| name | string | No | Company/organization name. Defaults to "{first_name} {last_name}". |
| country_code | string | Yes | 2-letter ISO country code (e.g. "US"). See the Country Lookup section. |
| region_code | string | Conditional | State/region/province code. Required when the country you send has regions (most do — US, CA, AU, etc.) and optional for countries that have none. Use the Region Lookup endpoint below to get the valid values for a given country_code. A supplied value must be one of them; an unrecognized value is rejected. |
| address_1 | string | Yes | Street address. |
| address_2 | string | No | Apartment, suite, unit, etc. |
| city | string | Yes | City. |
| zip_postal_code | string | Yes | ZIP/postal code. Letters, numbers, spaces and hyphens only. |
| cell_phone | string | Yes | The affiliate's phone number. Digits and the characters + - ( ) . and spaces only — no letters. |
| initial_password | string | No | Minimum 8 characters, and must contain at least one letter and one number. If omitted, the affiliate will need to reset their password before they can log in. |
| language | string | Conditional | Required only if the offer has more than one configured language option; otherwise defaults to "en". If required, your Inflektion account manager will tell you which value to send. |
| currency_id | string | Conditional | ISO 4217 currency code. Required only if the offer has more than one configured currency option; otherwise defaults to "USD". A value that is not one of the offer's configured options falls back to "USD" rather than being rejected. If required, your Inflektion account manager will tell you which value to send. |
| vanity_slug | string | Yes | The affiliate's vanity URL slug and coupon code. 3–25 characters, lowercase letters and numbers only (no hyphens, underscores, or spaces). Use the Check Vanity Slug Availability endpoint below to pre-check this. |
| channels | array | Yes | At least one social/contact channel. See Channel Object below. |
| signup_ip | string | No | The affiliate's own signup/terms-agreement IP (IPv4 or IPv6). If omitted, falls back to the connecting request's own IP. |
| auto_approve | boolean | No | Set to true to approve this affiliate immediately. Defaults to false, which creates the affiliate as pending for manual review. |
| referrer_id | integer | No | The network_affiliate_id of the affiliate who referred this signup, for brands using our referral program. Only applied if your brand has referrals enabled and the ID resolves to a real affiliate; otherwise it is silently ignored rather than rejected. |
RETURNING AFFILIATES: If the email already belongs to an affiliate in your program on another offer, that same affiliate is added to this offer rather than created again. Their existing name and country are kept, and the name and address fields you send in that case are used only for the new offer's records, not to change the person's identity.
Channel Object
Each entry in channels is an object with a type and a handle:
{ "type": "instagram", "handle": "@youraffiliate" }| FIELD | TYPE | REQUIRED | DESCRIPTION |
| type | string | Yes | One of: instagram, tiktok, x, youtube, email, linkedin, facebook, twitch, pinterest, website, podcast, other. |
| handle | string | Yes | The affiliate's handle/URL/address for this channel, up to 255 characters. Sent through as-is, so whatever shape the channel uses (@name, a profile URL, channel/xyz, a bare domain) is accepted. Control characters and the characters < > \ ` are rejected. |
Example Request
curl --request POST 'https://brand-api.inflektion.io/api/affiliates' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
"offer_uuid": "11111111-1111-1111-1111-111111111111",
"email": "ada@example.com",
"first_name": "Ada",
"last_name": "Lovelace",
"country_code": "US",
"region_code": "CA",
"address_1": "123 Main St",
"city": "Springfield",
"zip_postal_code": "12345",
"cell_phone": "5551234567",
"vanity_slug": "adalovelace",
"channels": [
{ "type": "instagram", "handle": "@ada" }
]
}'Example Response
{
"network_affiliate_id": 45566,
"status": "pending"
}status is either "pending" (awaiting manual review/approval) or "approved" (when auto_approve was set to true).
VALIDATION: If the vanity slug, coupon code, or a required field is invalid, the request fails with a 422 and no affiliate is created. Nothing is left partially created. See the Error Handling section below.
Check Vanity Slug Availability
POST /api/affiliates/vanity-slug-checkPre-checks whether a vanity URL slug is available for a given offer, both within Inflektion and against your program's live coupon codes, before you submit the full Create Affiliate payload.
Request Body
| FIELD | TYPE | REQUIRED | DESCRIPTION |
| offer_uuid | string | Yes | The offer to check against. Provided by your Inflektion account manager. |
| slug | string | Yes | The vanity slug you are considering. |
Example Request
curl --request POST 'https://brand-api.inflektion.io/api/affiliates/vanity-slug-check' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--data '{
"offer_uuid": "11111111-1111-1111-1111-111111111111",
"slug": "adalovelace"
}'Example Response
{
"available": true
}available is true, false, or null. A null value means the availability check could not be completed at that moment, and is returned with a 502 status and a message field. Treat it as "unknown" rather than "available", and retry.
NOTE: This is a best-effort pre-check, not a guarantee. The Create Affiliate endpoint above still runs its own full validation at creation time and is the authoritative gate.
Region Lookup
GET /api/regions?country_code={country_code}Returns the valid region_code values for a given country, for use in the Create Affiliate endpoint's region_code field.
Query Parameters
| PARAMETER | TYPE | REQUIRED | DESCRIPTION |
| country_code | string | Yes | 2-letter ISO country code (e.g. "US"). |
Example Request
curl --request GET 'https://brand-api.inflektion.io/api/regions?country_code=US' \
--header 'Authorization: Bearer YOUR_API_KEY'Example Response
{
"regions": [
{ "region_code": "CA", "region_name": "California", "country_code": "US" },
{ "region_code": "NY", "region_name": "New York", "country_code": "US" }
]
}NOTE: If region_code is not required for the offer you are signing an affiliate up for, you do not need to call this endpoint at all. Simply omit region_code from your Create Affiliate request.
Country Lookup
GET /api/countriesReturns the full list of valid country_code values, for use in the Create Affiliate endpoint's country_code field.
Example Request
curl --request GET 'https://brand-api.inflektion.io/api/countries' \
--header 'Authorization: Bearer YOUR_API_KEY'Example Response
{
"countries": [
{ "country_code": "US", "country_name": "United States" },
{ "country_code": "CA", "country_name": "Canada" }
]
}Timezone Lookup
GET /api/timezonesReturns the full timezone reference list, including every timezone_id accepted by the reporting endpoints.
Example Request
curl --request GET 'https://brand-api.inflektion.io/api/timezones' \
--header 'Authorization: Bearer YOUR_API_KEY'Example Response
{
"timezones": [
{ "timezone_id": 80, "timezone_name": "Eastern Daylight Time (America/New_York)", "timezone": "America/New_York", "utc_offset": "-04:00" },
{ "timezone_id": 90, "timezone_name": "Pacific Daylight Time (America/Los_Angeles)", "timezone": "America/Los_Angeles", "utc_offset": "-07:00" }
]
}
Error Handling
Each of the API points use standard HTTP status codes. Errors return a JSON body with a descriptive message.
| STATUS | MEANING |
| 200 | Success. |
| 201 | Created — a new affiliate was created successfully. |
| 400 | Bad request — check your payload for missing or invalid fields (e.g. date range exceeds one year). |
| 401 | Unauthorized — missing or invalid API key. |
| 403 | Forbidden — your key does not have access to this resource. |
| 404 | Not found — the requested record does not exist (e.g. an unknown affiliate ID or offer_uuid). |
| 422 | Validation failed — see the errors object in the response body for field-specific reasons (e.g. a vanity slug that is already taken). |
| 429 | Rate limited — you are sending too many requests. Back off and retry. |
| 500 | Internal server error — retry after a brief delay. If persistent, contact support. |
| 502 | Could not verify against an upstream system right now (e.g. the availability lookup behind the Check Vanity Slug Availability endpoint). Retry. |
Rate Limits
API requests are rate-limited per API key. The affiliate-creation endpoints (Create Affiliate, Check Vanity Slug Availability, and the Region, Country, and Timezone Lookup endpoints) allow 60 requests per minute. If you receive a 429 response, implement an exponential backoff strategy before retrying. For high-volume integrations or real-time use cases, contact your Inflektion account manager to discuss elevated rate limits.
Need help?
Reach out to your Inflektion account manager through Slack or email.