Skip to main content

Authentication

The CrateBytes Game API offers Steam Authentication for secure logins with Steam accounts and Guest Authentication for access without registration using project public keys.

Sessions

Manage player sessions with the CrateBytes Game API for tracking player activity and engagement. Start, maintain, and end player sessions.

Leaderboards

Implement global leaderboards and rankings with the CrateBytes Game API to boost player competitiveness and engagement. Submit scores and retrieve rankings.

Player Metadata

Store and retrieve player metadata with the CrateBytes Game API. Manage player-specific data and settings.

Base URL

All Game API endpoints are prefixed with /api/game/.

Authentication

Most endpoints require authentication using a JWT token obtained from the authentication endpoints. Include the token in the Authorization header:
Authorization: Bearer <your-jwt-token>

Response Format

All API responses follow a consistent format:
{
  "statusCode": 200,
  "data": {
    // Response data here
  }
}

Error Handling

Errors are returned with appropriate HTTP status codes and error messages:
{
  "statusCode": 400,
  "error": {
    "message": "Error description"
  }
}