update-insight-status (deprecated)
This command is deprecated and may be removed in a future release.
dci update-insight-status <sourceID> <insightKey> [body]
Updates the display status (e.g. actionable, acknowledged, dismissed) of a single insight. Only insights created via the public API can have their status changed. Deprecated: use the status field on the create/update insight endpoint instead.
sourceID— Only insights created via the public API can be managed. Currently only "public-api" is supported.insightKey— The unique key identifying the insight to update.
Pass the request body as name: value arguments or pipe JSON on stdin — see Command structure.
This command is deprecated. Set the status when you create or update the
insight instead, for example
dci create-insight public-api <insight-key> < insight.json with "status": "dismissed"
and a dismissalDetails object in the JSON; the rest of the insight's
required metadata must be included in the same request.
Examples
# Acknowledge an insight (deprecated; prefer the `status` field of create-insight).
dci update-insight-status public-api <insight-key> status: acknowledged
Request
Content-Type: application/json
| Field | Type | Required | Description |
|---|---|---|---|
status | string | yes | The display status of the insight. One of: "actionable", "acknowledged", "optimized", "dismissed", "in progress", "upgrade needed", "permissions needed". |
dismissalDetails | object | Details for why an insight was dismissed. | |
dismissalDetails.reason | string | The reason for dismissal. One of: "not relevant", "not enough information", "not worth the effort", "inaccurate optimization opportunities". | |
dismissalDetails.comment | string | An optional free-text comment providing additional context. |
Raw JSON schema
{
"type": "object",
"description": "Request body for updating an insight's display status.",
"required": [
"status"
],
"properties": {
"status": {
"type": "string",
"enum": [
"actionable",
"acknowledged",
"optimized",
"dismissed",
"in progress",
"upgrade needed",
"permissions needed"
],
"description": "The display status of the insight."
},
"dismissalDetails": {
"type": "object",
"description": "Details for why an insight was dismissed.",
"properties": {
"reason": {
"type": "string",
"description": "The reason for dismissal.",
"enum": [
"not relevant",
"not enough information",
"not worth the effort",
"inaccurate optimization opportunities"
]
},
"comment": {
"type": "string",
"description": "An optional free-text comment providing additional context."
}
}
}
}
}
Output
On success, this command produces no response data.
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 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. |
| 500 | 40 | API_SERVER_ERROR | The API failed to process the request. Retryable; contact DoiT support if it persists. |
Related
- create-insight — Create or update an insight
- get-insight — Retrieve an insight
- list-insights — List insights
- API reference: PUT /insights/v1/results/source/{sourceID}/insight/{insightKey}/status
Aliases: updateinsightstatus