Skip to content

delete_app_monitor

delete_app_monitor(
    name: AppMonitorName, *, config_overrides: Optional[RUMClientConfig] = None
) -> DeleteAppMonitorResponse

Deletes an existing app monitor. This immediately stops the collection of data.

Parameters:

Raises:

Source code in docs_src/capo_rum/_services/rum.py
def delete_app_monitor(
    self,
    name: "capo_rum.types.app_monitor_name.AppMonitorName",
    *,
    config_overrides: Optional[RUMClientConfig] = None,
) -> "capo_rum.types.delete_app_monitor_response.DeleteAppMonitorResponse":
    """<p>Deletes an existing app monitor. This immediately stops the collection of data.</p>

    Args:
        name: <p>The name of the app monitor to delete.</p>

    Raises:
        capo_rum.errors.access_denied_exception.AccessDeniedException: <p>You don't have sufficient permissions to perform this action.</p>
        capo_rum.errors.conflict_exception.ConflictException: <p>This operation attempted to create a resource that already exists.</p>
        capo_rum.errors.internal_server_exception.InternalServerException: <p>Internal service exception.</p>
        capo_rum.errors.resource_not_found_exception.ResourceNotFoundException: <p>Resource not found.</p>
        capo_rum.errors.throttling_exception.ThrottlingException: <p>The request was throttled because of quota limits.</p>
        capo_rum.errors.validation_exception.ValidationException: <p>One of the arguments for the request is not valid.</p>
        capo_rum.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_rum.types.delete_app_monitor_request.DeleteAppMonitorRequest]",
    ) -> OperationResponse[
        "capo_rum.types.delete_app_monitor_response.DeleteAppMonitorResponse"
    ]:
        import capo_rum._operations.rum.delete_app_monitor

        output, http_response = (
            capo_rum._operations.rum.delete_app_monitor.delete_app_monitor(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DeleteAppMonitor")
    )
    input_: capo_rum.types.delete_app_monitor_request.DeleteAppMonitorRequest = {
        "name": name
    }

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output