Socrata was acquired by Tyler Technologies in 2018 and is now the Data and Insights division of Tyler. The platform is still powered by the same software formerly known as Socrata but you will see references to Data & Insights going forward.

The $order Parameter

The $order parameter determines how the results should be sorted, using the values from the specified columns, similar to a SQL ORDER BY. Sorting can be performed in either ascending or descending order, the default being ascending, but you can also reverse the order with DESC.

For example, to sort our earthquakes by magnitude, in descending order:

https://soda.demo.socrata.com/resource/4tka-6guv.json?$order=magnitude DESC

We could sort them in ascending order by replacing DESC with ASC, or by simply omitting it.

Heads Up! The order of the results of a query are not implicitly ordered, so if you're paging, make sure you provide an $order clause or at a minimum $order=:id. That will guarantee that the order of your results will be stable as you page through the dataset.