:doc:`MediaLive <../../medialive>` / Client / create_node

***********
create_node
***********



.. py:method:: MediaLive.Client.create_node(**kwargs)

  Create a Node in the specified Cluster. You can also create Nodes using the CreateNodeRegistrationScript. Note that you can't move a Node to another Cluster.

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/medialive-2017-10-14/CreateNode>`_  


  **Request Syntax**
  ::

    response = client.create_node(
        ClusterId='string',
        Name='string',
        NodeInterfaceMappings=[
            {
                'LogicalInterfaceName': 'string',
                'NetworkInterfaceMode': 'NAT'|'BRIDGE',
                'PhysicalInterfaceName': 'string'
            },
        ],
        RequestId='string',
        Role='BACKUP'|'ACTIVE',
        Tags={
            'string': 'string'
        }
    )
    
  :type ClusterId: string
  :param ClusterId: **[REQUIRED]** The ID of the cluster.

  
  :type Name: string
  :param Name: The user-specified name of the Node to be created.

  
  :type NodeInterfaceMappings: list
  :param NodeInterfaceMappings: Documentation update needed

  
    - *(dict) --* Used in CreateNodeRequest.

    
      - **LogicalInterfaceName** *(string) --* Specify one of the logicalInterfaceNames that you created in the Cluster that this node belongs to. For example, my-Inputs-Interface.

      
      - **NetworkInterfaceMode** *(string) --* The style of the network -- NAT or BRIDGE.

      
      - **PhysicalInterfaceName** *(string) --* Specify the physical name that corresponds to the logicalInterfaceName that you specified in this interface mapping. For example, Eth1 or ENO1234EXAMPLE.

      
    

  :type RequestId: string
  :param RequestId: An ID that you assign to a create request. This ID ensures idempotency when creating resources.This field is autopopulated if not provided.

  
  :type Role: string
  :param Role: The initial role of the Node in the Cluster. ACTIVE means the Node is available for encoding. BACKUP means the Node is a redundant Node and might get used if an ACTIVE Node fails.

  
  :type Tags: dict
  :param Tags: A collection of key-value pairs.

  
    - *(string) --* Placeholder documentation for __string

    
      - *(string) --* Placeholder documentation for __string

      


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

    
    ::

      {
          'Arn': 'string',
          'ChannelPlacementGroups': [
              'string',
          ],
          'ClusterId': 'string',
          'ConnectionState': 'CONNECTED'|'DISCONNECTED',
          'Id': 'string',
          'InstanceArn': 'string',
          'Name': 'string',
          'NodeInterfaceMappings': [
              {
                  'LogicalInterfaceName': 'string',
                  'NetworkInterfaceMode': 'NAT'|'BRIDGE',
                  'PhysicalInterfaceName': 'string',
                  'PhysicalInterfaceIpAddresses': [
                      'string',
                  ]
              },
          ],
          'Role': 'BACKUP'|'ACTIVE',
          'State': 'CREATED'|'REGISTERING'|'READY_TO_ACTIVATE'|'REGISTRATION_FAILED'|'ACTIVATION_FAILED'|'ACTIVE'|'READY'|'IN_USE'|'DEREGISTERING'|'DRAINING'|'DEREGISTRATION_FAILED'|'DEREGISTERED',
          'SdiSourceMappings': [
              {
                  'CardNumber': 123,
                  'ChannelNumber': 123,
                  'SdiSource': 'string'
              },
          ]
      }
      
    **Response Structure**

    

    - *(dict) --* A node create is in progress.
      

      - **Arn** *(string) --* The ARN of the Node. It is automatically assigned when the Node is created.
      

      - **ChannelPlacementGroups** *(list) --* An array of IDs. Each ID is one ChannelPlacementGroup that is associated with this Node. Empty if the Node is not yet associated with any groups.
        

        - *(string) --* Placeholder documentation for __string
    
      

      - **ClusterId** *(string) --* The ID of the Cluster that the Node belongs to.
      

      - **ConnectionState** *(string) --* The current connection state of the Node.
      

      - **Id** *(string) --* The unique ID of the Node. Unique in the Cluster. The ID is the resource-id portion of the ARN.
      

      - **InstanceArn** *(string) --* The ARN of the EC2 instance hosting the Node.
      

      - **Name** *(string) --* The name that you specified for the Node.
      

      - **NodeInterfaceMappings** *(list) --* Documentation update needed
        

        - *(dict) --* A mapping that's used to pair a logical network interface name on a Node with the physical interface name exposed in the operating system.
          

          - **LogicalInterfaceName** *(string) --* A uniform logical interface name to address in a MediaLive channel configuration.
          

          - **NetworkInterfaceMode** *(string) --* Used in NodeInterfaceMapping and NodeInterfaceMappingCreateRequest
          

          - **PhysicalInterfaceName** *(string) --* The name of the physical interface on the hardware that will be running Elemental anywhere.
          

          - **PhysicalInterfaceIpAddresses** *(list) --* The IP addresses associated with the physical interface on the node hardware.
            

            - *(string) --* Placeholder documentation for __string
        
      
    
      

      - **Role** *(string) --* The initial role current role of the Node in the Cluster. ACTIVE means the Node is available for encoding. BACKUP means the Node is a redundant Node and might get used if an ACTIVE Node fails.
      

      - **State** *(string) --* The current state of the Node.
      

      - **SdiSourceMappings** *(list) --* An array of SDI source mappings. Each mapping connects one logical SdiSource to the physical SDI card and port that the physical SDI source uses.
        

        - *(dict) --* Used in DescribeNodeSummary, DescribeNodeResult.
          

          - **CardNumber** *(integer) --* A number that uniquely identifies the SDI card on the node hardware.
          

          - **ChannelNumber** *(integer) --* A number that uniquely identifies a port on the SDI card.
          

          - **SdiSource** *(string) --* The ID of the SdiSource to associate with this port on this card. You can use the ListSdiSources operation to discover all the IDs.
      
    
  
  **Exceptions**
  
  *   :py:class:`MediaLive.Client.exceptions.BadRequestException`

  
  *   :py:class:`MediaLive.Client.exceptions.UnprocessableEntityException`

  
  *   :py:class:`MediaLive.Client.exceptions.InternalServerErrorException`

  
  *   :py:class:`MediaLive.Client.exceptions.ForbiddenException`

  
  *   :py:class:`MediaLive.Client.exceptions.BadGatewayException`

  
  *   :py:class:`MediaLive.Client.exceptions.GatewayTimeoutException`

  
  *   :py:class:`MediaLive.Client.exceptions.TooManyRequestsException`

  