Portfolio Metrics
Retrieves performance metrics for a portfolio.
Endpoint
GET/data/v1/portfolio_metrics/:idParameters
api_key string required
Your authentication key needed to make requests.
benchmark int
ID of benchmark portfolio. To retrieve all available benchmarks including their ids please refer to Benchmarks endpoint.
period float
Defines period of returns in years from latest available date. By default metrics provided for longest possible period available.
format string default: json
Defines return format of response. Options are json or csv. Default is json.
Example Request
cURL
curl -X GET "https://sensaai.com/data/v1/portfolio_metrics/337?api_key=API_KEY"
Response
Returns a list of performance metrics if a valid portfolio ID was provided. Returns an error otherwise.
[
{
"metric": "Start Period",
"Portfolio": "2012-01-03"
},
{
"metric": "End Period",
"Portfolio": "2023-10-18"
},
{
"metric": "Risk-Free Rate ",
"Portfolio": "0.0%"
},
{
"metric": "Cumulative Return ",
"Portfolio": "1,303.90%"
},
{
"metric": "CAGR﹪",
"Portfolio": "25.1%"
},
{
"metric": "Sharpe",
"Portfolio": "1.13"
},
...more metrics
]
Table of Contents