Developer Portal

Quickstart

EdgeBalancer is an API-first platform. Every operation available in the dashboard is also available via the REST API. Authentication uses JWT cookies set by Google OAuth.

  1. Sign in at edge.nexoral.in/login — this sets a JWT cookie.
  2. Call any API endpoint with credentials included (withCredentials: true).
  3. Use the AI agent at POST /api/ai/generate for natural-language provisioning.

API Reference

Full OpenAPI 3.1 specification with all endpoints, schemas, and rate limits:

Authentication

All API requests require a JWT cookie set by POST /api/auth/google with a Firebase ID token. The cookie is httpOnly and auto-sent by the browser. For programmatic access, use a headless browser or extract the cookie.

Two-factor authentication (TOTP or WebAuthn passkeys) adds a second login step when enabled. The /api/auth/google response includes twoFactorRequired: true when 2FA is active.

AI Agent

The AI agent accepts natural language and executes real API calls. Send a prompt to POST /api/ai/generate and receive an SSE stream of events.

curl -X POST https://edge.nexoral.in/api/ai/generate \
  -H "Content-Type: application/json" \
  -b "token=YOUR_JWT" \
  -d '{"prompt": "Create a round-robin load balancer for example.com with origins https://a.com and https://b.com"}'

Rate limit: 30 requests per 15 minutes per user.

MCP Server

Model Context Protocol server — connect AI coding assistants directly to your EdgeBalancer account. One endpoint, 15 tools, OAuth 2.0 authentication.

https://apiedge.nexoral.in/mcp

Connect your client

Claude Code
claude mcp add edgebalancer --transport http https://apiedge.nexoral.in/mcp
Cursor
{ "mcpServers": { "edgebalancer": { "url": "https://apiedge.nexoral.in/mcp" } } }
OpenCode
{ "mcp": { "edgebalancer": { "type": "http", "url": "https://apiedge.nexoral.in/mcp" } } }
Codex
[mcp_servers.edgebalancer] url = "https://apiedge.nexoral.in/mcp" transport = "http"

Available tools (15)

list_load_balancers get_load_balancer create_load_balancer update_load_balancer delete_load_balancer pause_load_balancer resume_load_balancer list_gateways get_gateway create_gateway update_gateway delete_gateway pause_gateway resume_gateway list_zones

Authentication

MCP uses OAuth 2.0 with dynamic client registration. On first connect, your client opens a browser for consent. After approval, a JWT is issued for subsequent requests.

  • Discovery: GET /.well-known/oauth-protected-resource
  • Registration: POST /mcp/auth/register
  • Authorization: GET /mcp/auth/authorize
  • Token exchange: POST /mcp/auth/token

Endpoints Overview

GET
/api/loadbalancers
List load balancers
POST
/api/loadbalancers
Create load balancer
PUT
/api/loadbalancers/:id
Update load balancer
DELETE
/api/loadbalancers/:id
Delete load balancer
POST
/api/loadbalancers/:id/pause
Pause load balancer
POST
/api/loadbalancers/:id/resume
Resume load balancer
GET
/api/gateways
List gateways
POST
/api/gateways
Create gateway
POST
/api/ai/generate
AI agent (SSE)
GET
/api/sessions
Deployment history
GET
/api/stats
Public stats
GET
/health
Health check

Rate Limits

All API responses include rate limit headers:

  • X-RateLimit-Limit — max requests in window
  • X-RateLimit-Remaining — remaining requests
  • X-RateLimit-Reset — seconds until window resets

Default: 100 requests/minute per IP. Mutating endpoints (create, update, delete): 5 requests/15 minutes.

Resources