Groups (Code Config)

Last Updated: 2021-10-12

Once you have an App, Source, and Properties (start with an App if you don't have any), then you're ready to define your Groups.

Groups are where the magic happens in Grouparoo. (It's in the name, after all!) Groups are a segment or cohort of Records. They are useful in that you can use Groups to target a specific set of users to export to some Destination. You can have Calculated Groups and Manual Groups. See here to learn more about the core concepts in Grouparoo.

Generating a Calculated Group

To generate a new Calculated Group for your Grouparoo application, run the generate command.

grouparoo generate group:calculated all_emails

Note here that new_high_value_customers is the ID for the Group. An ID is always required when generating a config object.

This command will generate a file in your application directory at config/groups/new_high_value_customers.js that looks something like this:

exports.default = async function buildConfig() {
  return [
    {
      class: "group",
      id: "new_high_value_customers",
      name: "New High Value Customers",
      type: "calculated",
      rules: [],
    },
  ];
};

which you can customize with rules such as:

exports.default = async function buildConfig() {
  return [
    {
      class: "group",
      id: "recent_high_value_customers",
      name: "Recent High Value Customers",
      type: "calculated",
      rules: [
        {
          propertyId: "email",
          operation: { op: "exists" },
        },
        {
          propertyId: "email",
          operation: { op: "notILike" },
          match: "%grouparoo.com",
        },
        {
          propertyId: "last_purchase_date",
          operation: { op: "relative_gt" },
          relativeMatch: "15",
          relativeMatchUnit: "days",
        },
        {
          propertyId: "ltv",
          operation: { op: "gt" },
          match: "3000",
        },
        {
          propertyId: "subscribed",
          operation: { op: "eq" },
          match: "true",
        },
      ],
    },
  ];
};

This Group would contain Records with an email address that is not @grouparoo.com that have made a purchase in the last 15 days, have a lifetime value over $3000, and are subscribed to our newsletter.

More info this below.

Configuring Your Calculated Group

Configuring a Calculated Group is all about adding Rules to the Group. A Rule is some logical operator to Filter Properties. A Record must match every Rule to be included in the Group.

Available operations depends on both the type of Property and the underlying Grouparoo database (SQLite vs. Postgres). See below for a list of rules. (If in doubt, choose Postgres.)

Note you can use SQL wildcard characters (%, _, [ ], ^, -) in your Group rule match values as appropriate and necessary.

The following operators are available on boolean properties:

exists
exists with any value
{
  "propertyId": "subscribed",
  "operation": {
    "op": "exists"
  }
}
All records that do not have data about subscription status
notExists
does not exist
{
  "propertyId": "subscribed",
  "operation": {
    "op": "notExists"
  }
}
All records that have data about subscription status
eq
is equal to
{
  "propertyId": "subscribed",
  "operation": {
    "op": "eq"
  },
  "match": "true"
}
All subscribers
ne
is not equal to
{
  "propertyId": "subscribed",
  "operation": {
    "op": "ne"
  },
  "match": "true"
}
All non-subscribers

The following operators are available on date properties:

exists
exists with any value
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "exists"
  }
}
All records who have made a purchase
notExists
does not exist
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "notExists"
  }
}
All records who have not made a purchase
eq
is equal to
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "eq"
  },
  "match": "2021-05-25T04:45:00.000+00:00"
}
All records whose most recent purchase was on May 25, 2021 at exactly 4:45AM UTC.
ne
is not equal to
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "ne"
  },
  "match": "2021-05-25T04:45:00.000+00:00"
}
All records whose most recent purchase was anytime except May 25, 2021 at exactly 4:45AM UTC.
gt
is after
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lt"
  },
  "match": "2020-12-25T04:45:00.00+00:00"
}
All records whose most recent purchase is after December 25, 2020 at 04:45:00 UTC.
lt
is before
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lt"
  },
  "match": "2021-05-25T09:30:00.000+00:00"
}
All records whose most recent purchase is prior to May 25, 2021 9:30:00 AM UTC.
gte
is on or after
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "gte"
  },
  "match": "2019-06-14T18:16:00.000+00:00"
}
All records whose most recent purchase is exactly at or after June 14, 2019 at 6:16 PM UTC
lte
is on or before
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lte"
  },
  "match": "2020-12-25T04:45:00.000+00:00"
}
All records whose most recent purchase is exactly at or before December 25, 2020 at 04:45:00 UTC.
relative_gt
is in the past
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "relative_gt"
  },
  "relativeMatchNumber": "60",
  "relativeMatchUnit": "days"
}
All records whose most recent purchase is within the last 60 days
relative_lt
is in the future
{
  "propertyId": "subscription_ends",
  "operation": {
    "op": "relative_lt"
  },
  "relativeMatchNumber": "30",
  "relativeMatchUnit": "days"
}
All records whose subscription ends within the next 30 days

The following operators are available on email properties:

exists
exists with any value
{
  "propertyId": "email",
  "operation": {
    "op": "exists"
  }
}
All records with an email address listed.
notExists
does not exist
{
  "propertyId": "email",
  "operation": {
    "op": "notExists"
  }
}
All records without an email address listed.
eq
is equal to
{
  "propertyId": "email",
  "operation": {
    "op": "eq"
  },
  "match": "hello@grouparoo.com"
}
All records with an email address exactly equal to hello@grouparoo.com.
ne
is not equal to
{
  "propertyId": "email",
  "operation": {
    "op": "ne"
  },
  "match": "hello@grouparoo.com"
}
All records without an email address exactly equal to hello@grouparoo.com.
like
is like (case sensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "like"
  },
  "match": "%smith%"
}
All records with an email address containing smith (case sensitive).
notLike
is not like (case sensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "notLike"
  },
  "match": "%smith%"
}
All records without an email address containing smith (case sensitive).
startsWith
starts with
{
  "propertyId": "email",
  "operation": {
    "op": "startsWith"
  },
  "match": "test"
}
All records with an email address starting with "test" (case sensitive).
endsWith
ends with
{
  "propertyId": "email",
  "operation": {
    "op": "endsWith"
  },
  "match": "grouparoo.com"
}
All records with an email address ending with "@grouparoo.com" (case sensitive).
substring
includes the string
{
  "propertyId": "email",
  "operation": {
    "op": "substring"
  },
  "match": "grouparoo"
}
All records with an email address containing "grouparoo".
iLike
is like (case insensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "like"
  },
  "match": "%smith%"
}
All records with an email address containing smith (case insensitive).
notILike
is not like (case insensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "notILike"
  },
  "match": "%smith%"
}
All records without an email address containing smith (case insensitive)).

The following operators are available on float properties:

exists
exists with any value
{
  "propertyId": "ltv",
  "operation": {
    "op": "exists"
  }
}
All records with an LTV value.
notExists
does not exist
{
  "propertyId": "ltv",
  "operation": {
    "op": "notExists"
  }
}
All records without an LTV value.
eq
is equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "eq"
  },
  "match": "113932.97"
}
All records with an LTV of exactly $113,932.97.
ne
is not equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "ne"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97.
gt
is greater than
{
  "propertyId": "ltv",
  "operation": {
    "op": "gt"
  },
  "match": "113932.97"
}
All records without an LTV of greater than $113,932.97.
lt
is less than
{
  "propertyId": "ltv",
  "operation": {
    "op": "lt"
  },
  "match": "113932.97"
}
All records without an LTV of less than $113,932.97.
gte
is greater than or equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "gte"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97. or more
lte
is less than or equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "lte"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97. or less

The following operators are available on integer properties:

exists
exists with any value
{
  "propertyId": "visits",
  "operation": {
    "op": "notExists"
  }
}
All records with any value in the "visits" field.
notExists
does not exist
{
  "propertyId": "visits",
  "operation": {
    "op": "notExists"
  }
}
All records with an empty "visits" field.
eq
is equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "eq"
  },
  "match": "6"
}
All records with exactly six visits.
ne
is not equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "ne"
  },
  "match": "6"
}
All records with any number of visits except six.
gt
is greater than
{
  "propertyId": "visits",
  "operation": {
    "op": "gt"
  },
  "match": "6"
}
All records with more than six visits.
lt
is less than
{
  "propertyId": "visits",
  "operation": {
    "op": "ne"
  },
  "match": "6"
}
All records with less than six visits.
gte
is greater than or equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "gte"
  },
  "match": "6"
}
All records with six or more visits.
lte
is less than or equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "lte"
  },
  "match": "6"
}
All records with 6 or fewer visits.

The following operators are available on phoneNumber properties:

exists
exists with any value
{
  "propertyId": "phone",
  "operation": {
    "op": "exists"
  }
}
All records with a phone number listed.
notExists
does not exist
{
  "propertyId": "phone",
  "operation": {
    "op": "notExists"
  }
}
All records without a phone number listed.
eq
is equal to
{
  "propertyId": "phone",
  "operation": {
    "op": "eq"
  },
  "match": "+1-555-555-5555"
}
All records with a phone number of +1-555-555-5555.
ne
is not equal to
{
  "propertyId": "phone",
  "operation": {
    "op": "ne"
  },
  "match": "+1-555-555-5555"
}
All records without a phone number of +1-555-555-5555.
like
is like (case sensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "like"
  },
  "match": "%780%"
}
All records with a phone number containing 780.
notLike
is not like (case sensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "notLike"
  },
  "match": "%780%"
}
All records without a phone number containing 780.
startsWith
starts with
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "+1"
}
All records with a phone number starting with +1.
endsWith
ends with
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "80"
}
All records with a phone number ending with 80.
substring
includes the string
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "80"
}
All records with a phone number containing the substring 80.
iLike
is like (case insensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "notLike"
  },
  "match": "%780%"
}
All records without a phone number containing 780.
notILike
is not like (case insensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "notLike"
  },
  "match": "%780%"
}
All records without a phone number containing 780.

The following operators are available on string properties:

exists
exists with any value
{
  "propertyId": "lastName",
  "operation": {
    "op": "exists"
  }
}
All records with a last name listed.
notExists
does not exist
{
  "propertyId": "lastName",
  "operation": {
    "op": "notExists"
  }
}
All records without a last name listed.
eq
is equal to
{
  "propertyId": "lastName",
  "operation": {
    "op": "eq"
  },
  "match": "Ramirez"
}
All records with a last name of exactly Ramirez.
ne
is not equal to
{
  "propertyId": "lastName",
  "operation": {
    "op": "ne"
  },
  "match": "Ramirez"
}
All records without a last name of exactly Ramirez.
like
is like (case sensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "like"
  },
  "match": "__m%"
}
All records with a last name that has a third letter of m.
notLike
is not like (case sensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "notLike"
  },
  "match": "__m%"
}
All records without a last name that has a third letter of m.
startsWith
starts with
{
  "propertyId": "lastName",
  "operation": {
    "op": "startsWith"
  },
  "match": "Mc"
}
All records with a last name starting with Mc (case sensitive)
endsWith
ends with
{
  "propertyId": "lastName",
  "operation": {
    "op": "endsWith"
  },
  "match": "son"
}
All records with a last name ending with son (case sensitive).
substring
includes the string
{
  "propertyId": "lastName",
  "operation": {
    "op": "substring"
  },
  "match": "al"
}
All records with a last name containing al (case sensitive).
iLike
is like (case insensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "iLike"
  },
  "match": "%al%"
}
All records with a last name containing al (case insensitive).
notILike
is not like (case insensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "iLike"
  },
  "match": "%al%"
}
All records without a last name containing al (case insensitive).

The following operators are available on url properties:

exists
exists with any value
{
  "propertyId": "company_url",
  "operation": {
    "op": "exists"
  }
}
All records with a company URL listed.
notExists
does not exist
{
  "propertyId": "company_url",
  "operation": {
    "op": "notExists"
  }
}
All records without a company URL listed.
eq
is equal to
{
  "propertyId": "company_url",
  "operation": {
    "op": "eq"
  },
  "match": "https://www.grouparoo.com"
}
All records with a company URL exactly equal to https://www.grouparoo.com.
ne
is not equal to
{
  "propertyId": "company_url",
  "operation": {
    "op": "ne"
  },
  "match": "https://www.grouparoo.com"
}
All records without a company URL exactly equal to https://www.grouparoo.com.
like
is like (case sensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "like"
  },
  "match": "%grouparoo.com"
}
All records with a company URL containing anything and then grouparoo.com (case sensitive).
notLike
is not like (case sensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "like"
  },
  "match": "%grouparoo.com"
}
All records without a company URL containing anything and then grouparoo.com (case sensitive).
startsWith
starts with
{
  "propertyId": "company_url",
  "operation": {
    "op": "startsWith"
  },
  "match": "https"
}
All records with a company URL starting with https (case sensitive).
endsWith
ends with
{
  "propertyId": "company_url",
  "operation": {
    "op": "startsWith"
  },
  "match": ".com"
}
All records with a company URL ending with .com (case sensitive)
substring
includes the string
{
  "propertyId": "company_url",
  "operation": {
    "op": "substring"
  },
  "match": "grouparoo"
}
All records with a company URL containing grouparoo (case sensitive)
iLike
is like (case insensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "substring"
  },
  "match": "%Grouparoo.com"
}
All records with a company URL containing anything followed by Grouparoo.com (case insensitive).
notILike
is not like (case insensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "substring"
  },
  "match": "%Grouparoo.com"
}
All records without a company URL containing anything followed by Grouparoo.com (case insensitive).

The following operators are available on boolean properties:

exists
exists with any value
{
  "propertyId": "subscribed",
  "operation": {
    "op": "exists"
  }
}
All records that do not have data about subscription status
notExists
does not exist
{
  "propertyId": "subscribed",
  "operation": {
    "op": "notExists"
  }
}
All records that have data about subscription status
eq
is equal to
{
  "propertyId": "subscribed",
  "operation": {
    "op": "eq"
  },
  "match": "true"
}
All subscribers
ne
is not equal to
{
  "propertyId": "subscribed",
  "operation": {
    "op": "ne"
  },
  "match": "true"
}
All non-subscribers

The following operators are available on date properties:

exists
exists with any value
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "exists"
  }
}
All records who have made a purchase
notExists
does not exist
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "notExists"
  }
}
All records who have not made a purchase
eq
is equal to
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "eq"
  },
  "match": "2021-05-25T04:45:00.000+00:00"
}
All records whose most recent purchase was on May 25, 2021 at exactly 4:45AM UTC.
ne
is not equal to
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "ne"
  },
  "match": "2021-05-25T04:45:00.000+00:00"
}
All records whose most recent purchase was anytime except May 25, 2021 at exactly 4:45AM UTC.
gt
is after
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lt"
  },
  "match": "2020-12-25T04:45:00.00+00:00"
}
All records whose most recent purchase is after December 25, 2020 at 04:45:00 UTC.
lt
is before
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lt"
  },
  "match": "2021-05-25T09:30:00.000+00:00"
}
All records whose most recent purchase is prior to May 25, 2021 9:30:00 AM UTC.
gte
is on or after
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "gte"
  },
  "match": "2019-06-14T18:16:00.000+00:00"
}
All records whose most recent purchase is exactly at or after June 14, 2019 at 6:16 PM UTC
lte
is on or before
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "lte"
  },
  "match": "2020-12-25T04:45:00.000+00:00"
}
All records whose most recent purchase is exactly at or before December 25, 2020 at 04:45:00 UTC.
relative_gt
is in the past
{
  "propertyId": "last_purchase_date",
  "operation": {
    "op": "relative_gt"
  },
  "relativeMatchNumber": "60",
  "relativeMatchUnit": "days"
}
All records whose most recent purchase is within the last 60 days
relative_lt
is in the future
{
  "propertyId": "subscription_ends",
  "operation": {
    "op": "relative_lt"
  },
  "relativeMatchNumber": "30",
  "relativeMatchUnit": "days"
}
All records whose subscription ends within the next 30 days

The following operators are available on email properties:

exists
exists with any value
{
  "propertyId": "email",
  "operation": {
    "op": "exists"
  }
}
All records with an email address listed.
notExists
does not exist
{
  "propertyId": "email",
  "operation": {
    "op": "notExists"
  }
}
All records without an email address listed.
eq
is equal to
{
  "propertyId": "email",
  "operation": {
    "op": "eq"
  },
  "match": "hello@grouparoo.com"
}
All records with an email address exactly equal to hello@grouparoo.com.
ne
is not equal to
{
  "propertyId": "email",
  "operation": {
    "op": "ne"
  },
  "match": "hello@grouparoo.com"
}
All records without an email address exactly equal to hello@grouparoo.com.
like
is like (case sensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "like"
  },
  "match": "%smith%"
}
All records with an email address containing smith (case sensitive).
notLike
is not like (case sensitive)
{
  "propertyId": "email",
  "operation": {
    "op": "notLike"
  },
  "match": "%smith%"
}
All records without an email address containing smith (case sensitive).
startsWith
starts with
{
  "propertyId": "email",
  "operation": {
    "op": "startsWith"
  },
  "match": "test"
}
All records with an email address starting with "test" (case sensitive).
endsWith
ends with
{
  "propertyId": "email",
  "operation": {
    "op": "endsWith"
  },
  "match": "grouparoo.com"
}
All records with an email address ending with "@grouparoo.com" (case sensitive).
substring
includes the string
{
  "propertyId": "email",
  "operation": {
    "op": "substring"
  },
  "match": "grouparoo"
}
All records with an email address containing "grouparoo".

The following operators are available on float properties:

exists
exists with any value
{
  "propertyId": "ltv",
  "operation": {
    "op": "exists"
  }
}
All records with an LTV value.
notExists
does not exist
{
  "propertyId": "ltv",
  "operation": {
    "op": "notExists"
  }
}
All records without an LTV value.
eq
is equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "eq"
  },
  "match": "113932.97"
}
All records with an LTV of exactly $113,932.97.
ne
is not equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "ne"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97.
gt
is greater than
{
  "propertyId": "ltv",
  "operation": {
    "op": "gt"
  },
  "match": "113932.97"
}
All records without an LTV of greater than $113,932.97.
lt
is less than
{
  "propertyId": "ltv",
  "operation": {
    "op": "lt"
  },
  "match": "113932.97"
}
All records without an LTV of less than $113,932.97.
gte
is greater than or equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "gte"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97. or more
lte
is less than or equal to
{
  "propertyId": "ltv",
  "operation": {
    "op": "lte"
  },
  "match": "113932.97"
}
All records without an LTV of exactly $113,932.97. or less

The following operators are available on integer properties:

exists
exists with any value
{
  "propertyId": "visits",
  "operation": {
    "op": "notExists"
  }
}
All records with any value in the "visits" field.
notExists
does not exist
{
  "propertyId": "visits",
  "operation": {
    "op": "notExists"
  }
}
All records with an empty "visits" field.
eq
is equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "eq"
  },
  "match": "6"
}
All records with exactly six visits.
ne
is not equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "ne"
  },
  "match": "6"
}
All records with any number of visits except six.
gt
is greater than
{
  "propertyId": "visits",
  "operation": {
    "op": "gt"
  },
  "match": "6"
}
All records with more than six visits.
lt
is less than
{
  "propertyId": "visits",
  "operation": {
    "op": "ne"
  },
  "match": "6"
}
All records with less than six visits.
gte
is greater than or equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "gte"
  },
  "match": "6"
}
All records with six or more visits.
lte
is less than or equal to
{
  "propertyId": "visits",
  "operation": {
    "op": "lte"
  },
  "match": "6"
}
All records with 6 or fewer visits.

The following operators are available on phoneNumber properties:

exists
exists with any value
{
  "propertyId": "phone",
  "operation": {
    "op": "exists"
  }
}
All records with a phone number listed.
notExists
does not exist
{
  "propertyId": "phone",
  "operation": {
    "op": "notExists"
  }
}
All records without a phone number listed.
eq
is equal to
{
  "propertyId": "phone",
  "operation": {
    "op": "eq"
  },
  "match": "+1-555-555-5555"
}
All records with a phone number of +1-555-555-5555.
ne
is not equal to
{
  "propertyId": "phone",
  "operation": {
    "op": "ne"
  },
  "match": "+1-555-555-5555"
}
All records without a phone number of +1-555-555-5555.
like
is like (case sensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "like"
  },
  "match": "%780%"
}
All records with a phone number containing 780.
notLike
is not like (case sensitive)
{
  "propertyId": "phone",
  "operation": {
    "op": "notLike"
  },
  "match": "%780%"
}
All records without a phone number containing 780.
startsWith
starts with
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "+1"
}
All records with a phone number starting with +1.
endsWith
ends with
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "80"
}
All records with a phone number ending with 80.
substring
includes the string
{
  "propertyId": "phone",
  "operation": {
    "op": "startsWith"
  },
  "match": "80"
}
All records with a phone number containing the substring 80.

The following operators are available on string properties:

exists
exists with any value
{
  "propertyId": "lastName",
  "operation": {
    "op": "exists"
  }
}
All records with a last name listed.
notExists
does not exist
{
  "propertyId": "lastName",
  "operation": {
    "op": "notExists"
  }
}
All records without a last name listed.
eq
is equal to
{
  "propertyId": "lastName",
  "operation": {
    "op": "eq"
  },
  "match": "Ramirez"
}
All records with a last name of exactly Ramirez.
ne
is not equal to
{
  "propertyId": "lastName",
  "operation": {
    "op": "ne"
  },
  "match": "Ramirez"
}
All records without a last name of exactly Ramirez.
like
is like (case sensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "like"
  },
  "match": "__m%"
}
All records with a last name that has a third letter of m.
notLike
is not like (case sensitive)
{
  "propertyId": "lastName",
  "operation": {
    "op": "notLike"
  },
  "match": "__m%"
}
All records without a last name that has a third letter of m.
startsWith
starts with
{
  "propertyId": "lastName",
  "operation": {
    "op": "startsWith"
  },
  "match": "Mc"
}
All records with a last name starting with Mc (case sensitive)
endsWith
ends with
{
  "propertyId": "lastName",
  "operation": {
    "op": "endsWith"
  },
  "match": "son"
}
All records with a last name ending with son (case sensitive).
substring
includes the string
{
  "propertyId": "lastName",
  "operation": {
    "op": "substring"
  },
  "match": "al"
}
All records with a last name containing al (case sensitive).

The following operators are available on url properties:

exists
exists with any value
{
  "propertyId": "company_url",
  "operation": {
    "op": "exists"
  }
}
All records with a company URL listed.
notExists
does not exist
{
  "propertyId": "company_url",
  "operation": {
    "op": "notExists"
  }
}
All records without a company URL listed.
eq
is equal to
{
  "propertyId": "company_url",
  "operation": {
    "op": "eq"
  },
  "match": "https://www.grouparoo.com"
}
All records with a company URL exactly equal to https://www.grouparoo.com.
ne
is not equal to
{
  "propertyId": "company_url",
  "operation": {
    "op": "ne"
  },
  "match": "https://www.grouparoo.com"
}
All records without a company URL exactly equal to https://www.grouparoo.com.
like
is like (case sensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "like"
  },
  "match": "%grouparoo.com"
}
All records with a company URL containing anything and then grouparoo.com (case sensitive).
notLike
is not like (case sensitive)
{
  "propertyId": "company_url",
  "operation": {
    "op": "like"
  },
  "match": "%grouparoo.com"
}
All records without a company URL containing anything and then grouparoo.com (case sensitive).
startsWith
starts with
{
  "propertyId": "company_url",
  "operation": {
    "op": "startsWith"
  },
  "match": "https"
}
All records with a company URL starting with https (case sensitive).
endsWith
ends with
{
  "propertyId": "company_url",
  "operation": {
    "op": "startsWith"
  },
  "match": ".com"
}
All records with a company URL ending with .com (case sensitive)
substring
includes the string
{
  "propertyId": "company_url",
  "operation": {
    "op": "substring"
  },
  "match": "grouparoo"
}
All records with a company URL containing grouparoo (case sensitive)

Add your list of Rules to the rules array in the generated config file. You may also change any of the other default values, as necessary.

Adding Manual Groups

While a great deal of the value of Grouparoo comes from our Calculated Groups, Manual Groups are still valuable in certain circumstances. Manual Groups are Groups of Records where you manually add or remove Records from the Group.

To generate a new Manual Group for your Grouparoo application, run the generate command.

grouparoo generate group:manual my_custom_group

Note here that my_custom_group is the ID for the Group. An ID is always required when generating a config object.

This command will generate a file in your application directory at config/groups/my_custom_group.js. You can change the name and id properties in this file.

Validating & Applying Your Config

You can validate your config at any time using the validate command:

$ grouparoo validate

And you can apply that config (save it to your Grouparoo application's database) using the apply command:

$ grouparoo apply