# Beggar Bot V2 Swap Build (Base Mainnet)

> Beggar Bot V2 Swap Build (Base Mainnet) is a paid API for AI agents from beggar-bot-demand.beggarbot.workers.dev, paid per call via x402, $0.02/call, status unknown (last checked 2026-11-23).

Builds a Uniswap V2 swap transaction for execution on Base mainnet, returning calldata or transaction parameters for a token swap.

## Facts

- Endpoint: GET https://beggar-bot-demand.beggarbot.workers.dev/v1/v2swapbuild?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/beggar-bot-v2-swap-build-base-mainnet-40f22902
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_y1yPvQAwHxR9pvv90boSw

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 beggar-bot-v2-swap-build-base-mainnet-40f22902
```

Example prompt: Build me a Uniswap V2 swap transaction on Base mainnet to swap 100 USDC (0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913) for WETH, sending the output to my wallet 0xAbC123...

## When to prefer this

Use this endpoint when you need to programmatically build Uniswap V2 swap transaction data on Base mainnet without running your own node or router logic. Prefer it over manual ABI encoding when you want a quick, pay-per-use service to generate ready-to-sign swap calldata. Best suited for agents that need on-demand swap construction without maintaining DeFi infrastructure.

## Known failure modes

- Invalid or unsupported token address returns an error
- Insufficient liquidity for the requested swap pair
- Network mismatch or unsupported network parameter
- Malformed input parameters result in a 400 error
- Payment not provided or failed x402 micropayment ($0.02 USDC) results in 402 response
- Token pair with no Uniswap V2 pool on Base returns an error

## How this service works

Paid: /v1/verify, /v1/risk, /v1/receipt cost $0.01 USDC per call on Base mainnet via x402 (payTo 0x719227f384b66BFEF00093D6d8d32fA9dC2B40e7); utilities analyze Base mainnet (USDC 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913) by default, network=base-sepolia optional; /v1/receipt/verify and discovery files are free. Operator: Beggar Bot.

## Output

Returns JSON containing the constructed swap transaction parameters such as calldata, target contract address, estimated output amounts, swap route, and gas estimates suitable for signing and broadcasting to Base mainnet.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "properties": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/beggar-bot-v2-swap-build-base-mainnet-40f22902/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from beggar-bot-demand.beggarbot.workers.dev](https://www.zero.xyz/host/beggar-bot-demand.beggarbot.workers.dev/llms.txt)
