UserSegments
Represents user segments that define who can view the content of a section or topic.
Table-Specific Information
Select
The following queries are processed server-side while other filters are processed client-side within the provider.SELECT * FROM UserSegments WHERE Id = '19236906991121'
SELECT * FROM UserSegments WHERE UserId = '19128124956177'
Insert
The Name and UserType columns are required to insert. All fields that are not readonly are optional for insert. This operation is allowed for logged-in users with the "Help Center manager" role.
INSERT INTO UserSegments (Name, OrTags, UserType, GroupIds, Tags) VALUES ('Test', 'abcd', 'staff', '19236839815825;19236761830161', 'vip;test')
Update
You must specify the Id of the user segment to update. All fields that are not readonly are optional for insert. This operation is allowed for logged-in users with the "Help Center manager" role.
UPDATE UserSegments SET Name = 'UpdatedName' WHERE Id = '19236906991121'
Delete
You must specify the Id of the user segment to delete it. This operation is allowed for logged-in users with the "Help Center manager" role.
DELETE FROM UserSegments WHERE Id = '19236906991121'
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | Long | True |
The Id of the user segment, automatically assigned when it is created. | |
| BuiltIn | Boolean | True |
Indicates whether the user segment is built-in. Built-in user segments cannot be modified. | |
| Name | String | False |
The name of the user segment (localized to the current user's locale for built-in user segments). | |
| OrTags | String | False |
A user must have at least one tag in the list to have access. For insertion and updating, provide these values separated by semicolons. | |
| GroupIds | String | False |
The Ids of the groups that have access. For insertion and updating, provide these values separated by semicolons. | |
| OrganizationIds | String | False |
The Ids of the organizations that have access. For insertion and updating, provide these values separated by semicolons. | |
| Tags | String | False |
All the tags a user must have to have access. For insertion and updating, provide these values separated by semicolons. | |
| UserType | String | False |
The set of users who can view content. The UserType can be 'signed_in_users' for only authenticated users and 'staff' for only agents and Help Center managers. | |
| CreatedAt | Datetime | True |
The date and time when the user segment was created. | |
| UpdatedAt | Datetime | True |
The date and time when the user segment was last updated. |
Pseudo-Columns
Pseudo column fields are used in the WHERE clause of SELECT statements and offer more granular control over the data returned from the data source.
| Name | Type | Description |
| UserId | Long |
The Id of the user. |