Api Endpoint

Portfolio Scenarios

When to use: what-if P&L under relative spot/vol shocks and calendar time decay on a European book. Returns base MTM+Greeks and per-scenario shocked MTM, MTM change, full Greeks. Single-option or multi-leg. USDC exact on Solana/Base.

Open interactive test console

Offering

Provider
derivatives-pricer-production.up.railway.app
Method
POST
Offering type
Api Endpoint
Transport type
http
Category
Financial Analysis
Delivery
Not provided
Pricing model
Not provided
x402 version
2

Endpoint context

URL
https://derivatives-pricer-production.up.railway.app/v1/portfolio/scenario
MIME type
Not provided
First seen
2026-10-16T01:51:51.176Z
Last seen
Tags
Portfolio, scenario, greeks, multi-chain, USDC

Payment pricing

x402 payment terms are the authoritative price for calling this endpoint.

Payment option 1
0.25 USDC
Atomic price: 250000 · Network: solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp · Asset: USDC · Scheme: exact
Payment option 2
0.25 USDC
Atomic price: 250000 · Network: eip155:8453 · Asset: USDC · Scheme: exact
Raw x402 terms
[
  {
    "scheme": "exact",
    "network": "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp",
    "asset": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
    "amount": "250000",
    "payTo": "DCi9X5mmacNGLeJvCw9fdWgX3G8V4QquDn4EuXATkcYr"
  },
  {
    "scheme": "exact",
    "network": "eip155:8453",
    "asset": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "amount": "250000",
    "payTo": "0x34cfb8bdbf16e4484b7da0ed31deed5771b16c8f"
  }
]

Observed health

Status
Healthy
Latest latency
97 ms
Average latency
108 ms
HTTP status
204
Last checked
Reachability
100% over 14 checks

Latency is measured to the first response headers. A reachable result does not verify response accuracy or merchant identity.

Input schema

{
  "additionalProperties": false,
  "properties": {
    "body": {
      "additionalProperties": false,
      "description": "Reprice a portfolio under relative spot/vol shocks and calendar time decay.",
      "properties": {
        "dividendYield": {
          "minimum": 0,
          "type": "number"
        },
        "optionStyle": {
          "default": "european",
          "description": "Exercise style (default \"european\").",
          "enum": [
            "european",
            "american"
          ],
          "type": "string"
        },
        "positions": {
          "items": {
            "additionalProperties": false,
            "properties": {
              "optionType": {
                "enum": [
                  "call",
                  "put"
                ],
                "type": "string"
              },
              "quantity": {
                "description": "Position size; >0 long, <0 short; must be non-zero",
                "type": "number"
              },
              "strike": {
                "exclusiveMinimum": 0,
                "type": "number"
              },
              "timeToExpiry": {
                "minimum": 0,
                "type": "number"
              },
              "underlying": {
                "description": "Underlying S for this leg",
                "exclusiveMinimum": 0,
                "type": "number"
              },
              "volatility": {
                "description": "Annualized vol σ for this leg",
                "exclusiveMinimum": 0,
                "type": "number"
              }
            },
            "required": [
              "underlying",
              "strike",
              "timeToExpiry",
              "optionType",
              "quantity",
              "volatility"
            ],
            "type": "object"
          },
          "minItems": 1,
          "type": "array"
        },
        "rate": {
          "type": "number"
        },
        "scenarios": {
          "items": {
            "additionalProperties": false,
            "properties": {
              "name": {
                "type": "string"
              },
              "spotShock": {
                "description": "Relative spot move; newS = S*(1+spotShock)",
                "type": "number"
              },
              "timeDecayDays": {
                "description": "Calendar days of time decay; T reduced by days/365",
                "minimum": 0,
                "type": "number"
              },
              "volShock": {
                "description": "Relative vol move; newσ = σ*(1+volShock)",
                "type": "number"
              }
            },
            "type": "object"
          },
          "maxItems": 20,
          "minItems": 1,
          "type": "array"
        }
      },
      "required": [
        "rate",
        "positions",
        "scenarios"
      ],
      "title": "PortfolioScenarioRequest",
      "type": "object"
    },
    "bodyType": {
      "enum": [
        "json",
        "form-data",
        "text"
      ],
      "type": "string"
    },
    "method": {
      "enum": [
        "POST"
      ],
      "type": "string"
    },
    "type": {
      "const": "http",
      "type": "string"
    }
  },
  "required": [
    "type",
    "method",
    "bodyType",
    "body"
  ],
  "type": "object"
}

Output schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "properties": {
    "input": {
      "additionalProperties": false,
      "properties": {
        "body": {
          "additionalProperties": false,
          "description": "Reprice a portfolio under relative spot/vol shocks and calendar time decay.",
          "properties": {
            "dividendYield": {
              "minimum": 0,
              "type": "number"
            },
            "optionStyle": {
              "default": "european",
              "description": "Exercise style (default \"european\").",
              "enum": [
                "european",
                "american"
              ],
              "type": "string"
            },
            "positions": {
              "items": {
                "additionalProperties": false,
                "properties": {
                  "optionType": {
                    "enum": [
                      "call",
                      "put"
                    ],
                    "type": "string"
                  },
                  "quantity": {
                    "description": "Position size; >0 long, <0 short; must be non-zero",
                    "type": "number"
                  },
                  "strike": {
                    "exclusiveMinimum": 0,
                    "type": "number"
                  },
                  "timeToExpiry": {
                    "minimum": 0,
                    "type": "number"
                  },
                  "underlying": {
                    "description": "Underlying S for this leg",
                    "exclusiveMinimum": 0,
                    "type": "number"
                  },
                  "volatility": {
                    "description": "Annualized vol σ for this leg",
                    "exclusiveMinimum": 0,
                    "type": "number"
                  }
                },
                "required": [
                  "underlying",
                  "strike",
                  "timeToExpiry",
                  "optionType",
                  "quantity",
                  "volatility"
                ],
                "type": "object"
              },
              "minItems": 1,
              "type": "array"
            },
            "rate": {
              "type": "number"
            },
            "scenarios": {
              "items": {
                "additionalProperties": false,
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "spotShock": {
                    "description": "Relative spot move; newS = S*(1+spotShock)",
                    "type": "number"
                  },
                  "timeDecayDays": {
                    "description": "Calendar days of time decay; T reduced by days/365",
                    "minimum": 0,
                    "type": "number"
                  },
                  "volShock": {
                    "description": "Relative vol move; newσ = σ*(1+volShock)",
                    "type": "number"
                  }
                },
                "type": "object"
              },
              "maxItems": 20,
              "minItems": 1,
              "type": "array"
            }
          },
          "required": [
            "rate",
            "positions",
            "scenarios"
          ],
          "title": "PortfolioScenarioRequest",
          "type": "object"
        },
        "bodyType": {
          "enum": [
            "json",
            "form-data",
            "text"
          ],
          "type": "string"
        },
        "method": {
          "enum": [
            "POST"
          ],
          "type": "string"
        },
        "type": {
          "const": "http",
          "type": "string"
        }
      },
      "required": [
        "type",
        "method",
        "bodyType",
        "body"
      ],
      "type": "object"
    },
    "output": {
      "properties": {
        "example": {
          "properties": {
            "base": {
              "type": "object"
            },
            "computedAt": {
              "type": "string"
            },
            "positionCount": {
              "type": "integer"
            },
            "requestId": {
              "type": "string"
            },
            "scenarioCount": {
              "type": "integer"
            },
            "scenarios": {
              "type": "array"
            }
          },
          "required": [
            "base",
            "scenarios",
            "positionCount",
            "scenarioCount",
            "requestId",
            "computedAt"
          ],
          "type": "object"
        },
        "type": {
          "type": "string"
        }
      },
      "required": [
        "type"
      ],
      "type": "object"
    }
  },
  "required": [
    "input"
  ],
  "type": "object"
}