closeio / closeio-api

Python API Client for Close
http://developer.close.com/
MIT License
65 stars 47 forks source link

Duplicate leads #96

Closed pquadri closed 6 years ago

pquadri commented 6 years ago

Hello, I'm trying to use your APIs implementation to retrieve data of our leads (about 45k records). While the number of retrieved records is correct, there are a lot of duplicates (about 8k) that don't match the number of duplicates i get from the export from the close.io website. Any idea about what could be causing that?

philfreo commented 6 years ago

Hey,

If you're seeing more leads/duplicates as you paginate via the Leads API than an Export, I'd ask what your query is. Specifically, if you're paginating through results you need to include a sort: that keeps the order of leads consistent even as the leads are changing (e.g. if somebody opens an email). So I would suggest something like sort:-created.

Note: our Export also offers an API, or you can just operate on the .json form of the export file which is typically better than paginating, if possible.

If you have further questions please don't hesitate to reach out to support@close.io!