:doc:`MigrationHubOrchestrator <../../migrationhuborchestrator>` / Client / create_template

***************
create_template
***************



.. py:method:: MigrationHubOrchestrator.Client.create_template(**kwargs)

  

  Creates a migration workflow template.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/migrationhuborchestrator-2021-08-28/CreateTemplate>`_  


  **Request Syntax**
  ::

    response = client.create_template(
        templateName='string',
        templateDescription='string',
        templateSource={
            'workflowId': 'string'
        },
        clientToken='string',
        tags={
            'string': 'string'
        }
    )
    
  :type templateName: string
  :param templateName: **[REQUIRED]** 

    The name of the migration workflow template.

    

  
  :type templateDescription: string
  :param templateDescription: 

    A description of the migration workflow template.

    

  
  :type templateSource: dict
  :param templateSource: **[REQUIRED]** 

    The source of the migration workflow template.

    .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``workflowId``. 

  
    - **workflowId** *(string) --* 

      The ID of the workflow from the source migration workflow template.

      

    
  
  :type clientToken: string
  :param clientToken: 

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see `Idempotency <https://smithy.io/2.0/spec/behavior-traits.html#idempotencytoken-trait>`__ in the Smithy documentation.

    This field is autopopulated if not provided.

  
  :type tags: dict
  :param tags: 

    The tags to add to the migration workflow template.

    

  
    - *(string) --* 

    
      - *(string) --* 

      


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

    
    ::

      {
          'templateId': 'string',
          'templateArn': 'string',
          'tags': {
              'string': 'string'
          }
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **templateId** *(string) --* 

        The ID of the migration workflow template.

        
      

      - **templateArn** *(string) --* 

        The Amazon Resource Name (ARN) of the migration workflow template. The format for an Migration Hub Orchestrator template ARN is ``arn:aws:migrationhub-orchestrator:region:account:template/template-abcd1234``. For more information about ARNs, see `Amazon Resource Names (ARNs) <https://docs.aws.amazon.com/IAM/latest/UserGuide/reference-arns.html>`__ in the *AWS General Reference*.

        
      

      - **tags** *(dict) --* 

        The tags added to the migration workflow template.

        
        

        - *(string) --* 
          

          - *(string) --* 
    
  
  
  **Exceptions**
  
  *   :py:class:`MigrationHubOrchestrator.Client.exceptions.ThrottlingException`

  
  *   :py:class:`MigrationHubOrchestrator.Client.exceptions.ConflictException`

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

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

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

  