メインコンテンツへスキップ

get-cloud-diagrams-stats

dci get-cloud-diagrams-stats [flags]

Returns a list of all diagrams with activity stats for the given time period.

Examples

# Every diagram with its cloud account, import status, and change counts.
dci get-cloud-diagrams-stats
# Activity stats for August 2026 (RFC 3339 timestamps).
dci get-cloud-diagrams-stats --start 2026-08-01T00:00:00Z --end 2026-09-01T00:00:00Z
# As JSON, e.g. to pick the `ss_id` (layer ID) that the other cloud-diagram commands take.
dci get-cloud-diagrams-stats --output json

Flags

FlagTypeDefaultExampleDescription
--startstring (date-time)2026-04-01T00:00:00ZStart of the period.
--endstring (date-time)2026-04-28T00:00:00ZEnd of the period.

Every command also accepts the CLI-wide flags for output shaping — see Output formats and Table output options.

Output

OK - List of diagrams with stats returned.

By default dci renders the result as a table. Use --output json to get the full structure described below — see Output formats.

FieldTypeDescription
[]._idstringID of the diagram.
[].ss_idstringID of the layer the diagram belongs to.
[].namestringName of the diagram.
[].typestringType of the diagram. One of: "application", "infrastructure", "network", "template".
[].account_namestringCloud account name.
[].account_idstringCloud account ID.
[].account_typestringCloud account type.
[].changesarray of objectActivity changes within the period.
[].changes[].typestringType of the change. One of: "NODE_CREATE", "NODE_UPDATE", "NODE_DELETE".
[].changes[].servicestringCloud service the change applies to.
[].changes[].countintegerNumber of occurrences of this change type.
[].importobjectCurrent import/sync state for a cloud-connected diagram.
[].import.statusstringImport status. One of: "queued", "in_progress", "success", "failure".
[].import.typestringConnected cloud account type. One of: "AWS", "GCP", "AZURE".
[].import.accountstringConnected account ID.
[].import.cloudIdstringCloud account ID.
[].import.errorMessagestringError message if the import failed.
[].import.syncedAtstring (date-time)Timestamp of the last successful sync.
Raw JSON schema
{
"type": "array",
"items": {
"type": "object",
"description": "Diagram with activity stats for a given time period.",
"properties": {
"_id": {
"type": "string",
"description": "ID of the diagram."
},
"ss_id": {
"type": "string",
"description": "ID of the layer the diagram belongs to."
},
"name": {
"type": "string",
"description": "Name of the diagram."
},
"type": {
"type": "string",
"enum": [
"application",
"infrastructure",
"network",
"template"
],
"description": "Type of the diagram."
},
"account_name": {
"type": "string",
"description": "Cloud account name."
},
"account_id": {
"type": "string",
"description": "Cloud account ID."
},
"account_type": {
"type": "string",
"description": "Cloud account type."
},
"changes": {
"type": "array",
"description": "Activity changes within the period.",
"items": {
"type": "object",
"description": "A single activity change entry in a diagram stats record.",
"properties": {
"type": {
"type": "string",
"enum": [
"NODE_CREATE",
"NODE_UPDATE",
"NODE_DELETE"
],
"description": "Type of the change."
},
"service": {
"type": "string",
"description": "Cloud service the change applies to."
},
"count": {
"type": "integer",
"description": "Number of occurrences of this change type."
}
}
}
},
"import": {
"type": "object",
"description": "Current import/sync state for a cloud-connected diagram.",
"properties": {
"status": {
"type": "string",
"enum": [
"queued",
"in_progress",
"success",
"failure"
],
"description": "Import status."
},
"type": {
"type": "string",
"enum": [
"AWS",
"GCP",
"AZURE"
],
"description": "Connected cloud account type."
},
"account": {
"type": "string",
"description": "Connected account ID."
},
"cloudId": {
"type": "string",
"description": "Cloud account ID."
},
"errorMessage": {
"type": "string",
"description": "Error message if the import failed."
},
"syncedAt": {
"type": "string",
"format": "date-time",
"description": "Timestamp of the last successful sync."
}
}
}
}
}
}

Errors

On failure, dci prints a single error message — with a hint when one is available — and exits with a typed code your scripts can branch on. See Errors and exit codes for the full contract.

HTTP status to exit code mapping
HTTP statusExit codeError codeMeaning
40030VALIDATION_ERRORThe arguments or request body were rejected. Review the command's flags and payload.
40110AUTHENTICATION_FAILEDNot signed in, or the API token is invalid. Run dci login or check DCI_API_KEY.
40311PERMISSION_DENIEDThe DoiT user or the active customer context does not have access.

Aliases: getclouddiagramsstats