Reference: Analytics Filters

This document provides reference documentation for Moesif’s User and Company analytics filters.

Filter Types

The available filters broadly falls into the following three categories:

You may have more filters available to you outside this document’s scope. For example, for GraphQL APIs, Moesif parses GraphQL queries and automatically generates a secondary set of filters called GraphQL Query filters. For more information, see API Protocol Support.

Search Function

To enter a custom query expression, select the search as the filter function. This function allows you to search on single terms within your text fields such as a title or description field.

The search function supports the following operators: -+ to perform a logical AND operation among the search terms.

  • | to perform a logical OR operation among the search terms.
  • - performs a logical NOT operation and negates a single search term.

The search function also supports the following special characters: -" wraps a set of search terms.

  • * wildcard operator to use at the start or end of any search term.
  • ( and ) to specify operator precedence.

For example, if you want to only match against URI Route that are not /esignature/, then enter -"/esignature/" as the search term.

The 'search' function in filters

User Filters

Contains filters to query on user analytics and data.

Geo IP

Allows you to filter by geographic location data associated with the user:

  • City
  • Country Code
  • Country
  • Region
  • Timezone

User Agent

Contains filters to query user agent data associated with the user:

  • Build
  • Device
  • Major
  • Minor
  • Name
  • OS Major
  • OS Minor
  • OS
  • Patch

Enrichment

Allows you to filter on demographic enrichment data that you have attached on user profiles.

Moesif Enterprise supports demographic enrichment for companies that allows you to add demographic data to customers. For more information, contact us.

Cohort

Allows you to filter on saved cohorts for companies.

Created

The time you created a user profile in Moesif.

First Seen Time

The first time a user accesses your product.

Last Seen Time

The last time a company used your product.

Modified Time

The last time a user profile was modified.

TTFHW

The Time to First Hello World (TTFHW) metric for a user.

User Email

Lets you filter by associated user’s email after setting it in the user metadata.

Name

Lets you filter by associated user’s name after setting it in the user metadata.

User Phone Number

Lets you filter by associated user’s phone number after setting it in the user metadata.

Metadata

User demographics or other properties you store in the user metadata.

Company Id

Allows you to filter for a specific customer by a company ID. This feature requires you to set up company identification using an SDK. Otherwise, you may not get accurate results.

Company

If the user is a member of a company, this object contains the linked company’s data. For more information, see Company Filters.

Campaign

Allows you to filter by HTTP Referer data and various UTM parameters.

By filtering on the Campaign object, you can track effectiveness of your acquisition channels. Moesif JavaScript browser SDK automatically sets this object, but not for server side SDKs.

Auth/Session Token

Allows you to filter by all API keys or session tokens a users have used. For more information, see Identification of Users

Initial Request Route

Initial Request Route refers to the API endpoint the user sent their very first request to. You can use this filter to understand how customers started to use your product.

Company Filters

Contains filters to query on company analytics and data.

Geo IP

Allows you to filter by geographic location data associated with the company:

  • City
  • Country Code
  • Country
  • Region
  • Timezone

User Agent

Contains filters to query user agent data associated with the company:

  • Build
  • Device
  • Major
  • Minor
  • Name
  • OS Major
  • OS Minor
  • OS
  • Patch

Enrichment

Allows you to filter on demographic enrichment data that you have attached on company profiles.

Moesif Enterprise supports demographic enrichment for companies that allows you to add demographic data to customers. For more information, contact us.

Subscriptions

Allows you to filter on subscription data for a company.

If you monetize your API, you can use these filters to set up complex business logic for different billing providers such as Chargebee, Recurly, Stripe, and more.

Metadata

User demographics or other properties you store in the company metadata.

Campaign

Allows you to filter by HTTP Referer data and various UTM parameters.

By filtering on the Campaign object, you can track effectiveness of your acquisition channels. Moesif JavaScript browser SDK automatically sets this object, but not for server side SDKs.

Auth/Session Token

Allows you to filter by all API keys or session tokens associated with the company. For more information, see How to Track Companies

Cohort

Allows you to filter on saved cohorts for companies.

Company Domain

Lets you filter by company website domains after setting them in the company metadata.

Company Id

Allows you to filter by company IDs.

This feature requires you to set up company identification using an SDK. Otherwise, you may not get accurate results.

Initial Request Route

Initial Request Route refers to the API endpoint the company sent their very first request to. You can use this filter to understand how customers started to use your product.

Created

The time you created a company profile in Moesif.

First Seen Time

The first time a company accesses your product.

Last Seen Time

The last time a company used your product.

Modified Time

Last time you modified a company’s metadata through UI or API.

TTFHW

The Time to First Hello World (TTFHW) metric for a company.

Event Filters

The event filters allow you to filter on event data.

These filters fall into four catagories:

Request Filters

Request filters allow you to filter on HTTP request data including headers.

Request.Geo IP

Allows you to filter by geographic location data with the following filters:

  • City
  • Country Code
  • Country
  • Region Code
  • Region
  • Timezone

Request.User Agent

Contains filters to query user agent data:

  • Build
  • Device
  • Major
  • Minor
  • Name
  • OS Major
  • OS Minor
  • OS
  • Patch

Request.Body

Contains filters to query data from a HTTP request body.

Request.URI Segments

Allows you to filter on URI segments. Moesif assigns zero-based numbers to the URI segments. Therefore, the first URI segment has the number 0, and so on.

Request.Headers

Allows you to filter on HTTP request headers.

Request.API Version

If you set an API version using Moesif SDKs, you can filter on the version.

Request.Content Length

Corresponds to the Content-Length HTTP request header.

Request.Content Type

Corresponds to the Content-Type HTTP request header.

Request.IP Address

The IP address of the user agent making a request. Moesif only supports IPv4 addresses.

Request.Time

The request time.

Request.URI Raw

The raw URI that was requested.

Request.URI Route

The path components of the URI—for example, https://myblog.com/posts contains the /posts route.

Request.Verb/Method

Allows you to filter on the HTTP request methods.

Response Filters

Response filters allow you to filter on HTTP response data including headers.

Response.Body

Contains filters to query data from a HTTP response body.

Response.Headers

Allows you to filter on HTTP response headers.

Response.Status Code

Allows you to filter on the HTTP response status codes.

Metadata Filters

The Metadata filter allows you to filter on custom metadata you set using event metadata.

Common filters

The following common filters are available outside the preceding three event filter types:

Tag

Allows you filter by event tags.

Action Name

Lets you filter by custom actions.

Auth/Session Token

The authentication or session token used when making API calls—for example, credentials in the Authorization HTTP request header. For more information, see Identification of Users and How to Track Companies.

Elapsed Duration

Lets you filter by the API request duration in milliseconds. The elapsed duration means the time elapsed between the API request and the server response.

id

Moesif assigns a unique ID to each API call called an event ID. If you know the event ID—for example, you can use it here as a filter.

Event Type

Allows you to filter by the event type: API Calls or Actions.

Request Direction

This filter applies to API Calls only and allows you to filter by the direction of API requests.

A value of Incoming shows only API calls to your own services you provide. A value of Outgoing only shows API calls going out to a third-party service.

Updated: