APIs & Integrations

EBirdsall
Participant

Order of Quote Lines is different in API than in UI

Sales Rep entered a quote in the UI in this order:

  1. Bananas
  2. Carrots
  3. Apples
  4. Oranges

 

When I pull the Line Items from the API for this Quote

It comes back;

  1. Carrots
  2. Oranges
  3. Bananas
  4. Apples

Any idea why the order would be different?

0 Upvotes
2 Replies 2
tominal
Guide | Partner
Guide | Partner

Order of Quote Lines is different in API than in UI

Hey @EBirdsall,

 

Most database order by their unique ID by default. Is there a specific reason for requiring them to be in the same order as the deal's line items?

 

Maybe we can help out with a solution for your use case here.

 

Hope that helps!


Thomas Johnson
Community Champion


Kahu Software LLC
A Texan HubSpot consulting firm
https://kahusoftware.com
0 Upvotes
EBirdsall
Participant

Order of Quote Lines is different in API than in UI

We're using the API to send the line items to another software of ours for invoicing.
So it just looks a bit unprofessional when the Customer signs a Quote in Hubspot that has the items in one order, but then gets an Invoice from us with items in a different order.

To give a bit more background... certain line items on our quotes "go together"
The Quote will look like:
Product A
Product A - Add On
Product A - Implementation Fee
Product B
Product C


But then the API pulls the lines in a different order...
Product C
Product A - Add On
Product B
Product A - Implementation Fee
Product A


It just looks a bit all over the place.
I think I'll just take the Array of Line Items and sort them by name- but that still doesn't really solve the issue- just makes things look a bit cleaner.

0 Upvotes