.group call
The .group
call is designed to allow you to organize your users into groups - (ie - accounts) - and record custom traits to those accounts (ie - MRR
, Plan_type
, Industry
, etc).
This call is very important if you want to organize, score, and segment your SaaS accounts in Sherlock.
Users can be assigned to a group with:
sherlock.group('{GroupID}');
Group traits can be set using:
sherlock.group('12345', {
name: "Nike"
status: "active",
mrr: 1000
});
When to make .group
call
.group
callJust like with an .identify
call, you should make your .group
calls when a new account is created or whenever any significant change in account information or status, for example:
- Conversion from trial to paid
- Upgrade/Downgrade
- Cancellation
- Change of location
- Etc.
Recommended Group traits
Group (or Account) traits are descriptive pieces of information about an Account that can be sent with a .group
call. While the traits you send are up to you, there are some standard traits that we recommend using for each account.
TRAIT | RECOMMENDATION | SAMPLE VALUES | DESCRIPTION |
---|---|---|---|
GroupID | Required | .group calls require a GroupID as the first argument | |
name | Highly recommended | This is a trait you would use to name an account. Without providing a name of your accounts, Sherlock will display your account by numeric ID - rendering them relatively useless. | |
created_at | Highly recommended | Date (ISO8601 or unix timestamp) | This trait is necessary to calculate the tenure of your accounts. *If you don't provide a created_at trait for an account, we will use the earliest created_at date for the users on that account to calculate the account tenure. |
status | Highly recommended | { trial , trial-expired , paid , canceled } | This describes the paid status of an account. This may be unique for your business, the basics are trial, trial expired , paid , canceled. |
plan | Recommended | {starter , pro , enterprise , etc ) | Providing the plan type for your paid accounts will help you understand engagement of your different account types. |
MRR | Recommended | {numeric value} | Providing MRR values for your accounts will allow you to segment accounts by value, but also will allow Sherlock to show you the dollar value of your different segments. |
*Traits must be an object containing keys that are strings, and values that are either a number, string, boolean or nested traits object
Updated about 4 years ago