Get started
Register an application, get credentials, and make your first authenticated request in about five minutes.
Before you begin
You need:
- A developer account on this portal. Sign up if you don't have one yet.
- A terminal with
curl, or Node.js 18+ or Python 3.9+ if you'd rather use code. - About five minutes.
1. Register an application
Applications hold your credentials and decide which APIs you can call.
- Open My applications and select New application.
- Name it after the project you're building, such as
order-sync. - Register the application with each API it needs to call.
Waiting for approval?
Some APIs approve registrations right away; others need an administrator. You'll get an email as soon as yours is approved. Until then, requests to that API return 403 Forbidden.
2. Generate credentials
Open your application and generate credentials. Which kind you use depends on the API:
| Credential | Best for | How to send it |
|---|---|---|
| API key | Server-to-server calls | Authorization: Bearer <API_KEY> |
| OAuth 2.0 client credentials | Short-lived, scoped tokens | Exchange them for an access token, then send Authorization: Bearer <token> |
Keep your key secret
You can see the full key only once. Store it in a secrets manager or an environment variable, never in source control or client-side code.
Export the key so the examples below can use it:
export API_KEY="paste-your-key-here"
3. Make your first request
List your most recent order:
cURL
JavaScript
Python
curl "https://api.example.com/v1/orders?limit=1" \
-H "Authorization: Bearer $API_KEY"
const response = await fetch('https://api.example.com/v1/orders?limit=1', {
headers: { Authorization: `Bearer ${process.env.API_KEY}` },
})
console.log(await response.json())
import os
import requests
response = requests.get(
"https://api.example.com/v1/orders",
params={"limit": 1},
headers={"Authorization": f"Bearer {os.environ['API_KEY']}"},
)
print(response.json())
A successful request returns 200 OK and a JSON body:
{
"data": [
{
"id": "ord_1042",
"status": "shipped",
"total": 129.00
}
],
"has_more": false
}
4. Check the response
If you didn't get a 200 OK, the status code tells you what to fix:
| Status | Meaning | What to do |
|---|---|---|
401 Unauthorized | The key is missing, revoked, or mistyped. | Check the Authorization header and the key. |
403 Forbidden | Your application isn't registered with this API yet. | Register it, or wait for approval. |
429 Too Many Requests | You're over your rate limit. | Wait for the time in the Retry-After header, then retry. |