This is an archive version of the document. To get the most up-to-date information, see the current version.

Orderby System Query Option ($orderby)

The $orderby System Query Option is used to sort resource collections in a response.

For example, to sort cloud repositories by their capacity, send the following request:

GET https://<hostname>:1281/v2/backupRepositories?$orderby=capacity

By default, sorting is made in ascending order. To return resources in a collection in descending order, use the desc suffix.

For example, to show hardware plans with the highest storage quota first in a collection, send the following request:

GET https://<hostname>:1281/v2/hardwarePlans?$orderby=storageQuota%20desc

For the formal grammar of the $orderby query option see the [OData-ABNF] syntax rule.