hubspot3 icon indicating copy to clipboard operation
hubspot3 copied to clipboard

Unable to pass params to contacts.get_all()

Open kvdb opened this issue 4 years ago • 1 comments

As documented in the project README (https://github.com/jpetrucciani/hubspot3#passing-params), I should pass params to send extra properties to hubspot. Seems this doesn't work for contacts:

contacts = client.contacts.get_all(params={"showListMemberships": "true"}, extra_properties=["hs_language"])

I got:

    contacts = client.contacts.get_all(params={"showListMemberships": "true"}, extra_properties=["hs_language"])
  File "/home/kvdb/.local/share/virtualenvs/send-cMuOhGEa/lib/python3.8/site-packages/hubspot3/contacts.py", line 163, in get_all
    batch = self._call(
TypeError: _call() got multiple values for keyword argument 'params'

kvdb avatar Jan 11 '21 14:01 kvdb

Hi kvdb, No you can only get contacts with extra properties, like: contacts = client.contacts.get_all(extra_properties=["hs_language"])

And get extra information on Memberships by diving into: client.contacts.get_contact_by_id(contact_id="ID")

In here you have you ListMemberships information

freekklein avatar May 10 '21 10:05 freekklein