# Synapse API — StarkNet Gas Estimator

> Synapse API — StarkNet Gas Estimator is a paid API for AI agents from synapse-api-brown.vercel.app, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Estimates gas fees for a transaction on the StarkNet blockchain given sender, recipient, calldata, and value

## Facts

- Endpoint: POST https://synapse-api-brown.vercel.app/api/starknet/gas/estimate
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/synapse-api-starknet-gas-estimator-2ada7dd8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_RYKgEZAiBwzFwKexG5Dil

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability synapse-api-starknet-gas-estimator-2ada7dd8 -d '<json body>'
```

Example prompt: Can you estimate the gas cost for a StarkNet transaction from 0xABC...123 to 0xDEF...456 with calldata 0x1234 and a value of 0?

## When to prefer this

Use this endpoint when you need a quick, pay-per-call gas estimate specifically for StarkNet (a ZK-rollup L2) transactions without setting up your own StarkNet node or RPC provider. Prefer it over generic Ethereum gas estimators when the target chain is StarkNet.

## Known failure modes

- Invalid or malformed address in 'to' or 'from' fields returns an error
- Malformed calldata string causes parsing failure
- StarkNet node unavailability causes a timeout or 503
- Transaction simulation failure if the contract call would revert
- Missing required fields returns a 400 bad request

## How this service works

High-speed API suite for AI processing, web scraping, and smart data utilities across 57+ blockchain networks. Pay-per-call via x402.

## Output

Returns an estimated gas amount (and likely fee in the StarkNet native fee token) required to execute the described transaction on the StarkNet network, allowing the caller to budget fees before broadcasting.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "to": {
   "type": "string"
  },
  "data": {
   "type": "string"
  },
  "from": {
   "type": "string"
  },
  "value": {
   "type": "string"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/synapse-api-starknet-gas-estimator-2ada7dd8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from synapse-api-brown.vercel.app](https://www.zero.xyz/host/synapse-api-brown.vercel.app/llms.txt)
