Docs › Reference
Read-only API
Scripts and other tools can read a workspace through a small JSON API: resources, relationships, impact and the path between two resources. It is read-only — there is no endpoint that changes anything.
Tokens
An admin creates tokens in Settings › API tokens › New API token:
- a token reads one workspace, with the rights of a viewer (owners and notes included);
- it is shown once and stored hashed; copy it into your secret store;
- it expires after 30 days, 90 days, a year, or never;
- Revoke stops it immediately. Creating and revoking tokens is recorded in the audit log.
Send it in the Authorization header:
curl -H "Authorization: Bearer dmp_api_..." https://inframole.example.com/api/v1/workspace
$h = @{ Authorization = "Bearer $env:INFRAMOLE_API_TOKEN" }
Invoke-RestMethod -Headers $h https://inframole.example.com/api/v1/resources?type=SERVER
Conventions
- Every response is JSON. Single objects come as
{ "data": … }; lists as{ "data": [ … ], "next": "<cursor>" | null }. - Pagination:
limit(1–500, default 100). Whennextis not null, ask again withcursor=<next>. - Confidence: every relationship and every affected resource carries
confirmed,detectedorinferred. Onlyconfirmedwas checked by a person; treat the others as suggestions. Impact means could be affected, never will break. - Archived resources and ignored relationships are left out unless you ask
for them (
status=ARCHIVED,status=IGNORED). - Limits: 300 requests per minute per token. Above that:
429with aRetry-Afterheader. - Errors:
401 unauthorized(missing, unknown, revoked or expired token),404 not_found,400 invalid_query(with the fields at fault),429 rate_limited. v1only ever gains fields; nothing is renamed or removed.
Endpoints
GET /api/v1/workspace
The token's workspace: id, name, slug, and how many resources and
relationships it has. A cheap way to check a token.
GET /api/v1/resources
| Parameter | Example | Meaning |
|---|---|---|
type |
SERVER |
SERVER, VM, APPLICATION, DATABASE, … |
environment |
PRODUCTION |
PRODUCTION, STAGING, DEVELOPMENT, TEST, OTHER |
status |
DISCOVERED |
Default: everything except ARCHIVED |
tag |
iis |
Has this tag |
owner |
Platform team |
Owner, exact (any case) |
q |
sql |
Name contains |
Each resource:
{
"id": "cmabc…",
"name": "SQL01",
"type": "SERVER",
"status": "ACTIVE",
"environment": "PRODUCTION",
"criticality": "CRITICAL",
"description": "Main SQL Server",
"notes": null,
"owner": "DBA team",
"ownerContact": "dba@example.com",
"redundancyGroup": "sql-cluster",
"tags": ["sql-server"],
"hostname": "sql01",
"fqdn": "sql01.corp.local",
"os": "Windows Server 2022",
"version": null,
"ipAddresses": ["10.0.0.40"],
"ports": [],
"links": [],
"source": "AGENT",
"sourceLabel": "Agent on SQL01",
"createdAt": "2026-09-01T10:00:00.000Z",
"updatedAt": "2026-10-01T08:12:00.000Z"
}
GET /api/v1/resources/{id}
One resource (archived ones too) with its relationships.
GET /api/v1/relationships
| Parameter | Example | Meaning |
|---|---|---|
status |
CONFIRMED |
CONFIRMED, UNCONFIRMED, IGNORED (default: not ignored) |
type |
USES_DATABASE |
One relationship type |
resource |
cmabc… |
Relationships of this resource (either end) |
Each relationship:
{
"id": "cmdef…",
"type": "USES_DATABASE",
"label": "uses database",
"from": { "id": "cm1…", "name": "Billing", "type": "APPLICATION" },
"to": { "id": "cm2…", "name": "CustomersDB", "type": "DATABASE" },
"status": "CONFIRMED",
"origin": "MANUAL",
"confidence": "confirmed",
"dependency": { "dependent": "cm1…", "dependency": "cm2…" },
"note": null,
"createdAt": "…",
"confirmedAt": "…"
}
Read it as "from label to". dependency says which end depends on
which — it is null for types that do not carry failures (backs up to,
monitored by, related to). Do not work it out from from / to: for
hosts, it is the to end that depends on the from end.
GET /api/v1/resources/{id}/impact
What could be affected if the resource went down. depth (1–10, default 10) limits the hops.
{
"data": {
"resource": { "id": "…", "name": "SQL01", "type": "SERVER" },
"affected": [
{
"resource": { "id": "…", "name": "Billing", "type": "APPLICATION" },
"depth": 2,
"confidence": "confirmed",
"path": [
{ "id": "…", "name": "SQL01" },
{ "id": "…", "name": "CustomersDB" },
{ "id": "…", "name": "Billing" }
],
"relationships": ["…", "…"],
"owner": "Finance apps",
"ownerContact": "finance-apps@example.com"
}
],
"summary": {
"total": 1,
"byConfidence": { "confirmed": 1, "detected": 0, "inferred": 0 },
"byType": { "APPLICATION": 1 }
},
"redundancy": { "degraded": [], "covered": [] },
"whoToWarn": {
"owners": [
{ "owner": "Finance apps", "contact": "finance-apps@example.com", "resources": ["Billing"] }
],
"withoutOwner": []
}
}
}
Each affected resource carries the strongest confidence any path offers, and the shortest such path.
redundancy reflects the redundancy groups
set on resources: degraded lists the groups that lose members
({ group, down: [resource], up: [resource] }) and covered what the
remaining members still serve ({ resource, group, path }) — those are not
in affected. Both are empty without groups.
GET /api/v1/impact?ids={id},{id}
Combined impact of several resources changing together (up to 50 ids,
comma-separated; depth as above). Each affected resource is listed once,
with causes: the ids of the changed resources that reach it. Ids that are
not in the token's workspace (or archived) are only counted in notFound;
when none is found the answer is 404.
{
"data": {
"changed": [{ "id": "…", "name": "SQL01", "type": "SERVER" }, …],
"notFound": 0,
"affected": [
{
"resource": { "id": "…", "name": "Billing", "type": "APPLICATION" },
"depth": 2,
"confidence": "confirmed",
"causes": ["…"],
"path": [{ "id": "…", "name": "SQL01" }, …],
"relationships": ["…", "…"],
"owner": "Finance apps",
"ownerContact": "finance-apps@example.com"
}
],
"summary": { "total": 1, "byConfidence": { … }, "byType": { … } },
"redundancy": { "degraded": [ … ], "covered": [ … ] },
"whoToWarn": { "owners": [ … ], "withoutOwner": [ … ] }
}
}
whoToWarn includes the owners of the changed resources too. redundancy
is as above, with every changed resource down at the same time.
GET /api/v1/path?from={id}&to={id}
How two resources are linked. kind is:
dependsOn— from depends on to, directly or through others;usedBy— to depends on from;connected— they are linked, but neither depends on the other.
{
"data": {
"kind": "dependsOn",
"confidence": "detected",
"path": [{ "id": "…", "name": "IT Portal", "type": "APPLICATION" }, …],
"steps": [{ "from": "…", "to": "…", "relationship": "…", "phrase": "calls", "confidence": "detected" }, …],
"text": "IT Portal may depend on SQL01 (detected, not confirmed):\n- IT Portal calls Billing (detected, not confirmed)\n- Billing uses database CustomersDB\n- CustomersDB runs on SQL01"
}
}
data is null when they are not linked. The path uses the strongest
confidence available, then the fewest hops — the same rule as impact.
text is ready to paste into a change request.
GET /api/v1/resilience
The resilience report: what each resource could affect, single points of failure and the recovery order. Optional parameters:
environment— e.g.PRODUCTION: only resources of that environment;view— a saved view's id: only the resources it shows (404 if it is not in the token's workspace);confidence— which relationships count:confirmed,detected(confirmed and detected, the default) orall.
{
"data": {
"scope": { "environment": null, "view": null, "confidence": "detected" },
"resources": 4,
"relationships": 3,
"unreviewed": 1,
"tooLarge": false,
"ranking": [
{
"resource": { "id": "…", "name": "SQL01", "type": "SERVER" },
"couldAffect": 3,
"byConfidence": { "confirmed": 2, "detected": 1, "inferred": 0 },
"coveredByRedundancy": 0,
"dependsOn": 0,
"singlePointOfFailure": true,
"criticality": "CRITICAL",
"redundancyGroup": null,
"owner": "DBA",
"ownerContact": "dba@example.com"
}
],
"recovery": {
"waves": [
[
{
"resources": [{ "id": "…", "name": "SQL01", "type": "SERVER" }],
"circular": false,
"redundancyGroup": null
}
]
],
"unconnected": [{ "id": "…", "name": "NAS01", "type": "STORAGE" }]
}
}
}
ranking lists every resource in scope, most impact first; couldAffect
is the number its impact page shows (with redundancy), byConfidence splits
it by the weakest link on the way, and dependsOn counts the resources that
could affect it. unreviewed relationships are still waiting in
Suggestions: the numbers can change when they are reviewed. Each wave of
recovery.waves depends only on earlier waves; a step is circular when
its resources depend on each other in a circle. Above 5,000 resources in
scope, tooLarge is true and the lists are empty — narrow the scope.
