target.apidocs.com.google.api.services.chat.v1.HangoutsChat.Spaces.Patch.html Maven / Gradle / Ivy
HangoutsChat.Spaces.Patch (Google Chat API v1-rev20240829-2.0.0)
com.google.api.services.chat.v1
Class HangoutsChat.Spaces.Patch
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.googleapis.services.AbstractGoogleClientRequest<T>
-
- com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest<T>
-
- com.google.api.services.chat.v1.HangoutsChatRequest<Space>
-
- com.google.api.services.chat.v1.HangoutsChat.Spaces.Patch
-
- Enclosing class:
- HangoutsChat.Spaces
public class HangoutsChat.Spaces.Patch
extends HangoutsChatRequest<Space>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Modifier
Constructor and Description
protected
Patch(String name,
Space content)
Updates a space.
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
String
getName()
Resource name of the space.
String
getUpdateMask()
Required.
Boolean
getUseAdminAccess()
[ Developer Preview](https://developers.google.com/workspace/preview).
HangoutsChat.Spaces.Patch
set(String parameterName,
Object value)
HangoutsChat.Spaces.Patch
set$Xgafv(String $Xgafv)
V1 error format.
HangoutsChat.Spaces.Patch
setAccessToken(String accessToken)
OAuth access token.
HangoutsChat.Spaces.Patch
setAlt(String alt)
Data format for response.
HangoutsChat.Spaces.Patch
setCallback(String callback)
JSONP
HangoutsChat.Spaces.Patch
setFields(String fields)
Selector specifying which fields to include in a partial response.
HangoutsChat.Spaces.Patch
setKey(String key)
API key.
HangoutsChat.Spaces.Patch
setName(String name)
Resource name of the space.
HangoutsChat.Spaces.Patch
setOauthToken(String oauthToken)
OAuth 2.0 token for the current user.
HangoutsChat.Spaces.Patch
setPrettyPrint(Boolean prettyPrint)
Returns response with indentations and line breaks.
HangoutsChat.Spaces.Patch
setQuotaUser(String quotaUser)
Available to use for quota purposes for server-side applications.
HangoutsChat.Spaces.Patch
setUpdateMask(String updateMask)
Required.
HangoutsChat.Spaces.Patch
setUploadProtocol(String uploadProtocol)
Upload protocol for media (e.g.
HangoutsChat.Spaces.Patch
setUploadType(String uploadType)
Legacy upload protocol for media (e.g.
HangoutsChat.Spaces.Patch
setUseAdminAccess(Boolean useAdminAccess)
[Developer Preview](https://developers.google.com/workspace/preview).
-
Methods inherited from class com.google.api.services.chat.v1.HangoutsChatRequest
get$Xgafv, getAbstractGoogleClient, getAccessToken, getAlt, getCallback, getFields, getKey, getOauthToken, getPrettyPrint, getQuotaUser, getUploadProtocol, getUploadType, setDisableGZipContent, setRequestHeaders
-
Methods inherited from class com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest
getJsonContent, newExceptionOnError, queue
-
Methods inherited from class com.google.api.client.googleapis.services.AbstractGoogleClientRequest
buildHttpRequest, buildHttpRequestUrl, buildHttpRequestUsingHead, checkRequiredParameter, execute, executeAndDownloadTo, executeAsInputStream, executeMedia, executeMediaAndDownloadTo, executeMediaAsInputStream, executeUnparsed, executeUsingHead, getDisableGZipContent, getHttpContent, getLastResponseHeaders, getLastStatusCode, getLastStatusMessage, getMediaHttpDownloader, getMediaHttpUploader, getRequestHeaders, getRequestMethod, getResponseClass, getReturnRawInputSteam, getUriTemplate, initializeMediaDownload, initializeMediaUpload, queue, setReturnRawInputStream
-
Methods inherited from class com.google.api.client.util.GenericData
clone, entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys, toString
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Constructor Detail
-
Patch
protected Patch(String name,
Space content)
Updates a space. For an example, see [Update a
space](https://developers.google.com/workspace/chat/update-spaces). If you're updating the
`displayName` field and receive the error message `ALREADY_EXISTS`, try a different display
name.. An existing space within the Google Workspace organization might already use this
display name. Requires [user
authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
Create a request for the method "spaces.patch".
This request holds the parameters needed by the the chat server. After setting any optional
parameters, call the AbstractGoogleClientRequest.execute()
method to invoke the remote operation. HangoutsChat.initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)
must
be called to initialize this instance immediately after invoking the constructor.
- Parameters:
name
- Resource name of the space. Format: `spaces/{space}` Where `{space}` represents the system-assigned
ID for the space. You can obtain the space ID by calling the [`spaces.list()`](https://dev
elopers.google.com/workspace/chat/api/reference/rest/v1/spaces/list) method or from the
space URL. For example, if the space URL is
`https://mail.google.com/mail/u/0/#chat/space/AAAAAAAAA`, the space ID is `AAAAAAAAA`.
content
- the Space
- Since:
- 1.13
-
Method Detail
-
set$Xgafv
public HangoutsChat.Spaces.Patch set$Xgafv(String $Xgafv)
Description copied from class: HangoutsChatRequest
V1 error format.
- Overrides:
set$Xgafv
in class HangoutsChatRequest<Space>
-
setAccessToken
public HangoutsChat.Spaces.Patch setAccessToken(String accessToken)
Description copied from class: HangoutsChatRequest
OAuth access token.
- Overrides:
setAccessToken
in class HangoutsChatRequest<Space>
-
setAlt
public HangoutsChat.Spaces.Patch setAlt(String alt)
Description copied from class: HangoutsChatRequest
Data format for response.
- Overrides:
setAlt
in class HangoutsChatRequest<Space>
-
setCallback
public HangoutsChat.Spaces.Patch setCallback(String callback)
Description copied from class: HangoutsChatRequest
JSONP
- Overrides:
setCallback
in class HangoutsChatRequest<Space>
-
setFields
public HangoutsChat.Spaces.Patch setFields(String fields)
Description copied from class: HangoutsChatRequest
Selector specifying which fields to include in a partial response.
- Overrides:
setFields
in class HangoutsChatRequest<Space>
-
setKey
public HangoutsChat.Spaces.Patch setKey(String key)
Description copied from class: HangoutsChatRequest
API key. Your API key identifies your project and provides you with API access, quota, and
reports. Required unless you provide an OAuth 2.0 token.
- Overrides:
setKey
in class HangoutsChatRequest<Space>
-
setOauthToken
public HangoutsChat.Spaces.Patch setOauthToken(String oauthToken)
Description copied from class: HangoutsChatRequest
OAuth 2.0 token for the current user.
- Overrides:
setOauthToken
in class HangoutsChatRequest<Space>
-
setPrettyPrint
public HangoutsChat.Spaces.Patch setPrettyPrint(Boolean prettyPrint)
Description copied from class: HangoutsChatRequest
Returns response with indentations and line breaks.
- Overrides:
setPrettyPrint
in class HangoutsChatRequest<Space>
-
setQuotaUser
public HangoutsChat.Spaces.Patch setQuotaUser(String quotaUser)
Description copied from class: HangoutsChatRequest
Available to use for quota purposes for server-side applications. Can be any arbitrary string
assigned to a user, but should not exceed 40 characters.
- Overrides:
setQuotaUser
in class HangoutsChatRequest<Space>
-
setUploadType
public HangoutsChat.Spaces.Patch setUploadType(String uploadType)
Description copied from class: HangoutsChatRequest
Legacy upload protocol for media (e.g. "media", "multipart").
- Overrides:
setUploadType
in class HangoutsChatRequest<Space>
-
setUploadProtocol
public HangoutsChat.Spaces.Patch setUploadProtocol(String uploadProtocol)
Description copied from class: HangoutsChatRequest
Upload protocol for media (e.g. "raw", "multipart").
- Overrides:
setUploadProtocol
in class HangoutsChatRequest<Space>
-
getName
public String getName()
Resource name of the space. Format: `spaces/{space}` Where `{space}` represents the system-assigned
ID for the space. You can obtain the space ID by calling the
[`spaces.list()`](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces/list)
method or from the space URL. For example, if the space URL is
`https://mail.google.com/mail/u/0/#chat/space/AAAAAAAAA`, the space ID is `AAAAAAAAA`.
-
setName
public HangoutsChat.Spaces.Patch setName(String name)
Resource name of the space. Format: `spaces/{space}` Where `{space}` represents the system-
assigned ID for the space. You can obtain the space ID by calling the [`spaces.list()`](htt
ps://developers.google.com/workspace/chat/api/reference/rest/v1/spaces/list) method or from
the space URL. For example, if the space URL is
`https://mail.google.com/mail/u/0/#chat/space/AAAAAAAAA`, the space ID is `AAAAAAAAA`.
-
getUpdateMask
public String getUpdateMask()
Required. The updated field paths, comma separated if there are multiple. You can update the
following fields for a space: - `space_details` - `display_name`: Only supports updating the
display name for spaces where `spaceType` field is `SPACE`. If you receive the error message
`ALREADY_EXISTS`, try a different value. An existing space within the Google Workspace organization
might already use this display name. - `space_type`: Only supports changing a `GROUP_CHAT` space
type to `SPACE`. Include `display_name` together with `space_type` in the update mask and ensure
that the specified space has a non-empty display name and the `SPACE` space type. Including the
`space_type` mask and the `SPACE` type in the specified space when updating the display name is
optional if the existing space already has the `SPACE` type. Trying to update the space type in
other ways results in an invalid argument error. `space_type` is not supported with admin access. -
`space_history_state`: Updates [space history
settings](https://support.google.com/chat/answer/7664687) by turning history on or off for the
space. Only supported if history settings are enabled for the Google Workspace organization. To
update the space history state, you must omit all other field masks in your request.
`space_history_state` is not supported with admin access. - `access_settings.audience`: Updates the
[access setting](https://support.google.com/chat/answer/11971020) of who can discover the space,
join the space, and preview the messages in named space where `spaceType` field is `SPACE`. If the
existing space has a target audience, you can remove the audience and restrict space access by
omitting a value for this field mask. To update access settings for a space, the authenticating
user must be a space manager and omit all other field masks in your request. You can't update this
field if the space is in [import mode](https://developers.google.com/workspace/chat/import-data-
overview). To learn more, see [Make a space discoverable to specific
users](https://developers.google.com/workspace/chat/space-target-audience).
`access_settings.audience` is not supported with admin access. - Developer Preview: Supports
changing the [permission settings](https://support.google.com/chat/answer/13340792) of a space,
supported field paths include: `permission_settings.manage_members_and_groups`,
`permission_settings.modify_space_details`, `permission_settings.toggle_history`,
`permission_settings.use_at_mention_all`, `permission_settings.manage_apps`,
`permission_settings.manage_webhooks`, `permission_settings.reply_messages` (Warning: mutually
exclusive with all other non-permission settings field paths). `permission_settings` is not
supported with admin access.
-
setUpdateMask
public HangoutsChat.Spaces.Patch setUpdateMask(String updateMask)
Required. The updated field paths, comma separated if there are multiple. You can update
the following fields for a space: - `space_details` - `display_name`: Only supports
updating the display name for spaces where `spaceType` field is `SPACE`. If you receive the
error message `ALREADY_EXISTS`, try a different value. An existing space within the Google
Workspace organization might already use this display name. - `space_type`: Only supports
changing a `GROUP_CHAT` space type to `SPACE`. Include `display_name` together with
`space_type` in the update mask and ensure that the specified space has a non-empty display
name and the `SPACE` space type. Including the `space_type` mask and the `SPACE` type in
the specified space when updating the display name is optional if the existing space
already has the `SPACE` type. Trying to update the space type in other ways results in an
invalid argument error. `space_type` is not supported with admin access. -
`space_history_state`: Updates [space history
settings](https://support.google.com/chat/answer/7664687) by turning history on or off for
the space. Only supported if history settings are enabled for the Google Workspace
organization. To update the space history state, you must omit all other field masks in
your request. `space_history_state` is not supported with admin access. -
`access_settings.audience`: Updates the [access
setting](https://support.google.com/chat/answer/11971020) of who can discover the space,
join the space, and preview the messages in named space where `spaceType` field is `SPACE`.
If the existing space has a target audience, you can remove the audience and restrict space
access by omitting a value for this field mask. To update access settings for a space, the
authenticating user must be a space manager and omit all other field masks in your request.
You can't update this field if the space is in [import
mode](https://developers.google.com/workspace/chat/import-data-overview). To learn more,
see [Make a space discoverable to specific
users](https://developers.google.com/workspace/chat/space-target-audience).
`access_settings.audience` is not supported with admin access. - Developer Preview:
Supports changing the [permission
settings](https://support.google.com/chat/answer/13340792) of a space, supported field
paths include: `permission_settings.manage_members_and_groups`,
`permission_settings.modify_space_details`, `permission_settings.toggle_history`,
`permission_settings.use_at_mention_all`, `permission_settings.manage_apps`,
`permission_settings.manage_webhooks`, `permission_settings.reply_messages` (Warning:
mutually exclusive with all other non-permission settings field paths).
`permission_settings` is not supported with admin access.
-
getUseAdminAccess
public Boolean getUseAdminAccess()
[ Developer Preview](https://developers.google.com/workspace/preview). When `true`, the method runs
[ using the user's Google Workspace administrator privileges. The calling user must be a Google
[ Workspace administrator with the [manage chat and spaces conversations
[ privilege](https://support.google.com/a/answer/13369245). Requires the `chat.admin.spaces` [OAuth
[ 2.0 scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-api-scopes).
[ Some `FieldMask` values are not supported using admin access. For details, see the description of
[ `update_mask`.
[
-
setUseAdminAccess
public HangoutsChat.Spaces.Patch setUseAdminAccess(Boolean useAdminAccess)
[Developer Preview](https://developers.google.com/workspace/preview). When `true`, the
method runs using the user's Google Workspace administrator privileges. The calling user
must be a Google Workspace administrator with the [manage chat and spaces conversations
privilege](https://support.google.com/a/answer/13369245). Requires the `chat.admin.spaces`
[OAuth 2.0 scope](https://developers.google.com/workspace/chat/authenticate-authorize#chat-
api-scopes). Some `FieldMask` values are not supported using admin access. For details, see
the description of `update_mask`.
-
set
public HangoutsChat.Spaces.Patch set(String parameterName,
Object value)
- Overrides:
set
in class HangoutsChatRequest<Space>
Copyright © 2011–2024 Google. All rights reserved.
© 2015 - 2024 Weber Informatics LLC | Privacy Policy