Get Partner
Read one partner by its partner participant ID: name, email, its state, enrollment, and partner tier in each affiliate Program, its tier history, its referral codes and links, its metrics, and its 50 newest referrals and Rewards with their referees. Needs the partners:read and referrals:read and rewards:read key permission.
Authorization
WorkspaceApiKey Workspace-owned Better Auth API key of one environment (Sandbox or Live); it authorizes the Projects of that environment in its Workspace. A Project of the other environment returns 403 ENVIRONMENT_MISMATCH. Never expose it in the browser.
In: header
Path Parameters
\S1 <= length <= 512Query Parameters
1 <= length <= 128Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/partners/string?projectId=string"{ "success": true, "data": { "partner": { "participantId": "string", "partnerId": "string", "name": "string", "email": "string", "joinedAt": "string", "website": "string", "description": "string", "contactEmail": "string" }, "programs": [ { "programId": "string", "programName": "string", "state": "invited", "date": "string", "enrollmentId": "string", "tier": { "tierId": "string", "name": "string", "pinned": true } } ], "tierHistory": [ { "id": "string", "programId": "string", "tierId": "string", "tierName": "string", "startsAt": "string", "endsAt": "string", "source": "automatic", "author": "string", "reason": "string" } ], "refCodes": [ { "id": "string", "createdAt": "string", "updatedAt": "string", "projectId": "string", "code": "string", "participantId": "string", "programId": "string" } ], "links": [ { "id": "string", "createdAt": "string", "updatedAt": "string", "projectId": "string", "slug": "string", "refCodeId": "string" } ], "metrics": { "clicks": 0, "referrals": 0, "customers": 0, "revenue": [ { "currency": "string", "currencyExponent": -9007199254740991, "amountMinor": "string" } ], "earnings": [ { "currency": "string", "currencyExponent": -9007199254740991, "amountMinor": "string" } ] }, "referrals": [ { "id": "string", "createdAt": "string", "updatedAt": "string", "projectId": "string", "referrerParticipantId": "string", "refereeParticipantId": "string", "enrollmentId": "string", "programId": "string", "touchId": "string", "touchKind": "click", "bindingEventId": "string", "bindingSubscriptionFactId": "string", "bindingOccurredAt": "string", "selectedAt": "string", "policyVersionId": "string", "void": { "voidId": "string", "reasonCode": "fraud", "reason": "string", "actor": "string", "voidedAt": "string" } } ], "rewards": [ { "id": "string", "createdAt": "string", "updatedAt": "string", "projectId": "string", "evaluationId": "string", "participantId": "string", "programId": "string", "ruleId": "string", "termsVersionId": "string", "allowanceId": "string", "beneficiaryRole": "referrer", "beneficiaryParticipantId": "string", "benefitKind": "cash", "amountMinor": "string", "currency": "string", "currencyExponent": -9007199254740991, "typedBenefitSnapshot": { "property1": null, "property2": null }, "purchaseId": "string", "void": { "id": "string", "reasonCode": "fraud", "reason": "string", "actor": "string", "voidedAt": "string" }, "netAmountMinor": "string", "fulfillmentStatus": "pending", "fulfillment": { "id": "string", "externalReference": "string", "occurredAt": "string", "actor": "string" }, "revocation": { "id": "string", "externalReference": "string", "occurredAt": "string", "actor": "string" }, "delivery": { "method": "operator", "status": "pending", "reason": "awaiting_operator", "providerReference": "string", "connectionId": "string", "attemptCount": -9007199254740991, "lastError": "string", "nextAttemptAt": "string", "grantDispatchedAt": "string", "revocationDispatchedAt": "string", "deliveredAmountMinor": "string", "planUpgradeTargets": [ { "provider": "dodo", "plan": "string", "periods": -9007199254740991 } ], "targetPlan": "string", "planPeriods": -9007199254740991, "revertDueAt": "string", "revertedAt": "string", "revertOutcome": "reverted" } } ], "referees": [ { "id": "string", "name": "string", "email": "string", "externalId": "string", "hasPurchase": true } ] }}Get Participant GET
Read one participant with its enrollments, referral codes and links, the referral that names it as referee, its newest referrals as referrer, and its newest Events. Needs the participants:read and referrals:read key permission.
Get Program Readiness GET
Check whether a Program can go live: the problems that block publish_program (no enabled rule, no referrer rule, no landing page of an affiliate Program, cash paid out by RefRef on a plan without cash payouts) and the warnings that do not. Needs the programs:read key permission.