Capture a referral visit
POST
Saves a referral code for a future signup.
Access: Layerbeat browser origin. No sign-in required.
- Returns
503 referrals_pausedwhile Refer & Earn is coming soon. - The first valid referral is kept in a secure cookie for 30 days. Invalid or suspended codes return
400; this does not create an account or reward.
Origin*stringThe exact Layerbeat browser origin.
Format
uriapplication/json- body
code*stringEight-character code, case-insensitive. Existing long codes remain accepted as aliases.
Successful response.
application/json- response
code*|Match
^[A-HJ-NP-Z2-9]{8}$expires_at*|Format
date-timecurl -X POST 'https://layerbeat.com/v1/referrals/visit' \ -H 'Origin: https://console.layerbeat.com' \ -H 'Content-Type: application/json' \ -d '{ "code": "K7M4Q9TR"}'{ "code": null, "expires_at": null}