AI Connectors and MCP
AffiliateBase can expose a scoped Model Context Protocol (MCP) connector so an AI client can help with setup and read program state.
Use this when you want ChatGPT, Claude, Cursor, Codex, or another MCP-compatible client to answer questions like:
- What setup step is incomplete?
- Which tracking instructions should I follow?
- What test affiliate link should I open?
- Has AffiliateBase seen a first click or conversion?
- What campaigns, affiliates, referrals, commissions, or payouts exist?
Create a connector token
- Open AffiliateBase.
- Go to Settings -> AI Connectors.
- Click Create token.
- Copy the token immediately. It is only shown once.
The default setup-assistant token is scoped to:
- setup status and setup guidance
- setup integration confirmation
- read-only reporting
- read-only campaign and affiliate lists
It does not grant payout execution, commission voiding, affiliate deletion, API key creation, or account-wide destructive access.
MCP endpoint
Use this MCP URL:
https://app.affiliatebase.io/mcp
Most clients need:
- the MCP URL
- the connector token
- your AffiliateBase account ID
Use the token as a bearer token:
Authorization: Bearer ab_live_your_connector_token
X-Account-Id: your_account_id
Example client config
For clients that accept a JSON MCP server config, use:
{
"mcpServers": {
"affiliatebase": {
"url": "https://app.affiliatebase.io/mcp",
"headers": {
"Authorization": "Bearer ab_live_your_connector_token",
"X-Account-Id": "your_account_id"
}
}
}
}
Starter prompt
After connecting the MCP server, start with:
Use AffiliateBase MCP to read my setup status, get install instructions, and help me verify that Stripe Checkout receives client_reference_id before marking setup complete.
The AI should read setup state first, then recommend the simplest next action.
What the connector can do
Setup tools:
read_setup_statusget_setup_contextget_install_instructionsget_test_affiliate_linkverify_tracking_installationmark_integration_confirmed
Read-only operating tools:
list_campaignslist_affiliateslist_referralslist_commissionslist_payoutsget_dashboard_summary
Safe write behavior
The only setup write in the default connector is mark_integration_confirmed.
Use it only after you have verified:
- an affiliate link was opened
- a Stripe checkout was started
- the Stripe Checkout Session has
client_reference_id
The tool requires an idempotency key and records an onboarding event. It marks setup integration as confirmed; it does not execute payouts or change commission state.
Recommended setup flow
Ask the AI client to:
- Call
read_setup_status. - Call
get_setup_context. - Call
get_install_instructionswith the right checkout path. - Call
get_test_affiliate_link. - Help you update your checkout code or Payment Link.
- Call
verify_tracking_installation. - Call
mark_integration_confirmedonly after you confirm the Stripe proof.
For most Stripe Payment Link setups, the AI should keep you on the default path: install the tracking script, add data-affiliatebase to the Payment Link, then confirm client_reference_id in Stripe.
Security notes
- Use AI connector tokens, not full-access REST API keys.
- Revoke connector tokens you no longer use.
- Create short-lived tokens for testing.
- Do not paste tokens into public chats, shared documents, or issue trackers.
- Use a disposable test account before testing setup writes.