cURL
curl --request POST \ --url https://api.superbox.ai/api/v1/auth/login \ --header 'Content-Type: application/json' \ --data ' { "email": "<string>", "password": "<string>", "provider": "<string>", "id_token": "<string>", "access_token": "<string>", "refresh_token": "<string>" } '
{ "id_token": "<string>", "refresh_token": "<string>", "expires_in": 123, "email": "<string>", "local_id": "<string>" }
Authenticate with email and password or an OAuth provider
POST /api/v1/auth/login
curl -X POST https://api.superbox.ai/api/v1/auth/login \ -H "Content-Type: application/json" \ -d '{ "email": "user@example.com", "password": "SecurePass123!" }'
POST /api/v1/auth/login/provider
google
github
access_token
id_token
curl -X POST https://api.superbox.ai/api/v1/auth/login/provider \ -H "Content-Type: application/json" \ -d '{ "provider": "google", "id_token": "<firebase-google-id-token>" }'
Authorization: Bearer <id_token>
/auth/refresh
{ "id_token": "eyJhbGciOiJSUzI1NiIsImtpZCI6...", "refresh_token": "AMf-vByW3...", "expires_in": 3600, "email": "user@example.com", "local_id": "abc123def456" }
{ "status": "error", "detail": "Invalid email or password" }
POST /api/v1/auth/refresh
curl -X POST https://api.superbox.ai/api/v1/auth/refresh \ -H "Content-Type: application/json" \ -d '{"refresh_token": "AMf-vByW3..."}'
curl https://api.superbox.ai/api/v1/servers \ -H "Authorization: Bearer eyJhbGciOiJSUzI1NiIsImtpZCI6..."