API Surfaces and Boundaries
Learn where the API starts and ends, and how it relates to PCAdmin, PCUser, PCCLI, jobs, and database records.
PanelConfig has several operational surfaces. The API is not a replacement for every surface; it is the remote JSON layer. Understanding the boundary prevents unsafe assumptions and keeps integrations maintainable.
Surface Comparison
| Surface | Best for | Access model |
|---|---|---|
| PCAdmin | Provider and operator decisions, security review, account administration | Interactive authenticated users with permissions. |
| PCUser | Customer self-service for hosting resources | Customer-scoped panel sessions. |
| PCCLI | Local server automation, cron, repeatable operator tasks | Shell access and command allowlists. |
| API | Remote JSON read access and integration workflows | Bearer token attached to an active user. |
Current Boundary
The current API files are simple resource endpoints. They authenticate, apply rate limits, read from existing tables, and return the standard JSON envelope. Write-heavy workflows such as provisioning an account, adding DNS records, restoring backups, or restarting services should be documented as planned unless matching route files are added.
Boundary Diagram
flowchart TD
A[API Client] --> B[Bearer Token Check]
B --> C[Role and Account Visibility]
C --> D[Read Existing Records]
D --> E[JSON Envelope]
B --> F[Token Last Used Updated]
B --> G[Request Log Inserted]Operator Advice
When connecting provider systems, start with read-only use cases: inventory sync, health reporting, SSL state checks, and backup visibility. Add write workflows only after the product source includes matching endpoints and those endpoints are tested on staging.