Skip to Content
DocsAPI ReferenceControl Panel API

Control Panel API

Complete reference for the Quazzar Control Panel REST API. All endpoints use the /api/ prefix and require JWT bearer token authentication. Every request is scoped to the authenticated user’s tenant. The base URL is your Control Panel instance (for example, https://panel.quazzar.cloud/api/).

See Authentication for details on obtaining and using tokens.


Authentication

Endpoints for user registration, login, profile management, and TOTP two-factor authentication.

MethodPathDescription
POST/api/auth/registerRegister a new user account
POST/api/auth/loginAuthenticate and receive JWT tokens
GET/api/auth/meGet the current authenticated user
PUT/api/auth/profileUpdate user profile
POST/api/auth/change-passwordChange password
POST/api/auth/totp/enableEnable TOTP two-factor authentication
POST/api/auth/totp/verifyVerify a TOTP code

Fleet Management

Monitor and manage all Cloud OS instances connected to the Control Panel. The fleet API provides a centralized view of instance health, metrics, and remote command execution.

MethodPathDescription
GET/api/fleet/instancesList all connected Cloud OS instances
GET/api/fleet/summaryGet fleet summary (total instances, health overview)
GET/api/fleet/healthGet health status for all instances
GET/api/fleet/metrics/{instanceId}Get metrics for a specific instance
GET/api/fleet/alertsList active alerts across the fleet
POST/api/fleet/commandsSend a command to one or more instances
POST/api/fleet/tokensGenerate a fleet enrollment token

Example: List Fleet Instances

curl https://panel.quazzar.cloud/api/fleet/instances \ -H "Authorization: Bearer <token>"
[ { "id": "inst_abc123", "name": "production-01", "hostname": "cloud.example.com", "version": "0.2.9", "status": "healthy", "apps_count": 12, "cpu_percent": 35.2, "memory_percent": 62.1, "last_seen": "2025-01-15T10:30:00Z" }, { "id": "inst_def456", "name": "staging-01", "hostname": "staging.example.com", "version": "0.2.9", "status": "healthy", "apps_count": 5, "cpu_percent": 12.8, "memory_percent": 28.4, "last_seen": "2025-01-15T10:29:55Z" } ]

Example: Get Fleet Summary

curl https://panel.quazzar.cloud/api/fleet/summary \ -H "Authorization: Bearer <token>"
{ "total_instances": 8, "healthy": 7, "degraded": 1, "offline": 0, "total_apps": 45, "total_cpu_cores": 32, "total_memory_gb": 128 }

Example: Send a Fleet Command

curl -X POST https://panel.quazzar.cloud/api/fleet/commands \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "instance_ids": ["inst_abc123", "inst_def456"], "command": "update", "params": { "version": "0.3.0" } }'

Example: Generate Enrollment Token

curl -X POST https://panel.quazzar.cloud/api/fleet/tokens \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "name": "datacenter-west", "expires_in_hours": 24 }'
{ "token": "flt_abc123def456...", "name": "datacenter-west", "expires_at": "2025-01-16T10:30:00Z" }

Use fleet enrollment tokens to connect new Cloud OS instances to the Control Panel. Pass the token during Cloud OS initial configuration to automatically register the instance.


Billing

Manage subscriptions and licenses for your tenant.

MethodPathDescription
GET/api/billing/subscriptionGet current subscription details
PUT/api/billing/subscriptionUpdate subscription plan
GET/api/billing/licensesList active licenses

Example: Get Subscription

curl https://panel.quazzar.cloud/api/billing/subscription \ -H "Authorization: Bearer <token>"
{ "plan": "pro", "status": "active", "instance_limit": 25, "instances_used": 8, "features": ["fleet-management", "ha-clustering", "governance", "priority-support"], "billing_cycle": "monthly", "next_invoice_date": "2025-02-01T00:00:00Z" }

Governance

Manage compliance policies, canary deployments, GitOps configurations, and governance scores across your fleet.

MethodPathDescription
GET/api/governance/policiesList governance policies
POST/api/governance/policiesCreate a governance policy
PUT/api/governance/policies/{id}Update a governance policy
DELETE/api/governance/policies/{id}Delete a governance policy
GET/api/governance/canaryList canary deployments
POST/api/governance/canaryCreate a canary deployment
PUT/api/governance/canary/{id}Update a canary deployment
GET/api/governance/gitopsList GitOps configurations
POST/api/governance/gitopsCreate a GitOps configuration
PUT/api/governance/gitops/{id}Update a GitOps configuration
GET/api/governance/scoresGet governance scores across the fleet

Example: Create a Governance Policy

curl -X POST https://panel.quazzar.cloud/api/governance/policies \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "name": "Require encrypted backups", "type": "backup", "rule": { "condition": "backup.encryption", "operator": "equals", "value": true }, "enforcement": "mandatory", "applies_to": "all_instances" }'

Example: Get Governance Scores

curl https://panel.quazzar.cloud/api/governance/scores \ -H "Authorization: Bearer <token>"
{ "overall_score": 87, "by_instance": [ { "instance_id": "inst_abc123", "name": "production-01", "score": 92, "violations": 1 }, { "instance_id": "inst_def456", "name": "staging-01", "score": 78, "violations": 4 } ] }

Kubernetes

Manage Kubernetes clusters and deployments through the Control Panel.

MethodPathDescription
GET/api/k8s/clustersList Kubernetes clusters
POST/api/k8s/clustersRegister a Kubernetes cluster
GET/api/k8s/clusters/{id}Get cluster details
PUT/api/k8s/clusters/{id}Update cluster configuration
DELETE/api/k8s/clusters/{id}Remove a cluster
GET/api/k8s/deploymentsList deployments across clusters
POST/api/k8s/deploymentsCreate a deployment
GET/api/k8s/deployments/{id}Get deployment details
PUT/api/k8s/deployments/{id}Update a deployment
DELETE/api/k8s/deployments/{id}Delete a deployment

Example: List Clusters

curl https://panel.quazzar.cloud/api/k8s/clusters \ -H "Authorization: Bearer <token>"
[ { "id": "k8s_abc123", "name": "production-cluster", "provider": "hetzner", "version": "1.29", "nodes": 5, "status": "healthy", "region": "eu-central" } ]

High Availability

Manage high availability clustering and failover for the Control Panel itself.

MethodPathDescription
GET/api/cc/ha/statusGet HA cluster status
GET/api/cc/ha/nodesList HA cluster nodes
POST/api/cc/ha/failoverTrigger a manual failover
POST/api/cc/ha/upgradeInitiate a rolling upgrade

Example: Get HA Status

curl https://panel.quazzar.cloud/api/cc/ha/status \ -H "Authorization: Bearer <token>"
{ "mode": "active-passive", "status": "healthy", "leader": "node-1", "nodes": 3, "replication_lag_ms": 12, "last_failover": "2025-01-10T08:15:00Z" }

Hosting

Manage hosting providers, servers, and infrastructure resources.

MethodPathDescription
GET/api/hosting/providersList configured hosting providers
GET/api/hosting/serversList provisioned servers
POST/api/hosting/serversProvision a new server
GET/api/hosting/servers/{id}Get server details
DELETE/api/hosting/servers/{id}Decommission a server
GET/api/hosting/regionsList available regions
GET/api/hosting/sizesList available server sizes

Example: Provision a Server

curl -X POST https://panel.quazzar.cloud/api/hosting/servers \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "provider": "hetzner", "region": "eu-central", "size": "cx31", "name": "production-03", "install_cloud_os": true }'
{ "id": "srv_abc123", "name": "production-03", "provider": "hetzner", "region": "eu-central", "size": "cx31", "status": "provisioning", "ip_address": null, "created_at": "2025-01-15T10:30:00Z" }

MSP (Managed Service Provider)

Endpoints for managed service providers to manage client organizations and white-label branding.

MethodPathDescription
GET/api/msp/clientsList MSP client organizations
POST/api/msp/clientsCreate a client organization
GET/api/msp/clients/{id}Get client details
PUT/api/msp/clients/{id}Update client configuration
DELETE/api/msp/clients/{id}Remove a client
GET/api/msp/brandingGet current branding configuration
PUT/api/msp/brandingUpdate white-label branding

Example: Create an MSP Client

curl -X POST https://panel.quazzar.cloud/api/msp/clients \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "name": "Acme Corp", "contact_email": "[email protected]", "instance_limit": 10, "plan": "pro" }'

Example: Update White-Label Branding

curl -X PUT https://panel.quazzar.cloud/api/msp/branding \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -d '{ "company_name": "CloudHost Pro", "logo_url": "https://cdn.cloudhost.pro/logo.svg", "primary_color": "#2563EB", "support_email": "[email protected]" }'

MSP features require the Enterprise plan. Client organizations are fully isolated tenants with their own instances, users, and billing.


Partners

Manage partner relationships and partner tier configurations.

MethodPathDescription
GET/api/partnersList partner organizations
POST/api/partnersRegister as a partner
GET/api/partners/{id}Get partner details
PUT/api/partners/{id}Update partner information
GET/api/partner-tiersList available partner tiers

Example: List Partner Tiers

curl https://panel.quazzar.cloud/api/partner-tiers \ -H "Authorization: Bearer <token>"
[ { "id": "tier_silver", "name": "Silver", "discount_percent": 10, "min_instances": 5, "features": ["priority-support", "co-branding"] }, { "id": "tier_gold", "name": "Gold", "discount_percent": 20, "min_instances": 25, "features": ["priority-support", "co-branding", "dedicated-account-manager"] } ]