Otto AI · GAS Oracle

by Otto AI

GETBaseSolana

$0.001

per call · USD Coin on Base

Base gas oracle from Otto's own RPC: current base fee (wei+gwei), legacy gas price, and slow/standard/fast EIP-1559 priority-fee tiers (p25/p50/p90 over the last 20 blocks) with a ready-to-sign maxFeePerGas per tier. Unlike the crowded gas shelf it PUBLISHES the formula, so every tier is reproducible from the response. Flat JSON, refreshed every minute. Base gas oracle, gas price, priority fee, EIP-1559, maxFeePerGas. $0.001 per call.

Endpoint

GET https://x402.ottoai.services/gas-oracle

4

Calls / 30d

3

Unique payers / 30d

Sep 8

Last called

exact

Payment scheme

Call this service

TypeScript · @x402/fetch
import { wrapFetchWithPayment } from "@x402/fetch";
import { privateKeyToAccount } from "viem/accounts";

const account = privateKeyToAccount(process.env.PRIVATE_KEY);
const fetchWithPay = wrapFetchWithPayment(fetch, account);

const res = await fetchWithPay("https://x402.ottoai.services/gas-oracle", {
  method: "GET",
});
const data = await res.json();
cURL
curl -X GET \
  "https://x402.ottoai.services/gas-oracle" \
  -H "X-PAYMENT: <signed x402 payment>"

Example response

{
  "data": {
    "baseFeePerGas": {
      "gwei": 0.005,
      "wei": "5000000"
    },
    "chain": "base",
    "chainId": 8453,
    "formula": "priorityFee tiers = mean of the p25/p50/p90 priority-fee tips over the last 20 blocks (eth_feeHistory); suggested maxFeePerGas = baseFeePerGas*2 + tierTip.",
    "gasPrice": {
      "gwei": 0.006,
      "wei": "6000000"
    },
    "generatedAt": "2026-09-01T12:01:00.000Z",
    "priorityFeePerGas": {
      "fast": 0.0025,
      "slow": 0,
      "standard": 0.00025,
      "unit": "gwei"
    },
    "suggested": {
      "fast": {
        "maxFeePerGasGwei": 0.0125,
        "maxFeePerGasWei": "12500000",
        "maxPriorityFeePerGasGwei": 0.0025
      },
      "slow": {
        "maxFeePerGasGwei": 0.01,
        "maxFeePerGasWei": "10000000",
        "maxPriorityFeePerGasGwei": 0
      },
      "standard": {
        "maxFeePerGasGwei": 0.01025,
        "maxFeePerGasWei": "10250000",
        "maxPriorityFeePerGasGwei": 0.00025
      }
    },
    "window": {
      "avgGasUsedRatio": 0.1132,
      "blocks": 20,
      "congestion": "low",
      "oldestBlock": 50738536
    }
  },
  "meta": {
    "degraded": false,
    "generatedAt": "",
    "stalenessSec": 0,
    "validUntil": ""
  },
  "status": "success"
}

Payment details

Pay to0x0e84ddedaae6a779c462c22a59f301ec31b6b808
AssetUSD Coin · 0x833589fcd6edb6e08f4c7c32d4f71b54bda02913
NetworksBase, Solana
Schemesexact

Is this your API?

Pin it to the top of Onchain Data and the homepage with a featured placement.

Get featured →

More from Otto AI & similar services