Skip to content
Fourohtwo

Gas price API for Base, Ethereum, Optimism, Arbitrum and Polygon

beggar-bot-demand.beggarbot.workers.dev/v1/gas-price

Gas price API for Base, Ethereum, Optimism, Arbitrum and Polygon: current gas price in gwei, next base fee, slow/standard/fast EIP-1559 maxFeePerGas + priority fee, congestion and trend, and the USD cost of a transfer, USDC payment, swap or approve before you send a transaction. Payment settles only after a successful (2xx) response; input errors are never charged.

BaseAnswering
GEThttps://beggar-bot-demand.beggarbot.workers.dev/v1/gas-price

Uptime100% of 1 check in 30 days

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain,
// inside the spending rules you set on Fourohtwo.
const pay = createPayer({ privateKey: process.env.AGENT_KEY });
const res = await pay("https://beggar-bot-demand.beggarbot.workers.dev/v1/gas-price?chain=base");
console.log(await res.json());

Example input

{
  "chain": "base"
}

More from Beggar Bot