:doc:`ElasticBeanstalk <../../elasticbeanstalk>` / Client / check_dns_availability

**********************
check_dns_availability
**********************



.. py:method:: ElasticBeanstalk.Client.check_dns_availability(**kwargs)

  

  Checks if the specified CNAME is available.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/elasticbeanstalk-2010-12-01/CheckDNSAvailability>`_  


  **Request Syntax**
  ::

    response = client.check_dns_availability(
        CNAMEPrefix='string'
    )
    
  :type CNAMEPrefix: string
  :param CNAMEPrefix: **[REQUIRED]** 

    The prefix used when this CNAME is reserved.

    

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

    
    ::

      {
          'Available': True|False,
          'FullyQualifiedCNAME': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 

      Indicates if the specified CNAME is available.

      
      

      - **Available** *(boolean) --* 

        Indicates if the specified CNAME is available:

         

        
        * ``true`` : The CNAME is available.
         
        * ``false`` : The CNAME is not available.
        

        
      

      - **FullyQualifiedCNAME** *(string) --* 

        The fully qualified CNAME to reserve when  CreateEnvironment is called with the provided prefix.

        
  

  **Examples**

  The following operation checks the availability of the subdomain my-cname:
  ::

    response = client.check_dns_availability(
        CNAMEPrefix='my-cname',
    )
    
    print(response)

  
  Expected Output:
  ::

    {
        'Available': True,
        'FullyQualifiedCNAME': 'my-cname.us-west-2.elasticbeanstalk.com',
        'ResponseMetadata': {
            '...': '...',
        },
    }

  