# Stemmer API
> Reduce words to their linguistic root (stem) with the classic Snowball stemming algorithms — running → run, fishing → fish, nationalization → nation — across 24 languages including English, German, French, Spanish, Italian, Portuguese, Dutch, Russian, Arabic, Finnish, Swedish and more. Stem a whole text (every word, returning both the per-word mapping and the fully stemmed text) or a single word. Stemming is the core normalisation step behind search engines, query expansion, text indexing, keyword matching and NLP preprocessing. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 4 endpoints. Distinct from sentiment/NLP analysis and fuzzy string matching.

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

## Pricing
- **Free** (Free) — 1,100 calls/Mo, 2 req/s
- **Starter** ($3/Mo) — 9,500 calls/Mo, 8 req/s
- **Pro** ($22/Mo) — 142,000 calls/Mo, 20 req/s
- **Mega** ($58/Mo) — 730,000 calls/Mo, 50 req/s

## Endpoints

### Stem

#### `GET /v1/stem` — Stem all words in a text

**Parameters:**
- `text` (query, required, string) — Text to stem Example: `The runners were running quickly`
- `language` (query, optional, string) — english|german|french|… (default english)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/stemmer-api/v1/stem?text=The+runners+were+running+quickly"
```

**Response:**
```json
{
    "data": {
        "count": 5,
        "stems": [
            {
                "stem": "the",
                "word": "The"
            },
            {
                "stem": "runner",
                "word": "runners"
            },
            {
                "stem": "were",
                "word": "were"
            },
            {
                "stem": "run",
                "word": "running"
            },
            {
                "stem": "quick",
                "word": "quickly"
            }
        ],
        "language": "english",
        "stemmed_text": "the runner were run quick"
    },
    "meta": {
        "timestamp": "2026-06-02T16:51:51.064Z",
        "request_id": "52712adc-f6f6-418a-81a6-414b43e865cd"
    },
    "status": "ok",
    "message": "Stem all words in a text",
    "success": true
}
```

#### `GET /v1/word` — Stem a single word

**Parameters:**
- `word` (query, required, string) — Word to stem Example: `nationalization`
- `language` (query, optional, string) — english|german|french|… (default english)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/stemmer-api/v1/word?word=nationalization"
```

**Response:**
```json
{
    "data": {
        "stem": "nation",
        "word": "nationalization",
        "language": "english"
    },
    "meta": {
        "timestamp": "2026-06-02T16:51:51.177Z",
        "request_id": "58b6b524-6964-40d8-92ca-2ec08a0a8158"
    },
    "status": "ok",
    "message": "Stem a single word",
    "success": true
}
```

### Reference

#### `GET /v1/languages` — Supported languages

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

**Response:**
```json
{
    "data": {
        "count": 24,
        "languages": [
            "arabic",
            "armenian",
            "basque",
            "catalan",
            "czech",
            "danish",
            "dutch",
            "english",
            "finnish",
            "french",
            "german",
            "hungarian",
            "italian",
            "irish",
            "norwegian",
            "porter",
            "portuguese",
            "romanian",
            "russian",
            "spanish",
            "slovene",
            "swedish",
            "tamil",
            "turkish"
        ]
    },
    "meta": {
        "timestamp": "2026-06-02T16:51:51.282Z",
        "request_id": "cae6c265-8373-4287-8d5c-2242c2df1f08"
    },
    "status": "ok",
    "message": "Supported languages",
    "success": true
}
```

### Meta

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

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

**Response:**
```json
{
    "data": {
        "auth": "none upstream; this gateway requires x-api-key",
        "name": "Stemmer API",
        "note": "Reduce words to their root form. /v1/stem?text=running quickly&language=english stems every word and returns the stemmed text; /v1/word?word=fishing for a single word; /v1/languages lists the 15+ supported languages (english, german, french, spanish, russian, …). Stemming powers search indexing, query expansion and NLP preprocessing. Instant, nothing stored. Distinct from sentiment/NLP analysis and fuzzy string matching.",
        "source": "Local Snowball stemming (snowball-stemmers) — no key, no upstream",
        "endpoints": 4
    },
    "meta": {
        "timestamp": "2026-06-02T16:51:51.386Z",
        "request_id": "0e465530-8160-42d9-a572-cda4e60f6c71"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


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