Python Rest API request = 403

Hi, new to using the API.

I’ve been getting intermittent 403 errors at which point the only thing that seems to work is creating a new application / API key. Now this isn’t working either. Any help would be greatly appreciated!

    # company house api credentials
    url = "https://api.companieshouse.gov.uk/search/companies?q={}"
    api_key = "<my key here>"

    response = requests.get(url.format(query), auth=(api_key,''), verify = source_path + "/Zscaler.crt")

<Response [403]>

JSONDecodeError: Expecting value