Jun 29, 20213:40 AM - edited Jun 29, 20214:36 AM
Participant
API - Batch read deals and include line items
SOLVE
Hi all,
I'm trying to figure out how I would get a list of specific deals and include their line items in the result set.
I can see on this end point /crm/v3/objects/deals that you can use the "associations" parameter to tell the API to include line items, however I'm struggling to recreate this behaviour on the batch read deals end point.
Here's where I am at;
I'm posting to /crm/v3/objects/deals/batch/read with the following JSON;
If what I am trying to do is not possible is there a way to get line items by association with deals? - i.e. I provide a list of deal id's as the search criteria and get back a list of line items matching the criteria.
Thanks for the response, yeah I've looked into associations API, I was hoping to avoid the extra call required to first get deals then a call to associations to get the line items (and then again to get the actual line items!) seems wasteful but after doing a lot of reading it looks like there isn't any other options.
Not sure if you'd know this but out of interest is there any plans to introduce GraphQL? it would be nice to be able to just define what I wanted from the API in a single call rather than have to make multiple calls to get all the data I wanted.
Thanks for the response, yeah I've looked into associations API, I was hoping to avoid the extra call required to first get deals then a call to associations to get the line items (and then again to get the actual line items!) seems wasteful but after doing a lot of reading it looks like there isn't any other options.
Not sure if you'd know this but out of interest is there any plans to introduce GraphQL? it would be nice to be able to just define what I wanted from the API in a single call rather than have to make multiple calls to get all the data I wanted.