custom_model_deployments
Creates, updates, deletes, gets or lists a custom_model_deployments resource.
Overview
| Name | custom_model_deployments |
| Type | Resource |
| Id | aws.bedrock.custom_model_deployments |
Fields
The following fields are returned by SELECT queries:
- get_custom_model_deployment
- list_custom_model_deployments
| Name | Datatype | Description |
|---|---|---|
created_at | string (date-time) | The date and time when the custom model deployment was created. |
custom_model_deployment_arn | string | The Amazon Resource Name (ARN) of the custom model deployment. (pattern: <code>arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:custom-model-deployment/[a-z0-9]{12}</code>) |
description | string | The description of the custom model deployment. (pattern: <code>.*</code>) |
failure_message | string | If the deployment status is FAILED, this field contains a message describing the failure reason. |
last_updated_at | string (date-time) | The date and time when the custom model deployment was last updated. |
model_arn | string | The Amazon Resource Name (ARN) of the custom model associated with this deployment. (pattern: <code>arn:aws(|-us-gov|-cn|-iso|-iso-b):bedrock:[a-z0-9-]{1,20}:[0-9]{12}:custom-model/(imported|[a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}([a-z0-9-]{1,63}[.]){0,2}[a-z0-9-]{1,63}([:][a-z0-9-]{1,63}){0,2})/[a-z0-9]{12}</code>) |
model_deployment_name | string | The name of the custom model deployment. (pattern: <code>([0-9a-zA-Z][_-]?){1,63}</code>) |
status | string | The status of the custom model deployment. Possible values are: CREATING - The deployment is being set up and prepared for inference. ACTIVE - The deployment is ready and available for inference requests. FAILED - The deployment failed to be created or became unavailable. (Creating, Active, Failed) |
update_details | object | Details about any pending or completed updates to the custom model deployment, including the new model ARN and update status. |
| Name | Datatype | Description |
|---|---|---|
created_at | string (date-time) | The date and time when the custom model deployment was created. |
custom_model_deployment_arn | string | The Amazon Resource Name (ARN) of the custom model deployment. (pattern: <code>arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}:[0-9]{12}:custom-model-deployment/[a-z0-9]{12}</code>) |
custom_model_deployment_name | string | The name of the custom model deployment. (pattern: <code>([0-9a-zA-Z][_-]?){1,63}</code>) |
failure_message | string | If the deployment status is FAILED, this field contains a message describing the failure reason. |
last_updated_at | string (date-time) | The date and time when the custom model deployment was last modified. |
model_arn | string | The Amazon Resource Name (ARN) of the custom model associated with this deployment. (pattern: <code>arn:aws(-[^:]+)?:bedrock:[a-z0-9-]{1,20}:(([0-9]{12}:custom-model/((imported)|([a-z0-9-]{1,63}[.]{1}[a-z0-9-]{1,63}))(([:][a-z0-9-]{1,63}){0,2})?/[a-z0-9]{12})|(:foundation-model/[a-z0-9-]{1,63}[.]{1}([a-z0-9-]{1,63}[.]){0,2}[a-z0-9-]{1,63}([:][a-z0-9-]{1,63}){0,2}))</code>) |
status | string | The status of the custom model deployment. Possible values are CREATING, ACTIVE, and FAILED. (Creating, Active, Failed) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_custom_model_deployment | select | custom_model_deployment_identifier, region | Retrieves information about a custom model deployment, including its status, configuration, and metadata. Use this operation to monitor the deployment status and retrieve details needed for inference requests. The following actions are related to the GetCustomModelDeployment operation: CreateCustomModelDeployment ListCustomModelDeployments DeleteCustomModelDeployment | |
list_custom_model_deployments | select | region | createdBefore, createdAfter, nameContains, maxResults, nextToken, sortBy, sortOrder, statusEquals, modelArnEquals | Lists custom model deployments in your account. You can filter the results by creation time, name, status, and associated model. Use this operation to manage and monitor your custom model deployments. We recommend using pagination to ensure that the operation returns quickly and successfully. The following actions are related to the ListCustomModelDeployments operation: CreateCustomModelDeployment GetCustomModelDeployment DeleteCustomModelDeployment |
create_custom_model_deployment | insert | region, modelDeploymentName, modelArn | Deploys a custom model for on-demand inference in Amazon Bedrock. After you deploy your custom model, you use the deployment's Amazon Resource Name (ARN) as the modelId parameter when you submit prompts and generate responses with model inference. For more information about setting up on-demand inference for custom models, see Set up inference for a custom model. The following actions are related to the CreateCustomModelDeployment operation: GetCustomModelDeployment ListCustomModelDeployments DeleteCustomModelDeployment | |
update_custom_model_deployment | update | custom_model_deployment_identifier, region, modelArn | Updates a custom model deployment with a new custom model. This allows you to deploy updated models without creating new deployment endpoints. | |
delete_custom_model_deployment | delete | custom_model_deployment_identifier, region | Deletes a custom model deployment. This operation stops the deployment and removes it from your account. After deletion, the deployment ARN can no longer be used for inference requests. The following actions are related to the DeleteCustomModelDeployment operation: CreateCustomModelDeployment GetCustomModelDeployment ListCustomModelDeployments |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
custom_model_deployment_identifier | string | The Amazon Resource Name (ARN) or name of the custom model deployment to delete. |
region | string | AWS region (default: us-east-1) |
createdAfter | string (date-time) | Filters deployments created after the specified date and time. |
createdBefore | string (date-time) | Filters deployments created before the specified date and time. |
maxResults | integer | The maximum number of results to return in a single call. |
modelArnEquals | string | Filters deployments by the Amazon Resource Name (ARN) of the associated custom model. |
nameContains | string | Filters deployments whose names contain the specified string. |
nextToken | string | The token for the next set of results. Use this token to retrieve additional results when the response is truncated. |
sortBy | string | The field to sort the results by. The only supported value is CreationTime. |
sortOrder | string | The sort order for the results. Valid values are Ascending and Descending. Default is Descending. |
statusEquals | string | Filters deployments by status. Valid values are CREATING, ACTIVE, and FAILED. |
SELECT examples
- get_custom_model_deployment
- list_custom_model_deployments
Retrieves information about a custom model deployment, including its status, configuration, and metadata. Use this operation to monitor the deployment status and retrieve details needed for inference requests. The following actions are related to the GetCustomModelDeployment operation: CreateCustomModelDeployment ListCustomModelDeployments DeleteCustomModelDeployment
SELECT
created_at,
custom_model_deployment_arn,
description,
failure_message,
last_updated_at,
model_arn,
model_deployment_name,
status,
update_details
FROM aws.bedrock.custom_model_deployments
WHERE custom_model_deployment_identifier = '{{ custom_model_deployment_identifier }}' -- required
AND region = '{{ region }}' -- required
;
Lists custom model deployments in your account. You can filter the results by creation time, name, status, and associated model. Use this operation to manage and monitor your custom model deployments. We recommend using pagination to ensure that the operation returns quickly and successfully. The following actions are related to the ListCustomModelDeployments operation: CreateCustomModelDeployment GetCustomModelDeployment DeleteCustomModelDeployment
SELECT
created_at,
custom_model_deployment_arn,
custom_model_deployment_name,
failure_message,
last_updated_at,
model_arn,
status
FROM aws.bedrock.custom_model_deployments
WHERE region = '{{ region }}' -- required
AND createdBefore = '{{ createdBefore }}'
AND createdAfter = '{{ createdAfter }}'
AND nameContains = '{{ nameContains }}'
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
AND sortBy = '{{ sortBy }}'
AND sortOrder = '{{ sortOrder }}'
AND statusEquals = '{{ statusEquals }}'
AND modelArnEquals = '{{ modelArnEquals }}'
;
INSERT examples
- create_custom_model_deployment
- Manifest
Deploys a custom model for on-demand inference in Amazon Bedrock. After you deploy your custom model, you use the deployment's Amazon Resource Name (ARN) as the modelId parameter when you submit prompts and generate responses with model inference. For more information about setting up on-demand inference for custom models, see Set up inference for a custom model. The following actions are related to the CreateCustomModelDeployment operation: GetCustomModelDeployment ListCustomModelDeployments DeleteCustomModelDeployment
INSERT INTO aws.bedrock.custom_model_deployments (
modelDeploymentName,
modelArn,
description,
tags,
clientRequestToken,
region
)
SELECT
'{{ modelDeploymentName }}' /* required */,
'{{ modelArn }}' /* required */,
'{{ description }}',
'{{ tags }}',
'{{ clientRequestToken }}',
'{{ region }}'
RETURNING
custom_model_deployment_arn
;
# Description fields are for documentation purposes
- name: custom_model_deployments
props:
- name: region
value: "{{ region }}"
description: Required parameter for the custom_model_deployments resource.
- name: modelDeploymentName
value: "{{ modelDeploymentName }}"
- name: modelArn
value: "{{ modelArn }}"
- name: description
value: "{{ description }}"
- name: tags
value:
- key: "{{ key }}"
value: "{{ value }}"
- name: clientRequestToken
value: "{{ clientRequestToken }}"
UPDATE examples
- update_custom_model_deployment
Updates a custom model deployment with a new custom model. This allows you to deploy updated models without creating new deployment endpoints.
UPDATE aws.bedrock.custom_model_deployments
SET
modelArn = '{{ modelArn }}'
WHERE
custom_model_deployment_identifier = '{{ custom_model_deployment_identifier }}' --required
AND region = '{{ region }}' --required
AND modelArn = '{{ modelArn }}' --required
RETURNING
custom_model_deployment_arn;
DELETE examples
- delete_custom_model_deployment
Deletes a custom model deployment. This operation stops the deployment and removes it from your account. After deletion, the deployment ARN can no longer be used for inference requests. The following actions are related to the DeleteCustomModelDeployment operation: CreateCustomModelDeployment GetCustomModelDeployment ListCustomModelDeployments
DELETE FROM aws.bedrock.custom_model_deployments
WHERE custom_model_deployment_identifier = '{{ custom_model_deployment_identifier }}' --required
AND region = '{{ region }}' --required
;