list-assets
dci list-assets [flags]
Returns a list of all available customer assets, such as Google Cloud billing accounts, G Suite/Workspace subscriptions, etc. Assets are returned in reverse chronological order by default.
CLI default view
dci list-assets presents a curated table by default:
- Columns:
name(a clickable link to the asset in the DoiT console in interactive terminals),type, andcreated (UTC)(fromcreateTime). - In interactive tables,
created (UTC)renders in your local timezone and is titledcreated (local); machine formats, agent mode, and--utckeep UTC — see Timestamps and timezones. --output jsonand explicit-C/--fieldsselections return the raw fields documented below.
Flags
--max-results: (integer format:int64 default:50)
--page-token: (string)
--filter: (string)
Output
OK - List of available assets returned.
By default dci renders the result as a table. Use --output json to get the full structure described below — see Output formats.
| Field | Type | Description |
|---|---|---|
assets | array of object | Array of Assets |
assets[].createTime | integer (int64) | The time when the asset was created, in milliseconds since the epoch. |
assets[].id | string | The unique identifier of the asset. |
assets[].name | string | A human-readable label for the asset, typically combining the product name and domain or account ID. |
assets[].quantity | integer (int64) | The number of licenses or seats currently assigned to this asset. |
assets[].type | string | The asset type, e.g. g-suite, office-365, google-cloud, amazon-web-services, or microsoft-azure. |
assets[].url | string | A link to the asset details page in the DoiT console. |
pageToken | string | Page token. Can be used to request the next page of results. |
rowCount | integer (int64) | Assets rows count |
Raw JSON schema
{
"type": "object",
"properties": {
"assets": {
"type": "array",
"description": "Array of Assets",
"items": {
"type": "object",
"description": "Summary information about a single asset.",
"properties": {
"createTime": {
"type": "integer",
"description": "The time when the asset was created, in milliseconds since the epoch.",
"format": "int64"
},
"id": {
"type": "string",
"description": "The unique identifier of the asset."
},
"name": {
"type": "string",
"description": "A human-readable label for the asset, typically combining the product name and domain or account ID."
},
"quantity": {
"type": "integer",
"description": "The number of licenses or seats currently assigned to this asset.",
"format": "int64"
},
"type": {
"type": "string",
"description": "The asset type, e.g. g-suite, office-365, google-cloud, amazon-web-services, or microsoft-azure."
},
"url": {
"type": "string",
"description": "A link to the asset details page in the DoiT console."
}
}
}
},
"pageToken": {
"type": "string",
"description": "Page token. Can be used to request the next page of results."
},
"rowCount": {
"type": "integer",
"description": "Assets rows count",
"format": "int64"
}
}
}
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 | Exit code | Error code | Meaning |
|---|---|---|---|
| 400 | 30 | VALIDATION_ERROR | The arguments or request body were rejected. Review the command's flags and payload. |
| 401 | 10 | AUTHENTICATION_FAILED | Not signed in, or the API token is invalid. Run dci login or check DCI_API_KEY. |
| 403 | 11 | PERMISSION_DENIED | The DoiT user or the active customer context does not have access. |
| 404 | 20 | RESOURCE_NOT_FOUND | The requested resource does not exist. Check the identifier argument. |
Aliases: id-of-assets