> ## Documentation Index
> Fetch the complete documentation index at: https://ti-mm-mycompc.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Pricing and referral discounts for Solana AI Gateway

> Flat per-call pricing in SOL, a free tier for new keys, and referral-based volume discounts up to 55% off for high-volume LLM agents.

Solana AI Gateway uses a flat per-call price in SOL with a generous free tier for new keys and a referral program that unlocks progressively larger discounts as agents you refer start using the gateway.

## Base price

Every paid endpoint costs the same flat rate.

| Item                  | Value                                          |
| --------------------- | ---------------------------------------------- |
| Price per paid call   | **2,200,000 lamports** (0.0022 SOL)            |
| Free tier (lifetime)  | 50 paid-endpoint calls per key                 |
| Free tier (daily cap) | 15 paid-endpoint calls per key per day         |
| Top-up wallet         | `Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU` |

Free-tier calls are consumed first. Once the lifetime limit or daily cap is hit, the gateway debits `2,200,000` lamports from your credit balance per call.

<Tip>
  At 0.0022 SOL per call, **1 SOL funds roughly 454 calls** and **0.1 SOL funds roughly 45 calls** after the free tier is exhausted.
</Tip>

## Referral discounts

Every wallet gets a referral link. When new wallets claim an API key through your link, they count as **leads** on your account. Reaching lead milestones unlocks time-boxed discounts on your own paid calls.

<CardGroup cols={3}>
  <Card title="Tier 1" icon="star">
    **15% off** your next **2,000 calls** <br />Unlocks at **1,100 leads**
  </Card>

  <Card title="Tier 2" icon="star">
    **30% off** your next **2,000 calls** <br />Unlocks at **3,300 leads**
  </Card>

  <Card title="Tier 3" icon="star">
    **55% off** your next **3,500 calls** <br />Unlocks at **5,500 leads**
  </Card>
</CardGroup>

### Effective per-call price at each tier

| Tier   | Discount | Price per call | Total call window |
| ------ | -------- | -------------- | ----------------- |
| Base   | 0%       | 0.00220 SOL    | unlimited         |
| Tier 1 | 15%      | 0.00187 SOL    | 2,000 calls       |
| Tier 2 | 30%      | 0.00154 SOL    | 2,000 calls       |
| Tier 3 | 55%      | 0.00099 SOL    | 3,500 calls       |

### How the tiers progress

<Steps>
  <Step title="Share your referral link">
    Every wallet that has claimed a key gets a unique referral link. Share it in your MCP server description, agent docs, or Discord.
  </Step>

  <Step title="Leads accumulate on your account">
    A lead is counted when a new wallet claims its first API key via your link. Each new wallet counts once, on one referrer's account only.
  </Step>

  <Step title="Milestones unlock discounts">
    Cumulative lead totals unlock each tier. Reaching **1,100** unlocks Tier 1, **3,300** unlocks Tier 2, and **5,500** unlocks Tier 3.
  </Step>

  <Step title="Discounts consume in order">
    Discounted call windows apply to your very next paid calls. When one window empties, the next unlocked window kicks in. If no window is active, you pay the base rate.
  </Step>
</Steps>

<Note>
  Leads are counted per referring wallet, not per API key. Rotating your key does not reset your lead total.
</Note>

## Top up and claim

1. Send SOL to `Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU` from the wallet you want the key tied to.
2. Complete the [claim flow](/guides/claim-api-key) to release your API key.
3. Start calling paid endpoints with `x-api-key: <your-key>`.

## Payment required response

When you run out of both free calls and credit balance, the gateway returns:

```json 402 Payment Required theme={null}
{
  "error": "Payment required",
  "priceLamports": 2200000,
  "instructions": "Pass header 'x-api-key: <key>' with sufficient balance. To top up, send SOL to Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU and claim your key.",
  "payTo": "Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU"
}
```

Top up the same wallet and continue. Existing credits and referral discount windows persist across top-ups.

## Related

<CardGroup cols={2}>
  <Card title="Keys and credits" icon="coins" href="/concepts/api-keys-and-credits">
    How the credit ledger is stored and debited.
  </Card>

  <Card title="Paywall model" icon="lock" href="/concepts/paywall-model">
    Which endpoints are free, which are paid, and how the middleware decides.
  </Card>
</CardGroup>

Solana AI Gateway uses a simple pay-per-call model with a free tier for onboarding and a referral program that rewards you for bringing other agents to the gateway. Pricing is enforced server-side by the `requirePayment` middleware and settled in SOL against your API key's credit balance.

## Base pricing

<CardGroup cols={2}>
  <Card title="Free tier" icon="gift">
    **50 lifetime calls**, capped at **15 per day** on any paid endpoint. Kicks in automatically the first time you use your API key.
  </Card>

  <Card title="Standard rate" icon="coins">
    **0.0022 SOL** (2,200,000 lamports) per paid call after the free tier is exhausted. Debited from your key's credit balance.
  </Card>
</CardGroup>

Public endpoints (`/api/solana/balance`, `/api/solana/blockhash`, `/api/keys/challenge`, `/.well-known/mcp.json`) are always free and do not count against any limit.

### Top-up math

Send SOL to the gateway wallet, then re-claim your key to credit the balance.

| Top-up  | Paid calls unlocked |
| ------- | ------------------- |
| 0.1 SOL | \~45 calls          |
| 0.5 SOL | \~227 calls         |
| 1 SOL   | \~454 calls         |
| 5 SOL   | \~2,272 calls       |

## Referral discounts

Every wallet with an active API key gets a personal referral link. Share it anywhere: X threads, Discord servers, MCP registries, agent frameworks. When someone clicks your link and stays on the site long enough to explore (a real visit, not a bot ping), it counts as a **lead**.

Hit a lead threshold and you unlock a discount on your **next batch of paid calls**.

<Warning>
  **Tiers do not stack, and lead counting pauses during a discounted batch.** While you are spending discounted calls, new referrals do not accrue toward the next tier. The counter only resumes once the batch is fully consumed and you are back at the standard rate.
</Warning>

### The tiers

| Leads referred | Discount    | Applies to            |
| -------------- | ----------- | --------------------- |
| **1,100**      | **15% off** | Next 2,000 paid calls |
| **3,300**      | **30% off** | Next 2,000 paid calls |
| **5,500**      | **55% off** | Next 3,500 paid calls |

### How lead counting works

<Steps>
  <Step title="Earn leads">
    Share your referral link. Each qualified visitor (link click plus meaningful time on site) increments your lead counter.
  </Step>

  <Step title="Hit a threshold">
    When your counter reaches the next tier, a discounted batch is queued against your API key.
  </Step>

  <Step title="Spend the batch">
    Your next paid calls automatically bill at the discounted rate until the batch is fully consumed.
  </Step>

  <Step title="Counter freezes during a batch">
    While you are burning down a discounted batch, new leads do not count toward the next tier. This keeps each tier meaningful and prevents runaway stacking.
  </Step>

  <Step title="Resume counting">
    Once the batch is spent, pricing returns to standard and your lead counter resumes. Reach the next threshold to unlock the next tier.
  </Step>
</Steps>

### Discounted rates at a glance

| Tier                  | Per-call price | Batch cost (SOL) |
| --------------------- | -------------- | ---------------- |
| Standard              | 0.00220 SOL    | —                |
| 15% off (2,000 calls) | 0.00187 SOL    | 3.740 SOL        |
| 30% off (2,000 calls) | 0.00154 SOL    | 3.080 SOL        |
| 55% off (3,500 calls) | 0.00099 SOL    | 3.465 SOL        |

## Worked example

Suppose your agent framework goes viral and you refer 5,500 leads over a month:

1. **Lead 1,100** unlocks *15% off × 2,000 calls*. You burn through them over a week. Lead counter is paused at 1,100 during this window.
2. **Batch ends.** Counter resumes. Between now and lead 3,300, you pay standard rate.
3. **Lead 3,300** unlocks *30% off × 2,000 calls*. Counter pauses again.
4. **Batch ends.** Counter resumes.
5. **Lead 5,500** unlocks *55% off × 3,500 calls*. Cheapest calls on the platform.

## When your balance runs out

Paid endpoints return `402 Payment Required` with the top-up address:

```json 402 response theme={null}
{
  "error": "Payment required",
  "priceLamports": 2200000,
  "instructions": "Pass header 'x-api-key: <key>' with sufficient balance. To top up, send SOL to Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU and claim your key.",
  "payTo": "Brpc8HoPo1d3Uiyo7kbERnjMqwLJJmbWxtwxHxzar6DU"
}
```

Top up the gateway wallet and re-run the [claim flow](/guides/claim-api-key) to add the deposit to your balance.

## Related

<CardGroup cols={2}>
  <Card title="Keys & Credits" icon="key" href="/concepts/api-keys-and-credits">
    How balances, top-ups, and key rotation work under the hood.
  </Card>

  <Card title="Paywall Model" icon="shield" href="/concepts/paywall-model">
    Which endpoints are free, which are paid, and how the middleware decides.
  </Card>
</CardGroup>
