Associating Products as line items and I am not able to get a total price.

I am having issues with the v3 api line items and associating them with deals. I have it all working except the total price is not being populated.
I am using the v3 REST API and the HS SDK, this is not being done on the ecom bridge.
{{uri}}/crm/v3/objects/line_items?hapikey={{hapikey}}

request to create line item…

{
	"properties": {
		"hs_product_id": 137686334,
		"bottle_count": 1,
		"quantity_per_line": 1,
		"rev_share_due": 123,
		"price": 200.59,
		"discount": 0
	}
}

response from creating the line item…

{
	"id": "796492646",
	"properties": {
		"amount": "200.590",
		"bottle_count": "1",
		"createdate": "2020-08-17T14:45:48.760Z",
		"description": "product description",
		"discount": "0",
		"hs_acv": "200.590",
		"hs_arr": "0.000",
		"hs_lastmodifieddate": "2020-08-17T16:43:30.528Z",
		"hs_margin": "200.590",
		"hs_margin_acv": "200.590",
		"hs_margin_arr": "0.000",
		"hs_margin_mrr": "0.000",
		"hs_margin_tcv": "200.590",
		"hs_mrr": "0.000",
		"hs_object_id": "796492646",
		"hs_product_id": "137686334",
		"hs_sku": "ggg",
		"hs_tcv": "200.590",
		"name": "Product name",
		"price": "200.59",
		"product_id": "222",
		"product_image": "https://test.com/wp-content/uploads/2015/12/test.jpg",
		"quantity_per_line": "1",
		"rev_share_due": "123"
	},
	"createdAt": "2020-08-17T14:45:48.760Z",
	"updatedAt": "2020-08-17T16:43:30.528Z",
	"archived": false
}

Ceate Association Line_items to Deal
{{baseUrl}}/crm/v3/associations/:fromObjectType/:toObjectType/batch/create?hapikey={{hapikey}}
Request to associate line items to deal…

{
	"inputs": [{
		"from": {
			"id": "796492646"
		},
		"to": {
			"id": "2794346745"
		},
		"type": "line_item_to_deal"
	}]
}

response from creating the assosiation…

{
	"status": "COMPLETE",
	"results": [{
		"from": {
			"id": "796492646"
		},
		"to": {
			"id": "2794346745"
		},
		"type": "line_item_to_deal"
	}, {
		"from": {
			"id": "2794346745"
		},
		"to": {
			"id": "796492646"
		},
		"type": "deal_to_line_item"
	}],
	"startedAt": "2020-08-17T16:44:15.228Z",
	"completedAt": "2020-08-17T16:44:15.289Z"
}

It looks like it goes thorugh ok but then when I look at the line items in the deal…

We have role based pricing so prices can vary from purchase to purchase and we would like to have our numbers show the purchase price not the MSRP and be totaled.
Any idea why this would be happening? Thanks!!

Hey @kjphilips,

Based on the screenshot that you shared here, I’m guessing that the reason why the total price is zero, could it be because there’s no quantity state on the line item?

Could you try indicating at least one quantity and see if the price populates?

HA!! I had to use the object properties endpoint to see that property (as suggested in the API documentation) once I dd that I was able to add the Quantity which cleared the issue up.