Skip to main content
POST
/
api
/
v1
/
users
curl --request POST \
  --url https://app.mlm-platform.com/api/v1/users \
  --header 'Content-Type: application/json' \
  --header 'x-tenant-api-key: <api-key>' \
  --data '
{
  "email": "newmember@example.com",
  "membership_tier": "ORDINARY"
}
'
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tenant_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"email": "jsmith@example.com",
"membership_tier": "ORDINARY",
"parent_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"is_active": true,
"can_recruit": true,
"is_test_user": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}

Authorizations

x-tenant-api-key
string
header
required

Tenant API key for authentication. Keys are scoped to specific environments (LIVE or SANDBOX). Obtain keys from the admin dashboard.

Body

application/json
email
string<email>
required

User's email address (must be unique)

membership_tier
enum<string>

Member's tier in the hierarchy

Available options:
ORDINARY,
SENIOR,
MANAGER,
DIRECTOR
parent_id
string<uuid>

Parent/sponsor user ID

referral_code
string

Referral code to attribute to a sponsor

is_active
boolean
default:true

Whether the user is active

can_recruit
boolean
default:true

Whether the user can recruit new members

metadata
object

Response

Member created successfully

id
string<uuid>
tenant_id
string<uuid>
email
string<email>
membership_tier
enum<string>

Member's tier in the hierarchy

Available options:
ORDINARY,
SENIOR,
MANAGER,
DIRECTOR
parent_id
string<uuid> | null
is_active
boolean
can_recruit
boolean
is_test_user
boolean
created_at
string<date-time>
updated_at
string<date-time>