Administrate

Version 2.5 (v2.5)

Filtering

The Administrate API provides a set of filters which are useful for requesting a restricted set of results to avoid further processing and reduce bandwidth. This allows the possiblity to return records between a set of dates, for example, or all those records that belong to a list of ids.

Name Operator Usage
Exactly equal, default __eq attribute__eq=[value]
Not equal __ne attribute__ne=[value]
Less than __lt attribute__lt=[value]
Less than or equal __le attribute__le=[value]
Greater than __gt attribute__gt=[value]
Greater than or equal __ge attribute__ge=[value]
Like, % in query matches any string __lk attribute__lk=[value]
Not Like __nl attribute__nl=[value]
Contains __ct attribute__ct=[value]
Starts with __sw attribute__sw=[value]
Ends with __ew attribute__ew=[value]
In, ie 2 is ‘in’ 1,2,3,4 __in attribute__in=value_1[,value_2]*
Not in __ni attribute__ni=value_1[,value_2]*

Limiting

You can limit the results of a request using the _limit parameter

Example

curl -k -u <username>:<password> \
     https://YOUR-SUBDOMAIN.administrateapp.com/api/v2.5/crm/opportunities?_limit=10

Order

You can order the results of a request using the _order parameter, which takes one or more attributes to order by. By default this will be in ascending order, to sort in descending order prefix the attribute by ‘-‘.

Example ordered by name in ascending order

curl -k -u <username>:<password> \
     https://YOUR-SUBDOMAIN.administrateapp.com/api/v2.5/crm/opportunities?_order=name&_limit=10

Example ordered by name in descending order

curl -k -u <username>:<password> \
    https://YOUR-SUBDOMAIN.administrateapp.com/api/v2.5/crm/opportunities?_order=-name&_limit=10