Skip to content

list_custom_models

Operation

list_custom_models

list_custom_models(request: ListCustomModelsInput | ListCustomModelsInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[ListCustomModelsInputDict]) -> ListCustomModelsOutput

Returns a list of the custom models that you have created with the CreateModelCustomizationJob operation.

For more information, see Custom models in the Amazon Bedrock User Guide.

Parameters:

Name Type Description Default
request ListCustomModelsInput | ListCustomModelsInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[ListCustomModelsInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
ListCustomModelsOutput

An instance of ListCustomModelsOutput.

list_custom_models async

list_custom_models(request: ListCustomModelsInput | ListCustomModelsInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[ListCustomModelsInputDict]) -> ListCustomModelsOutput

Returns a list of the custom models that you have created with the CreateModelCustomizationJob operation.

For more information, see Custom models in the Amazon Bedrock User Guide.

Parameters:

Name Type Description Default
request ListCustomModelsInput | ListCustomModelsInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[ListCustomModelsInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
ListCustomModelsOutput

An instance of ListCustomModelsOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

ListCustomModelsInputDict

Bases: TypedDict

Dictionary form of ListCustomModelsInput.

Attributes

base_model_arn_equals instance-attribute
base_model_arn_equals: str | None

Return custom models only if the base model Amazon Resource Name (ARN) matches this parameter.

creation_time_after instance-attribute
creation_time_after: datetime | None

Return custom models created after the specified time.

creation_time_before instance-attribute
creation_time_before: datetime | None

Return custom models created before the specified time.

foundation_model_arn_equals instance-attribute
foundation_model_arn_equals: str | None

Return custom models only if the foundation model Amazon Resource Name (ARN) matches this parameter.

is_owned instance-attribute
is_owned: bool | None

Return custom models depending on if the current account owns them (true) or if they were shared with the current account (false).

max_results instance-attribute
max_results: int | None

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

model_status instance-attribute
model_status: str | None

The status of them model to filter results by. Possible values include:

  • Creating - Include only models that are currently being created and validated.

  • Active - Include only models that have been successfully created and are ready for use.

  • Failed - Include only models where the creation process failed.

If you don't specify a status, the API returns models in all states.

name_contains instance-attribute
name_contains: str | None

Return custom models only if the job name contains these characters.

next_token instance-attribute
next_token: str | None

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

sort_by instance-attribute
sort_by: str | None

The field to sort by in the returned list of models.

sort_order instance-attribute
sort_order: str | None

The sort order of the results.

ListCustomModelsInput dataclass

Bases: _SerdeShape

Dataclass for ListCustomModelsInput structure.

Attributes

base_model_arn_equals class-attribute instance-attribute
base_model_arn_equals: str | None = ...

Return custom models only if the base model Amazon Resource Name (ARN) matches this parameter.

creation_time_after class-attribute instance-attribute
creation_time_after: datetime | None = ...

Return custom models created after the specified time.

creation_time_before class-attribute instance-attribute
creation_time_before: datetime | None = ...

Return custom models created before the specified time.

foundation_model_arn_equals class-attribute instance-attribute
foundation_model_arn_equals: str | None = ...

Return custom models only if the foundation model Amazon Resource Name (ARN) matches this parameter.

is_owned class-attribute instance-attribute
is_owned: bool | None = ...

Return custom models depending on if the current account owns them (true) or if they were shared with the current account (false).

max_results class-attribute instance-attribute
max_results: int | None = ...

The maximum number of results to return in the response. If the total number of results is greater than this value, use the token returned in the response in the nextToken field when making another request to return the next batch of results.

model_status class-attribute instance-attribute
model_status: str | None = ...

The status of them model to filter results by. Possible values include:

  • Creating - Include only models that are currently being created and validated.

  • Active - Include only models that have been successfully created and are ready for use.

  • Failed - Include only models where the creation process failed.

If you don't specify a status, the API returns models in all states.

name_contains class-attribute instance-attribute
name_contains: str | None = ...

Return custom models only if the job name contains these characters.

next_token class-attribute instance-attribute
next_token: str | None = ...

If the total number of results is greater than the maxResults value provided in the request, enter the token returned in the nextToken field in the response in this field to return the next batch of results.

sort_by class-attribute instance-attribute
sort_by: str | None = ...

The field to sort by in the returned list of models.

sort_order class-attribute instance-attribute
sort_order: str | None = ...

The sort order of the results.

Output

ListCustomModelsOutput dataclass

Bases: _SerdeShape

Dataclass for ListCustomModelsOutput structure.

Attributes

model_summaries class-attribute instance-attribute
model_summaries: list[CustomModelSummary] | None = ...

Model summaries.

next_token class-attribute instance-attribute
next_token: str | None = ...

If the total number of results is greater than the maxResults value provided in the request, use this token when making another request in the nextToken field to return the next batch of results.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.