npm xfuel-mcpstdioApache-2.0updated 8d ago
XFuel is the book. This agent spent Y on this job. You hold hub, model, and amount.
Was kannst du mit XFuel machen?
XFuel Protocol
XFuel is the book. This agent spent Y on this job. You hold hub, model, and amount.
POST /v1/chat/completions returns a signed receipt: hub, model, amount, verify_url. Cost-plus, quoted, receipted — pay USDC on Base or Solana. GET|POST /v1/agents/:agent_id/book is possession-gated last-N collected spend. Signed receipt is table stakes (HMAC); SP1 settlement proof is on demand. Live routes today are Theta and Akash. Demo key xfuel-demo skips payment (rate-limited). Register is fail-closed: a collected HMAC-valid receipt plus an AAWP official or smart-account agentWallet.
To learn more about the protocol design, read the whitepaper. For live endpoints and what is real vs mock today, see runtime state. Full documentation hub: docs/.
Live app: https://xfuel.app
Public API: https://api.xfuel.app
Table of Contents
Setup
Prerequisites
Install Node.js 20+ and npm 10+. A Rust toolchain is required if you build CosmWasm, SP1, or zkLLM crates.
Build and test
Clone the repository, install dependencies, compile contracts, and run the test suite:
git clone https://github.com/XFuel-Lab/xfuel-protocol.git
cd xfuel-protocol
npm install
npx hardhat compile
npx hardhat test
Agent gateway
The agent-facing API (routing, payments, proving, receipts) runs from services/gateway:
cd services/gateway
npm install
npm run m2m-server
The gateway listens on http://localhost:3002 by default. Env examples live under services/gateway/. Production layout is documented in runtime state.
Website
cd apps/web
npm install
npm run dev
Try the demo
No account. No API key. A wallet that can pay the 402 is enough. Register is only to hold the book after a collected receipt.
curl.exe -sS -D - -X POST https://api.xfuel.app/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{}'
Unauthenticated /v1 returns HTTP 402 with payment requirements (USDC on Base or Solana). The receipt prices the next call. Demo key xfuel-demo skips payment (rate-limited). Working copy: docs/DESIGN_PARTNER_ONBOARDING.md.
npm install xfuel-sdk
npx xfuel-mcp
flagship-demo.ts is the paid /task-request path (402 without a payer). Do not start there.
- TypeScript SDK — packages/sdk
- MCP server — packages/mcp
- Agent playbook — packages/agent-skills
- Hosted endpoint — docs/HOSTED_TESTNET_ENDPOINT.md
Windows note: if you use raw HTTP, call curl.exe — PowerShell’s curl is not real curl.
API reference: M2M API · OpenAI gateway: docs here · Payments: x402 adapter.
Documentation
| Doc | Description |
|---|---|
| WHITEPAPER.md | Protocol design |
| docs/README.md | Documentation hub |
| docs/RUNTIME_STATE.md | As-deployed state |
| docs/POSITIONING.md | Messaging |
| docs/DEPLOYMENT.md | Deployment |
| docs/TESTING.md | Tests |
| AGENTS.md | Agent / LLM index |
| CONTRIBUTING.md | Contributing |
Security
Responsible disclosure (safe harbour; no cash bounty until the first audit): docs/bug-bounty.md.
Reporting policy: SECURITY.md.
Apache-2.0 — see LICENSE.
Installation
XFuel zu deinem Client hinzufügen. Wähl den, den du nutzt.
claude mcp add xfuel-mcp -- npx -y xfuel-mcpcodex mcp add xfuel-mcp -- npx -y xfuel-mcpamp mcp add xfuel-mcp -- npx -y xfuel-mcp{
"mcpServers": {
"xfuel-mcp": {
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"xfuel-mcp": {
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
code --add-mcp '{"name":"xfuel-mcp","command":"npx","args":["-y","xfuel-mcp"]}'Or add the block manually to `.vscode/mcp.json` under `servers`.
{
"mcpServers": {
"xfuel-mcp": {
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"xfuel-mcp": {
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"xfuel-mcp": {
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"xfuel-mcp": {
"type": "local",
"command": "npx",
"args": [
"-y",
"xfuel-mcp"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"xfuel-mcp": {
"command": {
"path": "npx",
"args": [
"-y",
"xfuel-mcp"
]
}
}
}
}Add to your Zed `settings.json`.
npx -y xfuel-mcpRun `goose configure`, choose **Add Extension → Command-line Extension**, and paste this command.
Score
39 / 100
Unvollständig
- Dokumentation22/25
- Pflege19/25
- Vertrauen13/20
- Funktionsumfang0/15
- Installation12/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 0 days ago
- Has a release history
- Repository is not archived
- Licensed Apache-2.0
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 0 tool(s) documented
- Provides prompt templates
- Provides resources
- 12 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint — no local install
Versionsverlauf
| Versionen | Veröffentlicht |
|---|---|
| 0.1.1Aktuell | 9. Juli 2026 |