Hi Everyone,
with the v4 api, I’m trying to get the associations, I just upgraded hubspot api from 7.0.0 to 9.0.0, but its the same code which runs well on the documentation website but doesn’t work when I run it on my laptop.
I’ve the following environment
IDE: JupyterNotebook
Python Version: 3.11.3
hubspot-api-client: 9.0.0
script is as follow
try:
api_response = client.crm.associations.v4.basic_api.get_page(object_type="contact", object_id="4115", to_object_type="2-118112", limit=10)
pprint(api_response)
except ApiException as e:
print("Exception when calling basic_api->get_page: %s\n" % e)
the error message:
AttributeError: 'Discovery' object has no attribute 'basic_api'
when I check dir with
dir(client.crm.associations)
i get the following
['class',
'delattr',
'dict',
'dir',
'doc',
'eq',
'format',
'ge',
'getattribute',
'getstate',
'gt',
'hash',
'init',
'init_subclass',
'le',
'lt',
'module',
'ne',
'new',
'reduce',
'reduce_ex',
'repr',
'setattr',
'sizeof',
'str',
'subclasshook',
'weakref',
'_configure_api_client',
'_default_api_factory',
'batch_api',
'config',
'types_api',
'v4']