Portfolio Optimizer & Quant Risk Math API
Published by @mdforge
· Verified
99.98% uptime
~12ms avg
AI Score 94/100
Mean-variance optimization (Max Sharpe, Min Variance, Risk Parity), Sharpe/Sortino/Calmar, Max Drawdown, VaR/CVaR & correlation matrices.
Try it live
https://api.indieapis.com/v1/portfolio-optimizer/optimize
Compute long-only optimal weights for max_sharpe, min_variance, or equal_risk_parity.
Response
Press Run to call the live API
{
"ok": true
}
Overview
Mean-variance optimization (Max Sharpe, Min Variance, Risk Parity), Sharpe/Sortino/Calmar, Max Drawdown, VaR/CVaR & correlation matrices.
Self-hosted production API with hard monthly spend caps ($0 surprise overages) and native Streamable HTTP MCP support.
Gateway Headers & Hard Caps
Every response includes X-Quota-Limit, X-Quota-Used, X-Quota-Remaining, and X-Quota-Reset.
When your monthly quota is reached, the gateway returns 429 QUOTA_EXCEEDED so you are never billed surprise overages.
3 endpoints
| Method | Path | Parameters | Description |
|---|---|---|---|
| POST | /optimize |
objective, assets*
|
Compute long-only optimal weights for max_sharpe, min_variance, or equal_risk_parity. |
| POST | /metrics |
returns*, periods_per_year
|
Calculate annualized return, volatility, Sharpe, Sortino, Max Drawdown, Calmar, VaR 95% & CVaR 95%. |
| POST | /correlation |
assets*
|
Compute pairwise Pearson correlation and covariance matrices across asset return series. |