{"uid":"cap_Wk12Nh5dBR4HUk7Fp1UZd","slug":"agentdiet-token-optimizer-db1410a2","name":"AgentDiet Token Optimizer","description":"Deterministic B2A/A2A/MCP/x402/MPP/L402 execution and intelligence node at https://status.agentdiet.dev settling in USDC on Base.","url":"https://status.agentdiet.dev/v1/token-optimizer?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET","POST"],"type":"string"},"queryParams":{"type":"object","properties":{"url":{"type":"string"},"mode":{"type":"string"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"data":{},"status":"ok","roi_proof":{"compression_ratio_pct":91.4}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_8pZSO2r7frUX2sA2V5uSA","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Compresses and distills AI context windows to reduce token usage by up to 85-91% before passing content to LLMs","exampleAgentPrompt":"Can you run this URL through AgentDiet's token optimizer to compress the content before I send it to the LLM — I want to cut down the token count as much as possible using GET mode?","exampleUseCases":[{"title":"Slash LLM inference costs in pipeline","prompt":"My agent keeps hitting token limits and burning through API budget — can you compress this long document URL through AgentDiet so it fits cleanly in the context window before I pass it to GPT-4?"},{"title":"Fit large webpage into context window","prompt":"I need to summarize this long news article but it's way too big for my model's context — can you use AgentDiet to distill it down to the essential tokens first?"},{"title":"Optimize agentic memory before tool call","prompt":"Before my agent calls the next tool, compress the accumulated conversation context using AgentDiet's token optimizer so we stay well under the context limit and keep costs low."}],"resultDescription":"A JSON response containing the compressed/distilled data payload, a status field, and an roi_proof object with a compression_ratio_pct indicating how much the input was reduced (e.g. 91.4% compression).","failureModes":["Missing required 'input' object returns validation error","Invalid or unreachable URL in queryParams.url causes fetch failure","Unsupported HTTP method enum value returns schema rejection","Content already minimal may yield low compression ratio","Payment not settled in USDC on Base results in 402 response"],"whenToPreferThis":"Choose this endpoint when your agent pipeline needs to reduce token consumption before expensive LLM calls, when context windows are near capacity, or when you want to cut inference costs systematically. Particularly suited for A2A and MCP workflows where deterministic token budgeting matters and you want provable compression ratios (roi_proof) rather than heuristic summarization.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-22T12:44:31.393Z","isFirstParty":false,"canonicalSlug":"agentdiet-token-optimizer-db1410a2"}