๐Ÿ”Œ API Documentation

Build powerful integrations with our RESTful API. Manage servers, games, billing, and more programmatically.

Version 1.0

๐Ÿ”‘ Authentication

All API requests require an API key. Include it in the X-API-Key header or as a bearer token.

Generate Your API Key

Log in to generate your API key.

Authorization: Bearer YOUR_API_KEY
X-API-Key: YOUR_API_KEY

๐Ÿ“ Base URL

https://yourdomain.com/api/v1

All endpoints are prefixed with /api/v1. The API version is included in the URL to ensure backward compatibility.

๐Ÿ–ฅ๏ธ Servers

GET /servers List all servers

Returns a list of all servers owned by the authenticated user.

Response

{ "servers": [ { "id": 1, "name": "My Minecraft Server", "status": "running", "slots": 20, "location": "US-East" } ], "total": 1 }
GET /servers/{id} Get server details

Returns detailed information about a specific server.

Parameter Type Description
id integer Server ID (required)
POST /servers Create a new server

Creates a new game server.

Parameter Type Description
name string Server name (required)
game_id integer Game ID (required)
slots integer Number of player slots
location string Server location
DELETE /servers/{id} Delete a server

๐ŸŽฎ Games

GET /games List available games

Returns a list of all available games for hosting.

Query Parameters

Parameter Type Description
category string Filter by category
search string Search by name

๐Ÿ’ณ Billing

GET /billing List invoices
GET /billing/{id} Get invoice details

๐Ÿ“Š System Status

GET /status Get system status (public)

Returns current system health status. This endpoint is public and does not require authentication.

โšก Rate Limits

The API has a rate limit of 100 requests per day per API key. Rate limit headers are included in all responses:

X-RateLimit-Limit: 100
X-RateLimit-Remaining: 95
X-RateLimit-Reset: 1640000000

โŒ Error Responses

Errors are returned in a consistent format:

{ "error": "Resource not found", "status": 404 }

HTTP Status Codes

Code Description
200Success
201Created
400Bad Request
401Unauthorized
403Forbidden
404Not Found
429Rate Limit Exceeded
500Server Error

๐Ÿงช API Sandbox

Test API endpoints directly from your browser.

Response will appear here...