APIs & Integrations

Lorinda
Member

Get Updated Contacts/Deals From API

SOLVE

Hi All,

 

I'm attempting to pull contacts and deals from the API by descending order of when they were last updated.

 

I don't have access to the GraphQL API on my clien't plan.

 

I'm using the below to pull the contacts along with custom attributes that I need. However, there doesn't seem to be any way to filter or sort by updatedAt.

 

https://api.hubapi.com/crm/v3/objects/contacts?properties=firstname&properties=lastname&properties=e...}

 

I found some docs from a legacy API that pull the records I need but when I try to add the custom attributes (which should be possible according to the docs), they don't appear in the results. 

 

https://api.hubapi.com/contacts/v1/lists/recently_updated/contacts/recent?properties=firstname&prope...

 

Here's the doc for the legacy API

 

https://community.hubspot.com/t5/APIs-Integrations/New-APIs-Get-all-the-updated-records-from-an-obje...

 

Please can someone correct my syntax or point me in the direction of the correct docs?

 

I'd prefer not to have to implement web hooks for this if poss. Hoping there's a way to do this via the API. It's sucha a great API in all other ways. Surely there's a way to do this 🙂

 

Many thanks in advance

 

Lorinda

0 Upvotes
1 Accepted solution
Jaycee_Lewis
Solution
Community Manager
Community Manager

Get Updated Contacts/Deals From API

SOLVE

Hey, @Lorinda 👋 I want to make sure you've seen this documentation — CRM Search API. This allows you to customize the properties returned, as well as sort them — Sort Search Results

 

Have fun coding! — Jaycee

linkedin

Jaycee Lewis

Developer Community Manager

Community | HubSpot

View solution in original post

2 Replies 2
Jaycee_Lewis
Solution
Community Manager
Community Manager

Get Updated Contacts/Deals From API

SOLVE

Hey, @Lorinda 👋 I want to make sure you've seen this documentation — CRM Search API. This allows you to customize the properties returned, as well as sort them — Sort Search Results

 

Have fun coding! — Jaycee

linkedin

Jaycee Lewis

Developer Community Manager

Community | HubSpot

Lorinda
Member

Get Updated Contacts/Deals From API

SOLVE

Jaycee Lewis. You are a hero. Thank you. Tested and working exactly as hoped