Skip to content

list_monitoring_schedules async

list_monitoring_schedules(
    *,
    config_overrides: Optional[AsyncSageMakerClientConfig] = None,
    endpoint_name: Optional[EndpointName] = None,
    sort_by: Optional[MonitoringScheduleSortKey] = None,
    sort_order: Optional[SortOrder] = None,
    next_token: Optional[NextToken] = None,
    max_results: Optional[MaxResults] = None,
    name_contains: Optional[NameContains] = None,
    creation_time_before: Optional[Timestamp] = None,
    creation_time_after: Optional[Timestamp] = None,
    last_modified_time_before: Optional[Timestamp] = None,
    last_modified_time_after: Optional[Timestamp] = None,
    status_equals: Optional[ScheduleStatus] = None,
    monitoring_job_definition_name: Optional[MonitoringJobDefinitionName] = None,
    monitoring_type_equals: Optional[MonitoringType] = None,
) -> ListMonitoringSchedulesResponse

Returns list of all monitoring schedules.

Parameters:

  • endpoint_name (Optional[EndpointName], default: None ) –

    Name of a specific endpoint to fetch schedules for.

  • sort_by (Optional[MonitoringScheduleSortKey], default: None ) –

    Whether to sort the results by the Status, CreationTime, or ScheduledTime field. The default is CreationTime.

  • sort_order (Optional[SortOrder], default: None ) –

    Whether to sort the results in Ascending or Descending order. The default is Descending.

  • next_token (Optional[NextToken], default: None ) –

    The token returned if the response is truncated. To retrieve the next set of job executions, use it in the next request.

  • max_results (Optional[MaxResults], default: None ) –

    The maximum number of jobs to return in the response. The default value is 10.

  • name_contains (Optional[NameContains], default: None ) –

    Filter for monitoring schedules whose name contains a specified string.

  • creation_time_before (Optional[Timestamp], default: None ) –

    A filter that returns only monitoring schedules created before a specified time.

  • creation_time_after (Optional[Timestamp], default: None ) –

    A filter that returns only monitoring schedules created after a specified time.

  • last_modified_time_before (Optional[Timestamp], default: None ) –

    A filter that returns only monitoring schedules modified before a specified time.

  • last_modified_time_after (Optional[Timestamp], default: None ) –

    A filter that returns only monitoring schedules modified after a specified time.

  • status_equals (Optional[ScheduleStatus], default: None ) –

    A filter that returns only monitoring schedules modified before a specified time.

  • monitoring_job_definition_name (Optional[MonitoringJobDefinitionName], default: None ) –

    Gets a list of the monitoring schedules for the specified monitoring job definition.

  • monitoring_type_equals (Optional[MonitoringType], default: None ) –

    A filter that returns only the monitoring schedules for the specified monitoring type.

Raises:

Source code in docs_src/capo_sagemaker/_services/async_sage_maker.py
async def list_monitoring_schedules(
    self,
    *,
    config_overrides: Optional[AsyncSageMakerClientConfig] = None,
    endpoint_name: Optional[
        "capo_sagemaker.types.endpoint_name.EndpointName"
    ] = None,
    sort_by: Optional[
        "capo_sagemaker.types.monitoring_schedule_sort_key.MonitoringScheduleSortKey"
    ] = None,
    sort_order: Optional["capo_sagemaker.types.sort_order.SortOrder"] = None,
    next_token: Optional["capo_sagemaker.types.next_token.NextToken"] = None,
    max_results: Optional["capo_sagemaker.types.max_results.MaxResults"] = None,
    name_contains: Optional[
        "capo_sagemaker.types.name_contains.NameContains"
    ] = None,
    creation_time_before: Optional[
        "capo_sagemaker.types.timestamp.Timestamp"
    ] = None,
    creation_time_after: Optional[
        "capo_sagemaker.types.timestamp.Timestamp"
    ] = None,
    last_modified_time_before: Optional[
        "capo_sagemaker.types.timestamp.Timestamp"
    ] = None,
    last_modified_time_after: Optional[
        "capo_sagemaker.types.timestamp.Timestamp"
    ] = None,
    status_equals: Optional[
        "capo_sagemaker.types.schedule_status.ScheduleStatus"
    ] = None,
    monitoring_job_definition_name: Optional[
        "capo_sagemaker.types.monitoring_job_definition_name.MonitoringJobDefinitionName"
    ] = None,
    monitoring_type_equals: Optional[
        "capo_sagemaker.types.monitoring_type.MonitoringType"
    ] = None,
) -> "capo_sagemaker.types.list_monitoring_schedules_response.ListMonitoringSchedulesResponse":
    """<p>Returns list of all monitoring schedules.</p>

    Args:
        endpoint_name: <p>Name of a specific endpoint to fetch schedules for.</p>
        sort_by: <p>Whether to sort the results by the <code>Status</code>, <code>CreationTime</code>, or <code>ScheduledTime</code> field. The default is <code>CreationTime</code>.</p>
        sort_order: <p>Whether to sort the results in <code>Ascending</code> or <code>Descending</code> order. The default is <code>Descending</code>.</p>
        next_token: <p>The token returned if the response is truncated. To retrieve the next set of job executions, use it in the next request.</p>
        max_results: <p>The maximum number of jobs to return in the response. The default value is 10.</p>
        name_contains: <p>Filter for monitoring schedules whose name contains a specified string.</p>
        creation_time_before: <p>A filter that returns only monitoring schedules created before a specified time.</p>
        creation_time_after: <p>A filter that returns only monitoring schedules created after a specified time.</p>
        last_modified_time_before: <p>A filter that returns only monitoring schedules modified before a specified time.</p>
        last_modified_time_after: <p>A filter that returns only monitoring schedules modified after a specified time.</p>
        status_equals: <p>A filter that returns only monitoring schedules modified before a specified time.</p>
        monitoring_job_definition_name: <p>Gets a list of the monitoring schedules for the specified monitoring job definition.</p>
        monitoring_type_equals: <p>A filter that returns only the monitoring schedules for the specified monitoring type.</p>

    Raises:
        capo_sagemaker.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_sagemaker.types.list_monitoring_schedules_request.ListMonitoringSchedulesRequest]",
    ) -> AsyncOperationResponse[
        "capo_sagemaker.types.list_monitoring_schedules_response.ListMonitoringSchedulesResponse"
    ]:
        import capo_sagemaker._operations.sage_maker.list_monitoring_schedules

        (
            output,
            http_response,
        ) = await capo_sagemaker._operations.sage_maker.list_monitoring_schedules.async_list_monitoring_schedules(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListMonitoringSchedules")
    )
    input_: capo_sagemaker.types.list_monitoring_schedules_request.ListMonitoringSchedulesRequest = {}
    if endpoint_name is not None:
        input_["endpoint_name"] = endpoint_name
    if sort_by is not None:
        input_["sort_by"] = sort_by
    if sort_order is not None:
        input_["sort_order"] = sort_order
    if next_token is not None:
        input_["next_token"] = next_token
    if max_results is not None:
        input_["max_results"] = max_results
    if name_contains is not None:
        input_["name_contains"] = name_contains
    if creation_time_before is not None:
        input_["creation_time_before"] = creation_time_before
    if creation_time_after is not None:
        input_["creation_time_after"] = creation_time_after
    if last_modified_time_before is not None:
        input_["last_modified_time_before"] = last_modified_time_before
    if last_modified_time_after is not None:
        input_["last_modified_time_after"] = last_modified_time_after
    if status_equals is not None:
        input_["status_equals"] = status_equals
    if monitoring_job_definition_name is not None:
        input_["monitoring_job_definition_name"] = monitoring_job_definition_name
    if monitoring_type_equals is not None:
        input_["monitoring_type_equals"] = monitoring_type_equals

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output