{"uid":"cap_3dzd8ZiD0okEQUxRuVSCR","slug":"derivatives-pricer-portfolio-scenario-reprice-793389bd","name":"Derivatives Pricer – Portfolio Scenario Reprice","description":"x402-paid Black-Scholes European option pricing, Greeks, IV surfaces, price/scenario on submitted smiles (TV bilinear), portfolio risk, free demo, and MCP. USDC exact on Solana (PayAI) and/or Base (CDP when configured). Receive wallets appear only in HTTP 402, never on free discovery.","url":"https://derivatives-pricer-production.up.railway.app/v1/portfolio/scenario?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"rate":{"type":"number"},"positions":{"type":"array","items":{"type":"object","required":["underlying","strike","timeToExpiry","optionType","quantity","volatility"],"properties":{"strike":{"type":"number","exclusiveMinimum":0},"quantity":{"type":"number","description":"Position size; >0 long, <0 short; must be non-zero"},"optionType":{"enum":["call","put"],"type":"string"},"underlying":{"type":"number","description":"Underlying S for this leg","exclusiveMinimum":0},"volatility":{"type":"number","description":"Annualized vol σ for this leg","exclusiveMinimum":0},"timeToExpiry":{"type":"number","minimum":0}},"additionalProperties":false},"minItems":1},"scenarios":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"volShock":{"type":"number","description":"Relative vol move; newσ = σ*(1+volShock)"},"spotShock":{"type":"number","description":"Relative spot move; newS = S*(1+spotShock)"},"timeDecayDays":{"type":"number","minimum":0,"description":"Calendar days of time decay; T reduced by days/365"}},"additionalProperties":false},"maxItems":20,"minItems":1},"optionStyle":{"enum":["european","american"],"type":"string","default":"european","description":"Exercise style (default \"european\")."},"dividendYield":{"type":"number","minimum":0}}},"responseSchema":{"type":"json","example":{"base":{"mtm":47.16439511,"greeks":{"rho":858.77721991,"vega":176.68540458,"delta":9.05941615,"gamma":0.09736793,"theta":-58.62185203}},"requestId":"00000000-0000-4000-8000-000000000005","scenarios":[{"mtm":-37.85755566,"name":"spot_down_10","greeks":{"rho":747.49532487,"vega":201.29852574,"delta":7.8848641,"gamma":0.13279827,"theta":-55.98280497},"shocks":{"volShock":0,"spotShock":-0.1,"timeDecayDays":0},"mtmChange":-85.02195077},{"mtm":53.31386329,"name":"vol_up_20pct_rel","greeks":{"rho":830.99263852,"vega":178.51169933,"delta":8.86589449,"gamma":0.08214409,"theta":-60.74906514},"shocks":{"volShock":0.2,"spotShock":0,"timeDecayDays":1},"mtmChange":6.14946818}],"computedAt":"2026-01-01T00:00:00.000Z","positionCount":2,"scenarioCount":2}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.25","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.25/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.25","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.25","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_stg9MvdCnArurS-rJajYb","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.25","costPer":"request","priority":0,"asset":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Reprices a multi-leg options portfolio under one or more spot/vol/time-decay scenarios using Black-Scholes, returning base and shocked MTM plus full analytic Greeks for each scenario.","exampleAgentPrompt":"Stress test my two-leg options portfolio — I'm long 10 calls (spot 100, strike 105, 30-day expiry, 25% vol) and short 5 puts (spot 100, strike 95, 30-day expiry, 20% vol) — and show me what happens to MTM and Greeks under a 10% spot drop and a 20% relative vol spike with 1 day of time decay.","exampleUseCases":[{"title":"Equity options book stress test","prompt":"I have a 3-leg equity options book: long 50 calls at spot 150, strike 155, 45 days to expiry, 30% vol; short 20 puts at spot 150, strike 145, 45 days, 28% vol; long 10 calls at spot 150, strike 160, 45 days, 32% vol. Run two scenarios for me: spot down 15% and vol up 25% relative, then also spot up 5% with 2 days of theta decay. What's the MTM change and net Greeks in each case?"},{"title":"Vol spike impact on short-vega position","prompt":"I'm short 100 straddles — short 100 calls and short 100 puts, both at spot 200, strike 200, 60 days to expiry, 20% annualized vol, risk-free rate 5%. Scenario: vol spikes 50% relative. What's my new MTM and how do my vega and delta change?"},{"title":"Overnight theta decay check","prompt":"I've got a long call position: underlying 50, strike 52, 7 days to expiry, 40% vol, quantity 200. Run a scenario with just 1 day of time decay and no spot or vol change — how much do I lose to theta overnight?"}],"resultDescription":"Returns a JSON object with a `base` block containing portfolio MTM and aggregate Greeks (delta, gamma, vega, theta, rho), plus a `scenarios` array where each entry includes the scenario name, applied shocks, shocked MTM, MTM change versus base, and shocked Greeks. Also includes requestId, computedAt timestamp, positionCount, and scenarioCount.","failureModes":["Missing required position fields (underlying, strike, timeToExpiry, optionType, quantity, volatility) returns 422 validation error","Zero quantity on a position rejected with validation error","Negative strike or underlying rejected (exclusiveMinimum: 0)","No scenarios provided (minItems: 1) returns validation error","More than 20 scenarios (maxItems: 20) returns validation error","Insufficient USDC balance or failed x402 payment returns 402 Payment Required","Malformed JSON body returns 400 Bad Request"],"whenToPreferThis":"Use this endpoint when you need to evaluate how a multi-leg options portfolio behaves under hypothetical market moves — combining spot shocks, vol shocks, and time decay in a single call. Prefer this over the single-option pricer when you need net portfolio Greeks or want to compare multiple stress scenarios at once. Best for risk managers, quant agents, and algo traders who need fast, analytic (not Monte Carlo) scenario analysis without managing API keys.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-12T06:32:24.708Z","isFirstParty":false,"canonicalSlug":"derivatives-pricer-portfolio-scenario-reprice-793389bd"}