google-apps-chat-v1 0.11.1 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/google/apps/chat/v1/chat_service/client.rb +461 -2
- data/lib/google/apps/chat/v1/chat_service/credentials.rb +2 -0
- data/lib/google/apps/chat/v1/chat_service/paths.rb +14 -0
- data/lib/google/apps/chat/v1/chat_service/rest/client.rb +449 -2
- data/lib/google/apps/chat/v1/chat_service/rest/service_stub.rb +241 -0
- data/lib/google/apps/chat/v1/version.rb +1 -1
- data/lib/google/chat/v1/chat_service_pb.rb +1 -1
- data/lib/google/chat/v1/chat_service_services_pb.rb +52 -0
- data/lib/google/chat/v1/reaction_pb.rb +7 -1
- data/proto_docs/google/chat/v1/reaction.rb +136 -3
- metadata +6 -12
@@ -193,6 +193,26 @@ module Google
|
|
193
193
|
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
194
194
|
}
|
195
195
|
|
196
|
+
default_config.rpcs.create_custom_emoji.timeout = 30.0
|
197
|
+
default_config.rpcs.create_custom_emoji.retry_policy = {
|
198
|
+
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
199
|
+
}
|
200
|
+
|
201
|
+
default_config.rpcs.get_custom_emoji.timeout = 30.0
|
202
|
+
default_config.rpcs.get_custom_emoji.retry_policy = {
|
203
|
+
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
204
|
+
}
|
205
|
+
|
206
|
+
default_config.rpcs.list_custom_emojis.timeout = 30.0
|
207
|
+
default_config.rpcs.list_custom_emojis.retry_policy = {
|
208
|
+
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
209
|
+
}
|
210
|
+
|
211
|
+
default_config.rpcs.delete_custom_emoji.timeout = 30.0
|
212
|
+
default_config.rpcs.delete_custom_emoji.retry_policy = {
|
213
|
+
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
214
|
+
}
|
215
|
+
|
196
216
|
default_config.rpcs.get_space_read_state.timeout = 30.0
|
197
217
|
default_config.rpcs.get_space_read_state.retry_policy = {
|
198
218
|
initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14]
|
@@ -3243,8 +3263,7 @@ module Google
|
|
3243
3263
|
# AND user.name = "users/\\{user}"
|
3244
3264
|
# ```
|
3245
3265
|
#
|
3246
|
-
# Invalid queries are rejected
|
3247
|
-
# error.
|
3266
|
+
# Invalid queries are rejected with an `INVALID_ARGUMENT` error.
|
3248
3267
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
3249
3268
|
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Apps::Chat::V1::Reaction>]
|
3250
3269
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -3394,6 +3413,406 @@ module Google
|
|
3394
3413
|
raise ::Google::Cloud::Error.from_error(e)
|
3395
3414
|
end
|
3396
3415
|
|
3416
|
+
##
|
3417
|
+
# Creates a custom emoji.
|
3418
|
+
#
|
3419
|
+
# Custom emojis are only available for Google Workspace accounts, and the
|
3420
|
+
# administrator must turn custom emojis on for the organization. For more
|
3421
|
+
# information, see [Learn about custom emojis in Google
|
3422
|
+
# Chat](https://support.google.com/chat/answer/12800149) and
|
3423
|
+
# [Manage custom emoji
|
3424
|
+
# permissions](https://support.google.com/a/answer/12850085).
|
3425
|
+
#
|
3426
|
+
# Requires [user
|
3427
|
+
# authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
|
3428
|
+
#
|
3429
|
+
# @overload create_custom_emoji(request, options = nil)
|
3430
|
+
# Pass arguments to `create_custom_emoji` via a request object, either of type
|
3431
|
+
# {::Google::Apps::Chat::V1::CreateCustomEmojiRequest} or an equivalent Hash.
|
3432
|
+
#
|
3433
|
+
# @param request [::Google::Apps::Chat::V1::CreateCustomEmojiRequest, ::Hash]
|
3434
|
+
# A request object representing the call parameters. Required. To specify no
|
3435
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3436
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3437
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3438
|
+
#
|
3439
|
+
# @overload create_custom_emoji(custom_emoji: nil)
|
3440
|
+
# Pass arguments to `create_custom_emoji` via keyword arguments. Note that at
|
3441
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3442
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3443
|
+
#
|
3444
|
+
# @param custom_emoji [::Google::Apps::Chat::V1::CustomEmoji, ::Hash]
|
3445
|
+
# Required. The custom emoji to create.
|
3446
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3447
|
+
# @yieldparam result [::Google::Apps::Chat::V1::CustomEmoji]
|
3448
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3449
|
+
#
|
3450
|
+
# @return [::Google::Apps::Chat::V1::CustomEmoji]
|
3451
|
+
#
|
3452
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3453
|
+
#
|
3454
|
+
# @example Basic example
|
3455
|
+
# require "google/apps/chat/v1"
|
3456
|
+
#
|
3457
|
+
# # Create a client object. The client can be reused for multiple calls.
|
3458
|
+
# client = Google::Apps::Chat::V1::ChatService::Rest::Client.new
|
3459
|
+
#
|
3460
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
3461
|
+
# request = Google::Apps::Chat::V1::CreateCustomEmojiRequest.new
|
3462
|
+
#
|
3463
|
+
# # Call the create_custom_emoji method.
|
3464
|
+
# result = client.create_custom_emoji request
|
3465
|
+
#
|
3466
|
+
# # The returned object is of type Google::Apps::Chat::V1::CustomEmoji.
|
3467
|
+
# p result
|
3468
|
+
#
|
3469
|
+
def create_custom_emoji request, options = nil
|
3470
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3471
|
+
|
3472
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Apps::Chat::V1::CreateCustomEmojiRequest
|
3473
|
+
|
3474
|
+
# Converts hash and nil to an options object
|
3475
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3476
|
+
|
3477
|
+
# Customize the options with defaults
|
3478
|
+
call_metadata = @config.rpcs.create_custom_emoji.metadata.to_h
|
3479
|
+
|
3480
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3481
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3482
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3483
|
+
gapic_version: ::Google::Apps::Chat::V1::VERSION,
|
3484
|
+
transports_version_send: [:rest]
|
3485
|
+
|
3486
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3487
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3488
|
+
|
3489
|
+
options.apply_defaults timeout: @config.rpcs.create_custom_emoji.timeout,
|
3490
|
+
metadata: call_metadata,
|
3491
|
+
retry_policy: @config.rpcs.create_custom_emoji.retry_policy
|
3492
|
+
|
3493
|
+
options.apply_defaults timeout: @config.timeout,
|
3494
|
+
metadata: @config.metadata,
|
3495
|
+
retry_policy: @config.retry_policy
|
3496
|
+
|
3497
|
+
@chat_service_stub.create_custom_emoji request, options do |result, operation|
|
3498
|
+
yield result, operation if block_given?
|
3499
|
+
end
|
3500
|
+
rescue ::Gapic::Rest::Error => e
|
3501
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3502
|
+
end
|
3503
|
+
|
3504
|
+
##
|
3505
|
+
# Returns details about a custom emoji.
|
3506
|
+
#
|
3507
|
+
# Custom emojis are only available for Google Workspace accounts, and the
|
3508
|
+
# administrator must turn custom emojis on for the organization. For more
|
3509
|
+
# information, see [Learn about custom emojis in Google
|
3510
|
+
# Chat](https://support.google.com/chat/answer/12800149) and
|
3511
|
+
# [Manage custom emoji
|
3512
|
+
# permissions](https://support.google.com/a/answer/12850085).
|
3513
|
+
#
|
3514
|
+
# Requires [user
|
3515
|
+
# authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
|
3516
|
+
#
|
3517
|
+
# @overload get_custom_emoji(request, options = nil)
|
3518
|
+
# Pass arguments to `get_custom_emoji` via a request object, either of type
|
3519
|
+
# {::Google::Apps::Chat::V1::GetCustomEmojiRequest} or an equivalent Hash.
|
3520
|
+
#
|
3521
|
+
# @param request [::Google::Apps::Chat::V1::GetCustomEmojiRequest, ::Hash]
|
3522
|
+
# A request object representing the call parameters. Required. To specify no
|
3523
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3524
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3525
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3526
|
+
#
|
3527
|
+
# @overload get_custom_emoji(name: nil)
|
3528
|
+
# Pass arguments to `get_custom_emoji` via keyword arguments. Note that at
|
3529
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3530
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3531
|
+
#
|
3532
|
+
# @param name [::String]
|
3533
|
+
# Required. Resource name of the custom emoji.
|
3534
|
+
#
|
3535
|
+
# Format: `customEmojis/{customEmoji}`
|
3536
|
+
#
|
3537
|
+
# You can use the emoji name as an alias for `{customEmoji}`. For example,
|
3538
|
+
# `customEmojis/:example-emoji:` where `:example-emoji:` is the emoji name
|
3539
|
+
# for a custom emoji.
|
3540
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3541
|
+
# @yieldparam result [::Google::Apps::Chat::V1::CustomEmoji]
|
3542
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3543
|
+
#
|
3544
|
+
# @return [::Google::Apps::Chat::V1::CustomEmoji]
|
3545
|
+
#
|
3546
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3547
|
+
#
|
3548
|
+
# @example Basic example
|
3549
|
+
# require "google/apps/chat/v1"
|
3550
|
+
#
|
3551
|
+
# # Create a client object. The client can be reused for multiple calls.
|
3552
|
+
# client = Google::Apps::Chat::V1::ChatService::Rest::Client.new
|
3553
|
+
#
|
3554
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
3555
|
+
# request = Google::Apps::Chat::V1::GetCustomEmojiRequest.new
|
3556
|
+
#
|
3557
|
+
# # Call the get_custom_emoji method.
|
3558
|
+
# result = client.get_custom_emoji request
|
3559
|
+
#
|
3560
|
+
# # The returned object is of type Google::Apps::Chat::V1::CustomEmoji.
|
3561
|
+
# p result
|
3562
|
+
#
|
3563
|
+
def get_custom_emoji request, options = nil
|
3564
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3565
|
+
|
3566
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Apps::Chat::V1::GetCustomEmojiRequest
|
3567
|
+
|
3568
|
+
# Converts hash and nil to an options object
|
3569
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3570
|
+
|
3571
|
+
# Customize the options with defaults
|
3572
|
+
call_metadata = @config.rpcs.get_custom_emoji.metadata.to_h
|
3573
|
+
|
3574
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3575
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3576
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3577
|
+
gapic_version: ::Google::Apps::Chat::V1::VERSION,
|
3578
|
+
transports_version_send: [:rest]
|
3579
|
+
|
3580
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3581
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3582
|
+
|
3583
|
+
options.apply_defaults timeout: @config.rpcs.get_custom_emoji.timeout,
|
3584
|
+
metadata: call_metadata,
|
3585
|
+
retry_policy: @config.rpcs.get_custom_emoji.retry_policy
|
3586
|
+
|
3587
|
+
options.apply_defaults timeout: @config.timeout,
|
3588
|
+
metadata: @config.metadata,
|
3589
|
+
retry_policy: @config.retry_policy
|
3590
|
+
|
3591
|
+
@chat_service_stub.get_custom_emoji request, options do |result, operation|
|
3592
|
+
yield result, operation if block_given?
|
3593
|
+
end
|
3594
|
+
rescue ::Gapic::Rest::Error => e
|
3595
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3596
|
+
end
|
3597
|
+
|
3598
|
+
##
|
3599
|
+
# Lists custom emojis visible to the authenticated user.
|
3600
|
+
#
|
3601
|
+
# Custom emojis are only available for Google Workspace accounts, and the
|
3602
|
+
# administrator must turn custom emojis on for the organization. For more
|
3603
|
+
# information, see [Learn about custom emojis in Google
|
3604
|
+
# Chat](https://support.google.com/chat/answer/12800149) and
|
3605
|
+
# [Manage custom emoji
|
3606
|
+
# permissions](https://support.google.com/a/answer/12850085).
|
3607
|
+
#
|
3608
|
+
# Requires [user
|
3609
|
+
# authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
|
3610
|
+
#
|
3611
|
+
# @overload list_custom_emojis(request, options = nil)
|
3612
|
+
# Pass arguments to `list_custom_emojis` via a request object, either of type
|
3613
|
+
# {::Google::Apps::Chat::V1::ListCustomEmojisRequest} or an equivalent Hash.
|
3614
|
+
#
|
3615
|
+
# @param request [::Google::Apps::Chat::V1::ListCustomEmojisRequest, ::Hash]
|
3616
|
+
# A request object representing the call parameters. Required. To specify no
|
3617
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3618
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3619
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3620
|
+
#
|
3621
|
+
# @overload list_custom_emojis(page_size: nil, page_token: nil, filter: nil)
|
3622
|
+
# Pass arguments to `list_custom_emojis` via keyword arguments. Note that at
|
3623
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3624
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3625
|
+
#
|
3626
|
+
# @param page_size [::Integer]
|
3627
|
+
# Optional. The maximum number of custom emojis returned. The service can
|
3628
|
+
# return fewer custom emojis than this value. If unspecified, the default
|
3629
|
+
# value is 25. The maximum value is 200; values above 200 are changed to 200.
|
3630
|
+
# @param page_token [::String]
|
3631
|
+
# Optional. (If resuming from a previous query.)
|
3632
|
+
#
|
3633
|
+
# A page token received from a previous list custom emoji call. Provide this
|
3634
|
+
# to retrieve the subsequent page.
|
3635
|
+
#
|
3636
|
+
# When paginating, the filter value should match the call that provided the
|
3637
|
+
# page token. Passing a different value might lead to unexpected results.
|
3638
|
+
# @param filter [::String]
|
3639
|
+
# Optional. A query filter.
|
3640
|
+
#
|
3641
|
+
# Supports filtering by creator.
|
3642
|
+
#
|
3643
|
+
# To filter by creator, you must specify a valid value. Currently only
|
3644
|
+
# `creator("users/me")` and `NOT creator("users/me")` are accepted to filter
|
3645
|
+
# custom emojis by whether they were created by the calling user or not.
|
3646
|
+
#
|
3647
|
+
# For example, the following query returns custom emojis created by the
|
3648
|
+
# caller:
|
3649
|
+
# ```
|
3650
|
+
# creator("users/me")
|
3651
|
+
# ```
|
3652
|
+
#
|
3653
|
+
# Invalid queries are rejected with an `INVALID_ARGUMENT` error.
|
3654
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3655
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Apps::Chat::V1::CustomEmoji>]
|
3656
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3657
|
+
#
|
3658
|
+
# @return [::Gapic::Rest::PagedEnumerable<::Google::Apps::Chat::V1::CustomEmoji>]
|
3659
|
+
#
|
3660
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3661
|
+
#
|
3662
|
+
# @example Basic example
|
3663
|
+
# require "google/apps/chat/v1"
|
3664
|
+
#
|
3665
|
+
# # Create a client object. The client can be reused for multiple calls.
|
3666
|
+
# client = Google::Apps::Chat::V1::ChatService::Rest::Client.new
|
3667
|
+
#
|
3668
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
3669
|
+
# request = Google::Apps::Chat::V1::ListCustomEmojisRequest.new
|
3670
|
+
#
|
3671
|
+
# # Call the list_custom_emojis method.
|
3672
|
+
# result = client.list_custom_emojis request
|
3673
|
+
#
|
3674
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
3675
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
3676
|
+
# result.each do |item|
|
3677
|
+
# # Each element is of type ::Google::Apps::Chat::V1::CustomEmoji.
|
3678
|
+
# p item
|
3679
|
+
# end
|
3680
|
+
#
|
3681
|
+
def list_custom_emojis request, options = nil
|
3682
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3683
|
+
|
3684
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Apps::Chat::V1::ListCustomEmojisRequest
|
3685
|
+
|
3686
|
+
# Converts hash and nil to an options object
|
3687
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3688
|
+
|
3689
|
+
# Customize the options with defaults
|
3690
|
+
call_metadata = @config.rpcs.list_custom_emojis.metadata.to_h
|
3691
|
+
|
3692
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3693
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3694
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3695
|
+
gapic_version: ::Google::Apps::Chat::V1::VERSION,
|
3696
|
+
transports_version_send: [:rest]
|
3697
|
+
|
3698
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3699
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3700
|
+
|
3701
|
+
options.apply_defaults timeout: @config.rpcs.list_custom_emojis.timeout,
|
3702
|
+
metadata: call_metadata,
|
3703
|
+
retry_policy: @config.rpcs.list_custom_emojis.retry_policy
|
3704
|
+
|
3705
|
+
options.apply_defaults timeout: @config.timeout,
|
3706
|
+
metadata: @config.metadata,
|
3707
|
+
retry_policy: @config.retry_policy
|
3708
|
+
|
3709
|
+
@chat_service_stub.list_custom_emojis request, options do |result, operation|
|
3710
|
+
result = ::Gapic::Rest::PagedEnumerable.new @chat_service_stub, :list_custom_emojis, "custom_emojis", request, result, options
|
3711
|
+
yield result, operation if block_given?
|
3712
|
+
throw :response, result
|
3713
|
+
end
|
3714
|
+
rescue ::Gapic::Rest::Error => e
|
3715
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3716
|
+
end
|
3717
|
+
|
3718
|
+
##
|
3719
|
+
# Deletes a custom emoji. By default, users can only delete custom emoji they
|
3720
|
+
# created. [Emoji managers](https://support.google.com/a/answer/12850085)
|
3721
|
+
# assigned by the administrator can delete any custom emoji in the
|
3722
|
+
# organization. See [Learn about custom emojis in Google
|
3723
|
+
# Chat](https://support.google.com/chat/answer/12800149).
|
3724
|
+
#
|
3725
|
+
# Custom emojis are only available for Google Workspace accounts, and the
|
3726
|
+
# administrator must turn custom emojis on for the organization. For more
|
3727
|
+
# information, see [Learn about custom emojis in Google
|
3728
|
+
# Chat](https://support.google.com/chat/answer/12800149) and
|
3729
|
+
# [Manage custom emoji
|
3730
|
+
# permissions](https://support.google.com/a/answer/12850085).
|
3731
|
+
#
|
3732
|
+
# Requires [user
|
3733
|
+
# authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
|
3734
|
+
#
|
3735
|
+
# @overload delete_custom_emoji(request, options = nil)
|
3736
|
+
# Pass arguments to `delete_custom_emoji` via a request object, either of type
|
3737
|
+
# {::Google::Apps::Chat::V1::DeleteCustomEmojiRequest} or an equivalent Hash.
|
3738
|
+
#
|
3739
|
+
# @param request [::Google::Apps::Chat::V1::DeleteCustomEmojiRequest, ::Hash]
|
3740
|
+
# A request object representing the call parameters. Required. To specify no
|
3741
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
3742
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
3743
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
3744
|
+
#
|
3745
|
+
# @overload delete_custom_emoji(name: nil)
|
3746
|
+
# Pass arguments to `delete_custom_emoji` via keyword arguments. Note that at
|
3747
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
3748
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
3749
|
+
#
|
3750
|
+
# @param name [::String]
|
3751
|
+
# Required. Resource name of the custom emoji to delete.
|
3752
|
+
#
|
3753
|
+
# Format: `customEmojis/{customEmoji}`
|
3754
|
+
#
|
3755
|
+
# You can use the emoji name as an alias for `{customEmoji}`. For example,
|
3756
|
+
# `customEmojis/:example-emoji:` where `:example-emoji:` is the emoji name
|
3757
|
+
# for a custom emoji.
|
3758
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
3759
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
3760
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
3761
|
+
#
|
3762
|
+
# @return [::Google::Protobuf::Empty]
|
3763
|
+
#
|
3764
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
3765
|
+
#
|
3766
|
+
# @example Basic example
|
3767
|
+
# require "google/apps/chat/v1"
|
3768
|
+
#
|
3769
|
+
# # Create a client object. The client can be reused for multiple calls.
|
3770
|
+
# client = Google::Apps::Chat::V1::ChatService::Rest::Client.new
|
3771
|
+
#
|
3772
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
3773
|
+
# request = Google::Apps::Chat::V1::DeleteCustomEmojiRequest.new
|
3774
|
+
#
|
3775
|
+
# # Call the delete_custom_emoji method.
|
3776
|
+
# result = client.delete_custom_emoji request
|
3777
|
+
#
|
3778
|
+
# # The returned object is of type Google::Protobuf::Empty.
|
3779
|
+
# p result
|
3780
|
+
#
|
3781
|
+
def delete_custom_emoji request, options = nil
|
3782
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
3783
|
+
|
3784
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Apps::Chat::V1::DeleteCustomEmojiRequest
|
3785
|
+
|
3786
|
+
# Converts hash and nil to an options object
|
3787
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
3788
|
+
|
3789
|
+
# Customize the options with defaults
|
3790
|
+
call_metadata = @config.rpcs.delete_custom_emoji.metadata.to_h
|
3791
|
+
|
3792
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
3793
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
3794
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
3795
|
+
gapic_version: ::Google::Apps::Chat::V1::VERSION,
|
3796
|
+
transports_version_send: [:rest]
|
3797
|
+
|
3798
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
3799
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
3800
|
+
|
3801
|
+
options.apply_defaults timeout: @config.rpcs.delete_custom_emoji.timeout,
|
3802
|
+
metadata: call_metadata,
|
3803
|
+
retry_policy: @config.rpcs.delete_custom_emoji.retry_policy
|
3804
|
+
|
3805
|
+
options.apply_defaults timeout: @config.timeout,
|
3806
|
+
metadata: @config.metadata,
|
3807
|
+
retry_policy: @config.retry_policy
|
3808
|
+
|
3809
|
+
@chat_service_stub.delete_custom_emoji request, options do |result, operation|
|
3810
|
+
yield result, operation if block_given?
|
3811
|
+
end
|
3812
|
+
rescue ::Gapic::Rest::Error => e
|
3813
|
+
raise ::Google::Cloud::Error.from_error(e)
|
3814
|
+
end
|
3815
|
+
|
3397
3816
|
##
|
3398
3817
|
# Returns details about a user's read state within a space, used to identify
|
3399
3818
|
# read and unread messages. For an example, see [Get details about a user's
|
@@ -4411,6 +4830,26 @@ module Google
|
|
4411
4830
|
#
|
4412
4831
|
attr_reader :delete_reaction
|
4413
4832
|
##
|
4833
|
+
# RPC-specific configuration for `create_custom_emoji`
|
4834
|
+
# @return [::Gapic::Config::Method]
|
4835
|
+
#
|
4836
|
+
attr_reader :create_custom_emoji
|
4837
|
+
##
|
4838
|
+
# RPC-specific configuration for `get_custom_emoji`
|
4839
|
+
# @return [::Gapic::Config::Method]
|
4840
|
+
#
|
4841
|
+
attr_reader :get_custom_emoji
|
4842
|
+
##
|
4843
|
+
# RPC-specific configuration for `list_custom_emojis`
|
4844
|
+
# @return [::Gapic::Config::Method]
|
4845
|
+
#
|
4846
|
+
attr_reader :list_custom_emojis
|
4847
|
+
##
|
4848
|
+
# RPC-specific configuration for `delete_custom_emoji`
|
4849
|
+
# @return [::Gapic::Config::Method]
|
4850
|
+
#
|
4851
|
+
attr_reader :delete_custom_emoji
|
4852
|
+
##
|
4414
4853
|
# RPC-specific configuration for `get_space_read_state`
|
4415
4854
|
# @return [::Gapic::Config::Method]
|
4416
4855
|
#
|
@@ -4496,6 +4935,14 @@ module Google
|
|
4496
4935
|
@list_reactions = ::Gapic::Config::Method.new list_reactions_config
|
4497
4936
|
delete_reaction_config = parent_rpcs.delete_reaction if parent_rpcs.respond_to? :delete_reaction
|
4498
4937
|
@delete_reaction = ::Gapic::Config::Method.new delete_reaction_config
|
4938
|
+
create_custom_emoji_config = parent_rpcs.create_custom_emoji if parent_rpcs.respond_to? :create_custom_emoji
|
4939
|
+
@create_custom_emoji = ::Gapic::Config::Method.new create_custom_emoji_config
|
4940
|
+
get_custom_emoji_config = parent_rpcs.get_custom_emoji if parent_rpcs.respond_to? :get_custom_emoji
|
4941
|
+
@get_custom_emoji = ::Gapic::Config::Method.new get_custom_emoji_config
|
4942
|
+
list_custom_emojis_config = parent_rpcs.list_custom_emojis if parent_rpcs.respond_to? :list_custom_emojis
|
4943
|
+
@list_custom_emojis = ::Gapic::Config::Method.new list_custom_emojis_config
|
4944
|
+
delete_custom_emoji_config = parent_rpcs.delete_custom_emoji if parent_rpcs.respond_to? :delete_custom_emoji
|
4945
|
+
@delete_custom_emoji = ::Gapic::Config::Method.new delete_custom_emoji_config
|
4499
4946
|
get_space_read_state_config = parent_rpcs.get_space_read_state if parent_rpcs.respond_to? :get_space_read_state
|
4500
4947
|
@get_space_read_state = ::Gapic::Config::Method.new get_space_read_state_config
|
4501
4948
|
update_space_read_state_config = parent_rpcs.update_space_read_state if parent_rpcs.respond_to? :update_space_read_state
|