Removes a dashboard from a space.
Parameters:
-
space_id
(SpaceId)
–
The unique ID of the space.
-
dashboard_id
(DashboardId)
–
The unique ID of the dashboard.
Raises:
Examples:
Delete a dashboard
The following example removes a dashboard from a space. Payloads are shown as JSON; on the wire they are CBOR-encoded.
>>> client.delete_omni_dashboard(space_id='a1b2c3d4-5e6f-4a3b-8c9d-0e1f2a3b4c5d', dashboard_id='c3d4e5f6-7a8b-4c9d-8e0f-1a2b3c4d5e6f')
Source code in docs_src/capo_cloudwatchomni/_services/cloud_watch_omni.py
| def delete_omni_dashboard(
self,
space_id: "capo_cloudwatchomni.types.space_id.SpaceId",
dashboard_id: "capo_cloudwatchomni.types.dashboard_id.DashboardId",
*,
config_overrides: Optional[CloudWatchOmniClientConfig] = None,
) -> "capo_cloudwatchomni.types.delete_omni_dashboard_output.DeleteOmniDashboardOutput":
"""Removes a dashboard from a space.
Args:
space_id: The unique ID of the space.
dashboard_id: The unique ID of the dashboard.
Raises:
capo_cloudwatchomni.errors.access_denied_exception.AccessDeniedException: The caller is not authorized to perform this action.
capo_cloudwatchomni.errors.conflict_exception.ConflictException: The operation could not be completed because of a conflict with the current state of the resource.
capo_cloudwatchomni.errors.internal_server_exception.InternalServerException: An unexpected error occurred while processing the request.
capo_cloudwatchomni.errors.throttling_exception.ThrottlingException: The request was throttled due to exceeding the allowed request rate.
capo_cloudwatchomni.errors.validation_exception.ValidationException: A parameter is specified incorrectly.
capo_cloudwatchomni.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
Delete a dashboard
The following example removes a dashboard from a space. Payloads are shown as JSON; on the wire they are CBOR-encoded.
>>> client.delete_omni_dashboard(space_id='a1b2c3d4-5e6f-4a3b-8c9d-0e1f2a3b4c5d', dashboard_id='c3d4e5f6-7a8b-4c9d-8e0f-1a2b3c4d5e6f')
"""
def _handler(
req: "OperationRequest[capo_cloudwatchomni.types.delete_omni_dashboard_input.DeleteOmniDashboardInput]",
) -> OperationResponse[
"capo_cloudwatchomni.types.delete_omni_dashboard_output.DeleteOmniDashboardOutput"
]:
import capo_cloudwatchomni._operations.cloud_watch_omni_frontend.delete_omni_dashboard
output, http_response = (
capo_cloudwatchomni._operations.cloud_watch_omni_frontend.delete_omni_dashboard.delete_omni_dashboard(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteOmniDashboard")
)
input_: capo_cloudwatchomni.types.delete_omni_dashboard_input.DeleteOmniDashboardInput = {
"space_id": space_id,
"dashboard_id": dashboard_id,
}
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|