Complete list of error responses for all API endpoints
All API endpoints return consistent error responses in JSON format. Each error includes an error message and success status.
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"API token is required", "success": false}
{"error":"Game player token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid game player token", "success": false}
{"error":"Player does not belong to this game", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"API private token is required", "success": false}
{"error":"Invalid API token or private token", "success": false}
{"error":"API token is required", "success": false}
{"error":"Game player token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player or does not belong to game", "success": false}
{"error":"Invalid endpoint", "success": false}
{"error":"Method not allowed", "success": false}
{"error":"Database error", "success": false}
{"error":"An unexpected error occurred", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Player name is required", "success": false}
{"error":"Failed to register player", "success": false}
{"error":"API token and game player token are required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid game player token", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token and game player token are required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Failed to update heartbeat", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token and game player token are required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token and game player token are required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"New name is required", "success": false}
{"error":"Player name must be between 2 and 50 characters", "success": false}
{"error":"Failed to update player name", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token and private token are required", "success": false}
{"error":"Invalid API credentials", "success": false}
{"error":"API token and private token are required", "success": false}
{"error":"Invalid API credentials", "success": false}
{"error":"player_id is required", "success": false}
{"error":"ban_duration is required (hour, day, week, month, quarter, year, forever)", "success": false}
{"error":"Invalid ban_duration. Must be one of: hour, day, week, month, quarter, year, forever", "success": false}
{"error":"Player not found or does not belong to this game", "success": false}
{"error":"API token and private token are required", "success": false}
{"error":"Invalid API credentials", "success": false}
{"error":"player_id is required", "success": false}
{"error":"Player not found or does not belong to this game", "success": false}
{"error":"Method not allowed", "success": false}
{"error":"Invalid endpoint", "success": false}
{"error":"Internal server error", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are already in a game room. Leave current room first.", "success": false}
{"error":"You cannot create a game room while in a matchmaking lobby.", "success": false}
{"error":"Failed to create room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Failed to list rooms", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are already in another room", "success": false}
{"error":"Room not found", "success": false}
{"error":"Room inactive", "success": false}
{"error":"Room is full", "success": false}
{"error":"Incorrect password", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any room", "success": false}
{"error":"You are not in this room", "success": false}
{"error":"Room not found", "success": false}
{"error":"Players are not allowed to leave this room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Player is not in any room", "success": false}
{"error":"Failed to update heartbeat", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Missing action_type", "success": false}
{"error":"request_data_json must be a string", "success": false}
{"error":"Player is not in any room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Player is not in any room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any room", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Status is required", "success": false}
{"error":"response_data_json must be a string", "success": false}
{"error":"response_data is not valid JSON", "success": false}
{"error":"Action not found or already processed", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Player is not in any room", "success": false}
{"error":"Missing required field: target_players", "success": false}
{"error":"Missing required field: type", "success": false}
{"error":"Missing required field: target_players_ids", "success": false}
{"error":"Invalid target players ids", "success": false}
{"error":"No valid target players found", "success": false}
{"error":"Invalid target players", "success": false}
{"error":"Failed to send updates", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Player is not in any room", "success": false}
{"error":"No valid source players found", "success": false}
{"error":"Invalid from players", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any game room", "success": false}
{"error":"Only host can stop game room", "success": false}
{"error":"Failed to stop game room", "success": false}
{"error":"You are banned", "success": false}
{"error":"Invalid endpoint", "success": false}
{"error":"Internal server error", "success": false}
{"error":"Method not allowed. Use POST.", "success": false}
{"error":"api_token is required", "success": false}
{"error":"Invalid or expired api_token", "success": false}
{"error":"Invalid JSON body", "success": false}
{"error":"sort_by must be a non-empty array of field names", "success": false}
{"error":"limit must be between 1 and 100", "success": false}
{"error":"No valid sort fields provided after sanitization", "success": false}
{"error":"Database error", "success": false}
{"error":"Server error", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are already in a matchmaking lobby", "success": false}
{"error":"You cannot create matchmaking while in a game room. Leave room first.", "success": false}
{"error":"Missing required field: max_players", "success": false}
{"error":"Failed to create matchmaking lobby", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Missing required parameter: matchmakingId", "success": false}
{"error":"You are already in a matchmaking lobby", "success": false}
{"error":"You already have a pending request to this matchmaking lobby", "success": false}
{"error":"Matchmaking lobby not found or already started", "success": false}
{"error":"Matchmaking lobby is full", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Missing required parameter: matchmakingId", "success": false}
{"error":"You are already in a matchmaking lobby", "success": false}
{"error":"Matchmaking lobby not found or already started", "success": false}
{"error":"This matchmaking lobby requires host approval. Use /request endpoint instead.", "success": false}
{"error":"Matchmaking lobby is full", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any matchmaking lobby", "success": false}
{"error":"Players are not allowed to leave this matchmaking lobby", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any matchmaking lobby", "success": false}
{"error":"Failed to get players", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in any matchmaking lobby", "success": false}
{"error":"Failed to update heartbeat", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in a matchmaking lobby", "success": false}
{"error":"Only host can remove matchmaking lobby", "success": false}
{"error":"Failed to remove matchmaking lobby", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Failed to get matchmaking status", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Missing required parameter: requestId", "success": false}
{"error":"Request not found or you are not the requester", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Missing required fields: requestId and action", "success": false}
{"error":"Action must be \"approve\" or \"reject\"", "success": false}
{"error":"Request not found or already processed", "success": false}
{"error":"Only the host can respond to join requests", "success": false}
{"error":"Matchmaking lobby not found or already started", "success": false}
{"error":"Matchmaking lobby is full", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in a matchmaking lobby", "success": false}
{"error":"Only host can start matchmaking", "success": false}
{"error":"Matchmaking lobby not found or already started", "success": false}
{"error":"Lobby must be full to start (strict_full enabled)", "success": false}
{"error":"You are banned", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"You are not in a matchmaking lobby", "success": false}
{"error":"Only host can stop matchmaking lobby", "success": false}
{"error":"Cannot stop matchmaking lobby after it has been started", "success": false}
{"error":"Failed to stop matchmaking lobby", "success": false}
{"error":"You are banned", "success": false}
{"error":"Invalid endpoint", "success": false}
{"error":"Internal server error", "success": false}
{"error":"API token is required", "success": false}
{"error":"Invalid API token", "success": false}
{"error":"Invalid player token", "success": false}
{"error":"Player token is required", "success": false}
{"error":"Player is not in a realtime-enabled room", "success": false}
{"error":"Failed to generate realtime token", "success": false}
{"error":"You are banned", "success": false}
{"error":"Invalid endpoint", "success": false}
{"error":"Internal server error", "success": false}
{"error":"Method not allowed", "success": false}
{"error":"API key is required", "success": false}
{"error":"Invalid API key", "success": false}
{"error":"Internal server error", "success": false}
{"error":"Method not allowed. Use POST.", "success": false}
{"error":"api_token is required", "success": false}
{"error":"Invalid or expired api_token", "success": false}
{"error":"Invalid JSON body", "success": false}
{"error":"text is required and must be a string", "success": false}
{"error":"text must be at most 1000 characters", "success": false}
{"error":"Too many requests", "success": false, "retry_after": 12}
{"error":"Database error", "success": false}
{"error":"Server error", "success": false}