# Dagon Inference > Uncensored LLM API for AI agents and developers: any OpenAI or Anthropic SDK, pay per request in USDC on Solana with x402, no account and no SOL needed. Signed receipts. ## For agents: how to pay An agent can buy its own inference, no browser or email. In order of preference: 1. **x402 pay per request** (no key, no setup; USDC on Solana, network fee paid by us, $0.5 to $1,000 a payment). POST the request with no key, get 402 with `accepts`, retry with the signed payment in `X-PAYMENT` or `PAYMENT-SIGNATURE`; keep the key from `x-dagon-key`. Guide: https://inference.dagon.so/x402-llm-api `const res = await wrapFetchWithPaymentFromConfig(fetch, { schemes: [{ network: "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp", client: new ExactSvmScheme(toClientSvmSigner(signer)) }] })("https://inference.dagon.so/v1/chat/completions", { method: "POST", headers: { "content-type": "application/json" }, body })` (@x402/fetch, @x402/svm) 2. **Wallet top-up in two calls** (needs a gk_ key: `curl -X POST https://inference.dagon.so/v1/keys`). Details below and at https://inference.dagon.so/buy-llm-credits-from-an-agent-wallet `curl https://inference.dagon.so/v1/credits/purchase -H "Authorization: Bearer $DAGON_KEY" -H "Content-Type: application/json" -d '{"amount_usd": 20, "payer_wallet": "", "chain": "solana"}'` then sign and send `unsigned_transaction`, then `POST /v1/credits/purchase/confirm {"purchase_id", "signature"}` 3. **MCP server** (local stdio, in the gateway repository's `mcp/` folder, not on npm): tools for models, balance, keys, wallet purchases and chat. `claude mcp add dagon --env DAGON_API_KEY=gk_... -- node /path/to/dagon-inference/mcp/src/index.ts` All three: Solana mainnet USDC to the treasury `9rMdbu4KdLWH2nPXbzhm9HTKaibGZ2ckakQbW1wPh6KK` (check it at https://inference.dagon.so/official); paying wallets are screened against the OFAC SDN list (403 `payment_refused`) and some locations are blocked (451 `location_blocked`); at most $2,000 of paid credit per key in 24 hours. ## About Dagon Inference is a metered gateway in front of upstream model providers: abliteration.ai, Refuseless and Experiential Labs. Each request goes to the cheapest healthy provider serving its model id, with fallback before any output. It is not affiliated with OpenAI, Anthropic or those providers. It is operated by Inkwell Finance, Inc. d/b/a Dagon. - Base URL for OpenAI SDKs: `https://inference.dagon.so/v1`; for Anthropic SDKs: `https://inference.dagon.so` - Auth: `Authorization: Bearer ` (gk_ prepaid key or lk_ private lease key) - Live models and prices (canonical, no key needed): https://inference.dagon.so/v1/models - Snapshot of this table: https://inference.dagon.so/models.json (JSON, documented schema) and https://inference.dagon.so/models.md - OpenAPI 3.1: https://inference.dagon.so/openapi.json ## Buy credits from an agent (wallet) An agent with a Solana wallet funds its own gk_ key in USDC with no browser and no email (guide with TypeScript and Python scripts: https://inference.dagon.so/buy-llm-credits-from-an-agent-wallet): 1. `POST https://inference.dagon.so/v1/credits/purchase` with `Authorization: Bearer ` and `{"amount_usd": 20, "payer_wallet": "", "chain": "solana"}` ($5 to $1,000, whole cents). Returns `purchase_id`, `amount_total`, `currency` ("usdc"), `unsigned_transaction` (base64), `blockhash`, `last_valid_block_height`, `fee_sponsored`, `expires_at`, `confirm_url`. 2. Deserialize `unsigned_transaction` (@solana/web3.js `VersionedTransaction.deserialize`), sign it with the wallet, send it (`sendRawTransaction`) and confirm it. The blockhash expires about a minute after step 1; if it does, repeat step 1. 3. `POST https://inference.dagon.so/v1/credits/purchase/confirm` with `{"purchase_id", "signature"}`. 200 `{"status": "credited", "credited_usd", "balance"}` once the payment is final (the call can take up to about 45 s); 202 `{"status": "pending"}` means call it again after `retry_after_s`. `GET https://inference.dagon.so/v1/credits/purchase/{purchase_id}` reads the status. When `fee_sponsored` is true the transaction is already signed by the payment service's fee payer, which pays the network fee and any account rent: keep that signature (sign with the wallet only) and the wallet needs no SOL, only the USDC. When false, the wallet pays the network fee in SOL. Errors: 400 `invalid_wallet`, 403 `payment_refused` (sanctioned wallet), 451 `location_blocked`. ## Models and prices USD per 1M tokens, 10% markup included (15% in total on private leases). Build snapshot at price version 2026-11-02.2, as of 2026-11-02. Prices follow the providers and may have changed since; the live prices and current price version are at https://inference.dagon.so/v1/models (no key needed). | Model id | Model | Input | Cached input | Output | Context | Max output | Providers | | --- | --- | --- | --- | --- | --- | --- | --- | | `abliterated-model-large-v2` | [Abliterated Large v2](https://inference.dagon.so/models/abliterated-model-large-v2) | $1.10 | $0.165 | $2.20 | 1,048,576 | 65,536 | abliteration.ai, Refuseless, Experiential Labs | | `deepseek-v4.1-flash-abliterated` | [DeepSeek V4.1 Flash Abliterated](https://inference.dagon.so/models/deepseek-v4.1-flash-abliterated) | $0.132 | $0.0275 | $0.495 | 1,048,576 | 65,536 | Refuseless, Experiential Labs | | `glm-5.3-flash-abliterated` | [GLM-5.3 Flash Abliterated](https://inference.dagon.so/models/glm-5.3-flash-abliterated) | $0.132 | $0.044 | $0.55 | 1,048,576 | 65,536 | Refuseless, Experiential Labs | | `abliterated-model-large-flash` | [Abliterated Large Flash](https://inference.dagon.so/models/abliterated-model-large-flash) | $1.10 | $0.11 | $2.20 | 1,048,576 | 65,536 | abliteration.ai | | `abliterated-model` | [Abliterated Model](https://inference.dagon.so/models/abliterated-model) | $1.10 | $0.11 | $3.30 | 262,144 | 65,536 | abliteration.ai | Each model is priced at the cheapest provider serving it plus the markup. A request that falls back to another provider is billed at that provider's rate plus the markup; its signed receipt names the provider and the price version. Billing is in whole millionths of a dollar, rounded up once per request. ## Quick start ```sh # 1. Create a key (no email, no password); save the "key" field, it is shown once curl -X POST https://inference.dagon.so/v1/keys # 2. Fund it in USDC: returns a hosted checkout link curl https://inference.dagon.so/v1/credits/checkout -H "Authorization: Bearer $DAGON_KEY" -H "Content-Type: application/json" -d '{"amount_usd": 20}' # 3. Call a model curl https://inference.dagon.so/v1/chat/completions \ -H "Authorization: Bearer $DAGON_KEY" \ -H "Content-Type: application/json" \ -d '{"model": "abliterated-model-large-flash", "messages": [{"role": "user", "content": "Hello"}]}' ``` ## Use it - OpenAI SDKs: base URL `https://inference.dagon.so/v1` (Chat Completions at /v1/chat/completions, Responses at /v1/responses) - Anthropic SDKs: base URL `https://inference.dagon.so` (Messages at /v1/messages) - Auth: `Authorization: Bearer ` with a gk_ prepaid key or an lk_ private lease key - Create a key: `curl -X POST https://inference.dagon.so/v1/keys` (no email, no password) - Fund it in USDC: `POST https://inference.dagon.so/v1/credits/checkout {"amount_usd": 20}` returns a hosted checkout link ($5 to $1,000 per top up) - Official domains and payment addresses, to check a checkout before you pay: https://inference.dagon.so/official - No key yet? Pay per request with x402: see "Pay per request (x402)" below - Each model's endpoints are listed in /v1/models; not every provider serves Responses or Messages - Web console: https://inference.dagon.so/app/ - API description: https://inference.dagon.so/openapi.json (also linked from https://inference.dagon.so/.well-known/api-catalog) ## Pay per request (x402) The inference routes (/v1/chat/completions, /v1/responses, /v1/messages) speak [x402](https://x402.org), versions 1 and 2, `exact` scheme, USDC on Solana mainnet. No account, no checkout page: an agent with a Solana wallet holding USDC can pay with the request. 1. Send the request without a key. The answer is HTTP 402. Its JSON body keeps the usual `error` object (code `payment_required`) and adds the x402 v1 `PaymentRequired` fields `x402Version` and `accepts`; the `PAYMENT-REQUIRED` header carries the same requirements as x402 v2 (base64 JSON). `network`: `solana` (v1) / `solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp` (v2); `asset`: USDC `EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v`; `payTo`: the treasury `9rMdbu4KdLWH2nPXbzhm9HTKaibGZ2ckakQbW1wPh6KK` (its USDC account `E6dUxbCSJ3ygHSuT5DrjLDJediPzHiKQy2nJHb115nfg`); `maxAmountRequired` / `amount`: this request's maximum cost in USDC base units (micro-USD), at least $0.5; `extra.feePayer`: the gateway's fee payer when it sponsors network fees. 2. Sign a transaction that transfers that amount with SPL Token `TransferChecked` from your own USDC account (your associated token account) to the treasury's, with `extra.feePayer` as fee payer, and do not broadcast it. Compute budget, memo and wallet-injected Lighthouse instructions are allowed; other programs and address lookup tables are not. Without `extra.feePayer`, be your own fee payer and sign fully. 3. Retry the same request with the base64 payment payload in `X-PAYMENT` (v1) or `PAYMENT-SIGNATURE` (v2). The gateway checks the transaction, screens the paying wallet against the OFAC SDN list, refuses blocked locations, co-signs as fee payer, broadcasts and waits for confirmation, then serves the request. 4. The response carries `X-PAYMENT-RESPONSE` / `PAYMENT-RESPONSE` (base64 JSON with the transaction signature) and `x-dagon-key`: a new gk_ prepaid key holding the payment minus this request's cost. Use it as `Authorization: Bearer` for the next requests; pay again when it runs out. With a key whose balance is too low, the 402 (code `insufficient_credits`) asks for a top-up of at least $1 or the shortfall; paying it with the key in `Authorization` credits that key. A transaction is credited once: a replay gets 402 `duplicate_settlement`. If confirmation takes too long the answer is 402 `settlement_pending` with `x-dagon-key`; retry the same request with that key and the same payment header. Clients: `@x402/fetch` or `@x402/axios` with `ExactSvmScheme` from `@x402/svm` and a Solana signer (network `solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp`), or the v1 packages `x402-fetch` / `x402-axios` with `createSigner("solana", privateKey)` (raise their default maximum payment for large requests). Read `x-dagon-key` from the first paid response and keep it. ## Questions ### What is Dagon Inference? A metered endpoint in front of abliteration.ai, Refuseless and Experiential Labs. You call it with an OpenAI or Anthropic SDK; it forwards each request to the cheapest healthy provider serving that model id, falls back to the next cheapest if that provider fails before any output, meters every token and charges your key the routed provider's price plus the markup, based on the usage the upstream reports. When none is reported, we charge an estimate or the reserved maximum. ### Which uncensored models does Dagon Inference serve? Abliterated Large v2 (abliterated-model-large-v2): $1.10 input, $2.20 output per 1M tokens; DeepSeek V4.1 Flash Abliterated (deepseek-v4.1-flash-abliterated): $0.132 input, $0.495 output per 1M tokens; GLM-5.3 Flash Abliterated (glm-5.3-flash-abliterated): $0.132 input, $0.55 output per 1M tokens; Abliterated Large Flash (abliterated-model-large-flash): $1.10 input, $2.20 output per 1M tokens; Abliterated Model (abliterated-model): $1.10 input, $3.30 output per 1M tokens. All are abliterated builds with refusal behavior reduced or removed. Prices include the 10% markup; the live list is GET /v1/models. ### What if I lose my API key? We do not recover it, transfer its balance or refund it, because we store only a hash of each key and cannot verify who owns one. Save the key in a password manager when you create it. If you sign in with a passkey instead, a lost key is easy to replace: delete it, the balance returns to your account, and you mint another. Wallet login can keep your keys in an encrypted vault, but a key you never saved there cannot be restored. ### Can I sign in with a passkey and give keys to my agents? Yes. Continue with a passkey in the console: it works with 1Password, Windows Hello, iCloud Keychain and security keys, and we store only its public key, no email and no vault. Your balance sits on your account, and you mint separate keys for each agent or teammate, fund each one with what it needs, take the money back, or delete a key. Keys under one account can be linked to each other. ### Do I need to sign up? No. One request creates a prepaid key, with no email and no password, and you fund it with USDC through hosted checkout, $5 to $1,000 at a time. A private lease from a zkAPI server needs no key creation at all. ### How do I know a checkout page is really yours? Our checkout runs only at https://pay.dagon.so, and you reach it only from a top up you start in the console or with POST /v1/credits/checkout. It asks your wallet for exactly the amount you chose, paid to our treasury on Solana or through Circle's CCTP contract from another chain, and a Solana payment expires about a minute after the checkout prepares it. Our domains and the treasury, relayer and contract addresses are listed at https://inference.dagon.so/official; check them in full before you approve. We never ask you to pay by direct message, ad or a link we did not generate. ### What does one request cost? The model's token rates plus 10% (15% on private leases, which also pay for the SOL to USDC swap), in whole millionths of a dollar, rounded up once per request. The worked example on this page, 1,200 characters to Large Flash with 238 tokens back, costs 724 ยต$, about $0.0007. ### Why hold more than a request costs? So two requests can never spend the same balance. The hold covers the prompt estimate plus your output cap (16,384 tokens unless you set one, 65,536 at most), and the unused part returns the moment the upstream reports usage. ### What if my stream drops halfway? You pay for the estimated prompt plus the text that was streamed before you left, at one token per three characters. If the upstream fails or is unreachable before it accepts the request, or reports an error before any output, the charge is zero. If usage is not reported or a request is cut off, you pay an estimate, which can be higher than the real cost. ### Do you store prompts or outputs? The gateway does not store or log them: they pass through memory to the provider that serves the request (abliteration.ai, Refuseless or Experiential Labs). The database keeps keys, holds, credits and receipts (ids, token counts, prices, a hash of the output). The gateway sees content, and your IP address, in transit; that provider sees content and timing. abliteration.ai states that it does not store prompts or completions by default; Refuseless may pass requests to third-party providers it chooses, which it says generally operate under zero data retention; Experiential Labs says its models are not zero retention. We cannot verify or control any of that. ### How do I check a receipt? Every response carries a receipt id. Fetch the receipt, verify its Ed25519 signature against the key at /v1/identity, and recompute the charge from the published rates. POST /v1/receipts/verify does all three for you. ### Why is web search refused? Upstream providers bill searches separately from tokens, and a token meter cannot see that cost. Rather than guess, the gateway answers 400 web_search_not_supported before anything is held or sent. ### Can an AI agent pay for API calls itself? Yes, three ways, none needing a browser or an email. With x402 the agent sends the request with no key, gets a 402 with the price, and retries with a signed USDC transfer on Solana; the answer comes back with a prepaid key for later requests. With a key, it can top up from its own wallet in two calls: POST /v1/credits/purchase returns a USDC transaction to sign and send, and POST /v1/credits/purchase/confirm credits the key. Or it can use the local MCP server, which wraps keys, purchases and chat as tools. ### What is x402 and do you support it? x402 is an open protocol that uses HTTP status 402 Payment Required to let a client pay for a request inside the request. We support x402 versions 1 and 2, exact scheme, USDC on Solana mainnet, on /v1/chat/completions, /v1/responses and /v1/messages. The 402 body carries the v1 requirements (x402Version, accepts) next to the usual error object, the PAYMENT-REQUIRED header carries v2, and the retry sends the payment in X-PAYMENT or PAYMENT-SIGNATURE. A keyless request pays its maximum cost, at least $0.5; one payment is at most $1,000, and a key receives at most $2,000 of paid credit a day. Guide: https://inference.dagon.so/x402-llm-api ### Does my agent need SOL? No. For x402 the 402 names the gateway's fee payer in extra.feePayer; the agent signs only the USDC transfer and the gateway pays the network fee. Wallet purchases are fee sponsored the same way when the response says fee_sponsored: true. The wallet needs only USDC in its own USDC account. ### Is there an MCP server? Yes, a local stdio MCP server in the mcp/ folder of the gateway repository, for Claude Desktop, Claude Code and other MCP clients. Its tools list models, check a balance, create a key, buy credits with Solana USDC (signing with a wallet you configure, or returning the transaction for you to sign) and chat. It is not published to npm; run it from a checkout with Node 22.18 or newer. ## Model pages - [Abliterated Large v2](https://inference.dagon.so/models/abliterated-model-large-v2): Abliterated Large v2 (abliterated-model-large-v2) on Dagon Inference: $1.10 input, $0.165 cached input, $2.20 output per 1M tokens, 1,048,576 token context, 3 providers. OpenAI compatible, paid in USDC. - [DeepSeek V4.1 Flash Abliterated](https://inference.dagon.so/models/deepseek-v4.1-flash-abliterated): DeepSeek V4.1 Flash Abliterated (deepseek-v4.1-flash-abliterated) on Dagon Inference: $0.132 input, $0.0275 cached input, $0.495 output per 1M tokens, 1,048,576 token context, 2 providers. OpenAI compatible, paid in USDC. - [GLM-5.3 Flash Abliterated](https://inference.dagon.so/models/glm-5.3-flash-abliterated): GLM-5.3 Flash Abliterated (glm-5.3-flash-abliterated) on Dagon Inference: $0.132 input, $0.044 cached input, $0.55 output per 1M tokens, 1,048,576 token context, 2 providers. OpenAI compatible, paid in USDC. - [Abliterated Large Flash](https://inference.dagon.so/models/abliterated-model-large-flash): Abliterated Large Flash (abliterated-model-large-flash) on Dagon Inference: $1.10 input, $0.11 cached input, $2.20 output per 1M tokens, 1,048,576 token context, 1 provider. OpenAI compatible, paid in USDC. - [Abliterated Model](https://inference.dagon.so/models/abliterated-model): Abliterated Model (abliterated-model) on Dagon Inference: $1.10 input, $0.11 cached input, $3.30 output per 1M tokens, 262,144 token context, 1 provider. OpenAI compatible, paid in USDC. ## Guides - [An uncensored LLM API for cybersecurity research](https://inference.dagon.so/cybersecurity-llm-api): An LLM API for security work: abliterated models with refusal behavior removed, for reverse engineering, vulnerability triage and authorized testing, paid per token in USDC. No prompt logging by the gateway. - [Audit smart contracts with an uncensored LLM](https://inference.dagon.so/smart-contract-audit-llm): Use an LLM to audit Solidity and Solana programs: long context, refusal behavior reduced or removed, paid per token in USDC with signed receipts. For your own code or code in audit scope. - [Pay for an LLM API with USDC](https://inference.dagon.so/pay-for-llm-api-with-usdc): Pay for LLM API access in USDC. Create a key with one request, top up from $5, and every request is metered and receipted. Private leases separate payment from usage. - [A private LLM API with zkAPI leases](https://inference.dagon.so/private-llm-api-zkapi): Use an LLM API that separates payment from usage. Private zkAPI leases fund a spend limited key without telling the gateway which deposit paid for it. - [Use an uncensored LLM with the OpenAI SDK](https://inference.dagon.so/uncensored-llm-openai-sdk): Point the OpenAI or Anthropic SDK at an uncensored LLM API by changing one line. Copy and paste code for Node, Python and curl, with model ids and pricing. - [Abliterated LLM API pricing](https://inference.dagon.so/abliterated-llm-pricing): Pricing for abliterated LLMs per 1M tokens: input, cached input and output, the serving provider's price plus 10%. One worked example, billed in USDC with signed receipts. - [Buy credits from an agent (wallet)](https://inference.dagon.so/buy-llm-credits-from-an-agent-wallet): An agent tops up its own Dagon Inference key in USDC from a Solana wallet with three HTTP calls and no browser or email. Copy and paste TypeScript and Python scripts. - [Pay-per-request LLM API with x402 (USDC on Solana)](https://inference.dagon.so/x402-llm-api): x402 LLM API: an AI agent pays for each request in USDC on Solana, with no account and no API key. Uncensored models over OpenAI and Anthropic endpoints, network fee sponsored, from $0.5. Full text of every guide: https://inference.dagon.so/llms-full.txt