APIs & Integrations

pbmartin
Contributor

Line Items: Return all properties with GET

SOLVE

Thanks in advance for your help. I don't receive all the LineItem properties that contain values when I use this GET in Postman. How can I receive all the data, including the associated Deal ID?

/crm/v3/objects/line_items?associations=deals&hapikey=xxxxx...

 

The returned data only shows:

"results": [
        {
            "id""777777777",
            "properties": {
                "amount""0.000",
                "createdate""2020-02-18T21:58:11.654Z",
                "hs_lastmodifieddate""2021-07-18T06:44:11.917Z",
                "hs_object_id""777777777",
                "hs_product_id""88888888",
                "quantity""1"
            },
            "createdAt""2020-02-18T21:58:11.654Z",
            "updatedAt""2021-07-18T06:44:11.917Z",
            "archived"false,
            "associations": {
                "deals": {
                    "results": [
                        {
                            "id""2222222222",
                            "type""line_item_to_deal"
                        }
                    ]
                }
            }
        },
0 Upvotes
1 Accepted solution
dennisedson
Solution
HubSpot Product Team
HubSpot Product Team

Line Items: Return all properties with GET

SOLVE

You would need to make a new request to the deals endpoint requesting the properties you are wanting.

View solution in original post

0 Upvotes
3 Replies 3
dennisedson
HubSpot Product Team
HubSpot Product Team

Line Items: Return all properties with GET

SOLVE

@pbmartin 

To get other properties, you will need to append them to the request url as a parameter

eg: properties=propertyname

0 Upvotes
pbmartin
Contributor

Line Items: Return all properties with GET

SOLVE
What about the properties under "Associations"
0 Upvotes
dennisedson
Solution
HubSpot Product Team
HubSpot Product Team

Line Items: Return all properties with GET

SOLVE

You would need to make a new request to the deals endpoint requesting the properties you are wanting.

0 Upvotes