Dictionary API
Access 15M+ words, definitions, synonyms, and translations across 100+ languages via a simple, high-performance RESTful API.
curl https://api.dictionary.com/v1/words/ephemeral \ -H "Authorization: Bearer <YOUR_API_KEY>"
Authentication
All API requests require authentication via Bearer token. Include your API key in the Authorization header.
Authorization: Bearer sk_live_8f9a2b3c4d5e6f7g8h9i0j
Never expose your secret keys in client-side code. Use environment variables or backend proxies.
API Endpoints
Fetches comprehensive data for a single word including definitions, pronunciation, etymology, and usage examples.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
word | string | Yes | The word to look up |
Response
{
"word": "ephemeral",
"phonetic": "/əˈfem.ər.əl/",
"definitions": [
{
"part_of_speech": "adjective",
"definition": "Lasting for a very short time",
"example": "The ephemeral beauty of cherry blossoms."
}
],
"source": "dictionary.com"
}
Uses our language model to generate contextual definitions, even for slang, neologisms, or technical jargon.
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
text | string | Yes | The word or phrase |
language | string | No | ISO 639-1 code (default: en) |
level | string | No | simple or advanced |
Response
{
"text": "algorithm",
"definition": "A step-by-step procedure for solving a problem or accomplishing a task, especially by a computer.",
"confidence": 0.98,
"context_tags": ["computing", "mathematics"]
}
Returns synonyms, antonyms, and related terms ranked by semantic similarity.
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
word | string | Yes | Target word |
limit | integer | No | Max results (default: 10) |
Response
{
"word": "happy",
"synonyms": ["joyful", "cheerful", "content"],
"antonyms": ["sad", "miserable"],
"related": ["delight", "pleasure"]
}
Translates words or phrases with awareness of idiomatic usage and regional variations.
Request Body
| Name | Type | Required | Description |
|---|---|---|---|
text | string | Yes | Text to translate |
target_lang | string | Yes | Target ISO 639-1 code |
source_lang | string | No | Auto-detected if omitted |
Response
{
"translated_text": "Bonjour le monde",
"source_lang": "en",
"target_lang": "fr",
"confidence": 0.99
}
Rate Limits
API requests are throttled based on your plan tier. Headers indicate your current usage.
| Header | Description |
|---|---|
X-RateLimit-Limit | Max requests per window |
X-RateLimit-Remaining | Requests left in current window |
X-RateLimit-Reset | Unix timestamp when quota resets |
Exceeding limits returns 429 Too Many Requests. Implement exponential backoff for resilience.
Error Handling
The API uses standard HTTP status codes and returns detailed error payloads.
| Code | Meaning | Resolution |
|---|---|---|
400 | Bad Request | Check parameters and payload format |
401 | Unauthorized | Verify API key & expiration |
403 | Forbidden | Insufficient permissions for endpoint |
404 | Not Found | Word not in database or invalid path |
429 | Rate Limited | Wait for reset time, retry with backoff |
500 | Server Error | Internal issue, try again later or contact support |
Official SDKs
Get started faster with our type-safe, auto-generated client libraries.
Python
Asyncio-ready with full type hints.
pip install dictionary-api
Node.js
Promises & streams supported.
npm install @dictionary/sdk
Ruby
Optimized for Rails & CLI apps.
gem install dictionary_api
Go
High performance, thread-safe.
go get github.com/dictionary/api-go