cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1136
Views
12
Helpful
2
Replies

/InventoryDetails - sort by "sub"-element

Bjoern Hansen
Level 1
Level 1

Hey!

I'd like to sort a /InventoryDetails call by the product family element.

As the product family element is part of the summary element, a ".sort=productFamily" or "sort=summary.productFamily" does not work.

The documentation on sorting is very short and does not cover this case - any idea on this?

Thanks in advance!

1 Accepted Solution

Accepted Solutions

Thanks for the hint.

It wasn't the missing dot (that was a copy&paste error), but a capital S in Summary - didn't think of that.

Thanks a lot for the help

I suggest adding the info on how to query sub-elements to the API docs. Not everybody might guess that right.

View solution in original post

2 Replies 2

Spencer Zier
Cisco Employee
Cisco Employee

Could this be a typo?  It looks like you don't have the preceding dot in front of sort.  "summary.productFamily" is the correct way to reference the product family parameter of InventoryDetails.  The API query should look something like "InventoryDetails?.sort=summary.productFamily".

Thanks for the hint.

It wasn't the missing dot (that was a copy&paste error), but a capital S in Summary - didn't think of that.

Thanks a lot for the help

I suggest adding the info on how to query sub-elements to the API docs. Not everybody might guess that right.