POST /v1/referrals/enroll
Service: affiliates · operationId: (none)
Join the referral program (creates a pending affiliate application).
Required scopes
(no scope declared — review service config)
Request body
{
"type": "object",
"properties": {
"brand_id": {
"type": "string",
"minLength": 1
},
"referral_code": {
"type": "string",
"minLength": 3,
"maxLength": 64
}
}
}Responses
200 Enrolled
{
"type": "object",
"properties": {
"enrolled": {
"type": "boolean",
"enum": [
true
]
},
"status": {
"type": "string"
},
"referral_code": {
"type": "string"
}
},
"required": [
"enrolled",
"status",
"referral_code"
]
}409 Already enrolled
{
"type": "object",
"properties": {
"error": {
"type": "string"
},
"message": {
"type": "string"
}
},
"required": [
"error",
"message"
]
}Example
curl -X POST https://affiliates.platform.loop.health/v1/referrals/enroll \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{ ... }'Related
services/affiliates— service overview- All endpoints — directory across services
- Auth model — how scopes are enforced