Arlo

REST Pub API: OnlineActivitySearch filters

The OnlineActivitySearch resource supports filtering of the resultset via the filter query parameter. Filters are specified using the format filter_code=filter_parameter. Multiple filters can be used in a single request and must be separated by commas in the query.

Care must be taken to ensure that all string parameter values are encoded for filters, particularly those involving user-specified values such as codes and names that may have value with characters that, if not properly encoded, would prevent correct parsing of the filter query.

Filters specification

Template ID (eventid)

Filters search results based on their TemplateID. Parameter must be an encoded template ID string value, or an array of encoded template ID string values.

Examples

  • Filter results by a single template ID: ?filter=templateID=233
  • Filter results by a list of template IDs: ?filter=templateID=[233,237,239]

Examples

Example 1

Retrieve all activity results that have a specific template ID (992). This example is a typical method of retrieving online activities for a single template.

GET /api/2012-02-01/pub/resources/onlineactivitysearch/?format=json&fields=OnlineActivityID,TemplateID,Name,ViewUri&filter=templateid=992

{
   "StartIndex":0,
   "Count":16,
   "Items":[
      {
         "OnlineActivityID":317,
         "Name":"Management 101",
         "TemplateID":992,
         "ViewUri":"http://events.example.org/courses/992-management-101",
      },
      {
        "OnlineActivityID":6634,
         "Name":"Management 301",
         "TemplateID":311,
         "ViewUri":"http://events.example.org/courses/311-management-301",
      },
      ...
   ]
}