How can i get the company and contact id associate it to a task with a search endpoint?
method: “post”,
path: “/crm/v3/objects/tasks/search”,
body: {
properties: [
“hubspot_owner_id”,
“hs_task_body”,
“hs_task_type”,
“hs_task_priority”,
“hs_task_subject”,
“hs_task_status”,
],
filterGroups: [
{
filters: [
{
propertyName: “hubspot_owner_id”,
operator: “EQ”,
value: ownerId,
},
{
propertyName: “hs_task_status”,
operator: “EQ”,
value: “NOT_STARTED”,
},
],
},
],
},
Hi, @BDecruz
Have you already looked at the Search through associations options using the pseudo-property associations.{objectType}?
I’d start there and post here again with any errors or to share if you were successful using that approach. Or a similar one.
Best,
Jaycee
Do you mean to add that pseaudo class in the properties array that i send on the body?
properties: [ “hubspot_owner_id”, “hs_task_body”, “hs_task_type”, “hs_task_priority”, “hs_task_subject”, “hs_task_status”, " associations.contacts"],