81trust / 100
Base Transaction Context
by MACH Base in Onchain & crypto
x402 APIPassing, checked 3 h ago
Verify an onchain payment or investigate a failed Base transaction in one call with transaction, receipt, success status, confirmations, gas and fee context.
POST https://api.mach.gallery/api/base/transaction-context
Last 30 days
All checks passedSome failedAll failedNot checked
- Uptime
- 100%
- Response time
- 226 ms typical, 226 ms slowest 5%
- Last check
- 3 h ago
- Next check
- any minute now
How to call it
# See the payment challenge (nothing is charged)
curl -i -X POST "https://api.mach.gallery/api/base/transaction-context" \
-H "content-type: application/json" \
-d '{"tx_hash":"0x0000000000000000000000000000000000000000000000000000000000000000"}'import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client().register(
"eip155:8453",
new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? Preflight it first for $0.03:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fapi.mach.gallery%2Fapi%2Fbase%2Ftransaction-context
const res = await pay("https://api.mach.gallery/api/base/transaction-context", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"tx_hash":"0x0000000000000000000000000000000000000000000000000000000000000000"}),
});
console.log(await res.json());Example input
{
"tx_hash": "0x0000000000000000000000000000000000000000000000000000000000000000"
}Example output
{
"block_number": 36000000,
"confirmations": 12,
"effective_gas_price_wei": "1000000",
"fee_wei": "21000000000",
"found": true,
"from": "0x...",
"gas_used": "21000",
"network": "eip155:8453",
"state": "confirmed",
"success": true,
"to": "0x...",
"tx_hash": "0x...",
"value_wei": "0"
}Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 3 h ago | Passed | 402 | 226 ms | $0.008 |