Authorization header for each request.
Authentication Overview
Authenticate
Send a Bearer token with every protected request.
Protect
Store keys in secure server-side environments.
Rotate
Replace keys after exposure or access changes.
Audit
Track usage through generation and content records.
When Authentication Applies
API authentication is required for integrations that create content, check generation status, retrieve saved content, or access account-level configuration programmatically.Applications
Embed WriterzRoom generation inside products, portals, dashboards, and internal tools.
Automation
Connect structured content workflows to editorial systems, campaign operations, and backend jobs.
Enterprise Operations
Support governed content workflows where access control, usage tracking, and auditability matter.
Request Header
Every authenticated request should include these headers.Example Request
Authentication Flow
1
Generate an API key
Go to Settings → API access and create a new API key for your integration.
2
Copy the key once
Copy the key immediately. For security, it may not be shown again after creation.
3
Store it securely
Save the key in an environment variable, deployment secret, or managed secrets service.
4
Send the Bearer token
Add the key to every API request using the
Authorization header.What an API Key Cannot Do
An API key is a single long-lived credential that never passes through two-factor authentication, so it cannot change the account that owns it. Requests made with an API key receive403 Forbidden from:
- API key management: listing, creating, or revoking keys
- Two-factor authentication setup, verification, and removal
- Signed-in device management
- Account profile lookup and account deletion
- Administrative endpoints
How the Web App Reaches the API
The WriterzRoom web app does not use your API keys or a shared secret to act on your behalf. For each request it makes to the API, the web app’s server signs a token that names your account, records whether your sign-in completed two-factor authentication, and expires after 60 seconds. The API verifies that signature with a public key and accepts no other form of web-app identity. Your browser never receives the signing key.Key Management Guidance
Operational Guidance
Where should API keys be stored?
Where should API keys be stored?
Store API keys in environment variables, deployment secrets, or a managed secrets service. Do not hardcode keys in application source code.
Can API keys be used in frontend code?
Can API keys be used in frontend code?
No. API keys should only be used from trusted backend services. Frontend applications should call your backend, and your backend should call WriterzRoom.
When should keys be rotated?
When should keys be rotated?
Rotate keys after suspected exposure, employee offboarding, vendor changes, access policy changes, or integration cleanup.
What causes authentication failure?
What causes authentication failure?
Authentication can fail when the key is missing, malformed, invalid, revoked, sent without the
Bearer prefix, or used from an account that no longer has eligible API access.Generate Content
Submit a generation request through the API.
Endpoints Reference
Review available API endpoints and expected responses.