REST API Reference

Direct REST API access for custom integrations. The Java SDK uses these endpoints internally.

Base URL

https://ilicence.ch/api/v1

All endpoints are relative to this base URL. Use HTTPS only. HTTP requests are not supported.

POST /license/verify

Verify a license and get its details. This is the primary endpoint.

Request

{
  "license_key": "XXXX-XXXX-XXXX-XXXX",
  "plugin_id": "your-plugin-slug",
  "server_ip": "123.45.67.89",
  "server_port": 25565
}

Parameters:

license_keystring

The license key to verify (required)

plugin_idstring

Your plugin slug from the dashboard (required)

server_ipstring

Server's public IP address (required)

server_portinteger

Server's port, usually 25565 (required)

Response

{
  "valid": true,
  "license": {
    "type": "PERMANENT",
    "expires_at": null,
    "max_servers": 3,
    "active_servers": 1
  }
}

Response Fields:

validboolean

True if license is valid

license.typestring

PERMANENT, SUBSCRIPTION, or TRIAL

license.expires_attimestamp

ISO 8601 datetime (null for PERMANENT)

license.max_serversinteger

Maximum concurrent servers allowed

license.active_serversinteger

Currently active servers using this license

Error Response

{
  "valid": false,
  "error": "revoked",
  "message": "This license has been revoked"
}

Common error values:

invalid_key

Key format is wrong

not_found

Key doesn't exist

revoked

License was revoked

expired

License expired (SUBSCRIPTION/TRIAL)

max_servers

Too many servers using this key

disabled

Plugin is disabled in dashboard

Example Request

curl -X POST https://ilicence.ch/api/v1/license/verify \
  -H "Content-Type: application/json" \
  -d '{"license_key":"XXXX-XXXX-XXXX-XXXX","plugin_id":"my-plugin","server_ip":"123.45.67.89","server_port":25565}'

HTTP Status Codes

200 OK

Request successful. Check response.valid for license status.

400 Bad Request

Missing or invalid parameters. Check request body.

401 Unauthorized

Authentication failed (shouldn't happen with public API)

429 Too Many Requests

Rate limit exceeded. See Rate Limiting section.

500 Server Error

ILicence API error. Grace period kicks in for SDK.

Rate Limiting

Rate limits are per IP address. The SDK is optimized to minimize API calls through caching and heartbeat intervals.

Free

25/hour

Pro

200/hour

Ultra

Unlimited

Rate limit headers

Rate limit info is included in response headers:

X-RateLimit-Limit: 25

X-RateLimit-Remaining: 20

X-RateLimit-Reset: 1617235200

Server Binding

License keys are bound to server IP + port. Each license can be active on multiple servers (up to max_servers limit).

How Server Binding Works:

  • First verify: Server is recorded as active for this license
  • Heartbeat: Server checks in every 6 hours (configurable)
  • Inactive: Server removed after 7 days of no heartbeat
  • Multi-server: Max 3 servers on Free tier, 10 on Ultra

Testing locally

When testing, your local machine's IP (e.g., 192.168.1.100) is different from your production server. You can use multiple keys or update the binding in the dashboard.

Best Practices

  • Use the Java SDK instead of direct REST calls. It handles caching, heartbeat, and error handling.
  • Cache responses for at least 12 hours. Each check is an API call.
  • Always include server_ip and server_port. Used for multi-server detection.
  • Handle timeouts gracefully. Use grace period (24h default) for temporary API downtime.
  • Log errors to console but don't expose sensitive data (API responses) to players.
  • Never hardcode license keys. Always read from config files.

API Status

Uptime SLA

99.9%

Response Time

< 100ms (avg)

Status Page

status.irixiagroup.ch