google-apps-chat-v1 0.a → 0.1.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/.yardopts +12 -0
- data/AUTHENTICATION.md +122 -0
- data/README.md +144 -8
- data/lib/google/apps/chat/v1/chat_service/client.rb +3663 -0
- data/lib/google/apps/chat/v1/chat_service/credentials.rb +63 -0
- data/lib/google/apps/chat/v1/chat_service/paths.rb +191 -0
- data/lib/google/apps/chat/v1/chat_service/rest/client.rb +3487 -0
- data/lib/google/apps/chat/v1/chat_service/rest/service_stub.rb +1614 -0
- data/lib/google/apps/chat/v1/chat_service/rest.rb +53 -0
- data/lib/google/apps/chat/v1/chat_service.rb +56 -0
- data/lib/google/apps/chat/v1/rest.rb +37 -0
- data/lib/google/apps/chat/v1/version.rb +7 -2
- data/lib/google/apps/chat/v1.rb +45 -0
- data/lib/google/chat/v1/action_status_pb.rb +44 -0
- data/lib/google/chat/v1/annotation_pb.rb +55 -0
- data/lib/google/chat/v1/attachment_pb.rb +51 -0
- data/lib/google/chat/v1/chat_service_pb.rb +53 -0
- data/lib/google/chat/v1/chat_service_services_pb.rb +359 -0
- data/lib/google/chat/v1/contextual_addon_pb.rb +50 -0
- data/lib/google/chat/v1/deletion_metadata_pb.rb +43 -0
- data/lib/google/chat/v1/group_pb.rb +42 -0
- data/lib/google/chat/v1/history_state_pb.rb +42 -0
- data/lib/google/chat/v1/matched_url_pb.rb +44 -0
- data/lib/google/chat/v1/membership_pb.rb +61 -0
- data/lib/google/chat/v1/message_pb.rb +89 -0
- data/lib/google/chat/v1/reaction_pb.rb +54 -0
- data/lib/google/chat/v1/slash_command_pb.rb +42 -0
- data/lib/google/chat/v1/space_pb.rb +63 -0
- data/lib/google/chat/v1/space_read_state_pb.rb +51 -0
- data/lib/google/chat/v1/space_setup_pb.rb +48 -0
- data/lib/google/chat/v1/thread_read_state_pb.rb +48 -0
- data/lib/google/chat/v1/user_pb.rb +46 -0
- data/lib/google/chat/v1/widgets_pb.rb +53 -0
- data/lib/google-apps-chat-v1.rb +21 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/client.rb +399 -0
- data/proto_docs/google/api/field_behavior.rb +85 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/api/resource.rb +222 -0
- data/proto_docs/google/apps/card/v1/card.rb +2076 -0
- data/proto_docs/google/chat/v1/action_status.rb +40 -0
- data/proto_docs/google/chat/v1/annotation.rb +186 -0
- data/proto_docs/google/chat/v1/attachment.rb +131 -0
- data/proto_docs/google/chat/v1/contextual_addon.rb +120 -0
- data/proto_docs/google/chat/v1/deletion_metadata.rb +60 -0
- data/proto_docs/google/chat/v1/group.rb +41 -0
- data/proto_docs/google/chat/v1/history_state.rb +42 -0
- data/proto_docs/google/chat/v1/matched_url.rb +37 -0
- data/proto_docs/google/chat/v1/membership.rb +294 -0
- data/proto_docs/google/chat/v1/message.rb +657 -0
- data/proto_docs/google/chat/v1/reaction.rb +185 -0
- data/proto_docs/google/chat/v1/slash_command.rb +37 -0
- data/proto_docs/google/chat/v1/space.rb +382 -0
- data/proto_docs/google/chat/v1/space_read_state.rb +104 -0
- data/proto_docs/google/chat/v1/space_setup.rb +92 -0
- data/proto_docs/google/chat/v1/thread_read_state.rb +66 -0
- data/proto_docs/google/chat/v1/user.rb +84 -0
- data/proto_docs/google/chat/v1/widgets.rb +293 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +34 -0
- data/proto_docs/google/protobuf/field_mask.rb +229 -0
- data/proto_docs/google/protobuf/timestamp.rb +127 -0
- data/proto_docs/google/protobuf/wrappers.rb +121 -0
- data/proto_docs/google/rpc/code.rb +185 -0
- data/proto_docs/google/type/color.rb +173 -0
- metadata +128 -10
@@ -0,0 +1,1614 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2024 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
require "google/chat/v1/chat_service_pb"
|
20
|
+
|
21
|
+
module Google
|
22
|
+
module Apps
|
23
|
+
module Chat
|
24
|
+
module V1
|
25
|
+
module ChatService
|
26
|
+
module Rest
|
27
|
+
##
|
28
|
+
# REST service stub for the ChatService service.
|
29
|
+
# Service stub contains baseline method implementations
|
30
|
+
# including transcoding, making the REST call, and deserialing the response.
|
31
|
+
#
|
32
|
+
class ServiceStub
|
33
|
+
def initialize endpoint:, endpoint_template:, universe_domain:, credentials:
|
34
|
+
# These require statements are intentionally placed here to initialize
|
35
|
+
# the REST modules only when it's required.
|
36
|
+
require "gapic/rest"
|
37
|
+
|
38
|
+
@client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint,
|
39
|
+
endpoint_template: endpoint_template,
|
40
|
+
universe_domain: universe_domain,
|
41
|
+
credentials: credentials,
|
42
|
+
numeric_enums: true,
|
43
|
+
raise_faraday_errors: false
|
44
|
+
end
|
45
|
+
|
46
|
+
##
|
47
|
+
# The effective universe domain
|
48
|
+
#
|
49
|
+
# @return [String]
|
50
|
+
#
|
51
|
+
def universe_domain
|
52
|
+
@client_stub.universe_domain
|
53
|
+
end
|
54
|
+
|
55
|
+
##
|
56
|
+
# The effective endpoint
|
57
|
+
#
|
58
|
+
# @return [String]
|
59
|
+
#
|
60
|
+
def endpoint
|
61
|
+
@client_stub.endpoint
|
62
|
+
end
|
63
|
+
|
64
|
+
##
|
65
|
+
# Baseline implementation for the create_message REST call
|
66
|
+
#
|
67
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateMessageRequest]
|
68
|
+
# A request object representing the call parameters. Required.
|
69
|
+
# @param options [::Gapic::CallOptions]
|
70
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
71
|
+
#
|
72
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
73
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Message]
|
74
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
75
|
+
#
|
76
|
+
# @return [::Google::Apps::Chat::V1::Message]
|
77
|
+
# A result object deserialized from the server's reply
|
78
|
+
def create_message request_pb, options = nil
|
79
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
80
|
+
|
81
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_message_request request_pb
|
82
|
+
query_string_params = if query_string_params.any?
|
83
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
84
|
+
else
|
85
|
+
{}
|
86
|
+
end
|
87
|
+
|
88
|
+
response = @client_stub.make_http_request(
|
89
|
+
verb,
|
90
|
+
uri: uri,
|
91
|
+
body: body || "",
|
92
|
+
params: query_string_params,
|
93
|
+
options: options
|
94
|
+
)
|
95
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
96
|
+
result = ::Google::Apps::Chat::V1::Message.decode_json response.body, ignore_unknown_fields: true
|
97
|
+
|
98
|
+
yield result, operation if block_given?
|
99
|
+
result
|
100
|
+
end
|
101
|
+
|
102
|
+
##
|
103
|
+
# Baseline implementation for the list_messages REST call
|
104
|
+
#
|
105
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListMessagesRequest]
|
106
|
+
# A request object representing the call parameters. Required.
|
107
|
+
# @param options [::Gapic::CallOptions]
|
108
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
109
|
+
#
|
110
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
111
|
+
# @yieldparam result [::Google::Apps::Chat::V1::ListMessagesResponse]
|
112
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
113
|
+
#
|
114
|
+
# @return [::Google::Apps::Chat::V1::ListMessagesResponse]
|
115
|
+
# A result object deserialized from the server's reply
|
116
|
+
def list_messages request_pb, options = nil
|
117
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
118
|
+
|
119
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_messages_request request_pb
|
120
|
+
query_string_params = if query_string_params.any?
|
121
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
122
|
+
else
|
123
|
+
{}
|
124
|
+
end
|
125
|
+
|
126
|
+
response = @client_stub.make_http_request(
|
127
|
+
verb,
|
128
|
+
uri: uri,
|
129
|
+
body: body || "",
|
130
|
+
params: query_string_params,
|
131
|
+
options: options
|
132
|
+
)
|
133
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
134
|
+
result = ::Google::Apps::Chat::V1::ListMessagesResponse.decode_json response.body, ignore_unknown_fields: true
|
135
|
+
|
136
|
+
yield result, operation if block_given?
|
137
|
+
result
|
138
|
+
end
|
139
|
+
|
140
|
+
##
|
141
|
+
# Baseline implementation for the list_memberships REST call
|
142
|
+
#
|
143
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListMembershipsRequest]
|
144
|
+
# A request object representing the call parameters. Required.
|
145
|
+
# @param options [::Gapic::CallOptions]
|
146
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
147
|
+
#
|
148
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
149
|
+
# @yieldparam result [::Google::Apps::Chat::V1::ListMembershipsResponse]
|
150
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
151
|
+
#
|
152
|
+
# @return [::Google::Apps::Chat::V1::ListMembershipsResponse]
|
153
|
+
# A result object deserialized from the server's reply
|
154
|
+
def list_memberships request_pb, options = nil
|
155
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
156
|
+
|
157
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_memberships_request request_pb
|
158
|
+
query_string_params = if query_string_params.any?
|
159
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
160
|
+
else
|
161
|
+
{}
|
162
|
+
end
|
163
|
+
|
164
|
+
response = @client_stub.make_http_request(
|
165
|
+
verb,
|
166
|
+
uri: uri,
|
167
|
+
body: body || "",
|
168
|
+
params: query_string_params,
|
169
|
+
options: options
|
170
|
+
)
|
171
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
172
|
+
result = ::Google::Apps::Chat::V1::ListMembershipsResponse.decode_json response.body, ignore_unknown_fields: true
|
173
|
+
|
174
|
+
yield result, operation if block_given?
|
175
|
+
result
|
176
|
+
end
|
177
|
+
|
178
|
+
##
|
179
|
+
# Baseline implementation for the get_membership REST call
|
180
|
+
#
|
181
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetMembershipRequest]
|
182
|
+
# A request object representing the call parameters. Required.
|
183
|
+
# @param options [::Gapic::CallOptions]
|
184
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
185
|
+
#
|
186
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
187
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Membership]
|
188
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
189
|
+
#
|
190
|
+
# @return [::Google::Apps::Chat::V1::Membership]
|
191
|
+
# A result object deserialized from the server's reply
|
192
|
+
def get_membership request_pb, options = nil
|
193
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
194
|
+
|
195
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_membership_request request_pb
|
196
|
+
query_string_params = if query_string_params.any?
|
197
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
198
|
+
else
|
199
|
+
{}
|
200
|
+
end
|
201
|
+
|
202
|
+
response = @client_stub.make_http_request(
|
203
|
+
verb,
|
204
|
+
uri: uri,
|
205
|
+
body: body || "",
|
206
|
+
params: query_string_params,
|
207
|
+
options: options
|
208
|
+
)
|
209
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
210
|
+
result = ::Google::Apps::Chat::V1::Membership.decode_json response.body, ignore_unknown_fields: true
|
211
|
+
|
212
|
+
yield result, operation if block_given?
|
213
|
+
result
|
214
|
+
end
|
215
|
+
|
216
|
+
##
|
217
|
+
# Baseline implementation for the get_message REST call
|
218
|
+
#
|
219
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetMessageRequest]
|
220
|
+
# A request object representing the call parameters. Required.
|
221
|
+
# @param options [::Gapic::CallOptions]
|
222
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
223
|
+
#
|
224
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
225
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Message]
|
226
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
227
|
+
#
|
228
|
+
# @return [::Google::Apps::Chat::V1::Message]
|
229
|
+
# A result object deserialized from the server's reply
|
230
|
+
def get_message request_pb, options = nil
|
231
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
232
|
+
|
233
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_message_request request_pb
|
234
|
+
query_string_params = if query_string_params.any?
|
235
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
236
|
+
else
|
237
|
+
{}
|
238
|
+
end
|
239
|
+
|
240
|
+
response = @client_stub.make_http_request(
|
241
|
+
verb,
|
242
|
+
uri: uri,
|
243
|
+
body: body || "",
|
244
|
+
params: query_string_params,
|
245
|
+
options: options
|
246
|
+
)
|
247
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
248
|
+
result = ::Google::Apps::Chat::V1::Message.decode_json response.body, ignore_unknown_fields: true
|
249
|
+
|
250
|
+
yield result, operation if block_given?
|
251
|
+
result
|
252
|
+
end
|
253
|
+
|
254
|
+
##
|
255
|
+
# Baseline implementation for the update_message REST call
|
256
|
+
#
|
257
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateMessageRequest]
|
258
|
+
# A request object representing the call parameters. Required.
|
259
|
+
# @param options [::Gapic::CallOptions]
|
260
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
261
|
+
#
|
262
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
263
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Message]
|
264
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
265
|
+
#
|
266
|
+
# @return [::Google::Apps::Chat::V1::Message]
|
267
|
+
# A result object deserialized from the server's reply
|
268
|
+
def update_message request_pb, options = nil
|
269
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
270
|
+
|
271
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_message_request request_pb
|
272
|
+
query_string_params = if query_string_params.any?
|
273
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
274
|
+
else
|
275
|
+
{}
|
276
|
+
end
|
277
|
+
|
278
|
+
response = @client_stub.make_http_request(
|
279
|
+
verb,
|
280
|
+
uri: uri,
|
281
|
+
body: body || "",
|
282
|
+
params: query_string_params,
|
283
|
+
options: options
|
284
|
+
)
|
285
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
286
|
+
result = ::Google::Apps::Chat::V1::Message.decode_json response.body, ignore_unknown_fields: true
|
287
|
+
|
288
|
+
yield result, operation if block_given?
|
289
|
+
result
|
290
|
+
end
|
291
|
+
|
292
|
+
##
|
293
|
+
# Baseline implementation for the delete_message REST call
|
294
|
+
#
|
295
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteMessageRequest]
|
296
|
+
# A request object representing the call parameters. Required.
|
297
|
+
# @param options [::Gapic::CallOptions]
|
298
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
299
|
+
#
|
300
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
301
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
302
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
303
|
+
#
|
304
|
+
# @return [::Google::Protobuf::Empty]
|
305
|
+
# A result object deserialized from the server's reply
|
306
|
+
def delete_message request_pb, options = nil
|
307
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
308
|
+
|
309
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_message_request request_pb
|
310
|
+
query_string_params = if query_string_params.any?
|
311
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
312
|
+
else
|
313
|
+
{}
|
314
|
+
end
|
315
|
+
|
316
|
+
response = @client_stub.make_http_request(
|
317
|
+
verb,
|
318
|
+
uri: uri,
|
319
|
+
body: body || "",
|
320
|
+
params: query_string_params,
|
321
|
+
options: options
|
322
|
+
)
|
323
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
324
|
+
result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
|
325
|
+
|
326
|
+
yield result, operation if block_given?
|
327
|
+
result
|
328
|
+
end
|
329
|
+
|
330
|
+
##
|
331
|
+
# Baseline implementation for the get_attachment REST call
|
332
|
+
#
|
333
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetAttachmentRequest]
|
334
|
+
# A request object representing the call parameters. Required.
|
335
|
+
# @param options [::Gapic::CallOptions]
|
336
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
337
|
+
#
|
338
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
339
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Attachment]
|
340
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
341
|
+
#
|
342
|
+
# @return [::Google::Apps::Chat::V1::Attachment]
|
343
|
+
# A result object deserialized from the server's reply
|
344
|
+
def get_attachment request_pb, options = nil
|
345
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
346
|
+
|
347
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_attachment_request request_pb
|
348
|
+
query_string_params = if query_string_params.any?
|
349
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
350
|
+
else
|
351
|
+
{}
|
352
|
+
end
|
353
|
+
|
354
|
+
response = @client_stub.make_http_request(
|
355
|
+
verb,
|
356
|
+
uri: uri,
|
357
|
+
body: body || "",
|
358
|
+
params: query_string_params,
|
359
|
+
options: options
|
360
|
+
)
|
361
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
362
|
+
result = ::Google::Apps::Chat::V1::Attachment.decode_json response.body, ignore_unknown_fields: true
|
363
|
+
|
364
|
+
yield result, operation if block_given?
|
365
|
+
result
|
366
|
+
end
|
367
|
+
|
368
|
+
##
|
369
|
+
# Baseline implementation for the upload_attachment REST call
|
370
|
+
#
|
371
|
+
# @param request_pb [::Google::Apps::Chat::V1::UploadAttachmentRequest]
|
372
|
+
# A request object representing the call parameters. Required.
|
373
|
+
# @param options [::Gapic::CallOptions]
|
374
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
375
|
+
#
|
376
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
377
|
+
# @yieldparam result [::Google::Apps::Chat::V1::UploadAttachmentResponse]
|
378
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
379
|
+
#
|
380
|
+
# @return [::Google::Apps::Chat::V1::UploadAttachmentResponse]
|
381
|
+
# A result object deserialized from the server's reply
|
382
|
+
def upload_attachment request_pb, options = nil
|
383
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
384
|
+
|
385
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_upload_attachment_request request_pb
|
386
|
+
query_string_params = if query_string_params.any?
|
387
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
388
|
+
else
|
389
|
+
{}
|
390
|
+
end
|
391
|
+
|
392
|
+
response = @client_stub.make_http_request(
|
393
|
+
verb,
|
394
|
+
uri: uri,
|
395
|
+
body: body || "",
|
396
|
+
params: query_string_params,
|
397
|
+
options: options
|
398
|
+
)
|
399
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
400
|
+
result = ::Google::Apps::Chat::V1::UploadAttachmentResponse.decode_json response.body, ignore_unknown_fields: true
|
401
|
+
|
402
|
+
yield result, operation if block_given?
|
403
|
+
result
|
404
|
+
end
|
405
|
+
|
406
|
+
##
|
407
|
+
# Baseline implementation for the list_spaces REST call
|
408
|
+
#
|
409
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListSpacesRequest]
|
410
|
+
# A request object representing the call parameters. Required.
|
411
|
+
# @param options [::Gapic::CallOptions]
|
412
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
413
|
+
#
|
414
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
415
|
+
# @yieldparam result [::Google::Apps::Chat::V1::ListSpacesResponse]
|
416
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
417
|
+
#
|
418
|
+
# @return [::Google::Apps::Chat::V1::ListSpacesResponse]
|
419
|
+
# A result object deserialized from the server's reply
|
420
|
+
def list_spaces request_pb, options = nil
|
421
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
422
|
+
|
423
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_spaces_request request_pb
|
424
|
+
query_string_params = if query_string_params.any?
|
425
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
426
|
+
else
|
427
|
+
{}
|
428
|
+
end
|
429
|
+
|
430
|
+
response = @client_stub.make_http_request(
|
431
|
+
verb,
|
432
|
+
uri: uri,
|
433
|
+
body: body || "",
|
434
|
+
params: query_string_params,
|
435
|
+
options: options
|
436
|
+
)
|
437
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
438
|
+
result = ::Google::Apps::Chat::V1::ListSpacesResponse.decode_json response.body, ignore_unknown_fields: true
|
439
|
+
|
440
|
+
yield result, operation if block_given?
|
441
|
+
result
|
442
|
+
end
|
443
|
+
|
444
|
+
##
|
445
|
+
# Baseline implementation for the get_space REST call
|
446
|
+
#
|
447
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetSpaceRequest]
|
448
|
+
# A request object representing the call parameters. Required.
|
449
|
+
# @param options [::Gapic::CallOptions]
|
450
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
451
|
+
#
|
452
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
453
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Space]
|
454
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
455
|
+
#
|
456
|
+
# @return [::Google::Apps::Chat::V1::Space]
|
457
|
+
# A result object deserialized from the server's reply
|
458
|
+
def get_space request_pb, options = nil
|
459
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
460
|
+
|
461
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_space_request request_pb
|
462
|
+
query_string_params = if query_string_params.any?
|
463
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
464
|
+
else
|
465
|
+
{}
|
466
|
+
end
|
467
|
+
|
468
|
+
response = @client_stub.make_http_request(
|
469
|
+
verb,
|
470
|
+
uri: uri,
|
471
|
+
body: body || "",
|
472
|
+
params: query_string_params,
|
473
|
+
options: options
|
474
|
+
)
|
475
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
476
|
+
result = ::Google::Apps::Chat::V1::Space.decode_json response.body, ignore_unknown_fields: true
|
477
|
+
|
478
|
+
yield result, operation if block_given?
|
479
|
+
result
|
480
|
+
end
|
481
|
+
|
482
|
+
##
|
483
|
+
# Baseline implementation for the create_space REST call
|
484
|
+
#
|
485
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateSpaceRequest]
|
486
|
+
# A request object representing the call parameters. Required.
|
487
|
+
# @param options [::Gapic::CallOptions]
|
488
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
489
|
+
#
|
490
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
491
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Space]
|
492
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
493
|
+
#
|
494
|
+
# @return [::Google::Apps::Chat::V1::Space]
|
495
|
+
# A result object deserialized from the server's reply
|
496
|
+
def create_space request_pb, options = nil
|
497
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
498
|
+
|
499
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_space_request request_pb
|
500
|
+
query_string_params = if query_string_params.any?
|
501
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
502
|
+
else
|
503
|
+
{}
|
504
|
+
end
|
505
|
+
|
506
|
+
response = @client_stub.make_http_request(
|
507
|
+
verb,
|
508
|
+
uri: uri,
|
509
|
+
body: body || "",
|
510
|
+
params: query_string_params,
|
511
|
+
options: options
|
512
|
+
)
|
513
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
514
|
+
result = ::Google::Apps::Chat::V1::Space.decode_json response.body, ignore_unknown_fields: true
|
515
|
+
|
516
|
+
yield result, operation if block_given?
|
517
|
+
result
|
518
|
+
end
|
519
|
+
|
520
|
+
##
|
521
|
+
# Baseline implementation for the set_up_space REST call
|
522
|
+
#
|
523
|
+
# @param request_pb [::Google::Apps::Chat::V1::SetUpSpaceRequest]
|
524
|
+
# A request object representing the call parameters. Required.
|
525
|
+
# @param options [::Gapic::CallOptions]
|
526
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
527
|
+
#
|
528
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
529
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Space]
|
530
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
531
|
+
#
|
532
|
+
# @return [::Google::Apps::Chat::V1::Space]
|
533
|
+
# A result object deserialized from the server's reply
|
534
|
+
def set_up_space request_pb, options = nil
|
535
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
536
|
+
|
537
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_set_up_space_request request_pb
|
538
|
+
query_string_params = if query_string_params.any?
|
539
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
540
|
+
else
|
541
|
+
{}
|
542
|
+
end
|
543
|
+
|
544
|
+
response = @client_stub.make_http_request(
|
545
|
+
verb,
|
546
|
+
uri: uri,
|
547
|
+
body: body || "",
|
548
|
+
params: query_string_params,
|
549
|
+
options: options
|
550
|
+
)
|
551
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
552
|
+
result = ::Google::Apps::Chat::V1::Space.decode_json response.body, ignore_unknown_fields: true
|
553
|
+
|
554
|
+
yield result, operation if block_given?
|
555
|
+
result
|
556
|
+
end
|
557
|
+
|
558
|
+
##
|
559
|
+
# Baseline implementation for the update_space REST call
|
560
|
+
#
|
561
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateSpaceRequest]
|
562
|
+
# A request object representing the call parameters. Required.
|
563
|
+
# @param options [::Gapic::CallOptions]
|
564
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
565
|
+
#
|
566
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
567
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Space]
|
568
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
569
|
+
#
|
570
|
+
# @return [::Google::Apps::Chat::V1::Space]
|
571
|
+
# A result object deserialized from the server's reply
|
572
|
+
def update_space request_pb, options = nil
|
573
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
574
|
+
|
575
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_space_request request_pb
|
576
|
+
query_string_params = if query_string_params.any?
|
577
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
578
|
+
else
|
579
|
+
{}
|
580
|
+
end
|
581
|
+
|
582
|
+
response = @client_stub.make_http_request(
|
583
|
+
verb,
|
584
|
+
uri: uri,
|
585
|
+
body: body || "",
|
586
|
+
params: query_string_params,
|
587
|
+
options: options
|
588
|
+
)
|
589
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
590
|
+
result = ::Google::Apps::Chat::V1::Space.decode_json response.body, ignore_unknown_fields: true
|
591
|
+
|
592
|
+
yield result, operation if block_given?
|
593
|
+
result
|
594
|
+
end
|
595
|
+
|
596
|
+
##
|
597
|
+
# Baseline implementation for the delete_space REST call
|
598
|
+
#
|
599
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteSpaceRequest]
|
600
|
+
# A request object representing the call parameters. Required.
|
601
|
+
# @param options [::Gapic::CallOptions]
|
602
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
603
|
+
#
|
604
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
605
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
606
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
607
|
+
#
|
608
|
+
# @return [::Google::Protobuf::Empty]
|
609
|
+
# A result object deserialized from the server's reply
|
610
|
+
def delete_space request_pb, options = nil
|
611
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
612
|
+
|
613
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_space_request request_pb
|
614
|
+
query_string_params = if query_string_params.any?
|
615
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
616
|
+
else
|
617
|
+
{}
|
618
|
+
end
|
619
|
+
|
620
|
+
response = @client_stub.make_http_request(
|
621
|
+
verb,
|
622
|
+
uri: uri,
|
623
|
+
body: body || "",
|
624
|
+
params: query_string_params,
|
625
|
+
options: options
|
626
|
+
)
|
627
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
628
|
+
result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
|
629
|
+
|
630
|
+
yield result, operation if block_given?
|
631
|
+
result
|
632
|
+
end
|
633
|
+
|
634
|
+
##
|
635
|
+
# Baseline implementation for the complete_import_space REST call
|
636
|
+
#
|
637
|
+
# @param request_pb [::Google::Apps::Chat::V1::CompleteImportSpaceRequest]
|
638
|
+
# A request object representing the call parameters. Required.
|
639
|
+
# @param options [::Gapic::CallOptions]
|
640
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
641
|
+
#
|
642
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
643
|
+
# @yieldparam result [::Google::Apps::Chat::V1::CompleteImportSpaceResponse]
|
644
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
645
|
+
#
|
646
|
+
# @return [::Google::Apps::Chat::V1::CompleteImportSpaceResponse]
|
647
|
+
# A result object deserialized from the server's reply
|
648
|
+
def complete_import_space request_pb, options = nil
|
649
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
650
|
+
|
651
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_complete_import_space_request request_pb
|
652
|
+
query_string_params = if query_string_params.any?
|
653
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
654
|
+
else
|
655
|
+
{}
|
656
|
+
end
|
657
|
+
|
658
|
+
response = @client_stub.make_http_request(
|
659
|
+
verb,
|
660
|
+
uri: uri,
|
661
|
+
body: body || "",
|
662
|
+
params: query_string_params,
|
663
|
+
options: options
|
664
|
+
)
|
665
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
666
|
+
result = ::Google::Apps::Chat::V1::CompleteImportSpaceResponse.decode_json response.body, ignore_unknown_fields: true
|
667
|
+
|
668
|
+
yield result, operation if block_given?
|
669
|
+
result
|
670
|
+
end
|
671
|
+
|
672
|
+
##
|
673
|
+
# Baseline implementation for the find_direct_message REST call
|
674
|
+
#
|
675
|
+
# @param request_pb [::Google::Apps::Chat::V1::FindDirectMessageRequest]
|
676
|
+
# A request object representing the call parameters. Required.
|
677
|
+
# @param options [::Gapic::CallOptions]
|
678
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
679
|
+
#
|
680
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
681
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Space]
|
682
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
683
|
+
#
|
684
|
+
# @return [::Google::Apps::Chat::V1::Space]
|
685
|
+
# A result object deserialized from the server's reply
|
686
|
+
def find_direct_message request_pb, options = nil
|
687
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
688
|
+
|
689
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_find_direct_message_request request_pb
|
690
|
+
query_string_params = if query_string_params.any?
|
691
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
692
|
+
else
|
693
|
+
{}
|
694
|
+
end
|
695
|
+
|
696
|
+
response = @client_stub.make_http_request(
|
697
|
+
verb,
|
698
|
+
uri: uri,
|
699
|
+
body: body || "",
|
700
|
+
params: query_string_params,
|
701
|
+
options: options
|
702
|
+
)
|
703
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
704
|
+
result = ::Google::Apps::Chat::V1::Space.decode_json response.body, ignore_unknown_fields: true
|
705
|
+
|
706
|
+
yield result, operation if block_given?
|
707
|
+
result
|
708
|
+
end
|
709
|
+
|
710
|
+
##
|
711
|
+
# Baseline implementation for the create_membership REST call
|
712
|
+
#
|
713
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateMembershipRequest]
|
714
|
+
# A request object representing the call parameters. Required.
|
715
|
+
# @param options [::Gapic::CallOptions]
|
716
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
717
|
+
#
|
718
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
719
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Membership]
|
720
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
721
|
+
#
|
722
|
+
# @return [::Google::Apps::Chat::V1::Membership]
|
723
|
+
# A result object deserialized from the server's reply
|
724
|
+
def create_membership request_pb, options = nil
|
725
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
726
|
+
|
727
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_membership_request request_pb
|
728
|
+
query_string_params = if query_string_params.any?
|
729
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
730
|
+
else
|
731
|
+
{}
|
732
|
+
end
|
733
|
+
|
734
|
+
response = @client_stub.make_http_request(
|
735
|
+
verb,
|
736
|
+
uri: uri,
|
737
|
+
body: body || "",
|
738
|
+
params: query_string_params,
|
739
|
+
options: options
|
740
|
+
)
|
741
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
742
|
+
result = ::Google::Apps::Chat::V1::Membership.decode_json response.body, ignore_unknown_fields: true
|
743
|
+
|
744
|
+
yield result, operation if block_given?
|
745
|
+
result
|
746
|
+
end
|
747
|
+
|
748
|
+
##
|
749
|
+
# Baseline implementation for the update_membership REST call
|
750
|
+
#
|
751
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateMembershipRequest]
|
752
|
+
# A request object representing the call parameters. Required.
|
753
|
+
# @param options [::Gapic::CallOptions]
|
754
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
755
|
+
#
|
756
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
757
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Membership]
|
758
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
759
|
+
#
|
760
|
+
# @return [::Google::Apps::Chat::V1::Membership]
|
761
|
+
# A result object deserialized from the server's reply
|
762
|
+
def update_membership request_pb, options = nil
|
763
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
764
|
+
|
765
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_membership_request request_pb
|
766
|
+
query_string_params = if query_string_params.any?
|
767
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
768
|
+
else
|
769
|
+
{}
|
770
|
+
end
|
771
|
+
|
772
|
+
response = @client_stub.make_http_request(
|
773
|
+
verb,
|
774
|
+
uri: uri,
|
775
|
+
body: body || "",
|
776
|
+
params: query_string_params,
|
777
|
+
options: options
|
778
|
+
)
|
779
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
780
|
+
result = ::Google::Apps::Chat::V1::Membership.decode_json response.body, ignore_unknown_fields: true
|
781
|
+
|
782
|
+
yield result, operation if block_given?
|
783
|
+
result
|
784
|
+
end
|
785
|
+
|
786
|
+
##
|
787
|
+
# Baseline implementation for the delete_membership REST call
|
788
|
+
#
|
789
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteMembershipRequest]
|
790
|
+
# A request object representing the call parameters. Required.
|
791
|
+
# @param options [::Gapic::CallOptions]
|
792
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
793
|
+
#
|
794
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
795
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Membership]
|
796
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
797
|
+
#
|
798
|
+
# @return [::Google::Apps::Chat::V1::Membership]
|
799
|
+
# A result object deserialized from the server's reply
|
800
|
+
def delete_membership request_pb, options = nil
|
801
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
802
|
+
|
803
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_membership_request request_pb
|
804
|
+
query_string_params = if query_string_params.any?
|
805
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
806
|
+
else
|
807
|
+
{}
|
808
|
+
end
|
809
|
+
|
810
|
+
response = @client_stub.make_http_request(
|
811
|
+
verb,
|
812
|
+
uri: uri,
|
813
|
+
body: body || "",
|
814
|
+
params: query_string_params,
|
815
|
+
options: options
|
816
|
+
)
|
817
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
818
|
+
result = ::Google::Apps::Chat::V1::Membership.decode_json response.body, ignore_unknown_fields: true
|
819
|
+
|
820
|
+
yield result, operation if block_given?
|
821
|
+
result
|
822
|
+
end
|
823
|
+
|
824
|
+
##
|
825
|
+
# Baseline implementation for the create_reaction REST call
|
826
|
+
#
|
827
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateReactionRequest]
|
828
|
+
# A request object representing the call parameters. Required.
|
829
|
+
# @param options [::Gapic::CallOptions]
|
830
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
831
|
+
#
|
832
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
833
|
+
# @yieldparam result [::Google::Apps::Chat::V1::Reaction]
|
834
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
835
|
+
#
|
836
|
+
# @return [::Google::Apps::Chat::V1::Reaction]
|
837
|
+
# A result object deserialized from the server's reply
|
838
|
+
def create_reaction request_pb, options = nil
|
839
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
840
|
+
|
841
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_create_reaction_request request_pb
|
842
|
+
query_string_params = if query_string_params.any?
|
843
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
844
|
+
else
|
845
|
+
{}
|
846
|
+
end
|
847
|
+
|
848
|
+
response = @client_stub.make_http_request(
|
849
|
+
verb,
|
850
|
+
uri: uri,
|
851
|
+
body: body || "",
|
852
|
+
params: query_string_params,
|
853
|
+
options: options
|
854
|
+
)
|
855
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
856
|
+
result = ::Google::Apps::Chat::V1::Reaction.decode_json response.body, ignore_unknown_fields: true
|
857
|
+
|
858
|
+
yield result, operation if block_given?
|
859
|
+
result
|
860
|
+
end
|
861
|
+
|
862
|
+
##
|
863
|
+
# Baseline implementation for the list_reactions REST call
|
864
|
+
#
|
865
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListReactionsRequest]
|
866
|
+
# A request object representing the call parameters. Required.
|
867
|
+
# @param options [::Gapic::CallOptions]
|
868
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
869
|
+
#
|
870
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
871
|
+
# @yieldparam result [::Google::Apps::Chat::V1::ListReactionsResponse]
|
872
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
873
|
+
#
|
874
|
+
# @return [::Google::Apps::Chat::V1::ListReactionsResponse]
|
875
|
+
# A result object deserialized from the server's reply
|
876
|
+
def list_reactions request_pb, options = nil
|
877
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
878
|
+
|
879
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_list_reactions_request request_pb
|
880
|
+
query_string_params = if query_string_params.any?
|
881
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
882
|
+
else
|
883
|
+
{}
|
884
|
+
end
|
885
|
+
|
886
|
+
response = @client_stub.make_http_request(
|
887
|
+
verb,
|
888
|
+
uri: uri,
|
889
|
+
body: body || "",
|
890
|
+
params: query_string_params,
|
891
|
+
options: options
|
892
|
+
)
|
893
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
894
|
+
result = ::Google::Apps::Chat::V1::ListReactionsResponse.decode_json response.body, ignore_unknown_fields: true
|
895
|
+
|
896
|
+
yield result, operation if block_given?
|
897
|
+
result
|
898
|
+
end
|
899
|
+
|
900
|
+
##
|
901
|
+
# Baseline implementation for the delete_reaction REST call
|
902
|
+
#
|
903
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteReactionRequest]
|
904
|
+
# A request object representing the call parameters. Required.
|
905
|
+
# @param options [::Gapic::CallOptions]
|
906
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
907
|
+
#
|
908
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
909
|
+
# @yieldparam result [::Google::Protobuf::Empty]
|
910
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
911
|
+
#
|
912
|
+
# @return [::Google::Protobuf::Empty]
|
913
|
+
# A result object deserialized from the server's reply
|
914
|
+
def delete_reaction request_pb, options = nil
|
915
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
916
|
+
|
917
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_delete_reaction_request request_pb
|
918
|
+
query_string_params = if query_string_params.any?
|
919
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
920
|
+
else
|
921
|
+
{}
|
922
|
+
end
|
923
|
+
|
924
|
+
response = @client_stub.make_http_request(
|
925
|
+
verb,
|
926
|
+
uri: uri,
|
927
|
+
body: body || "",
|
928
|
+
params: query_string_params,
|
929
|
+
options: options
|
930
|
+
)
|
931
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
932
|
+
result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true
|
933
|
+
|
934
|
+
yield result, operation if block_given?
|
935
|
+
result
|
936
|
+
end
|
937
|
+
|
938
|
+
##
|
939
|
+
# Baseline implementation for the get_space_read_state REST call
|
940
|
+
#
|
941
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetSpaceReadStateRequest]
|
942
|
+
# A request object representing the call parameters. Required.
|
943
|
+
# @param options [::Gapic::CallOptions]
|
944
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
945
|
+
#
|
946
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
947
|
+
# @yieldparam result [::Google::Apps::Chat::V1::SpaceReadState]
|
948
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
949
|
+
#
|
950
|
+
# @return [::Google::Apps::Chat::V1::SpaceReadState]
|
951
|
+
# A result object deserialized from the server's reply
|
952
|
+
def get_space_read_state request_pb, options = nil
|
953
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
954
|
+
|
955
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_space_read_state_request request_pb
|
956
|
+
query_string_params = if query_string_params.any?
|
957
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
958
|
+
else
|
959
|
+
{}
|
960
|
+
end
|
961
|
+
|
962
|
+
response = @client_stub.make_http_request(
|
963
|
+
verb,
|
964
|
+
uri: uri,
|
965
|
+
body: body || "",
|
966
|
+
params: query_string_params,
|
967
|
+
options: options
|
968
|
+
)
|
969
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
970
|
+
result = ::Google::Apps::Chat::V1::SpaceReadState.decode_json response.body, ignore_unknown_fields: true
|
971
|
+
|
972
|
+
yield result, operation if block_given?
|
973
|
+
result
|
974
|
+
end
|
975
|
+
|
976
|
+
##
|
977
|
+
# Baseline implementation for the update_space_read_state REST call
|
978
|
+
#
|
979
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateSpaceReadStateRequest]
|
980
|
+
# A request object representing the call parameters. Required.
|
981
|
+
# @param options [::Gapic::CallOptions]
|
982
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
983
|
+
#
|
984
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
985
|
+
# @yieldparam result [::Google::Apps::Chat::V1::SpaceReadState]
|
986
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
987
|
+
#
|
988
|
+
# @return [::Google::Apps::Chat::V1::SpaceReadState]
|
989
|
+
# A result object deserialized from the server's reply
|
990
|
+
def update_space_read_state request_pb, options = nil
|
991
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
992
|
+
|
993
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_update_space_read_state_request request_pb
|
994
|
+
query_string_params = if query_string_params.any?
|
995
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
996
|
+
else
|
997
|
+
{}
|
998
|
+
end
|
999
|
+
|
1000
|
+
response = @client_stub.make_http_request(
|
1001
|
+
verb,
|
1002
|
+
uri: uri,
|
1003
|
+
body: body || "",
|
1004
|
+
params: query_string_params,
|
1005
|
+
options: options
|
1006
|
+
)
|
1007
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
1008
|
+
result = ::Google::Apps::Chat::V1::SpaceReadState.decode_json response.body, ignore_unknown_fields: true
|
1009
|
+
|
1010
|
+
yield result, operation if block_given?
|
1011
|
+
result
|
1012
|
+
end
|
1013
|
+
|
1014
|
+
##
|
1015
|
+
# Baseline implementation for the get_thread_read_state REST call
|
1016
|
+
#
|
1017
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetThreadReadStateRequest]
|
1018
|
+
# A request object representing the call parameters. Required.
|
1019
|
+
# @param options [::Gapic::CallOptions]
|
1020
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1021
|
+
#
|
1022
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1023
|
+
# @yieldparam result [::Google::Apps::Chat::V1::ThreadReadState]
|
1024
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1025
|
+
#
|
1026
|
+
# @return [::Google::Apps::Chat::V1::ThreadReadState]
|
1027
|
+
# A result object deserialized from the server's reply
|
1028
|
+
def get_thread_read_state request_pb, options = nil
|
1029
|
+
raise ::ArgumentError, "request must be provided" if request_pb.nil?
|
1030
|
+
|
1031
|
+
verb, uri, query_string_params, body = ServiceStub.transcode_get_thread_read_state_request request_pb
|
1032
|
+
query_string_params = if query_string_params.any?
|
1033
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
1034
|
+
else
|
1035
|
+
{}
|
1036
|
+
end
|
1037
|
+
|
1038
|
+
response = @client_stub.make_http_request(
|
1039
|
+
verb,
|
1040
|
+
uri: uri,
|
1041
|
+
body: body || "",
|
1042
|
+
params: query_string_params,
|
1043
|
+
options: options
|
1044
|
+
)
|
1045
|
+
operation = ::Gapic::Rest::TransportOperation.new response
|
1046
|
+
result = ::Google::Apps::Chat::V1::ThreadReadState.decode_json response.body, ignore_unknown_fields: true
|
1047
|
+
|
1048
|
+
yield result, operation if block_given?
|
1049
|
+
result
|
1050
|
+
end
|
1051
|
+
|
1052
|
+
##
|
1053
|
+
# @private
|
1054
|
+
#
|
1055
|
+
# GRPC transcoding helper method for the create_message REST call
|
1056
|
+
#
|
1057
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateMessageRequest]
|
1058
|
+
# A request object representing the call parameters. Required.
|
1059
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1060
|
+
# Uri, Body, Query string parameters
|
1061
|
+
def self.transcode_create_message_request request_pb
|
1062
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1063
|
+
.with_bindings(
|
1064
|
+
uri_method: :post,
|
1065
|
+
uri_template: "/v1/{parent}/messages",
|
1066
|
+
body: "message",
|
1067
|
+
matches: [
|
1068
|
+
["parent", %r{^spaces/[^/]+/?$}, false]
|
1069
|
+
]
|
1070
|
+
)
|
1071
|
+
transcoder.transcode request_pb
|
1072
|
+
end
|
1073
|
+
|
1074
|
+
##
|
1075
|
+
# @private
|
1076
|
+
#
|
1077
|
+
# GRPC transcoding helper method for the list_messages REST call
|
1078
|
+
#
|
1079
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListMessagesRequest]
|
1080
|
+
# A request object representing the call parameters. Required.
|
1081
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1082
|
+
# Uri, Body, Query string parameters
|
1083
|
+
def self.transcode_list_messages_request request_pb
|
1084
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1085
|
+
.with_bindings(
|
1086
|
+
uri_method: :get,
|
1087
|
+
uri_template: "/v1/{parent}/messages",
|
1088
|
+
matches: [
|
1089
|
+
["parent", %r{^spaces/[^/]+/?$}, false]
|
1090
|
+
]
|
1091
|
+
)
|
1092
|
+
transcoder.transcode request_pb
|
1093
|
+
end
|
1094
|
+
|
1095
|
+
##
|
1096
|
+
# @private
|
1097
|
+
#
|
1098
|
+
# GRPC transcoding helper method for the list_memberships REST call
|
1099
|
+
#
|
1100
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListMembershipsRequest]
|
1101
|
+
# A request object representing the call parameters. Required.
|
1102
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1103
|
+
# Uri, Body, Query string parameters
|
1104
|
+
def self.transcode_list_memberships_request request_pb
|
1105
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1106
|
+
.with_bindings(
|
1107
|
+
uri_method: :get,
|
1108
|
+
uri_template: "/v1/{parent}/members",
|
1109
|
+
matches: [
|
1110
|
+
["parent", %r{^spaces/[^/]+/?$}, false]
|
1111
|
+
]
|
1112
|
+
)
|
1113
|
+
transcoder.transcode request_pb
|
1114
|
+
end
|
1115
|
+
|
1116
|
+
##
|
1117
|
+
# @private
|
1118
|
+
#
|
1119
|
+
# GRPC transcoding helper method for the get_membership REST call
|
1120
|
+
#
|
1121
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetMembershipRequest]
|
1122
|
+
# A request object representing the call parameters. Required.
|
1123
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1124
|
+
# Uri, Body, Query string parameters
|
1125
|
+
def self.transcode_get_membership_request request_pb
|
1126
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1127
|
+
.with_bindings(
|
1128
|
+
uri_method: :get,
|
1129
|
+
uri_template: "/v1/{name}",
|
1130
|
+
matches: [
|
1131
|
+
["name", %r{^spaces/[^/]+/members/[^/]+/?$}, false]
|
1132
|
+
]
|
1133
|
+
)
|
1134
|
+
transcoder.transcode request_pb
|
1135
|
+
end
|
1136
|
+
|
1137
|
+
##
|
1138
|
+
# @private
|
1139
|
+
#
|
1140
|
+
# GRPC transcoding helper method for the get_message REST call
|
1141
|
+
#
|
1142
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetMessageRequest]
|
1143
|
+
# A request object representing the call parameters. Required.
|
1144
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1145
|
+
# Uri, Body, Query string parameters
|
1146
|
+
def self.transcode_get_message_request request_pb
|
1147
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1148
|
+
.with_bindings(
|
1149
|
+
uri_method: :get,
|
1150
|
+
uri_template: "/v1/{name}",
|
1151
|
+
matches: [
|
1152
|
+
["name", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1153
|
+
]
|
1154
|
+
)
|
1155
|
+
transcoder.transcode request_pb
|
1156
|
+
end
|
1157
|
+
|
1158
|
+
##
|
1159
|
+
# @private
|
1160
|
+
#
|
1161
|
+
# GRPC transcoding helper method for the update_message REST call
|
1162
|
+
#
|
1163
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateMessageRequest]
|
1164
|
+
# A request object representing the call parameters. Required.
|
1165
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1166
|
+
# Uri, Body, Query string parameters
|
1167
|
+
def self.transcode_update_message_request request_pb
|
1168
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1169
|
+
.with_bindings(
|
1170
|
+
uri_method: :put,
|
1171
|
+
uri_template: "/v1/{message.name}",
|
1172
|
+
body: "message",
|
1173
|
+
matches: [
|
1174
|
+
["message.name", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1175
|
+
]
|
1176
|
+
)
|
1177
|
+
.with_bindings(
|
1178
|
+
uri_method: :patch,
|
1179
|
+
uri_template: "/v1/{message.name}",
|
1180
|
+
body: "message",
|
1181
|
+
matches: [
|
1182
|
+
["message.name", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1183
|
+
]
|
1184
|
+
)
|
1185
|
+
transcoder.transcode request_pb
|
1186
|
+
end
|
1187
|
+
|
1188
|
+
##
|
1189
|
+
# @private
|
1190
|
+
#
|
1191
|
+
# GRPC transcoding helper method for the delete_message REST call
|
1192
|
+
#
|
1193
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteMessageRequest]
|
1194
|
+
# A request object representing the call parameters. Required.
|
1195
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1196
|
+
# Uri, Body, Query string parameters
|
1197
|
+
def self.transcode_delete_message_request request_pb
|
1198
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1199
|
+
.with_bindings(
|
1200
|
+
uri_method: :delete,
|
1201
|
+
uri_template: "/v1/{name}",
|
1202
|
+
matches: [
|
1203
|
+
["name", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1204
|
+
]
|
1205
|
+
)
|
1206
|
+
transcoder.transcode request_pb
|
1207
|
+
end
|
1208
|
+
|
1209
|
+
##
|
1210
|
+
# @private
|
1211
|
+
#
|
1212
|
+
# GRPC transcoding helper method for the get_attachment REST call
|
1213
|
+
#
|
1214
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetAttachmentRequest]
|
1215
|
+
# A request object representing the call parameters. Required.
|
1216
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1217
|
+
# Uri, Body, Query string parameters
|
1218
|
+
def self.transcode_get_attachment_request request_pb
|
1219
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1220
|
+
.with_bindings(
|
1221
|
+
uri_method: :get,
|
1222
|
+
uri_template: "/v1/{name}",
|
1223
|
+
matches: [
|
1224
|
+
["name", %r{^spaces/[^/]+/messages/[^/]+/attachments/[^/]+/?$}, false]
|
1225
|
+
]
|
1226
|
+
)
|
1227
|
+
transcoder.transcode request_pb
|
1228
|
+
end
|
1229
|
+
|
1230
|
+
##
|
1231
|
+
# @private
|
1232
|
+
#
|
1233
|
+
# GRPC transcoding helper method for the upload_attachment REST call
|
1234
|
+
#
|
1235
|
+
# @param request_pb [::Google::Apps::Chat::V1::UploadAttachmentRequest]
|
1236
|
+
# A request object representing the call parameters. Required.
|
1237
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1238
|
+
# Uri, Body, Query string parameters
|
1239
|
+
def self.transcode_upload_attachment_request request_pb
|
1240
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1241
|
+
.with_bindings(
|
1242
|
+
uri_method: :post,
|
1243
|
+
uri_template: "/v1/{parent}/attachments:upload",
|
1244
|
+
body: "*",
|
1245
|
+
matches: [
|
1246
|
+
["parent", %r{^spaces/[^/]+/?$}, false]
|
1247
|
+
]
|
1248
|
+
)
|
1249
|
+
transcoder.transcode request_pb
|
1250
|
+
end
|
1251
|
+
|
1252
|
+
##
|
1253
|
+
# @private
|
1254
|
+
#
|
1255
|
+
# GRPC transcoding helper method for the list_spaces REST call
|
1256
|
+
#
|
1257
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListSpacesRequest]
|
1258
|
+
# A request object representing the call parameters. Required.
|
1259
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1260
|
+
# Uri, Body, Query string parameters
|
1261
|
+
def self.transcode_list_spaces_request request_pb
|
1262
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1263
|
+
.with_bindings(
|
1264
|
+
uri_method: :get,
|
1265
|
+
uri_template: "/v1/spaces",
|
1266
|
+
matches: []
|
1267
|
+
)
|
1268
|
+
transcoder.transcode request_pb
|
1269
|
+
end
|
1270
|
+
|
1271
|
+
##
|
1272
|
+
# @private
|
1273
|
+
#
|
1274
|
+
# GRPC transcoding helper method for the get_space REST call
|
1275
|
+
#
|
1276
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetSpaceRequest]
|
1277
|
+
# A request object representing the call parameters. Required.
|
1278
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1279
|
+
# Uri, Body, Query string parameters
|
1280
|
+
def self.transcode_get_space_request request_pb
|
1281
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1282
|
+
.with_bindings(
|
1283
|
+
uri_method: :get,
|
1284
|
+
uri_template: "/v1/{name}",
|
1285
|
+
matches: [
|
1286
|
+
["name", %r{^spaces/[^/]+/?$}, false]
|
1287
|
+
]
|
1288
|
+
)
|
1289
|
+
transcoder.transcode request_pb
|
1290
|
+
end
|
1291
|
+
|
1292
|
+
##
|
1293
|
+
# @private
|
1294
|
+
#
|
1295
|
+
# GRPC transcoding helper method for the create_space REST call
|
1296
|
+
#
|
1297
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateSpaceRequest]
|
1298
|
+
# A request object representing the call parameters. Required.
|
1299
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1300
|
+
# Uri, Body, Query string parameters
|
1301
|
+
def self.transcode_create_space_request request_pb
|
1302
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1303
|
+
.with_bindings(
|
1304
|
+
uri_method: :post,
|
1305
|
+
uri_template: "/v1/spaces",
|
1306
|
+
body: "space",
|
1307
|
+
matches: []
|
1308
|
+
)
|
1309
|
+
transcoder.transcode request_pb
|
1310
|
+
end
|
1311
|
+
|
1312
|
+
##
|
1313
|
+
# @private
|
1314
|
+
#
|
1315
|
+
# GRPC transcoding helper method for the set_up_space REST call
|
1316
|
+
#
|
1317
|
+
# @param request_pb [::Google::Apps::Chat::V1::SetUpSpaceRequest]
|
1318
|
+
# A request object representing the call parameters. Required.
|
1319
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1320
|
+
# Uri, Body, Query string parameters
|
1321
|
+
def self.transcode_set_up_space_request request_pb
|
1322
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1323
|
+
.with_bindings(
|
1324
|
+
uri_method: :post,
|
1325
|
+
uri_template: "/v1/spaces:setup",
|
1326
|
+
body: "*",
|
1327
|
+
matches: []
|
1328
|
+
)
|
1329
|
+
transcoder.transcode request_pb
|
1330
|
+
end
|
1331
|
+
|
1332
|
+
##
|
1333
|
+
# @private
|
1334
|
+
#
|
1335
|
+
# GRPC transcoding helper method for the update_space REST call
|
1336
|
+
#
|
1337
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateSpaceRequest]
|
1338
|
+
# A request object representing the call parameters. Required.
|
1339
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1340
|
+
# Uri, Body, Query string parameters
|
1341
|
+
def self.transcode_update_space_request request_pb
|
1342
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1343
|
+
.with_bindings(
|
1344
|
+
uri_method: :patch,
|
1345
|
+
uri_template: "/v1/{space.name}",
|
1346
|
+
body: "space",
|
1347
|
+
matches: [
|
1348
|
+
["space.name", %r{^spaces/[^/]+/?$}, false]
|
1349
|
+
]
|
1350
|
+
)
|
1351
|
+
transcoder.transcode request_pb
|
1352
|
+
end
|
1353
|
+
|
1354
|
+
##
|
1355
|
+
# @private
|
1356
|
+
#
|
1357
|
+
# GRPC transcoding helper method for the delete_space REST call
|
1358
|
+
#
|
1359
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteSpaceRequest]
|
1360
|
+
# A request object representing the call parameters. Required.
|
1361
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1362
|
+
# Uri, Body, Query string parameters
|
1363
|
+
def self.transcode_delete_space_request request_pb
|
1364
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1365
|
+
.with_bindings(
|
1366
|
+
uri_method: :delete,
|
1367
|
+
uri_template: "/v1/{name}",
|
1368
|
+
matches: [
|
1369
|
+
["name", %r{^spaces/[^/]+/?$}, false]
|
1370
|
+
]
|
1371
|
+
)
|
1372
|
+
transcoder.transcode request_pb
|
1373
|
+
end
|
1374
|
+
|
1375
|
+
##
|
1376
|
+
# @private
|
1377
|
+
#
|
1378
|
+
# GRPC transcoding helper method for the complete_import_space REST call
|
1379
|
+
#
|
1380
|
+
# @param request_pb [::Google::Apps::Chat::V1::CompleteImportSpaceRequest]
|
1381
|
+
# A request object representing the call parameters. Required.
|
1382
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1383
|
+
# Uri, Body, Query string parameters
|
1384
|
+
def self.transcode_complete_import_space_request request_pb
|
1385
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1386
|
+
.with_bindings(
|
1387
|
+
uri_method: :post,
|
1388
|
+
uri_template: "/v1/{name}:completeImport",
|
1389
|
+
body: "*",
|
1390
|
+
matches: [
|
1391
|
+
["name", %r{^spaces/[^/]+/?$}, false]
|
1392
|
+
]
|
1393
|
+
)
|
1394
|
+
transcoder.transcode request_pb
|
1395
|
+
end
|
1396
|
+
|
1397
|
+
##
|
1398
|
+
# @private
|
1399
|
+
#
|
1400
|
+
# GRPC transcoding helper method for the find_direct_message REST call
|
1401
|
+
#
|
1402
|
+
# @param request_pb [::Google::Apps::Chat::V1::FindDirectMessageRequest]
|
1403
|
+
# A request object representing the call parameters. Required.
|
1404
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1405
|
+
# Uri, Body, Query string parameters
|
1406
|
+
def self.transcode_find_direct_message_request request_pb
|
1407
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1408
|
+
.with_bindings(
|
1409
|
+
uri_method: :get,
|
1410
|
+
uri_template: "/v1/spaces:findDirectMessage",
|
1411
|
+
matches: []
|
1412
|
+
)
|
1413
|
+
transcoder.transcode request_pb
|
1414
|
+
end
|
1415
|
+
|
1416
|
+
##
|
1417
|
+
# @private
|
1418
|
+
#
|
1419
|
+
# GRPC transcoding helper method for the create_membership REST call
|
1420
|
+
#
|
1421
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateMembershipRequest]
|
1422
|
+
# A request object representing the call parameters. Required.
|
1423
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1424
|
+
# Uri, Body, Query string parameters
|
1425
|
+
def self.transcode_create_membership_request request_pb
|
1426
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1427
|
+
.with_bindings(
|
1428
|
+
uri_method: :post,
|
1429
|
+
uri_template: "/v1/{parent}/members",
|
1430
|
+
body: "membership",
|
1431
|
+
matches: [
|
1432
|
+
["parent", %r{^spaces/[^/]+/?$}, false]
|
1433
|
+
]
|
1434
|
+
)
|
1435
|
+
transcoder.transcode request_pb
|
1436
|
+
end
|
1437
|
+
|
1438
|
+
##
|
1439
|
+
# @private
|
1440
|
+
#
|
1441
|
+
# GRPC transcoding helper method for the update_membership REST call
|
1442
|
+
#
|
1443
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateMembershipRequest]
|
1444
|
+
# A request object representing the call parameters. Required.
|
1445
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1446
|
+
# Uri, Body, Query string parameters
|
1447
|
+
def self.transcode_update_membership_request request_pb
|
1448
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1449
|
+
.with_bindings(
|
1450
|
+
uri_method: :patch,
|
1451
|
+
uri_template: "/v1/{membership.name}",
|
1452
|
+
body: "membership",
|
1453
|
+
matches: [
|
1454
|
+
["membership.name", %r{^spaces/[^/]+/members/[^/]+/?$}, false]
|
1455
|
+
]
|
1456
|
+
)
|
1457
|
+
transcoder.transcode request_pb
|
1458
|
+
end
|
1459
|
+
|
1460
|
+
##
|
1461
|
+
# @private
|
1462
|
+
#
|
1463
|
+
# GRPC transcoding helper method for the delete_membership REST call
|
1464
|
+
#
|
1465
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteMembershipRequest]
|
1466
|
+
# A request object representing the call parameters. Required.
|
1467
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1468
|
+
# Uri, Body, Query string parameters
|
1469
|
+
def self.transcode_delete_membership_request request_pb
|
1470
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1471
|
+
.with_bindings(
|
1472
|
+
uri_method: :delete,
|
1473
|
+
uri_template: "/v1/{name}",
|
1474
|
+
matches: [
|
1475
|
+
["name", %r{^spaces/[^/]+/members/[^/]+/?$}, false]
|
1476
|
+
]
|
1477
|
+
)
|
1478
|
+
transcoder.transcode request_pb
|
1479
|
+
end
|
1480
|
+
|
1481
|
+
##
|
1482
|
+
# @private
|
1483
|
+
#
|
1484
|
+
# GRPC transcoding helper method for the create_reaction REST call
|
1485
|
+
#
|
1486
|
+
# @param request_pb [::Google::Apps::Chat::V1::CreateReactionRequest]
|
1487
|
+
# A request object representing the call parameters. Required.
|
1488
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1489
|
+
# Uri, Body, Query string parameters
|
1490
|
+
def self.transcode_create_reaction_request request_pb
|
1491
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1492
|
+
.with_bindings(
|
1493
|
+
uri_method: :post,
|
1494
|
+
uri_template: "/v1/{parent}/reactions",
|
1495
|
+
body: "reaction",
|
1496
|
+
matches: [
|
1497
|
+
["parent", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1498
|
+
]
|
1499
|
+
)
|
1500
|
+
transcoder.transcode request_pb
|
1501
|
+
end
|
1502
|
+
|
1503
|
+
##
|
1504
|
+
# @private
|
1505
|
+
#
|
1506
|
+
# GRPC transcoding helper method for the list_reactions REST call
|
1507
|
+
#
|
1508
|
+
# @param request_pb [::Google::Apps::Chat::V1::ListReactionsRequest]
|
1509
|
+
# A request object representing the call parameters. Required.
|
1510
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1511
|
+
# Uri, Body, Query string parameters
|
1512
|
+
def self.transcode_list_reactions_request request_pb
|
1513
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1514
|
+
.with_bindings(
|
1515
|
+
uri_method: :get,
|
1516
|
+
uri_template: "/v1/{parent}/reactions",
|
1517
|
+
matches: [
|
1518
|
+
["parent", %r{^spaces/[^/]+/messages/[^/]+/?$}, false]
|
1519
|
+
]
|
1520
|
+
)
|
1521
|
+
transcoder.transcode request_pb
|
1522
|
+
end
|
1523
|
+
|
1524
|
+
##
|
1525
|
+
# @private
|
1526
|
+
#
|
1527
|
+
# GRPC transcoding helper method for the delete_reaction REST call
|
1528
|
+
#
|
1529
|
+
# @param request_pb [::Google::Apps::Chat::V1::DeleteReactionRequest]
|
1530
|
+
# A request object representing the call parameters. Required.
|
1531
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1532
|
+
# Uri, Body, Query string parameters
|
1533
|
+
def self.transcode_delete_reaction_request request_pb
|
1534
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1535
|
+
.with_bindings(
|
1536
|
+
uri_method: :delete,
|
1537
|
+
uri_template: "/v1/{name}",
|
1538
|
+
matches: [
|
1539
|
+
["name", %r{^spaces/[^/]+/messages/[^/]+/reactions/[^/]+/?$}, false]
|
1540
|
+
]
|
1541
|
+
)
|
1542
|
+
transcoder.transcode request_pb
|
1543
|
+
end
|
1544
|
+
|
1545
|
+
##
|
1546
|
+
# @private
|
1547
|
+
#
|
1548
|
+
# GRPC transcoding helper method for the get_space_read_state REST call
|
1549
|
+
#
|
1550
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetSpaceReadStateRequest]
|
1551
|
+
# A request object representing the call parameters. Required.
|
1552
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1553
|
+
# Uri, Body, Query string parameters
|
1554
|
+
def self.transcode_get_space_read_state_request request_pb
|
1555
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1556
|
+
.with_bindings(
|
1557
|
+
uri_method: :get,
|
1558
|
+
uri_template: "/v1/{name}",
|
1559
|
+
matches: [
|
1560
|
+
["name", %r{^users/[^/]+/spaces/[^/]+/spaceReadState/?$}, false]
|
1561
|
+
]
|
1562
|
+
)
|
1563
|
+
transcoder.transcode request_pb
|
1564
|
+
end
|
1565
|
+
|
1566
|
+
##
|
1567
|
+
# @private
|
1568
|
+
#
|
1569
|
+
# GRPC transcoding helper method for the update_space_read_state REST call
|
1570
|
+
#
|
1571
|
+
# @param request_pb [::Google::Apps::Chat::V1::UpdateSpaceReadStateRequest]
|
1572
|
+
# A request object representing the call parameters. Required.
|
1573
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1574
|
+
# Uri, Body, Query string parameters
|
1575
|
+
def self.transcode_update_space_read_state_request request_pb
|
1576
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1577
|
+
.with_bindings(
|
1578
|
+
uri_method: :patch,
|
1579
|
+
uri_template: "/v1/{space_read_state.name}",
|
1580
|
+
body: "space_read_state",
|
1581
|
+
matches: [
|
1582
|
+
["space_read_state.name", %r{^users/[^/]+/spaces/[^/]+/spaceReadState/?$}, false]
|
1583
|
+
]
|
1584
|
+
)
|
1585
|
+
transcoder.transcode request_pb
|
1586
|
+
end
|
1587
|
+
|
1588
|
+
##
|
1589
|
+
# @private
|
1590
|
+
#
|
1591
|
+
# GRPC transcoding helper method for the get_thread_read_state REST call
|
1592
|
+
#
|
1593
|
+
# @param request_pb [::Google::Apps::Chat::V1::GetThreadReadStateRequest]
|
1594
|
+
# A request object representing the call parameters. Required.
|
1595
|
+
# @return [Array(String, [String, nil], Hash{String => String})]
|
1596
|
+
# Uri, Body, Query string parameters
|
1597
|
+
def self.transcode_get_thread_read_state_request request_pb
|
1598
|
+
transcoder = Gapic::Rest::GrpcTranscoder.new
|
1599
|
+
.with_bindings(
|
1600
|
+
uri_method: :get,
|
1601
|
+
uri_template: "/v1/{name}",
|
1602
|
+
matches: [
|
1603
|
+
["name", %r{^users/[^/]+/spaces/[^/]+/threads/[^/]+/threadReadState/?$}, false]
|
1604
|
+
]
|
1605
|
+
)
|
1606
|
+
transcoder.transcode request_pb
|
1607
|
+
end
|
1608
|
+
end
|
1609
|
+
end
|
1610
|
+
end
|
1611
|
+
end
|
1612
|
+
end
|
1613
|
+
end
|
1614
|
+
end
|