Ir al contenido
GET /v1/cagr

Compound annual growth rate

Pruébalo en vivo

10 llamadas gratis al día — sin registro, sin clave API. Pasa por el gateway de oanor.

Encabezados personalizados (opcional)
api.oanor.com/investment-api

Funciona. Consigue una clave API y úsala en tu proyecto.

Obtener una clave API

Fragmentos de código

curl "https://api.oanor.com/investment-api/v1/cagr" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/investment-api/v1/cagr", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/investment-api/v1/cagr");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/investment-api/v1/cagr",
    headers={"x-oanor-key": "oanor_test_..."}
)

Respuesta de ejemplo

Una respuesta real de este endpoint, capturada en la última comprobación de estado.

{
    "data": {
        "note": "CAGR = (end/begin)^(1/years) − 1: the constant annual rate that turns the begin value into the end value.",
        "inputs": {
            "years": 7,
            "end_value": 20000,
            "begin_value": 10000
        },
        "cagr_pct": 10.408951,
        "total_return_pct": 100,
        "total_growth_multiple": 2
    },
    "meta": {
        "timestamp": "2026-06-04T18:38:08.453Z",
        "request_id": "0ba57741-d64c-4ff5-bbb5-090085a4bc33"
    },
    "status": "ok",
    "message": "CAGR",
    "success": true
}