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

************************
provision_ipam_pool_cidr
************************



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

  

  Provision a CIDR to an IPAM pool. You can use this action to provision new CIDRs to a top-level pool or to transfer a CIDR from a top-level pool to a pool within it.

   

  For more information, see `Provision CIDRs to pools <https://docs.aws.amazon.com/vpc/latest/ipam/prov-cidr-ipam.html>`__ in the *Amazon VPC IPAM User Guide*.

  

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


  **Request Syntax**
  ::

    response = client.provision_ipam_pool_cidr(
        DryRun=True|False,
        IpamPoolId='string',
        Cidr='string',
        CidrAuthorizationContext={
            'Message': 'string',
            'Signature': 'string'
        },
        NetmaskLength=123,
        ClientToken='string',
        VerificationMethod='remarks-x509'|'dns-token',
        IpamExternalResourceVerificationTokenId='string'
    )
    
  :type DryRun: boolean
  :param DryRun: 

    A check for 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 IpamPoolId: string
  :param IpamPoolId: **[REQUIRED]** 

    The ID of the IPAM pool to which you want to assign a CIDR.

    

  
  :type Cidr: string
  :param Cidr: 

    The CIDR you want to assign to the IPAM pool. Either "NetmaskLength" or "Cidr" is required. This value will be null if you specify "NetmaskLength" and will be filled in during the provisioning process.

    

  
  :type CidrAuthorizationContext: dict
  :param CidrAuthorizationContext: 

    A signed document that proves that you are authorized to bring a specified IP address range to Amazon using BYOIP. This option only applies to IPv4 and IPv6 pools in the public scope.

    

  
    - **Message** *(string) --* 

      The plain-text authorization message for the prefix and account.

      

    
    - **Signature** *(string) --* 

      The signed authorization message for the prefix and account.

      

    
  
  :type NetmaskLength: integer
  :param NetmaskLength: 

    The netmask length of the CIDR you'd like to provision to a pool. Can be used for provisioning Amazon-provided IPv6 CIDRs to top-level pools and for provisioning CIDRs to pools with source pools. Cannot be used to provision BYOIP CIDRs to top-level pools. Either "NetmaskLength" or "Cidr" is required.

    

  
  :type ClientToken: string
  :param ClientToken: 

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

    This field is autopopulated if not provided.

  
  :type VerificationMethod: string
  :param VerificationMethod: 

    The method for verifying control of a public IP address range. Defaults to ``remarks-x509`` if not specified. This option only applies to IPv4 and IPv6 pools in the public scope.

    

  
  :type IpamExternalResourceVerificationTokenId: string
  :param IpamExternalResourceVerificationTokenId: 

    Verification token ID. This option only applies to IPv4 and IPv6 pools in the public scope.

    

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

    
    ::

      {
          'IpamPoolCidr': {
              'Cidr': 'string',
              'State': 'pending-provision'|'provisioned'|'failed-provision'|'pending-deprovision'|'deprovisioned'|'failed-deprovision'|'pending-import'|'failed-import',
              'FailureReason': {
                  'Code': 'cidr-not-available'|'limit-exceeded',
                  'Message': 'string'
              },
              'IpamPoolCidrId': 'string',
              'NetmaskLength': 123
          }
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **IpamPoolCidr** *(dict) --* 

        Information about the provisioned CIDR.

        
        

        - **Cidr** *(string) --* 

          The CIDR provisioned to the IPAM pool. A CIDR is a representation of an IP address and its associated network mask (or netmask) and refers to a range of IP addresses. An IPv4 CIDR example is ``10.24.34.0/23``. An IPv6 CIDR example is ``2001:DB8::/32``.

          
        

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

          The state of the CIDR.

          
        

        - **FailureReason** *(dict) --* 

          Details related to why an IPAM pool CIDR failed to be provisioned.

          
          

          - **Code** *(string) --* 

            An error code related to why an IPAM pool CIDR failed to be provisioned.

            
          

          - **Message** *(string) --* 

            A message related to why an IPAM pool CIDR failed to be provisioned.

            
      
        

        - **IpamPoolCidrId** *(string) --* 

          The IPAM pool CIDR ID.

          
        

        - **NetmaskLength** *(integer) --* 

          The netmask length of the CIDR you'd like to provision to a pool. Can be used for provisioning Amazon-provided IPv6 CIDRs to top-level pools and for provisioning CIDRs to pools with source pools. Cannot be used to provision BYOIP CIDRs to top-level pools. "NetmaskLength" or "Cidr" is required.

          
    
  