Authentication
All Eazip API requests require authentication using an API key.
Getting an API Key
Section titled “Getting an API Key”- Sign in to your Eazip dashboard
- Navigate to API Keys in the sidebar
- Click Create API Key
- Give your key a descriptive name
- Copy the key immediately (it won’t be shown again)
Using Your API Key
Section titled “Using Your API Key”Include your API key in the Authorization header of every request:
curl https://api.eazip.io/jobs \ -H "Authorization: Bearer YOUR_API_KEY"API Key Best Practices
Section titled “API Key Best Practices”Environment Variables
Section titled “Environment Variables”Store your API key in an environment variable:
export EAZIP_API_KEY="your_api_key_here"Then use it in your requests:
curl https://api.eazip.io/jobs \ -H "Authorization: Bearer $EAZIP_API_KEY"In Your Code
Section titled “In Your Code”Node.js:
const response = await fetch('https://api.eazip.io/jobs', { headers: { 'Authorization': `Bearer ${process.env.EAZIP_API_KEY}`, 'Content-Type': 'application/json', },});Python:
import osimport requests
response = requests.get( 'https://api.eazip.io/jobs', headers={'Authorization': f'Bearer {os.environ["EAZIP_API_KEY"]}'})Managing API Keys
Section titled “Managing API Keys”You can manage your API keys from the dashboard:
- View all active keys
- Revoke keys that are no longer needed
- Create new keys for different environments
Error Responses
Section titled “Error Responses”If authentication fails, you’ll receive a 401 Unauthorized response:
{ "success": false, "error": { "code": "UNAUTHORIZED", "message": "Invalid or missing API key" }}Common causes:
- Missing
Authorizationheader - Invalid API key
- Revoked API key