<commit_before>import logging

import requests

_logger = logging.getLogger(__name__)


class GoDaddyAPI(object):
    _API_TEMPLATE = 'https://api.godaddy.com'

    _GET_DOMAINS = '/v1/domains'
    _GET_DOMAIN = '/v1/domains/{domain}'
    _GET_RECORDS_TYPE_NAME = '/v1/domains/{domain}/records/{type}/@'
    _PUT_RECORDS_TYPE_NAME = '/v1/domains/{domain}/records/{type}/{name}'
    _PATCH_RECORDS = '/v1/domains/{domain}/records'
    _PUT_RECORDS = '/v1/domains/{domain}/records'
    _SSO_KEY_TEMPLATE = 'sso-key {api_key}:{api_secret}'

    def discover_domains(self, account):
        url = self._API_TEMPLATE + self._GET_DOMAINS
        resp = requests.get(url, headers=self._get_auth_headers(account))
        data = resp.json()

        self._log_response_from_method('get', self.discover_domains.__name__, resp)

        domains = list()<commit_msg>Moved version number to a better location in the API URL strings<commit_after>import logging

import requests

_logger = logging.getLogger(__name__)


class GoDaddyAPI(object):
    _API_TEMPLATE = 'https://api.godaddy.com/v1'

    _GET_DOMAINS = '/domains'
    _GET_DOMAIN = '/domains/{domain}'
    _GET_RECORDS_TYPE_NAME = '/domains/{domain}/records/{type}/@'
    _PUT_RECORDS_TYPE_NAME = '/domains/{domain}/records/{type}/{name}'
    _PATCH_RECORDS = '/domains/{domain}/records'
    _PUT_RECORDS = '/domains/{domain}/records'
    _SSO_KEY_TEMPLATE = 'sso-key {api_key}:{api_secret}'

    def discover_domains(self, account):
        url = self._API_TEMPLATE + self._GET_DOMAINS
        resp = requests.get(url, headers=self._get_auth_headers(account))
        data = resp.json()

        self._log_response_from_method('get', self.discover_domains.__name__, resp)

        domains = list()
{'fraction_non_alphanumeric': 0.13459335624284077, 'fraction_numerical': 0.004009163802978236, 'mean_word_length': 3.839335180055402, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2845088', 'n_tokens_mistral': 620, 'n_tokens_neox': 593, 'n_words': 92}