Skip to Content
Indexify
Social

Generate a referral link

POST
/api/refer.php

Creates a new referral link with an auto-generated access code for the authenticated user.

Authorization

ApiKeyAuth
headerX-API-KEY<token>

API key with the ix_ prefix. You can generate an API Key by navigating to Settings -> API Key in the web app. Pass it in the X-API-KEY header on every request.

Request Body

application/json
  1. body
referral_code*string

The referral code to embed in the link.

Response Body

Referral link created.

application/json
  1. response
referral_link?string

Full referral URL.

access_code?string

Generated early-access code.

access_code_name?string

Descriptive name of the access code.

referral_code?string

The referral code that was provided.

expires_at?string

Expiration timestamp of the access code.

Example Request
curl -X POST 'https://api.indexify.finance/api/refer.php' \  -H 'Content-Type: application/json' \  -d '{  "referral_code": "string"}'
Example Response
{  "referral_link": "string",  "access_code": "string",  "access_code_name": "string",  "referral_code": "string",  "expires_at": "string"}