# AI Inference Gateway

The first commoditized AI gateway on Hyperliquid, with instant settlement via x402 payments.

Based AI Gateway turns AI inference into a pay-as-you-use commodity. Hold USDC or USDH in your self-custodial wallet and start consuming AI models instantly — no subscriptions, no credit purchases, no KYC required.

Get started at <https://ai.based.one/>.

![Dashboard — account overview and inference usage at a glance](/files/fZ3qecy8JpKeRacZkAjM)

## How It Works

{% stepper %}
{% step %}
**Hold a balance**

Hold **>$1 in USDC or USDH** in your self-custodial wallet, or top up your credit balance with a credit card.
{% endstep %}

{% step %}
**Call the gateway**

Use the built-in Chat interface, or call the API directly with any supported model.
{% endstep %}

{% step %}
**Pay per request**

Your balance is deducted automatically per request. Track spending in real time on the Usage page.
{% endstep %}
{% endstepper %}

Powered by Privy and Hyperliquid. Settlement happens via x402 micro-transactions on-chain.

## Chat

Chat with any supported model directly in your browser — no API key or code required. Select a model, type a message, and start a conversation.

![Chat — talk to any model directly from the dashboard](/files/V5Rv7TgWewVaTY6uIfXp)

Suggested prompts help you get started quickly:

* Create a Based Page for your project
* Write a Python script to call the API
* Ask what models are available
* Deploy a landing page

## API Access

For programmatic access, create API tokens from the dashboard. Use them as Bearer tokens in the Authorization header to call the gateway from your own code or agents.

![API Tokens — create and manage tokens for programmatic access](/files/8Bjm5EIYBfrJfoTToqW4)

The Quick Start section on the API Tokens page provides a ready-to-use `curl` command you can copy and run immediately.

## One Gateway, All Models

Based AI Gateway is a single integration point for all major AI models.

* One API integration for access to all supported models
* Freedom to route, switch, and experiment across providers without rebuilding your stack
* API endpoints compatible with all major AI provider formats

## Why a Gateway on Hyperliquid

Agentic commerce is programmatic payments for goods, services, and commodities via AI. For this to work, two primitives are needed:

1. **Programmatic, per-action settlement** — Hyperliquid provides this with gasless UX, instant finality, and high throughput
2. **Intelligence as a commodity** — Based AI Gateway delivers this with pay-per-use inference

Traditional AI billing is SaaS-based, which works when humans make a few requests per day. It does not work when agents fire off thousands of decisions across multiple models in real time. Based AI Gateway is designed for continuous, high-frequency consumption by both humans and AI agents.

## Billing

Manage your balance and payment methods from the Billing page. Based AI Gateway supports two funding methods:

![Billing — wallet balance, credit balance, and payment methods](/files/1s9fnVxyhyeAhTyun2Xc)

{% tabs %}
{% tab title="On-chain" %}
Deposit USDC or USDH directly from your wallet on HyperLiquid Core L1. You can also withdraw to another address at any time.

**How to deposit:**

1. Transfer USDC / USDH to your wallet on HyperLiquid Core L1
2. Send to your wallet address above using [app.hyperliquid.xyz](https://app.hyperliquid.xyz)
3. Your balance updates in the dashboard
   {% endtab %}

{% tab title="Credit Card" %}
Top up your credit balance with a credit card. All requests are billed against your credit balance when available.

**Auto Top-Up:** Enable automatic top-up to recharge your USDC credit balance when it falls below a threshold — so you never run out mid-workflow.
{% endtab %}
{% endtabs %}

## Usage

Track your API request history and spending in real time. The Usage page shows daily model usage broken down by model, request count, tokens consumed, and cost.

![Usage — daily model usage breakdown and spending](/files/CjvxyRznLYO6fwvsoIP0)

## Agent Mail

Send and receive email at your agents via API. Each agent gets its own mailbox at `@basedmail.ai` — no server or mail infrastructure required.

![Mail — manage agent mailboxes and email](/files/AkzWZPdMv6vOFqblsHnA)

* Create up to 300 mailboxes
* Send and receive programmatically via the API
* Read and compose from the built-in mail client

## Privacy Cloud

Most AI services route your requests through third parties, leaving you uncertain about what is stored, logged, or reused.

For privacy workloads, Based runs open-weight models on a self-hosted GPU cluster with a simple guarantee:

* Requests are **not stored**
* Logs are **not retained**
* **No caches** — raw input in, raw output out

There are no opt-out settings to find. AI inference through Privacy Cloud is not attributable to you.

## Summary

| Feature        | Detail                                       |
| -------------- | -------------------------------------------- |
| Payment        | On-chain (USDC / USDH) or credit card        |
| Settlement     | x402 micro-transactions on Hyperliquid       |
| Billing model  | Pay-per-use, no subscriptions                |
| Models         | All major AI models via one integration      |
| Access         | Browser chat or API tokens                   |
| Agent Mail     | Email mailboxes for agents at @basedmail.ai  |
| Privacy option | Self-hosted GPU cluster, zero data retention |
| KYC            | Not required                                 |

## Get Started

Start using AI inference on Hyperliquid — no KYC, no card required:

<a href="https://ai.based.one/" class="button primary">Launch AI Gateway</a>

{% hint style="info" %}
Pricing, supported models, and mechanics described on this page are subject to change. Visit [ai.based.one](https://ai.based.one/) for the latest details.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://basedapp.gitbook.io/docs/based-ai/ai-inference-gateway.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
