:doc:`EC2 <../../ec2>` / Client / delete_secondary_subnet

***********************
delete_secondary_subnet
***********************



.. py:method:: EC2.Client.delete_secondary_subnet(**kwargs)

  

  Deletes a secondary subnet. A secondary subnet must not contain any secondary interfaces prior to deletion.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/DeleteSecondarySubnet>`_  


  **Request Syntax**
  ::

    response = client.delete_secondary_subnet(
        ClientToken='string',
        DryRun=True|False,
        SecondarySubnetId='string'
    )
    
  :type ClientToken: string
  :param ClientToken: 

    Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see `Ensure Idempotency <https://docs.aws.amazon.com/ec2/latest/devguide/ec2-api-idempotency.html>`__.

    This field is autopopulated if not provided.

  
  :type DryRun: boolean
  :param DryRun: 

    Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is ``DryRunOperation``. Otherwise, it is ``UnauthorizedOperation``.

    

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

    The ID of the secondary subnet to delete.

    

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

    
    ::

      {
          'SecondarySubnet': {
              'SecondarySubnetId': 'string',
              'SecondarySubnetArn': 'string',
              'SecondaryNetworkId': 'string',
              'SecondaryNetworkType': 'rdma',
              'OwnerId': 'string',
              'AvailabilityZoneId': 'string',
              'AvailabilityZone': 'string',
              'Ipv4CidrBlockAssociations': [
                  {
                      'AssociationId': 'string',
                      'CidrBlock': 'string',
                      'State': 'associating'|'associated'|'association-failed'|'disassociating'|'disassociated'|'disassociation-failed',
                      'StateReason': 'string'
                  },
              ],
              'State': 'create-in-progress'|'create-complete'|'create-failed'|'delete-in-progress'|'delete-complete'|'delete-failed',
              'StateReason': 'string',
              'Tags': [
                  {
                      'Key': 'string',
                      'Value': 'string'
                  },
              ]
          },
          'ClientToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **SecondarySubnet** *(dict) --* 

        Information about the secondary subnet being deleted.

        
        

        - **SecondarySubnetId** *(string) --* 

          The ID of the secondary subnet.

          
        

        - **SecondarySubnetArn** *(string) --* 

          The Amazon Resource Name (ARN) of the secondary subnet.

          
        

        - **SecondaryNetworkId** *(string) --* 

          The ID of the secondary network.

          
        

        - **SecondaryNetworkType** *(string) --* 

          The type of the secondary network.

          
        

        - **OwnerId** *(string) --* 

          The ID of the Amazon Web Services account that owns the secondary subnet.

          
        

        - **AvailabilityZoneId** *(string) --* 

          The ID of the Availability Zone of the secondary subnet.

          
        

        - **AvailabilityZone** *(string) --* 

          The Availability Zone of the secondary subnet.

          
        

        - **Ipv4CidrBlockAssociations** *(list) --* 

          Information about the IPv4 CIDR blocks associated with the secondary subnet.

          
          

          - *(dict) --* 

            Describes an IPv4 CIDR block associated with a secondary subnet.

            
            

            - **AssociationId** *(string) --* 

              The association ID for the IPv4 CIDR block.

              
            

            - **CidrBlock** *(string) --* 

              The IPv4 CIDR block.

              
            

            - **State** *(string) --* 

              The state of the CIDR block association.

              
            

            - **StateReason** *(string) --* 

              The reason for the current state of the CIDR block association.

              
        
      
        

        - **State** *(string) --* 

          The state of the secondary subnet.

          
        

        - **StateReason** *(string) --* 

          The reason for the current state of the secondary subnet.

          
        

        - **Tags** *(list) --* 

          The tags assigned to the secondary subnet.

          
          

          - *(dict) --* 

            Describes a tag.

            
            

            - **Key** *(string) --* 

              The key of the tag.

               

              Constraints: Tag keys are case-sensitive and accept a maximum of 127 Unicode characters. May not begin with ``aws:``.

              
            

            - **Value** *(string) --* 

              The value of the tag.

               

              Constraints: Tag values are case-sensitive and accept a maximum of 256 Unicode characters.

              
        
      
    
      

      - **ClientToken** *(string) --* 

        Unique, case-sensitive identifier to ensure the idempotency of the request. Only returned if a client token was provided in the request.

        
  