# Chebyshev Filter API
> Chebyshev Type I filter-design maths as an API, computed locally and deterministically. The order endpoint computes the minimum filter order to meet a specification, n = ⌈acosh(√((10^(As/10)−1)/(10^(Ap/10)−1))) / acosh(fs/fp)⌉, from the passband edge frequency and its ripple and the stopband edge and its required attenuation — a Chebyshev filter usually needs a lower order than a Butterworth for the same specification, trading a flat passband for equiripple. The response endpoint computes the equiripple magnitude response, |H| = 1/√(1 + ε²·Tₙ²(f/fc)) with the ripple factor ε = √(10^(Ap/10) − 1) and the Chebyshev polynomial Tₙ, in linear and decibel form — in the passband the magnitude ripples between 0 and −Ap dB and reaches exactly −Ap dB at the cutoff, then rolls off faster than a Butterworth. The ripple endpoint converts between the passband ripple in decibels and the ripple factor ε, with the passband maximum and minimum. Frequencies are in hertz, ripple and attenuation in decibels and the order a positive integer. Everything is computed locally and deterministically, so it is instant and private. Ideal for DSP, audio, RF, communications and instrumentation app developers, filter-design and selectivity tools, and signal-processing education. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is the Chebyshev Type I filter; for the maximally-flat Butterworth use a Butterworth API.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/chebyshev-api/..."
```

## Pricing
- **Free** (Free) — 2,960 calls/Mo, 2 req/s
- **Starter** ($9/Mo) — 40,200 calls/Mo, 6 req/s
- **Pro** ($24/Mo) — 251,500 calls/Mo, 15 req/s
- **Mega** ($72/Mo) — 1,695,000 calls/Mo, 40 req/s

## Endpoints

### Chebyshev

#### `GET /v1/order` — Minimum filter order

**Parameters:**
- `passband_edge` (query, required, string) — Passband edge (Hz) Example: `1000`
- `stopband_edge` (query, required, string) — Stopband edge (Hz) Example: `4000`
- `passband_ripple` (query, required, string) — Passband ripple Ap (dB) Example: `1`
- `stopband_attenuation` (query, required, string) — Stopband attenuation As (dB) Example: `40`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/chebyshev-api/v1/order?passband_edge=1000&stopband_edge=4000&passband_ripple=1&stopband_attenuation=40"
```

**Response:**
```json
{
    "data": {
        "note": "Chebyshev Type I minimum order n = ⌈acosh(√((10^(As/10)−1)/(10^(Ap/10)−1))) / acosh(fs/fp)⌉. It is usually a lower order than Butterworth for the same spec, at the cost of passband ripple.",
        "order": 3,
        "inputs": {
            "passband_edge": 1000,
            "stopband_edge": 4000,
            "passband_ripple": 1,
            "stopband_attenuation": 40
        },
        "exact_order": 2.895106
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:34.413Z",
        "request_id": "70e75780-84b2-4d68-9da2-e1db8f8502d7"
    },
    "status": "ok",
    "message": "Filter order",
    "success": true
}
```

#### `GET /v1/response` — Magnitude response

**Parameters:**
- `order` (query, required, string) — Filter order n Example: `3`
- `frequency` (query, required, string) — Frequency (Hz) Example: `2000`
- `cutoff` (query, required, string) — Cutoff frequency fc (Hz) Example: `1000`
- `passband_ripple` (query, required, string) — Passband ripple Ap (dB) Example: `1`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/chebyshev-api/v1/response?order=3&frequency=2000&cutoff=1000&passband_ripple=1"
```

**Response:**
```json
{
    "data": {
        "note": "Magnitude |H| = 1/√(1 + ε²·Tn²(f/fc)) with ε = √(10^(Ap/10) − 1). In the passband the response ripples between 0 and −Ap dB; at fc it is exactly −Ap dB.",
        "inputs": {
            "order": 3,
            "cutoff": 1000,
            "frequency": 2000,
            "passband_ripple": 1
        },
        "epsilon": 0.50884714,
        "magnitude": 0.07537065,
        "magnitude_db": -22.455955,
        "attenuation_db": 22.455955
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:34.547Z",
        "request_id": "d8052954-9832-4e1e-b2bd-b4cb961f7a17"
    },
    "status": "ok",
    "message": "Magnitude response",
    "success": true
}
```

#### `GET /v1/ripple` — Ripple / epsilon

**Parameters:**
- `passband_ripple` (query, optional, string) — Passband ripple Ap (dB) Example: `1`
- `epsilon` (query, optional, string) — Or ripple factor ε

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/chebyshev-api/v1/ripple?passband_ripple=1"
```

**Response:**
```json
{
    "data": {
        "note": "ε = √(10^(Ap/10) − 1); the passband magnitude ripples between 1 and 1/√(1+ε²) (i.e. between 0 and −Ap dB).",
        "inputs": {
            "passband_ripple": 1
        },
        "epsilon": 0.50884714,
        "passband_max": 1,
        "passband_min": 0.89125094
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:34.665Z",
        "request_id": "d486e6dc-8c0c-4b04-bf31-30979019384c"
    },
    "status": "ok",
    "message": "Ripple/epsilon",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/chebyshev-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "notes": "Frequencies in Hz (or any consistent unit), ripple/attenuation in dB, order a positive integer. Chebyshev Type I ripples in the passband and is flat in the stopband.",
        "service": "chebyshev-api",
        "formulae": {
            "order": "n = ⌈acosh(√((10^(As/10)−1)/(10^(Ap/10)−1)))/acosh(fs/fp)⌉",
            "epsilon": "ε = √(10^(Ap/10) − 1)",
            "response": "|H| = 1/√(1 + ε²·Tn²(f/fc))"
        },
        "endpoints": {
            "GET /v1/meta": "This document.",
            "GET /v1/order": "Minimum order from passband/stopband edges, ripple and attenuation.",
            "GET /v1/ripple": "Convert between passband ripple (dB) and the ripple factor ε.",
            "GET /v1/response": "Magnitude (and dB) of an n-th order Chebyshev at a frequency."
        },
        "description": "Chebyshev Type I filter calculator: minimum order for a spec, the equiripple magnitude response, and the ripple/epsilon relationship."
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:34.768Z",
        "request_id": "2e4b2007-5c73-4ab9-8e4d-2931f764edf7"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/chebyshev-api
OpenAPI spec: https://www.oanor.com/api/chebyshev-api/openapi.json
