ClickAPIs
Examples · MSFT: ten years of return and risk

Examples / Basics

MSFT: ten years of return and risk

Level 1 · BasicsPOST/v1/performance

What it answers

The standard performance and risk tear sheet: period returns, annualised return and volatility, Sharpe and Sortino, maximum drawdown, value at risk, and how the stock behaved against SPY (beta, alpha, correlation, up and down capture).

Request

Input POST /v1/performance
{
  "symbol": "MSFT",
  "start_date": "2016-01-01",
  "benchmark": "SPY"
}
Open in playground

Response

Output 200 OK
{
  "ok": true,
  "data": {
    "symbol": "MSFT",
    "start": "2016-01-04",
    "end": "2026-11-12",
    "last_close": 521.89,
    "returns": {
      "1d": 0.001468,
      "1w": -0.026197,
      "1m": -0.035591,
      "3m": 0.061831,
      "6m": 0.285064,
      "ytd": 0.085981,
      "1y": 0.02945,
      "3y": 0.444878,
      "5y": 0.615058,
      "10y": 8.959733,
      "max": 9.947976,
      "since": "2016-01-04",
      "3y_annualized": 0.130517,
      "5y_annualized": 0.100621,
      "10y_annualized": 0.258418
    },
    "bars_per_year": 250.7,
    "risk": {
      "days": 2731,
      "annual_return": 0.245655,
      "annual_volatility": 0.274939,
      "sharpe": 0.936359,
      "sortino": 1.395959,
      "max_drawdown": -0.371499,
      "calmar": 0.661254,
      "best_day": 0.15505,
      "worst_day": -0.147401,
      "up_days_pct": 0.534969,
      "avg_up_day": 0.012112,
      "avg_down_day": -0.011855,
      "skew": 0.280358,
      "excess_kurtosis": 8.739985,
      "var_95_1d": 0.026629,
      "cvar_95_1d": 0.038566,
      "var_99_1d": 0.042883,
      "cvar_99_1d": 0.060305
    },
    "vs_benchmark": {
      "benchmark": "SPY",
      "days": 2731,
      "beta": 1.177276,
      "correlation": 0.756801,
      "alpha_annual": 0.077741,
      "r_squared": 0.572747,
      "tracking_error": 0.182906,
      "information_ratio": 0.574099,
      "up_capture": 1.2372,
      "down_capture": 1.143882,
      "excess_return_total": 6.485207
    },
    "interval": "1day"
  },
  "meta": {
    "op": "performance",
    "units": 4,
    "cost_usd": 0.0,
    "billing": "internal",
    "free_call": false,
    "free_calls_left": 0,
    "balance_usd": 5.0,
    "ms": 79,
    "interval": "1day",
    "data_as_of": "2026-11-12",
    "partial_last_bar": false
  }
}

How to read it

risk holds the stand-alone statistics; relative compares with the benchmark. A beta above 1 means bigger swings than the market; up_capture above down_capture means the stock kept more of the market's gains than its losses.

Parameters and limits: Performance & risk reference. Analytics, not advice.