async def get_records_for_zone(self, dns_zone, params=None):
        """Get all resource record sets for a managed zone, using the DNS zone.

        Args:
            dns_zone (str): Desired DNS zone to query.
            params (dict): (optional) Additional query parameters for HTTP
                requests to the GDNS API.
        Returns:
            list of dicts representing rrsets.
        """
        managed_zone = self.get_managed_zone(dns_zone)
        url = f'{self._base_url}/managedZones/{managed_zone}/rrsets'

        if not params:
            params = {}

        if 'fields' not in params:
            # Get only the fields we care about
            params['fields'] = ('rrsets/name,rrsets/kind,rrsets/rrdatas,'
                                'rrsets/type,rrsets/ttl,nextPageToken')
        next_page_token = None

        records = []
        while True:
            if next_page_token:
                params['pageToken'] = next_page_token
            response = await self.get_json(url, params=params)
            records.extend(response['rrsets'])
            next_page_token = response.get('nextPageToken')
            if not next_page_token:
                break

        logging.info(f'Found {len(records)} rrsets for zone "{dns_zone}".')
        return records
async def get_records_for_zone ( self , dns_zone , params = None ) : managed_zone = self . get_managed_zone ( dns_zone ) url = f'{self._base_url}/managedZones/{managed_zone}/rrsets' if not params : params = { } if 'fields' not in params : params [ 'fields' ] = ( 'rrsets/name,rrsets/kind,rrsets/rrdatas,' 'rrsets/type,rrsets/ttl,nextPageToken' ) next_page_token = None records = [ ] while True : if next_page_token : params [ 'pageToken' ] = next_page_token response = await self . get_json ( url , params = params ) records . extend ( response [ 'rrsets' ] ) next_page_token = response . get ( 'nextPageToken' ) if not next_page_token : break logging . info ( f'Found {len(records)} rrsets for zone "{dns_zone}".' ) return records
Get all resource record sets for a managed zone, using the DNS zone.

        Args:
            dns_zone (str): Desired DNS zone to query.
            params (dict): (optional) Additional query parameters for HTTP
                requests to the GDNS API.
        Returns:
            list of dicts representing rrsets.