Dagon Inference

io.github.inkwell-finance由 GitHub 帳號 inkwell-finance 發布v0.1.0更新於 Nov 11, 2026

Uncensored LLM inference: list models, chat, create keys, buy credits with Solana USDC.

已驗證Streamable HTTP可網頁執行金融AI 與機器學習

概覽

AI 產生的概覽

讓助理接入 Dagon Inference 的無審查開放權重模型:列出模型、對話、建立帳戶金鑰,並以 Solana USDC 購買額度。

可以做什麼
  • 列出可用模型與其價格
  • 查詢帳戶額度、用量與可用美元餘額
  • 建立新的 Dagon 帳戶金鑰(僅顯示一次)
  • 以 Solana USDC 購買額度:可回傳未簽章交易交由自有錢包簽署,或以已設定的錢包簽署
  • 確認自行送出或自行簽署的購買
  • 對指定模型執行一次非串流對話完成
適用情境
適合希望助理在 MCP 用戶端直接呼叫 Dagon 開放權重模型,或不必離開對話就能查看餘額、加值額度的情境。主要面向已用 Solana USDC 支付推論費用的使用者。
執行需求
可透過 npx 在本機執行(需 Node 22.18 以上),也可作為遠端端點使用。餘額、購買與對話需要 DAGON_API_KEY(或 Authorization 標頭);購買另需 DAGON_TREASURY_WALLET。選用的 DAGON_WALLET_SECRET_KEY 用於自行簽署購買,DAGON_SOLANA_RPC_URL 用於送出非代付交易。需要連線至閘道與 Solana RPC 的網路。
安裝前請注意
購買會花費真實資金:USDC 額度及可能的 SOL 手續費,受 DAGON_MAX_PURCHASE_USD、單次工作階段、每日上限與 DAGON_MAX_SOL_FEES 限制。DAGON_WALLET_SECRET_KEY 是 Solana 私鑰,請使用只存放預計支出金額的專用熱錢包。DAGON_TREASURY_WALLET 應取自 README 或官網,不要取自工具回傳結果。購買一律記入已設定的 DAGON_API_KEY。用戶端工具逾時建議至少 90 秒。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Dagon Inference,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.inkwell-finance%2Fdagon-mcp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "dagon-inference": {
      "type": "http",
      "url": "https://inference.dagon.so/mcp"
    }
  }
}

README

Dagon Inference MCP server

A stdio Model Context Protocol server for Dagon Inference: list models, check a balance, create keys, buy credits with USDC on Solana, and chat.

[npm] MIT licensed.

Dagon Inference serves uncensored (abliterated) open-weight LLMs through an OpenAI-compatible API, paid with USDC on Solana. This server lets an MCP client (Claude Desktop, Claude Code, Cursor, ...) use it directly. Needs Node 22.18 or newer; no install step:

sh
npx -y dagon-mcp

Get an account key with the dagon_create_key tool or at https://inference.dagon.so.

No MCP client? An agent can pay per request with x402 instead: send the request with no key, sign the USDC transfer the 402 asks for, retry, and keep the key returned in x-dagon-key. No key, no SOL, no install beyond an x402 client such as @x402/fetch with @x402/svm. This server does not pay with x402; it uses keys and the wallet purchase below.

Tools

ToolWhat it doesKey
dagon_modelsGET /v1/models: models and prices.no
dagon_balanceGET /v1/credits: credits, usage and available balance in USD.yes
dagon_create_keyPOST /v1/keys: creates an account key, shown once.no
dagon_buy_credits{ amount_usd, chain: "solana", payer_wallet? }: buys credits with Solana USDC.yes
dagon_confirm_purchase{ purchase_id, signature } for a payment you submitted yourself, or { purchase_id, signed_transaction } for a fee-sponsored one you signed but did not submit: credits it.yes
dagon_chat{ model, prompt or messages, system?, max_tokens?, temperature? }: one non-streaming chat completion.yes

Balance and chat use DAGON_API_KEY by default and accept an api_key argument. Purchases and confirmations never accept an account override: they always use the server's configured DAGON_API_KEY, so a tool caller cannot redirect a configured wallet's payment to another account.

Buying credits

dagon_buy_credits calls POST /v1/credits/purchase, then POST /v1/credits/purchase/confirm (guide).

Before any gateway call, the amount must be at least DAGON_MIN_PURCHASE_USD (default $1), within DAGON_MAX_PURCHASE_USD (per call, default $50), together with purchases this server process has already prepared within DAGON_MAX_PURCHASE_USD_PER_SESSION (default $200), and together with everything prepared today (UTC) by any server process sharing the spend ledger within DAGON_MAX_PURCHASE_USD_PER_DAY (default $200). Requests outside these limits fail with a tool error and create nothing. Purchases the gateway did not create do not count. The session total resets when the MCP server restarts; the daily total does not, because it is kept in DAGON_SPEND_LEDGER (default %APPDATA%\dagon-mcp\spend-ledger.json on Windows, $XDG_CONFIG_HOME/dagon-mcp/spend-ledger.json or ~/.config/dagon-mcp/spend-ledger.json elsewhere; written with mode 0600 where supported). An unreadable or corrupt ledger refuses purchases. DAGON_TREASURY_WALLET is required for every purchase, with or without a wallet.

When the gateway does not sponsor the network fee, the payer's worst-case SOL cost (5,000 lamports per signature, the compute-budget priority fee, and 0.00203928 SOL rent whenever the transaction creates the treasury's USDC account) is counted against DAGON_MAX_SOL_FEES per UTC day (default 0.05 SOL) in the same ledger; a purchase that would exceed it is refused unsigned. An invalid limit stops the server at startup.

  • DAGON_WALLET_SECRET_KEY set: DAGON_API_KEY and DAGON_TREASURY_WALLET are also required. The server first proves that the returned transaction (legacy or v0 message) is exactly the payment the payment service builds: one USDC TransferChecked of the requested amount from the configured wallet's associated token account to the configured treasury's associated token account, one SPL Memo whose data is the purchase_id, and at most one idempotent creation of the treasury's USDC account whose rent is paid by the fee payer. It rejects mismatched response metadata, amounts, mint, token program, destination, memo, blockhash, fee-payer or signer roles, lookup tables, duplicate keys, unrelated instructions, accounts or writable authorities; a sponsor fee payer may appear in no instruction except as that rent payer. Only bounded Solana compute-budget instructions may also accompany the transfer. After validation it signs as the wallet. A fee-sponsored transaction carries no fee payer signature: the server does not submit it but sends it to the gateway's confirm as signed_transaction, and the payment service adds its fee payer signature and submits it. Otherwise it submits through DAGON_SOLANA_RPC_URL and confirms with the signature. Either way it confirms the purchase for at most 45 seconds; past that it reports the purchase as pending. Once the payment may be on-chain, every result and error names the purchase_id and the transaction signature (or, when fee sponsored, the signed transaction): do not buy again, pass them to dagon_confirm_purchase. The wallet needs the USDC, and SOL for the fee only when the purchase is not fee sponsored. Give the client a tool timeout of at least 90 seconds; cancelling the tool call stops the wait.
  • No wallet: pass payer_wallet. The server runs the same byte-level validation with payer_wallet as payer and transfer authority, and only then returns the unsigned base64 transaction, naming the treasury it pays and the SOL it can cost. A transaction that fails validation is never returned. Sign it with that wallet before it expires, without rebuilding it. When fee_sponsored is true, do not submit it: call dagon_confirm_purchase with purchase_id and signed_transaction (the base64 wallet-signed transaction). Otherwise submit it, then call dagon_confirm_purchase with purchase_id and its signature.

The secret key never leaves the server process and is never echoed, including in errors. At startup the server prints the derived payer address to stderr; check it is the wallet you meant. The trusted treasury address is configured independently rather than accepted from the gateway response. Use a dedicated hot wallet holding only what you intend to spend.

Every gateway and Solana RPC request is aborted after 30 seconds or when the client cancels the tool call, and gateway responses larger than 4 MiB are refused.

Configuration

VariableDefaultPurpose
DAGON_API_KEYnoneAccount key (gk_...) for balance, purchases and chat. Required with DAGON_WALLET_SECRET_KEY; purchases cannot override it.
DAGON_BASE_URLhttps://inference.dagon.soGateway URL. Must be https://; http:// is accepted only for localhost/127.x/[::1].
DAGON_WALLET_SECRET_KEYnoneSolana secret key: 64-byte base58 (Phantom/Solflare export) or JSON byte array (solana-keygen file; a 32-byte seed is accepted only in this form). 32 bytes of base58 is a Solana address and is refused. Enables validated self-signed purchases.
DAGON_TREASURY_WALLETnoneTrusted Solana treasury owner whose USDC associated token account receives purchases. Required for any purchase and with DAGON_WALLET_SECRET_KEY.
DAGON_SOLANA_RPC_URLhttps://api.mainnet-beta.solana.comRPC for submitting signed purchases that are not fee sponsored (the payment service submits sponsored ones).
DAGON_MIN_PURCHASE_USD1Smallest single dagon_buy_credits amount in USD (whole cents).
DAGON_MAX_PURCHASE_USD50Largest single dagon_buy_credits amount in USD (whole cents). 0 disables purchases.
DAGON_MAX_PURCHASE_USD_PER_SESSION200Total USD of purchases one MCP server process may prepare.
DAGON_MAX_PURCHASE_USD_PER_DAY200Total USD of purchases per UTC day, persisted across restarts in the spend ledger.
DAGON_MAX_SOL_FEES0.05Worst-case SOL (fees plus treasury account rent) unsponsored purchases may cost the payer per UTC day.
DAGON_SPEND_LEDGERuser config dir (see above)File holding the daily totals.

Install

Claude Code

sh
claude mcp add dagon --env DAGON_API_KEY=gk_... -- npx -y dagon-mcp

Claude Desktop

Add to claude_desktop_config.json (Settings → Developer → Edit Config); write the values themselves:

json
{  "mcpServers": {    "dagon": {      "command": "npx",      "args": ["-y", "dagon-mcp"],      "env": {        "DAGON_API_KEY": "gk_...",        "DAGON_TREASURY_WALLET": "9rMdbu4KdLWH2nPXbzhm9HTKaibGZ2ckakQbW1wPh6KK"      }    }  }}

On Windows, if npx is not found, use "command": "cmd", "args": ["/c", "npx", "-y", "dagon-mcp"].

Cursor

~/.cursor/mcp.json (global) or .cursor/mcp.json (project):

json
{  "mcpServers": {    "dagon": {      "command": "npx",      "args": ["-y", "dagon-mcp"],      "env": { "DAGON_API_KEY": "gk_..." }    }  }}

Project .mcp.json, omp

Claude Code and omp expand ${VAR} from your environment, so secrets stay out of the file:

json
{  "mcpServers": {    "dagon": {      "command": "npx",      "args": ["-y", "dagon-mcp"],      "env": {        "DAGON_API_KEY": "${DAGON_API_KEY}",        "DAGON_WALLET_SECRET_KEY": "${DAGON_WALLET_SECRET_KEY:-}",        "DAGON_TREASURY_WALLET": "${DAGON_TREASURY_WALLET:-}"      },      "timeout": 120000    }  }}

timeout is omp's per-tool timeout in milliseconds; drop it for clients that do not use it.

Security

  • DAGON_WALLET_SECRET_KEY is optional. Without it the server never signs anything: it returns validated unsigned transactions for you to sign with your own wallet. With it, use a dedicated hot wallet holding only what you intend to spend; the key never leaves the process and is never echoed.
  • DAGON_TREASURY_WALLET is the trust anchor for purchases: every transaction is checked byte-for-byte to pay exactly that treasury, so a compromised or spoofed gateway cannot redirect funds. The published Dagon treasury is 9rMdbu4KdLWH2nPXbzhm9HTKaibGZ2ckakQbW1wPh6KK; take it from this README or https://inference.dagon.so, not from a tool result.
  • Per-call, per-session and per-day USD caps and a daily SOL fee cap bound what any tool caller can spend.
  • Purchases always credit the configured DAGON_API_KEY; a tool caller cannot redirect them to another account.

Development

sh
git clone https://github.com/inkwell-finance/dagon-mcp.gitcd dagon-mcpnpm cinpm run check   # type-checknpm test        # tool tests against a mocked fetch; no networknpm run build   # compile to dist/

License

MIT © Inkwell Finance, Inc. d/b/a Dagon

來源:README.md,提交 b6950f7

工具

0
SourceWeft 尚未讀取此伺服器的工具。

版本歷史

1
  1. v0.1.0最新Nov 11, 2026

評分

已滿足適用檢查項的 85%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具必需15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分