Skip to main content
POST
/
enter-referral-code
Enter protocol referral code
curl --request POST \
  --url https://api.tokenlayer.network/enter-referral-code \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "referral_code": "alice2025",
  "network_mode": "mainnet"
}
'
{
  "success": true,
  "referrer_code": "alice2025",
  "message": "Referral code successfully applied"
}

Authorizations

Authorization
string
header
required

JWT token or API key

Body

application/json
referral_code
string
required

The referral code to enter

Example:

"alice2025"

network_mode
enum<string>
default:mainnet

Network mode for this referral code

Available options:
testnet,
mainnet,
both
Example:

"mainnet"

Response

Successful response

success
enum<boolean>
required
Available options:
true,
false
referrer_code
string
required

The referral code that was entered

Example:

"alice2025"

message
string
required

Success message

Example:

"Referral code successfully applied"