# Velvet DAO DeFi Token Swap

> Velvet DAO DeFi Token Swap is a paid API for AI agents from vu.velvetdao.xyz, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Returns the best swap route and ready-to-sign transaction data for a DeFi token exchange.

## Facts

- Endpoint: POST https://vu.velvetdao.xyz/api/v1/swap_402
- 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/vu-velvetdao-xyz-cd5202e8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_jqjzYc-Mx7xjVsKRBNCKD

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 vu-velvetdao-xyz-cd5202e8 -d '<json body>'
```

Example prompt: Find me the best swap route to exchange 1 ETH for USDC on Base using my wallet 0xAbC123... and give me the ready-to-sign transaction data.

## When to prefer this

Use this endpoint when you need both a swap route recommendation AND a ready-to-sign transaction payload in one call, particularly within the Velvet DAO ecosystem. Ideal for AI agents that need to execute DeFi swaps on behalf of users without building transaction data manually.

## Known failure modes

- Insufficient liquidity for the requested token pair — no route found
- Unsupported chain or token address — 400 error
- Slippage too high for the requested trade size
- Invalid wallet address format
- Payment not received or x402 payment header missing — 402 error
- Network congestion causing stale price data

## How this service works

DeFi token swap: returns best route and ready-to-sign transaction data.

## Output

Returns the optimal DEX route for the requested token swap along with fully constructed, ready-to-sign transaction data including expected output amount, routing path, gas estimates, and on-chain execution payload.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "instruction": {
   "type": "string",
   "description": "Natural-language swap instruction with wallet address"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "answer": "Best route via Uniswap V3: 10 USDC â 0.003 ETH",
  "txdata": {}
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/vu-velvetdao-xyz-cd5202e8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from vu.velvetdao.xyz](https://www.zero.xyz/host/vu.velvetdao.xyz/llms.txt)
