Datamuse APIdatamuse.com ↗
Find words by meaning, sound, spelling, or rhyme via the Datamuse API. Get definitions, parts of speech, syllable counts, and autocomplete suggestions.
What is the Datamuse API?
The Datamuse API exposes 4 endpoints for querying English (and Spanish) vocabulary by meaning, pronunciation, spelling, and rhyme. The word_search endpoint alone accepts over 8 parameters — including ml for semantic similarity, sl for phonetic matching, and sp for wildcard spelling patterns — and returns up to 1000 ranked word results, optionally annotated with definitions, parts of speech, syllable counts, and frequency data.
curl -X GET 'https://api.parse.bot/scraper/71e6a4c4-cffd-4e3f-9635-40695f12feab/word_search?ml=happy' \ -H 'X-API-Key: $PARSE_API_KEY'
Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace datamuse-com-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
from parse_apis.datamuse_api import Datamuse
datamuse = Datamuse()
# Search for words meaning "happy"
for word in datamuse.words.search(ml="happy", limit=5):
print(word.word, word.score, word.tags)
# Get detailed metadata for a specific word
info = datamuse.words.get(word="hello")
print(info.word, info.numSyllables, info.defs)
# Find perfect rhymes for "love"
for rhyme in datamuse.words.rhymes(word="love", limit=5):
print(rhyme.word, rhyme.score, rhyme.numSyllables)
# Get autocomplete suggestions for a prefix
for suggestion in datamuse.words.autocomplete(s="hel", limit=5):
print(suggestion.word, suggestion.score)
General word search with multiple constraints. Supports meanings like, sounds like, spelled like, and various lexical relations (synonyms, antonyms, rhymes, triggers, etc.). At least one search parameter should be provided to get meaningful results. Returns up to 1000 words ordered by relevance score.
| Param | Type | Description |
|---|---|---|
| v | string | Vocabulary identifier (e.g. es for Spanish) |
| lc | string | Left context: a word that precedes the target word |
| md | string | Metadata flags: d (definitions), p (parts of speech), s (syllable count), r (pronunciation), f (frequency) |
| ml | string | Means like: find words with a similar meaning |
| qe | string | Query echo: prepend a result that describes the query string |
| rc | string | Right context: a word that follows the target word |
| sl | string | Sounds like: find words with a similar pronunciation |
| sp | string | Spelled like: find words with a similar spelling (supports * and ? wildcards) |
| ipa | integer | Set to 1 to include IPA pronunciation in results (requires md=r) |
| max | integer | Maximum number of results to return (up to 1000) |
| topics | string | Topic hints: one or more comma-separated words to bias results |
| rel_ant | string | Antonyms (semantic opposites) |
| rel_bga | string | Frequent followers (words that frequently follow the given word) |
| rel_bgb | string | Frequent predecessors (words that frequently precede the given word) |
| rel_com | string | Holonyms (words that the given word is a part of) |
| rel_gen | string | Hyponyms (more specific terms) |
| rel_hom | string | Homophones (sound-alike words) |
| rel_jja | string | Nouns that the given adjective describes |
| rel_jjb | string | Adjectives that describe the given noun |
| rel_nry | string | Near rhymes (approximate rhymes) |
| rel_par | string | Meronyms (words that are parts of the given word) |
| rel_rhy | string | Perfect rhymes |
| rel_spc | string | Hypernyms (more general terms) |
| rel_syn | string | Synonyms (words with the same meaning) |
| rel_trg | string | Triggers (statistically associated words) |
{
"type": "object",
"fields": {
"items": "array of word result objects each containing word, score, and optionally tags and numSyllables"
},
"sample": {
"data": {
"items": [
{
"tags": [
"syn",
"adj",
"v",
"results_type:primary_rel"
],
"word": "pleased",
"score": 40004395
},
{
"tags": [
"syn",
"adj"
],
"word": "blissful",
"score": 40004156
}
]
},
"status": "success"
}
}About the Datamuse API
Word Search and Lexical Relations
The word_search endpoint is the core of the API. The ml parameter finds words with similar meanings (e.g., synonyms and near-synonyms), sl matches by pronunciation, and sp supports wildcard patterns using * and ? for flexible spelling queries. You can also request contextual relevance using lc (left context) and rc (right context) to bias results toward words that fit naturally in a phrase. Results include a score field reflecting ranking confidence, and the md parameter controls which metadata is appended: d for definitions, p for parts of speech, s for syllable count, r for pronunciation, and f for word frequency.
Rhymes and Autocomplete
The get_rhyming_words endpoint accepts a word parameter and returns perfect rhymes ranked by score, each result including numSyllables — useful for filtering by metrical constraints in poetry tools. The get_autocomplete_suggestions endpoint takes a prefix string via the s parameter and returns frequency-ordered completions, with an optional max parameter to cap result count. Both endpoints support the v parameter to switch to a Spanish vocabulary.
Word Metadata Lookup
The get_word_metadata endpoint retrieves a full profile for a specific word: defs contains definition strings prefixed with part-of-speech labels (e.g., n the act of...), tags contains part-of-speech codes and IPA-style pronunciation strings, and numSyllables gives the syllable count. The score field is always present but is most meaningful in ranked search results rather than direct lookups.
The Datamuse API is a managed, monitored endpoint for datamuse.com — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when datamuse.com changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official datamuse.com API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Poetry tools that filter rhyme candidates by syllable count using
numSyllablesfromget_rhyming_words - Crossword and word game solvers using wildcard
sppatterns inword_search - Semantic search over vocabulary using
mlto expand query terms with similar-meaning words - Search-as-you-type UI components powered by frequency-ranked results from
get_autocomplete_suggestions - Writing assistants that suggest contextually appropriate synonyms using
lcandrccontext parameters - Phonetic spelling correctors using the
sl(sounds like) parameter inword_search - Vocabulary apps that surface definitions and parts of speech via
get_word_metadata
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Datamuse have an official developer API?+
What does the `word_search` endpoint return beyond just the word string?+
word string and an integer score reflecting relevance rank. When metadata flags are passed via the md parameter, results also include tags (an array with part-of-speech codes like n, v, adj and IPA pronunciation strings) and defs (definition strings), as well as numSyllables when the s flag is set.Does the API cover languages other than English?+
v=es on word_search and get_autocomplete_suggestions. Other languages are not currently covered. You can fork the API on Parse and revise it to point at additional Datamuse vocabulary identifiers if they become available.Does the API return near-rhymes or only perfect rhymes?+
get_rhyming_words endpoint returns perfect rhymes only. Near-rhymes (approximate or slant rhymes) are not exposed through that endpoint. You can fork the API on Parse and revise it to add a near-rhyme endpoint using the rel_nry relation parameter available in word_search.Is there any pagination support across these endpoints?+
word_search returns up to 1000 results in a single response with no cursor or page parameter. get_autocomplete_suggestions and get_rhyming_words support a max parameter to cap result count, but there is no offset or continuation token for paging through additional results beyond that limit.