{"uid":"cap_8ZXWPZqPZqLqs7e-EAVjm","slug":"toolsmith-gas-price-latest-block-68de27ef","name":"Toolsmith Gas Price & Latest Block","description":"Current gas price and latest block for Base or Ethereum mainnet, straight from public RPC. Fresh within 15 seconds. JSON response. $0.002 USDC per call, pay via x402, no API key.","url":"https://toolsmith-api.dassad10.workers.dev/t/crypto/gas","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"],"type":"string"},"queryParams":{"type":"object","required":["chain"],"properties":{"chain":{"enum":["base","ethereum"],"type":"string","description":"Chain to query"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"chain":"base","blockNumber":32456789,"gasPriceWei":"5150000","gasPriceGwei":0.00515}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_r2-S7-38Ml98yrI679tuU","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns the current gas price and latest block number for Base or Ethereum mainnet, fetched live from public RPC nodes and cached for up to 15 seconds.","exampleAgentPrompt":"What's the current gas price and latest block on Base mainnet right now?","exampleUseCases":null,"resultDescription":"A JSON object containing the current gas price (likely in wei or gwei) and the latest block number for the requested chain (either 'base' or 'ethereum'), sourced directly from public RPC and fresh within 15 seconds.","failureModes":["Missing or invalid 'chain' query parameter — returns error since it is required and must be 'base' or 'ethereum'","Payment not completed via x402 protocol — returns 402 Payment Required","Upstream RPC node timeout or unavailability — may return 5xx error","Stale data beyond 15-second cache window if RPC is degraded"],"whenToPreferThis":"Use this endpoint when you need a quick, low-cost, keyless lookup of current gas prices or the latest block number on Ethereum mainnet or Base. Ideal for agents that need to estimate transaction costs, check network congestion, or timestamp actions against chain state without setting up an RPC provider or API key. At $0.002 per call via x402, it's suitable for frequent polling or on-demand checks.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T12:46:55.153Z","isFirstParty":false}