:doc:`Bedrock <../../bedrock>` / Client / create_custom_model_deployment

******************************
create_custom_model_deployment
******************************



.. py:method:: Bedrock.Client.create_custom_model_deployment(**kwargs)

  

  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 <https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-use.html>`__.

   

  The following actions are related to the ``CreateCustomModelDeployment`` operation:

   

  
  * `GetCustomModelDeployment <https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GetCustomModelDeployment.html>`__
   
  * `ListCustomModelDeployments <https://docs.aws.amazon.com/bedrock/latest/APIReference/API_ListCustomModelDeployments.html>`__
   
  * `DeleteCustomModelDeployment <https://docs.aws.amazon.com/bedrock/latest/APIReference/API_DeleteCustomModelDeployment.html>`__
  

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/bedrock-2023-04-20/CreateCustomModelDeployment>`_  


  **Request Syntax**
  ::

    response = client.create_custom_model_deployment(
        modelDeploymentName='string',
        modelArn='string',
        description='string',
        tags=[
            {
                'key': 'string',
                'value': 'string'
            },
        ],
        clientRequestToken='string'
    )
    
  :type modelDeploymentName: string
  :param modelDeploymentName: **[REQUIRED]** 

    The name for the custom model deployment. The name must be unique within your Amazon Web Services account and Region.

    

  
  :type modelArn: string
  :param modelArn: **[REQUIRED]** 

    The Amazon Resource Name (ARN) of the custom model to deploy for on-demand inference. The custom model must be in the ``Active`` state.

    

  
  :type description: string
  :param description: 

    A description for the custom model deployment to help you identify its purpose.

    

  
  :type tags: list
  :param tags: 

    Tags to assign to the custom model deployment. You can use tags to organize and track your Amazon Web Services resources for cost allocation and management purposes.

    

  
    - *(dict) --* 

      Definition of the key/value pair for a tag.

      

    
      - **key** *(string) --* **[REQUIRED]** 

        Key for the tag.

        

      
      - **value** *(string) --* **[REQUIRED]** 

        Value for the tag.

        

      
    

  :type clientRequestToken: string
  :param clientRequestToken: 

    A unique, case-sensitive identifier to ensure that the operation completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see `Ensuring idempotency <https://docs.aws.amazon.com/bedrock/latest/userguide/model-customization-idempotency.html>`__.

    This field is autopopulated if not provided.

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'customModelDeploymentArn': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **customModelDeploymentArn** *(string) --* 

        The Amazon Resource Name (ARN) of the custom model deployment. Use this ARN as the ``modelId`` parameter when invoking the model with the ``InvokeModel`` or ``Converse`` operations.

        
  
  **Exceptions**
  
  *   :py:class:`Bedrock.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`Bedrock.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`Bedrock.Client.exceptions.ValidationException`

  
  *   :py:class:`Bedrock.Client.exceptions.InternalServerException`

  
  *   :py:class:`Bedrock.Client.exceptions.TooManyTagsException`

  
  *   :py:class:`Bedrock.Client.exceptions.ServiceQuotaExceededException`

  
  *   :py:class:`Bedrock.Client.exceptions.ThrottlingException`

  