---
title: "Get Referral Code"
method: GET
path: "/api/referral/code"
tags: ["Referral"]
---

# Get Referral Code

`GET /api/referral/code`

## Request

- Base URL: `https://api.earmarkiq.app` (the document declares no server; this is the origin it was published from)
- URL: `https://api.earmarkiq.app/api/referral/code`
- Auth: HTTP bearer

Returns user's unique referral code (generates one if doesn't exist).

## Response `200`

Successful Response

- ReferralCodeResponse
  - `referral_code` string, required

---

[API](https://skmtc.dev/earmarkiq/apis/earmark-api.md) · [All operations](https://skmtc.dev/earmarkiq/apis/earmark-api/llms.txt) · [OpenAPI document](https://skmtc.dev/earmarkiq/apis/earmark-api/revisions/4a2c41907105?raw)
