# WriteHuman API > The WriteHuman API rewrites AI-generated text so that it reads as human-written, scores text for AI authorship, and reports your word balance. It is a JSON REST API at https://api.writehuman.ai with three endpoints and Bearer key authentication. ## Get started - [WriteHuman AI Humanizer API Documentation](https://writehuman.ai/api/docs): The WriteHuman API rewrites AI-generated text so that it reads as human-written, scores text for AI authorship, and reports your word balance. It is a JSON API over HTTPS with Bearer key authentication and three endpoints. - [Authentication](https://writehuman.ai/api/docs/authentication): Every request must include an API key as a Bearer token. Keys are created in the API dashboard and belong to an API account. - [SDKs](https://writehuman.ai/api/docs/sdks): Official client libraries for TypeScript and Python. Each provides one method per endpoint, typed errors, and a retry policy that never resends a request that may have been charged. ## API reference - [Humanize text](https://writehuman.ai/api/docs/humanize): Rewrites text so that it reads as human-written. Requests are charged by the number of words submitted, and only when the request succeeds. - [Detect AI text](https://writehuman.ai/api/docs/detect): Scores text for AI authorship using the WriteHuman detector, for the document as a whole and optionally for each sentence. Requests are charged by the number of words submitted, as with humanize. - [Get usage](https://writehuman.ai/api/docs/usage): Returns your plan, the words used in the current billing cycle and your top-up balance. This endpoint is not billed and does not count toward the rate limit. - [Errors](https://writehuman.ai/api/docs/errors): Every failed request returns a JSON body with a stable `code`. This page describes the error format, which errors are safe to retry, and when a failed request can still be charged. ## Guides - [Tone and language](https://writehuman.ai/api/docs/tone-and-language): Two optional fields control a humanize request: `tone` sets the writing style of the result, and `language` specifies the language of the text. - [Enhanced model](https://writehuman.ai/api/docs/enhanced-model): Premium plans can select the enhanced model for any humanize request. The enhanced model applies a more extensive rewrite, intended for the strictest AI detectors, at the same per-word rate. - [Freezing text](https://writehuman.ai/api/docs/freezing): Freezing preserves selected parts of the text exactly as written while the surrounding text is rewritten. Use it for quotations, names, figures and citations. - [Production best practices](https://writehuman.ai/api/docs/production): Recommended configuration before sending production traffic: timeouts, retries, long documents, rate limits and balance monitoring. ## Account - [Plans and limits](https://writehuman.ai/api/docs/limits): Per-plan limits: words per month, words per request, requests per minute, results per request and API keys. - [Words and billing](https://writehuman.ai/api/docs/billing): The API is billed by word count. Requests are charged for the words submitted, and only when the request succeeds. Plan words are consumed first, followed by top-up words. - [Teams](https://writehuman.ai/api/docs/teams): On Premium and Enterprise plans, teammates sign in with their own WriteHuman accounts and work on the same API account, without sharing a password. Teammates are included at no additional cost. ## Optional - [Every page in one file](https://writehuman.ai/api/docs/llms-full.txt) - [OpenAPI document](https://api.writehuman.ai/openapi.json)