Skip to content
GET /v1/continued-fraction

Continued fraction

Try it live

10 free calls per day — no sign-up, no API key. Goes through the oanor gateway.

Custom headers (optional)
api.oanor.com/numrep-api

It works. Grab an API key and use it in your project.

Get an API key

Code snippets

curl "https://api.oanor.com/numrep-api/v1/continued-fraction" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/numrep-api/v1/continued-fraction", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/numrep-api/v1/continued-fraction");
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/numrep-api/v1/continued-fraction",
    headers={"x-oanor-key": "oanor_test_..."}
)

Example response

A real response from this endpoint, captured by the latest health check.

{
    "data": {
        "input": {
            "numerator": "415",
            "denominator": "93"
        },
        "terms": [
            4,
            2,
            6,
            7
        ],
        "reduced": "415/93",
        "convergents": [
            {
                "den": "1",
                "num": "4",
                "value": 4
            },
            {
                "den": "2",
                "num": "9",
                "value": 4.5
            },
            {
                "den": "13",
                "num": "58",
                "value": 4.461538461538462
            },
            {
                "den": "93",
                "num": "415",
                "value": 4.462365591397849
            }
        ]
    },
    "meta": {
        "timestamp": "2026-06-03T17:42:13.839Z",
        "request_id": "1dee780e-b335-40e9-8260-8612b99c8ba3"
    },
    "status": "ok",
    "message": "Continued fraction",
    "success": true
}