ElementAPI: How to order and/or limit results? Currently collaborating on a site with another developer, which is using ElementAPI pretty heavily for content delivery. 

Is there a way to limit the number of returns on any given json feed? Say; only return the 10 most recent entries in any given channel? Or order the returned data by a specified field asc/desc?

A sample code: 

'trucks.json' =&gt; [
  'elementType' =&gt; 'Entry',
  'criteria' =&gt; ['section' =&gt; 'trucks'],
  'paginate' =&gt; false,
  'transformer' =&gt; function(EntryModel $entry) {
    return [
      (int)$entry-&gt;id,
      $entry-&gt;manufacturer,
Just setting the limit property doesn’t do the trick alone, you need to deactivate pagination, too:

'criteria' =&gt; [
    'section' =&gt; 'trucks',
    'limit'   =&gt; 10,
    'orderBy'   =&gt; 'title asc',
],
'paginate' =&gt; false,