> ## Documentation Index
> Fetch the complete documentation index at: https://docs.b3.fun/llms.txt
> Use this file to discover all available pages before exploring further.

# Register Referrer

Registers a new referrer for collection tracking. Requires signature verification to ensure the wallet owner is registering themselves.

` POST /referrers `

Register Referrer

Registers a new referrer for collection tracking. Requires signature verification to ensure the wallet owner is registering themselves.

## Servers

- ` https://createkit.b3.fun ` — Production server

## Request body (required)

Content type: ` application/json `

- ` value `: type ` object ` — Request to register a new referrer

  - Required fields: ` referrer_id `, ` wallet_address `, ` message `, ` signature `

  - ` referrer_id `: type ` string ` — Unique referrer identifier (lowercase alphanumeric)

    - pattern: ` "^[a-z0-9]+$" `

  - ` wallet_address `: type ` string ` — Referrer wallet address

    - pattern: ` "^0x[a-fA-F0-9]{40}$" `

  - ` message `: type ` string ` — Message that was signed

  - ` signature `: type ` string ` — EIP-191 signature of the message

## Responses

### ` 200 ` — Referrer registered successfully

Content type: ` application/json `

- ` value `: type ` object `

  - ` success `: type ` boolean `

    - example: ` true `

  - ` message `: type ` string ` — Success message

### ` 400 ` — Bad Request - Missing required fields or invalid format

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` success `, ` error `

  - ` success `: type ` boolean `

    - example: ` false `

  - ` error `: type ` string ` — Error message describing what went wrong

### ` 403 ` — Forbidden - Invalid signature

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` success `, ` error `

  - ` success `: type ` boolean `

    - example: ` false `

  - ` error `: type ` string ` — Error message describing what went wrong

### ` 409 ` — Conflict - Referrer already exists

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` success `, ` error `

  - ` success `: type ` boolean `

    - example: ` false `

  - ` error `: type ` string ` — Error message describing what went wrong

## Request examples

### cURL

```curl
curl -X POST 'https://createkit.b3.fun/referrers' \
  -H 'Content-Type: application/json' \
  -d '{
  "referrer_id": "string",
  "wallet_address": "string",
  "message": "string",
  "signature": "string"
}'
```

### JavaScript

```javascript
const response = await fetch('https://createkit.b3.fun/referrers', {
  method: 'POST',
  headers: {
      "Content-Type": "application/json"
  },
  body: JSON.stringify({
    "referrer_id": "string",
    "wallet_address": "string",
    "message": "string",
    "signature": "string"
  })
});

const data = await response.json();
console.log(data);
```

### Python

```python
import requests

response = requests.post('https://createkit.b3.fun/referrers', json={
  "referrer_id": "string",
  "wallet_address": "string",
  "message": "string",
  "signature": "string"
})
print(response.json())
```