Resource: Section
Represents a section in Google Chat. Sections help users organize their spaces. There are two types of sections:
System Sections: These are predefined sections managed by Google Chat. Their resource names are fixed, and they cannot be created, deleted, or have their
displayNamemodified. Examples include:users/{user}/sections/default-direct-messagesusers/{user}/sections/default-spacesusers/{user}/sections/default-apps
Custom Sections: These are sections created and managed by the user. Creating a custom section using
sections.createrequires adisplayName. Custom sections can be updated usingsections.patchand deleted usingsections.delete.
| JSON representation |
|---|
{
"name": string,
"displayName": string,
"sortOrder": integer,
"type": enum ( |
| Fields | |
|---|---|
name |
Identifier. Resource name of the section. For system sections, the section ID is a constant string:
Format: |
displayName |
Required. The section's display name. Only populated for sections of type |
sortOrder |
Output only. The order of the section in relation to other sections. Sections with a lower |
type |
Required. The type of the section. |
SectionType
Section types.
| Enums | |
|---|---|
SECTION_TYPE_UNSPECIFIED |
Unspecified section type. |
CUSTOM_SECTION |
Custom section. |
DEFAULT_DIRECT_MESSAGES |
Default section containing DIRECT_MESSAGE between two human users or GROUP_CHAT spaces that don't belong to any custom section. |
DEFAULT_SPACES |
Default spaces that don't belong to any custom section. |
DEFAULT_APPS |
Default section containing a user's installed apps. |
Methods |
|
|---|---|
|
Creates a section in Google Chat. |
|
Deletes a section of type CUSTOM_SECTION. |
|
Lists sections available to the Chat user. |
|
Updates a section. |
|
Changes the sort order of a section. |