Web API routes
Each console serves its pages and a JSON API on the same origin. The API exists for the console’s own pages: to automate Harbor, use the PowerShell cmdlets. This page lists every route, so you can see what each role can reach and audit the surface.
How every request is handled
Section titled “How every request is handled”- Same origin only. Requests from another origin, or with a host name the console does not serve, are refused before anything else.
- CSRF token. Every state-changing request needs the
X-Harbor-Csrfheader with the token from the console page. - Signed in. Every
/api/route except the sign-in routes needs a session cookie (__Host-harbor_sidon https). On a console in its first run, only/api/statusand the first-run route answer. - Role. The route’s minimum role is checked before it runs: viewer < operator < admin.
- Destructive routes also need a sign-in or identity check within the re-check window (15 minutes by default). See Sign-in overview.
- Async routes can run long against the tenant: the console answers
202with a job id, and the page polls/api/jobs/<id>. - When the console is busy it answers
503withRetry-After; a read that passes its time limit gets504.
Routes the shared web edge answers
Section titled “Routes the shared web edge answers”Both consoles answer these before the route table:
| Method | Path | Who | What it does |
|---|---|---|---|
| POST | /api/auth/login |
anyone (throttled) | Sign in with the emergency (break-glass) account. |
| POST | /api/auth/logout |
anyone | Sign out. |
| POST | /api/auth/reconfirm |
signed in | Confirm your identity before a destructive action (emergency account). |
| POST | /api/auth/bootstrap |
first run, local machine only | Create the emergency account with the one-time setup code. |
| POST | /api/auth/break-glass |
the emergency account (current password), or an admin with a recent sign-in when none exists | Change, or create, the emergency account. |
| GET | /auth/login |
anyone | Start a CyberArk single sign-on. |
| GET | /auth/callback |
anyone (the identity provider redirects here) | Finish a CyberArk single sign-on. |
| POST | /api/_stop |
admin (or the demo operator) | Stop the console, after in-flight requests finish. |
| POST | /api/_clientlog |
anyone with the page’s CSRF token | Record a browser-side error in the console log. |
Harbor Onboard 0.59.0 (port 8787)
Section titled “Harbor Onboard 0.59.0 (port 8787)”61 routes in the route table.
| Method | Path | Summary | Minimum role | Async | Destructive |
|---|---|---|---|---|---|
| GET | /api/jobs/<id> |
Returns the state or result of a background job this session started. | viewer | No | No |
| GET | /api/jobs/<id> |
Serves the offline documentation read-only, with no sign-in (handled by the web edge). | viewer | No | No |
| POST | /api/account |
Adds one account to a safe. | operator | No | No |
| POST | /api/account-action |
Verifies, changes or reconciles the credential of one account or of every account in a safe. | operator | No | No |
| GET | /api/accounts |
Returns the entries of the local account register. | viewer | No | No |
| GET | /api/activity |
Returns the most recent activity-log entries. | viewer | No | No |
| POST | /api/assist/explain-drift |
Asks the Claude assistant to explain one safe’s drift in plain English. | operator | Yes | No |
| POST | /api/assist/safe-suggestion |
Asks the Claude assistant to suggest a standard safe from a description. | operator | Yes | No |
| GET | /api/assist/status |
Reports whether the Claude assistant is available on this profile. | viewer | No | No |
| GET | /api/audit-verify |
Verifies one day’s audit-log hash chain and reports any break. | viewer | No | No |
| GET | /api/categorize |
Groups the vault’s safes by the safe type their name parses to, as a background job. | viewer | Yes | No |
| POST | /api/compliance |
Runs a one-off compliance report and records a trend line. | operator | No | No |
| GET | /api/compliance-history |
Returns the compliance trend lines recorded by past reports. | viewer | No | No |
| POST | /api/compliance-scan |
Runs a compliance scan that stores a snapshot and alerts on new drift, as a background job. | operator | Yes | No |
| GET | /api/compliance-schedule |
Reports the scheduled compliance scan and its latest snapshot. | viewer | No | No |
| POST | /api/compliance-schedule |
Registers or removes the scheduled compliance scan. | admin | No | No |
| GET | /api/compliance-snapshot-diff |
Compares two stored compliance snapshots. | viewer | No | No |
| GET | /api/compliance-snapshots |
Lists the stored compliance snapshots, newest first. | viewer | No | No |
| GET | /api/config |
Returns one standards document (naming, rbac or safe-defaults) as text. | viewer | No | No |
| POST | /api/config |
Saves one standards document. | admin | No | No |
| GET | /api/config-changes |
Returns the standards change history with field-level differences. | viewer | No | No |
| POST | /api/config-impact |
Previews the effect of a proposed standards change and writes nothing. | operator | No | No |
| POST | /api/connect |
Connects the console to the vault with its service account. | admin | No | No |
| GET | /api/cpms |
Lists the managing CPMs configured for the served profile. | viewer | No | No |
| POST | /api/cpms |
Saves the list of managing CPMs. | admin | No | No |
| GET | /api/cpms/discover |
Returns the CPM names found in the vault, from the cached scan. | viewer | No | No |
| POST | /api/cpms/discover |
Rescans the vault for CPM names and refreshes the cache. | operator | No | No |
| POST | /api/decommission |
Decommissions a safe, which needs a recent identity check. | operator | No | Yes |
| POST | /api/disconnect |
Ends the caller’s own vault session, or the console’s service session for an admin. | operator (stricter for some requests, see the roles matrix) | No | No |
| GET | /api/doctor |
Runs the setup checks and returns each result. | viewer | No | No |
| GET | /api/drift |
Compares every registered safe’s members with the standard, as a background job. | viewer | Yes | No |
| GET | /api/health |
Tests the connection to the CyberArk tenant. | viewer | No | No |
| POST | /api/import-accounts |
Adds accounts in bulk from an uploaded CSV. | operator | No | No |
| POST | /api/import-safes |
Creates safes in bulk from an uploaded CSV. | operator | No | No |
| GET | /api/logs |
Exports one day’s activity log in the requested format. | viewer | No | No |
| GET | /api/monthly-summary |
Returns the monthly roll-up of registers, compliance and activity, or its HTML report. | viewer | No | No |
| GET | /api/ops-dashboard |
Returns the Harbor Home operations board in one call, as a background job. | viewer | Yes | No |
| GET | /api/permissions |
Returns the persona permission matrix, for every safe type or for one. | viewer | No | No |
| GET | /api/platforms |
Lists the active platforms in the vault. | viewer | No | No |
| GET | /api/register |
Returns the entries of the local safe register. | viewer | No | No |
| POST | /api/register-refresh |
Rebuilds the safe register from the vault and returns it, as a background job. | operator | Yes | No |
| POST | /api/repair |
Brings a safe’s members back to the standard; removing members needs a recent identity check. | operator | No | Sometimes: Destructive only when it removes unexpected members. |
| GET | /api/rogue-safes |
Lists vault safes that are unregistered or break the naming standard, as a background job. | viewer | Yes | No |
| POST | /api/safe |
Creates a safe from the standard, or a safe under a governed naming exception. | operator | No | No |
| POST | /api/safe-exception |
Accepts or revokes a governed naming exception on an existing safe. | operator | No | No |
| GET | /api/safe-members |
Lists the members of one vault safe. | viewer | No | No |
| GET | /api/safe-passport |
Returns one safe’s lifecycle: register entry, accounts, history and live members. | viewer | No | No |
| GET | /api/service-account |
Describes the console’s service account and where its secret lives, never the secret. | viewer | No | No |
| POST | /api/service-account |
Sets, changes or removes the console’s service account. | admin | No | Yes |
| POST | /api/settings/tenant |
Saves the tenant and connection settings of a profile. | admin | No | No |
| GET | /api/sso-setup |
Returns the CyberArk Identity SSO settings for the setup wizard. | admin | No | No |
| POST | /api/sso-setup |
Checks the issuer, then saves or turns off CyberArk Identity SSO. | admin | No | Yes |
| GET | /api/standard |
Returns the naming standard (segments, safe types and length budget) for the served profile. | viewer | No | No |
| GET | /api/status |
Reports the console’s vault connection, sign-in state, served profile and suite map. | viewer | No | No |
| POST | /api/sync |
Reconciles the safe register with the vault. | operator | No | No |
| GET | /api/template |
Returns a CSV import template for safes or accounts as text. | viewer | No | No |
| POST | /api/validate |
Checks a safe name or account name against the standard and writes nothing. | viewer | No | No |
| GET | /api/vault-accounts |
Searches the vault’s accounts live, with a capped number of results. | viewer | No | No |
| GET | /api/vault-export |
Returns the vault governance evidence pack as JSON, with safe members on request. | viewer | No | No |
| GET | /api/zones |
Returns the fleet zones for the Harbor Home environment view. | viewer | No | No |
| POST | /api/zones |
Saves the fleet zones. | admin | No | No |
Harbor Health 0.22.0 (port 8788)
Section titled “Harbor Health 0.22.0 (port 8788)”20 routes in the route table.
| Method | Path | Summary | Minimum role | Async | Destructive |
|---|---|---|---|---|---|
| GET | /api/jobs/<id> |
Returns the state or result of a background job this session started. | viewer | No | No |
| GET | /api/jobs/<id> |
Serves the offline documentation read-only, with no sign-in (handled by the web edge). | viewer | No | No |
| GET | /api/checks |
Returns the check catalogue with its scoring facts and which checks are turned on. | viewer | No | No |
| POST | /api/checks-config |
Sets which checks are turned off for the served profile. | admin | No | No |
| GET | /api/components |
Returns the component fleet from the cache, collecting it when needed, as a background job. | viewer | Yes | No |
| POST | /api/components |
Collects the component fleet live from the tenant, as a background job. | operator | Yes | No |
| POST | /api/connect |
Connects the console to the tenant with its service account. | admin | No | No |
| POST | /api/disconnect |
Ends the caller’s own vault session, or the console’s service session for an admin. | operator (stricter for some requests, see the roles matrix) | No | No |
| POST | /api/health-scan |
Runs a health scan of every check, a pillar or named checks, as a background job. | operator | Yes | No |
| GET | /api/health-schedule |
Reports the scheduled health scan. | viewer | No | No |
| POST | /api/health-schedule |
Registers or removes the scheduled health scan. | admin | No | No |
| GET | /api/history |
Lists past scans, or returns one stored scan by id. | viewer | No | No |
| GET | /api/last-result |
Returns the most recent scan result. | viewer | No | No |
| GET | /api/remediation |
Lists the recorded remediation decisions. | viewer | No | No |
| POST | /api/remediation |
Records a remediation decision for a check and changes no tenant state. | operator | No | No |
| GET | /api/report |
Returns the HTML report of a stored scan, the latest by default. | viewer | No | No |
| GET | /api/server-detail |
Reads one server’s operating-system telemetry over WinRM, as a background job. | viewer | Yes | No |
| GET | /api/status |
Reports the console’s tenant connection, sign-in state, served profile and suite map. | viewer | No | No |
| GET | /api/thresholds |
Returns the effective thresholds and the settings that can be tuned. | viewer | No | No |
| POST | /api/thresholds |
Saves or resets the threshold overrides. | admin | No | No |
Covers Harbor Onboard 0.59.0 / Harbor Health 0.22.0. On an older release? Upgrading and the release notes list what changed.
