Bot Client Endpoints

POST /api/bots/register
Register new bot or reconnect existing HWID. Auto-reconnects if HWID already linked (code validation skipped).
Headers:
  x-hwid: string (required)
  Content-Type: application/json

Body:
  code: string (6 letters, required for first link)
  hwid: string (required)
  robloxUserId: string (required)
  robloxUsername: string (required)
  robloxDisplayName: string (optional)
  metadata: {
    clientVersion: string
    executor: string
    gameId: string
    placeId: string
  }

Response (200):
  { success: true, connected: true, alreadyLinked: boolean }
POST /api/bots/ping
Send heartbeat to keep bot online. Call every 5 seconds. Updates bot status and last seen time.
Headers:
  x-hwid: string (required)
  Content-Type: application/json

Body:
  hwid: string (required)
  robloxUserId: string (required)
  robloxUsername: string (required)
  metadata: {
    gameId: string
    placeId: string
    players: number
    executor: string
  }

Response (200):
  { success: true, targetAccount: { userId, username } }
GET /api/commands/poll
Retrieve pending commands. Returns up to 10 commands, marks them as executing. Poll every 5 seconds.
Headers:
  x-hwid: string (required)
  x-roblox-user: string (username, required)

Query Parameters:
  robloxUserId: string (required)

Response (200):
  { commands: [{ _id, commandType, commandData, status }] }
POST /api/commands/:id/complete
Mark command as completed or failed. Call after executing each command.
Headers:
  x-hwid: string (required)
  Content-Type: application/json

Body:
  success: boolean (required)
  error: string | null (error message if failed)

Response (200):
  { message: "Command marked as completed" }

Error Codes

HWID_REQUIRED - Include x-hwid header in request
CODE_REQUIRED - Provide connection code in body
INVALID_CODE - Code not found, generate new one
CODE_EXPIRED - Code expired (10 minute limit)
HWID_NOT_LINKED - Register with valid code first
BOT_NOT_FOUND - Complete registration process
DIFFERENT_HWID_LINKED - Reset HWID in panel first
401 Unauthorized - Authentication required (web only)

Rate Limiting

Global Limit: 100 requests per 15 minutes per IP address
Recommended Intervals:
• Ping: Every 5 seconds (720 req/hour)
• Poll: Every 5 seconds (720 req/hour)
• Total: ~1440 req/hour (well under limit)
Response (429 Too Many Requests):
  { "error": "Too many requests from this IP..." }

Headers:
  X-RateLimit-Limit: 100
  X-RateLimit-Remaining: 0
  X-RateLimit-Reset: 1704902400 (unix timestamp)

Quick Start

Load bot client with one command in your executor:
_G.CC = "YOUR_CODE"
loadstring(game:HttpGet("https://bot.nyxor.cc/loader"))()
Steps:
1. Generate code in panel (Settings → HWID Connection)
2. Replace YOUR_CODE with your 6-letter code
3. Execute in Roblox game
4. Bot auto-reconnects on future runs (no code needed)