Developer API — Getting Started
Generate an API key, authenticate your requests, and make your first call in minutes.
Getting Your API Key
API keys authenticate your requests to the Staty API. They are required for all POST and PUT (write) operations, and recommended for GET requests to access private data.
Read-only GET requests on public data may not require a key, but all write operations do. When in doubt, include your key — it also unlocks higher rate limits.
How to create a key
- Log in to the Staty Admin dashboard
- Go to Settings → API Keys
- Click Create API Key
- Give the key a descriptive name (e.g. “Schedule Widget”, “Registration Bot”)
- Select the scopes your integration needs
- Copy the key immediately — it is only shown once
Keys are prefixed sk_live_ for production. Keep them secret — never embed them in client-side JavaScript or commit them to source control.
sk_live_abc123xyz789...Authentication
All API requests require an Authorization header with a Bearer token:
Authorization: Bearer sk_live_abc123...Available Scopes
| Scope | Access |
|---|---|
read:leagues | Read seasons, tournaments, divisions |
read:teams | Read teams and rosters |
read:players | Read player profiles and stats |
read:games | Read game schedule and scores |
read:registrations | Read registration submissions |
write:registrations | Submit registrations on behalf of users |
read:payments | Read payment status |
admin | Full read/write access |
Make Your First Request
Base URL: https://api.staty.io/api/v1
All responses follow this envelope:
{
"success": true,
"data": [ ... ],
"count": 5
}curl
curl https://api.staty.io/api/v1/leagues \
-H "Authorization: Bearer sk_live_..."JavaScript (fetch)
const res = await fetch(
'https://api.staty.io/api/v1/leagues',
{
headers: {
'Authorization': 'Bearer sk_live_...'
}
}
);
const { data } = await res.json();
console.log(data); // array of leagues for your orgExplore the API Reference
| Resource | Endpoint |
|---|---|
| Leagues | /api/v1/leagues |
| Tournaments | /api/v1/tournaments |
| Divisions | /api/v1/divisions |
| Registrations | /api/v1/registrations |
| Players | /api/v1/players |
| Games | /api/v1/games |
Last updated on