Validate Referral Code
Referral
Validate Referral Code
Validate a referral code entered by a user during registration
GET
Validate Referral Code
GET https://api.baanx.com/v1/referral/{code}/validate
Validates a referral code when a user enters it, checking whether it is valid or has expired.
Overview
Use this endpoint during the registration flow to verify a referral code before accepting it. Returns a boolean indicating whether the code is currently valid.This endpoint only requires the client key — no user Bearer token is needed, as it is intended for use during registration before a user account exists.
Authentication
This endpoint requires only a client key:Request
Headers
Your public API client key
Set to
true to route requests to the US backend environmentPath Parameters
The referral code to validate (e.g.,
FHLSO5)Request Example
Response
200 Success
true if the referral code is valid and can be used. false if the code is expired or has reached its usage cap.Error Responses
Related Endpoints
GET /v1/referral/- Get the authenticated user’s own referral code