users

PATCH /v1/users/{usersId}/sections/{sectionsId}

Updates a section. Only sections of type CUSTOM_SECTION can be updated. For details, see Create and organize sections in Google Chat. Requires user authentication with the authorization scope: - https://www.googleapis.com/auth/chat.users.sections

Request

  • Base URL
    https://chat.googleapis.com
  • URL
    https://chat.googleapis.com/v1/users/{usersId}/sections/{sectionsId}
  • Auth
    OAuth 2 and OAuth 2
    Implicit: https://accounts.google.com/o/oauth2/auth
    Scopes: https://www.googleapis.com/auth/chat.users.sections
    Authorization code: https://accounts.google.com/o/oauth2/auth
    Token URL: https://accounts.google.com/o/oauth2/token scopes: https://www.googleapis.com/auth/chat.users.sections

Path parameters

usersIdstring required
sectionsIdstring required

Query parameters

updateMaskstring google-fieldmask

Required. The mask to specify which fields to update. Currently supported field paths: - display_name

Request body

displayNamestring

Optional. The section's display name. Only populated for sections of type CUSTOM_SECTION. Supports up to 80 characters. Required when creating a CUSTOM_SECTION.

namestring

Identifier. Resource name of the section. For system sections, the section ID is a constant string: - DEFAULT_DIRECT_MESSAGES: users/{user}/sections/default-direct-messages - DEFAULT_SPACES: users/{user}/sections/default-spaces - DEFAULT_APPS: users/{user}/sections/default-apps Format: users/{user}/sections/{section}

sortOrderinteger

Output only. The order of the section in relation to other sections. Sections with a lower sort_order value appear before sections with a higher value.

type'SECTION_TYPE_UNSPECIFIED' | 'CUSTOM_SECTION' | 'DEFAULT_DIRECT_MESSAGES' | 'DEFAULT_SPACES' | 'DEFAULT_APPS'

Required. The type of the section.

Response

Successful response

displayNamestring

Optional. The section's display name. Only populated for sections of type CUSTOM_SECTION. Supports up to 80 characters. Required when creating a CUSTOM_SECTION.

namestring

Identifier. Resource name of the section. For system sections, the section ID is a constant string: - DEFAULT_DIRECT_MESSAGES: users/{user}/sections/default-direct-messages - DEFAULT_SPACES: users/{user}/sections/default-spaces - DEFAULT_APPS: users/{user}/sections/default-apps Format: users/{user}/sections/{section}

sortOrderinteger

Output only. The order of the section in relation to other sections. Sections with a lower sort_order value appear before sections with a higher value.

type'SECTION_TYPE_UNSPECIFIED' | 'CUSTOM_SECTION' | 'DEFAULT_DIRECT_MESSAGES' | 'DEFAULT_SPACES' | 'DEFAULT_APPS'

Required. The type of the section.

Changes

No recorded changes to this operation across all 9 revisions of this API.