Developer Onboarding
Quickstart: Your First API Call in 5 Minutes
This guide gets you from zero to a working API integration as fast as possible. By the end, you'll have made your first authenticated request and received a response.
What you'll accomplish
- Create an account and get your API key
- Make your first authenticated API request
- Understand the response format
- Know where to go next
Prerequisites
- A terminal or command prompt
curlinstalled (or any HTTP client)- 5 minutes
Step 1: Get your API key
- Go to
https://dashboard.example.com/signup - Create an account with your email
- Navigate to Settings → API Keys
- Click Create API Key and copy the key
Keep your API key secure. Never commit it to source control or expose it in client-side code.
Step 2: Set up your environment
Export your API key as an environment variable:
# Linux/macOS
export EXAMPLE_API_KEY="your-api-key-here"
# Windows (PowerShell)
$env:EXAMPLE_API_KEY="your-api-key-here"
Step 3: Make your first request
Let's retrieve your account information to verify everything works:
curl -X GET "https://api.example.com/v1/account" \
-H "Authorization: Bearer $EXAMPLE_API_KEY" \
-H "Content-Type: application/json"
Expected response
{
"id": "acct_1234567890",
"email": "you@example.com",
"created_at": "2024-03-12T10:30:00Z",
"plan": "developer",
"api_calls_remaining": 10000
}
If you see this response, congratulations! Your API key is working.
Step 4: Create your first resource
Now let's create something. We'll create a simple project:
curl -X POST "https://api.example.com/v1/projects" \
-H "Authorization: Bearer $EXAMPLE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "My First Project",
"description": "Testing the API"
}'
Expected response
{
"id": "proj_abc123",
"name": "My First Project",
"description": "Testing the API",
"created_at": "2024-03-12T10:35:00Z",
"status": "active"
}
Troubleshooting
401 Unauthorized
Your API key is missing or invalid. Check that:
- The key is correctly copied (no extra spaces)
- The environment variable is set:
echo $EXAMPLE_API_KEY - The key hasn't been revoked in the dashboard
403 Forbidden
Your key doesn't have permission for this action. Check your plan limits in the dashboard.
Connection refused
Check your network connection and firewall settings. The API requires outbound HTTPS (port 443).
What's next?
Now that you've made your first API call, explore further:
- API Reference — Complete endpoint documentation with examples
- Authentication Guide — OAuth flows, token refresh, and scopes
- SDKs — Official libraries for Python, Node.js, Go, and more
- Webhooks — Receive real-time notifications for events
Code samples
Here's the same request in popular languages:
Python
import requests
import os
response = requests.get(
"https://api.example.com/v1/account",
headers={"Authorization": f"Bearer {os.environ['EXAMPLE_API_KEY']}"}
)
print(response.json())
Node.js
const response = await fetch("https://api.example.com/v1/account", {
headers: { "Authorization": `Bearer ${process.env.EXAMPLE_API_KEY}` }
});
console.log(await response.json());
Related Samples
This is a sample article to demonstrate how I write.