# POST /api/mcp/data/simulate-chain

> What would the SPY chain look like if the stock rose 2% and IV rose 5 points in 10 days?

Black-Scholes what-if: pass chain rows from /chain, or just a ticker and the server fetches the chain, and get every contract re-priced with new Greeks at your scenario.

- **Family:** Strategies (https://apexvol.com/developers/strategies-api)
- **Plan:** Basic and above. Every call needs `Authorization: Bearer avmcp_<token>`; tokens are issued to paid and trial accounts under Account, then API Access.
- **Units:** sim_price in dollars; sim_dte in days; iv_adjustment in IV percentage points; output prices in dollars, IVs as decimals.
- **Basis:** Re-pricing holds each contract's IV plus the shift and moves spot and time.
- **MCP tools:** `simulate_option_chain`
- **Background:** https://apexvol.com/learn/how-options-pricing-works

## Parameters

| Name | In | Default | Range | Meaning |
|---|---|---|---|---|
| `sim_price` (required) | body |  | dollars | Hypothetical spot. |
| `sim_dte` (required) | body |  | days | Days to expiration in the scenario. |
| `iv_adjustment` | body | 0 | IV points | Shift applied to every IV. |
| `chain` | body |  | rows from /chain | Rows to re-price. |
| `ticker` | body |  | symbol | Fetch the chain when rows are omitted. |
| `expiration` | body | nearest | YYYY-MM-DD | Which expiration to fetch. |
| `strikes_around` | body | 20 | 0 for all | Strikes per side. |

## Request

```bash
curl -X POST "https://apexvol.com/api/mcp/data/simulate-chain" \
     -H "Authorization: Bearer avmcp_YOUR_TOKEN" \
     -H "Content-Type: application/json" \
     -d '{"ticker": "SPY", "sim_price": 785.65, "sim_dte": 10, "iv_adjustment": 5, "strikes_around": 3}'
```

## Response (captured 2026-09-08)

Real response, lists cut to the rows nearest the money. The envelope is `{"success": true, "data": ...}`.

```json
{
  "success": true,
  "data": {
    "chain": [
      {
        "Call Ask": 17.7104,
        "Call Bid": 17.6704,
        "Delta Call": 0.9877,
        "Delta Put": -0.0188,
        "Gamma Call": 0.004,
        "Gamma Put": 0.0053,
        "IV Call": 0.0612,
        "IV Put": 0.0663,
        "IVx Call": 0.1324,
        "IVx Put": 0.0076,
        "Put Ask": 0.0694,
        "Put Bid": 0.0494,
        "Strike": 769.0,
        "Theta Call": -0.112,
        "Theta Put": -0.0179,
        "Vega Call": 0.0414,
        "Vega Put": 0.0599
      },
      {
        "Call Ask": 16.7084,
        "Call Bid": 16.6884,
        "Delta Call": 0.9852,
        "Delta Put": -0.0222,
        "Gamma Call": 0.0048,
        "Gamma Put": 0.0063,
        "IV Call": 0.0596,
        "IV Put": 0.0646,
        "IVx Call": 0.1334,
        "IVx Put": 0.0089,
        "Put Ask": 0.0796,
        "Put Bid": 0.0596,
        "Strike": 770.0,
        "Theta Call": -0.1137,
        "Theta Put": -0.0199,
        "Vega Call": 0.0486,
        "Vega Put": 0.0688
      },
      {
        "Call Ask": 15.7199,
        "Call Bid": 15.6999,
        "Delta Call": 0.9816,
        "Delta Put": -0.0282,
        "Gamma Call": 0.0059,
        "Gamma Put": 0.0078,
        "IV Call": 0.0584,
        "IV Put": 0.0639,
        "IVx Call": 0.1349,
        "IVx Put": 0.0115,
        "Put Ask": 0.1005,
        "Put Bid": 0.0805,
        "Strike": 771.0,
        "Theta Call": -0.116,
        "Theta Put": -0.024,
        "Vega Call": 0.0586,
        "Vega Put": 0.0841
      }
    ],
    "expiration": "2026-09-08",
    "iv_adjustment": 5,
    "sim_dte": 10,
    "sim_price": 785.65
  }
}
```

## Fields

- `chain[].Strike, Call Bid, Call Ask, Put Bid, Put Ask`: Re-priced quotes.
- `chain[].Delta Call, Gamma Call, Theta Call, Vega Call and the put twins`: Re-priced Greeks.
- `sim_price, sim_dte, iv_adjustment, expiration`: The scenario echoed.

## Errors

- `401`: no or revoked token
- `429`: Retry-After seconds
- `400`: missing or malformed body
- Full list: https://apexvol.com/developers/errors

## Ask it in an MCP client

- Re-price the SPY chain at 790 with 10 days left and IV up 5 points.
- What would my NVDA calls be worth if the stock fell 5% tomorrow?
- Simulate the AAPL chain at a 3% higher spot.

Conventions for units, bases and timestamps: https://apexvol.com/developers/conventions
