Getting Started
Authentication
Learn how to authenticate with the Cronhost API using API keys
Authentication
The Cronhost API uses API key authentication. All requests must include a valid API key in the request headers.
API Key Header
Include your API key in the x-api-key
header:
Getting Your API Key
- Log in to your Cronhost dashboard
- Navigate to Settings
- Create a new API key or copy an existing one
Example Request
Security Best Practices
- Never expose API keys in client-side code, public repositories, or logs
- Use environment variables to store API keys in your applications
- Rotate keys regularly for enhanced security
- Use different keys for different environments (development, staging, production)
- Revoke unused keys from your dashboard
Error Responses
Missing API Key
Status Code: 401 Unauthorized
Invalid API Key
Status Code: 401 Unauthorized
Expired API Key
Status Code: 401 Unauthorized
Environment Variables
Store your API key securely using environment variables: