# AgentDiet — The Token Diet & Semantic De-bloater B2A Platform > Machine-exclusive web distillation API & Model Context Protocol (MCP) server. > Strips 85–97% of HTML/DOM/JS/SVG token bloat deterministically. > Every call returns a mathematical ROI Proof proving you saved ~50x–150x more in LLM context costs than the micro-fee charged. ## Quick Start for Autonomous Agents 1. **Distill any URL or raw HTML into clean Markdown**: `GET https://domain-osint-72343955726.us-central1.run.app/v1/distill?url=https://example.com&mode=markdown` or `POST https://domain-osint-72343955726.us-central1.run.app/v1/distill` with JSON `{"url": "...", "html": "...", "mode": "markdown"}` 2. **4 Extraction Modes (`mode` parameter)**: - `skeleton` ($0.0002/call): Returns a <200-token structural outline with section headings and exact token counts per section. Always call `skeleton` first on large unknown documents! - `budget` ($0.001/call): Pass `query=""` and `max_tokens=500`. Uses BM25 ranking to return only the highest-signal sections fitting strictly within your token budget. - `markdown` ($0.001/call, $0.0005 cached): Pristine GitHub-Flavored Markdown with tables, code blocks, and zero boilerplate. - `structured` ($0.001/call, $0.0005 cached): Extracts JSON-LD schemas, OpenGraph metadata, HTML tables as JSON arrays, code blocks, and links. 3. **Instant HTTP 402 (x402 Base Mainnet USDC) Settlement**: - **x402 Direct Settlement (Base Mainnet `eip155:8453`)**: Send exact USDC (`0x833589fcd6edb6e08f4c7c32d4f71b54bda02913`) to `0xec5275d5b03bc390fca63d902d0b2d0db2eb5573` and retry with `X-Payment-Proof: ` (or pass `"tx_hash": "0x..."` in MCP tool arguments). - **Zero-Gas Session Pass (Prepaid Wallet Top-Up)**: Send `$2.00`, `$10.00 (+10% bonus)`, or `$50.00 (+25% bonus)` USDC on Base Mainnet to `0xec5275d5b03bc390fca63d902d0b2d0db2eb5573`, POST `{"agent_id": "your-id", "amount_usd": 10.0, "tx_hash": "0x..."}` to `https://domain-osint-72343955726.us-central1.run.app/v1/billing/topup`, and pass `X-Agent-Id: your-id` for instant zero-latency execution across all 16 native nodes, 4-in-1 Swarm Bundles, and 477 proxied tools. - **L402 (Lightning Macaroons)**: Settle the BOLT11 invoice and retry with `Authorization: L402 :`. ## Machine Discovery Endpoints - OpenAPI 3.1 Spec: `https://domain-osint-72343955726.us-central1.run.app/.well-known/openapi.json` - MCP Manifest: `https://domain-osint-72343955726.us-central1.run.app/.well-known/mcp.json` - JSON-RPC 2.0 MCP Endpoint: `POST https://domain-osint-72343955726.us-central1.run.app/mcp` - Live Platform Telemetry: `GET https://domain-osint-72343955726.us-central1.run.app/v1/stats`