Admin API
The Admin API lives under /admin on the same host and port as the Web API.
| Route | Purpose |
|---|---|
GET /admin/health |
{status, ...}; 503 when the status is Unhealthy, 200 otherwise |
GET /admin/doctor |
self-checks (configuration, authentication, migrations, the file store, plug-ins) |
GET /admin/logs?level=&since=&take= |
recent log entries from an in-memory ring buffer (take 1 to 1000) |
GET /admin/orgs, POST /admin/orgs, DELETE /admin/orgs/{database} |
organization databases |
POST /admin/orgs/{database}/backup, POST /admin/orgs/{database}/restore |
backup and restore |
DELETE /admin/solutions/{uniquename}?cascade=true |
cascade delete of a solution (cascade=true is required) |
GET /admin/hierarchy-security, PUT /admin/hierarchy-security |
the manager hierarchy security model: {enabled, depth, excludedTables[]}. PUT takes any of the three: the parts given replace the current ones (excludedTables replaces the whole list). An unknown table or a depth outside 1 to 100 is a 400 and nothing is written. See Security |
GET /admin/schema, POST /admin/schema/apply?dryRun= |
export and apply a schema file; dryRun defaults to true (pass dryRun=false to write); rejections are a 400 with the plan |
Every route requires a valid token and the System Administrator role. No token is 401; a valid token without the
role is 403 with code 0x80040220 ("The Admin API requires the System Administrator role."), in the same JSON error
format as the Web API. /admin/health is admin-only too, which is why xrmd server status needs a profile. For an
unauthenticated liveness probe use GET /healthz (as the Docker health check does).
The authoring API
Workflow authoring as code has its own route group, /authoring/workflows, beside the Admin API on the same host and port (see
Workflow authoring as code). It is not admin-only: it needs a valid token (401 without one) and no
role, because every operation is a request as the caller and the Dataverse privileges on workflow decide
(Security). /admin stays for System Administrators. Errors use the Web API error envelope.
| Route | Purpose |
|---|---|
POST /authoring/workflows/apply?dryRun=&solution=&activate= |
body: the YAML (text/yaml, at most 1 MiB); dryRun defaults to true, as POST /admin/schema/apply. 200 with { id, name, action, state, stateChanged, assumedShapes, errors }; 400 with the same body when errors is not empty (nothing is written) |
GET /authoring/workflows?kind=&entity= |
the list: id, name, kind, entity, mode, state, unsupportedSteps |
GET /authoring/workflows/{nameOrId}?format=yaml|xaml |
the process as YAML (text/yaml, the default) or its XAML (text/xml); a process with no YAML form is a 400 with the reasons |
POST /authoring/workflows/{nameOrId}/activate, /deactivate |
change the state; the response is the summary after |
A name that contains / must be given by its id. A name that matches several processes is a 400 listing their ids; an unknown
name or id is 404.