# Kanji API
> The Japanese kanji writing system as an API — every Jōyō, Kyōiku and Jinmeiyō kanji with its on/kun readings, English meanings, JLPT level, school grade, stroke count and newspaper frequency. Look up a single kanji (e.g. 字 → grade 1, JLPT 4, readings ジ / あざ, meanings "character, letter"), find every kanji that shares a kana reading (e.g. かじ), list the vocabulary that uses a given kanji, or pull a whole standard set (Jōyō 2,136 · Kyōiku · grade-1…grade-6 · Jinmeiyō) with paging. Backed by the open KANJIDIC2 / JMdict datasets via kanjiapi.dev. Ideal for Japanese-learning and flashcard apps, SRS/Anki-style study tools, furigana and reading aids, language-education platforms and linguistics research.

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

## Pricing
- **Free** (Free) — 2,800 calls/Mo, 2 req/s
- **Starter** ($5/Mo) — 44,000 calls/Mo, 8 req/s
- **Pro** ($16/Mo) — 220,000 calls/Mo, 20 req/s
- **Mega** ($40/Mo) — 1,100,000 calls/Mo, 50 req/s

## Endpoints

### Kanji

#### `GET /v1/kanji` — A single kanji: readings, meanings, JLPT, grade, strokes

**Parameters:**
- `character` (query, required, string) — A single kanji, e.g. 字 Example: `字`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/kanji-api/v1/kanji?character=%E5%AD%97"
```

**Response:**
```json
{
    "data": {
        "kanji": {
            "jlpt": 4,
            "grade": 1,
            "kanji": "字",
            "notes": [],
            "unicode": "5B57",
            "meanings": [
                "character",
                "letter",
                "section of village",
                "word"
            ],
            "frequency": 485,
            "on_readings": [
                "ジ"
            ],
            "kun_readings": [
                "-な",
                "あざ",
                "あざな"
            ],
            "stroke_count": 6,
            "name_readings": [],
            "heisig_keyword": "character"
        }
    },
    "meta": {
        "timestamp": "2026-06-01T00:04:44.442Z",
        "request_id": "9f160eda-eb71-4d5c-a03c-b4e5a78a8239"
    },
    "status": "ok",
    "message": "Kanji retrieved",
    "success": true
}
```

#### `GET /v1/reading` — Kanji that share a kana reading

**Parameters:**
- `reading` (query, required, string) — A hiragana/katakana reading, e.g. かじ Example: `かじ`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/kanji-api/v1/reading?reading=%E3%81%8B%E3%81%98"
```

**Response:**
```json
{
    "data": {
        "reading": {
            "reading": "かじ",
            "main_kanji": [
                "柁",
                "柂",
                "梶",
                "楫",
                "榜",
                "槳",
                "橈",
                "檝",
                "櫂",
                "牓",
                "舵"
            ],
            "name_kanji": []
        }
    },
    "meta": {
        "timestamp": "2026-06-01T00:04:44.568Z",
        "request_id": "33f41c3c-2a8f-40da-ae60-a4f37b2b38a6"
    },
    "status": "ok",
    "message": "Reading retrieved",
    "success": true
}
```

#### `GET /v1/words` — Vocabulary that uses a kanji

**Parameters:**
- `character` (query, required, string) — A single kanji, e.g. 字 Example: `字`
- `limit` (query, optional, string) — Max words (1-200, default 30) Example: `20`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/kanji-api/v1/words?character=%E5%AD%97&limit=20"
```

**Response:**
```json
{
    "data": {
        "count": 20,
        "total": 890,
        "words": [
            {
                "meanings": [
                    "(bind) firmly"
                ],
                "variants": [
                    {
                        "written": "雁字搦みに",
                        "priorities": [],
                        "pronounced": "がんじがらみに"
                    }
                ]
            },
            {
                "meanings": [
                    "(in) the shape of the character hachi (eight)"
                ],
                "variants": [
                    {
                        "written": "八文字",
                        "priorities": [],
                        "pronounced": "はちもんじ"
                    }
                ]
            },
            {
                "meanings": [
                    "(words with) different kanji but the same Japanese reading (and usu. a similar meaning)"
                ],
                "variants": [
                    {
                        "written": "異字同訓",
                        "priorities": [],
                        "pronounced": "いじどうくん"
                    }
                ]
            },
            {
                "meanings": [
                    "(words with) different kanji but the same Japanese reading (and usu. a similar meaning)"
                ],
                "variants": [
                    {
                 
…(truncated, see openapi.json for full schema)
```

### Sets

#### `GET /v1/list` — A standard kanji set with paging

**Parameters:**
- `set` (query, optional, string) — jouyou | kyouiku | grade-1..grade-6 | grade-8 | jinmeiyou | heisig | all (default jouyou) Example: `grade-1`
- `limit` (query, optional, string) — Page size (1-500, default 100) Example: `50`
- `offset` (query, optional, string) — Pagination offset Example: `0`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/kanji-api/v1/list?set=grade-1&limit=50&offset=0"
```

**Response:**
```json
{
    "data": {
        "set": "grade-1",
        "count": 50,
        "kanji": [
            "一",
            "七",
            "三",
            "上",
            "下",
            "中",
            "九",
            "二",
            "五",
            "人",
            "休",
            "先",
            "入",
            "八",
            "六",
            "円",
            "出",
            "力",
            "十",
            "千",
            "口",
            "右",
            "名",
            "四",
            "土",
            "夕",
            "大",
            "天",
            "女",
            "子",
            "字",
            "学",
            "小",
            "山",
            "川",
            "左",
            "年",
            "手",
            "文",
            "日",
            "早",
            "月",
            "木",
            "本",
            "村",
            "林",
            "校",
            "森",
            "正",
            "気"
        ],
        "total": 80,
        "offset": 0
    },
    "meta": {
        "timestamp": "2026-06-01T00:04:44.877Z",
        "request_id": "64d39746-9a3b-4e47-b844-f386140fda14"
    },
    "status": "ok",
    "message": "Kanji set retrieved",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Available sets & source

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

**Response:**
```json
{
    "data": {
        "note": "Japanese kanji dictionary. /v1/kanji = one kanji's readings (on/kun), meanings, JLPT, grade, stroke count and frequency (e.g. character=字); /v1/reading = kanji sharing a kana reading (e.g. reading=かじ); /v1/words = vocabulary using a kanji; /v1/list = a standard set (set=jouyou|kyouiku|grade-1..grade-6|grade-8|jinmeiyou|heisig|all) with limit/offset paging. Data: KANJIDIC2 / JMdict via kanjiapi.dev.",
        "sets": [
            "grade-1",
            "grade-2",
            "grade-3",
            "grade-4",
            "grade-5",
            "grade-6",
            "grade-8",
            "kyouiku",
            "jouyou",
            "jinmeiyou",
            "heisig",
            "all"
        ],
        "source": "kanjiapi.dev",
        "endpoints": [
            "/v1/kanji",
            "/v1/reading",
            "/v1/words",
            "/v1/list",
            "/v1/meta"
        ]
    },
    "meta": {
        "timestamp": "2026-06-01T00:04:44.945Z",
        "request_id": "7b316d95-f67c-48e7-a602-837ba99446be"
    },
    "status": "ok",
    "message": "Meta retrieved",
    "success": true
}
```


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