# ADA Ramp API
> ADA wheelchair-ramp maths as an API, computed locally and deterministically — the run, landing and slope numbers a builder or accessibility planner sizes a ramp by. The rule the ADA fixes is 1 inch of rise per 12 of run, a maximum 8.33 % slope, so the ramp endpoint turns a rise into the ramp: run = rise × 12 (or × 16 / × 20 for a gentler grade if you have the room), plus the level landings the code requires — a 5-foot landing top and bottom and another between runs whenever the rise exceeds 30 inches — and the total length end to end, so a 24-inch rise needs a 24-foot run and 34 feet overall, while a 36-inch rise breaks into two runs with an intermediate landing for 51 feet. The fit endpoint answers the real-world question: does a ramp for this rise fit the run you have? It returns the minimum run an ADA 1:12 ramp needs, whether your space is enough, and the slope you would actually get if you forced it in — flagging when that exceeds 8.33 % and you need a switchback or a lower rise. Everything is computed locally and deterministically, so it is instant and private. Ideal for construction, accessibility, home-modification and contractor app developers, ramp-estimator and code-check tools, and building software. Pure local computation — no key, no third-party service, instant. Confirm against current ADA and local code. Live, nothing stored. 2 compute endpoints.

## 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/adaramp-api/..."
```

## Pricing
- **Free** (Free) — 6,500 calls/Mo, 2 req/s
- **Starter** ($5/Mo) — 52,400 calls/Mo, 6 req/s
- **Pro** ($12/Mo) — 217,500 calls/Mo, 15 req/s
- **Mega** ($39/Mo) — 1,278,000 calls/Mo, 40 req/s

## Endpoints

### Ramp

#### `GET /v1/fit` — Does it fit the run?

**Parameters:**
- `rise` (query, required, string) — Vertical rise Example: `10`
- `available_run` (query, required, string) — Available horizontal run Example: `120`
- `unit` (query, optional, string) — in or ft (default in) Example: `in`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/adaramp-api/v1/fit?rise=10&available_run=120&unit=in"
```

**Response:**
```json
{
    "data": {
        "note": "The available run is long enough for an ADA 1:12 ramp (8.33 %). Using more of it makes a gentler, easier ramp.",
        "inputs": {
            "rise": 10,
            "unit": "in",
            "available_run": 120
        },
        "fits_ada": true,
        "slope_percent": 8.33,
        "slope_in_available_run": "1:12",
        "available_run_compliant": true,
        "required_run_ft_at_1_12": 10
    },
    "meta": {
        "timestamp": "2026-06-06T15:30:50.451Z",
        "request_id": "acd39317-fdf5-4659-8d75-6b58ddf74cfa"
    },
    "status": "ok",
    "message": "Ramp fit",
    "success": true
}
```

#### `GET /v1/ramp` — Ramp run + landings

**Parameters:**
- `rise` (query, required, string) — Vertical rise Example: `24`
- `unit` (query, optional, string) — in or ft (default in) Example: `in`
- `slope_denominator` (query, optional, string) — Slope 1:N (default 12 = ADA max) Example: `12`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/adaramp-api/v1/ramp?rise=24&unit=in&slope_denominator=12"
```

**Response:**
```json
{
    "data": {
        "note": "ADA: a ramp rises 1 inch per 12 of run (max 8.33 % slope), a single run climbs at most 30\", and a 5-ft (60\") level landing goes top, bottom and between runs. Run = rise × slope denominator. Gentler is better — 1:16 or 1:20 if you have the room.",
        "inputs": {
            "rise": 24,
            "unit": "in",
            "slope_denominator": 12
        },
        "rise_in": 24,
        "ramp_run_ft": 24,
        "ramp_run_in": 288,
        "slope_ratio": "1:12",
        "ada_compliant": true,
        "slope_percent": 8.33,
        "total_length_ft": 34,
        "intermediate_landings": 0
    },
    "meta": {
        "timestamp": "2026-06-06T15:30:50.544Z",
        "request_id": "f1d22fa7-9c5a-481c-bce7-773c97f590ea"
    },
    "status": "ok",
    "message": "Ramp design",
    "success": true
}
```

### Meta

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

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

**Response:**
```json
{
    "data": {
        "notes": "ADA: 1:12 max slope (8.33 %), 30\" max rise per run, 5-ft landings top/bottom/between. Run = rise × 12. Rise/run in inches or feet. Accessibility code — confirm against current ADA/local requirements. For generic slope conversion use a slope API.",
        "service": "adaramp-api",
        "endpoints": {
            "GET /v1/fit": "Whether a ramp for a rise fits an available run, and the resulting slope.",
            "GET /v1/meta": "This document.",
            "GET /v1/ramp": "Ramp run, landings and total length for a rise at a chosen slope (default ADA 1:12)."
        },
        "description": "ADA wheelchair-ramp maths: required run and landings for a rise, and whether a ramp fits an available run."
    },
    "meta": {
        "timestamp": "2026-06-06T15:30:50.651Z",
        "request_id": "b002a8d6-ef55-4f8c-87ac-13f45bca6b0e"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


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