API Documentation for Developers
Introduction
Welcome to the NumberInWord.com API documentation. Our API enables developers to integrate our number-to-word conversion tools directly into their applications, websites, and services. With simple RESTful endpoints, you can convert numbers to words, generate ordinal numbers, convert Roman numerals, and more.
This documentation provides everything you need to start using our API, including authentication, available endpoints, request parameters, and response formats.
Getting Started
To use the NumberInWord.com API, you'll need an API key. You can obtain one by registering for a developer account. We offer free and paid tiers based on usage requirements.
Authentication
All API requests require an API key passed either as a query parameter ?api_key=YOUR_API_KEY or in the request headers as X-API-Key: YOUR_API_KEY.
Base URL
All API endpoints use the following base URL:
Available Endpoints
Number to Words Conversion
Converts a numeric value to its word representation.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| number | number | Yes | The numeric value to convert |
| language | string | No | Language code (default: en-US) |
| format | string | No | Output format (options: standard, hyphenated, capitalized) |
Example Request
Example Response
Ordinal Number Conversion
Converts a number to its ordinal word form.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| number | number | Yes | The number to convert |
| format | string | No | Output format (options: word, numeral) |
Example Request
Example Response
Rate Limits and Usage
Our API implements rate limiting to ensure fair usage across all users:
- Free tier: 100 requests per day
- Basic tier: 1,000 requests per day
- Premium tier: 10,000 requests per day
- Enterprise tier: Custom limits
Rate limit information is included in the response headers:
- X-RateLimit-Limit: Your total daily request limit
- X-RateLimit-Remaining: Remaining requests for the current day
- X-RateLimit-Reset: Time (in Unix seconds) when the limit resets
Error Handling
The API uses conventional HTTP response codes to indicate success or failure:
- 200 OK: Request successful
- 400 Bad Request: Invalid parameters
- 401 Unauthorized: Missing or invalid API key
- 429 Too Many Requests: Rate limit exceeded
- 500 Server Error: Something went wrong on our end
Error responses include details about what went wrong:
Code Examples
For more detailed implementation examples in various programming languages, visit our Code Examples page.