google-apis-pubsub_v1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,28 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ module Google
16
+ module Apis
17
+ module PubsubV1
18
+ # Version of the google-apis-pubsub_v1 gem
19
+ GEM_VERSION = "0.1.0"
20
+
21
+ # Version of the code generator used to generate this client
22
+ GENERATOR_VERSION = "0.1.1"
23
+
24
+ # Revision of the discovery document this client was generated from
25
+ REVISION = "20201201"
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,572 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module PubsubV1
24
+
25
+ class AcknowledgeRequest
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
31
+ class Binding
32
+ class Representation < Google::Apis::Core::JsonRepresentation; end
33
+
34
+ include Google::Apis::Core::JsonObjectSupport
35
+ end
36
+
37
+ class CreateSnapshotRequest
38
+ class Representation < Google::Apis::Core::JsonRepresentation; end
39
+
40
+ include Google::Apis::Core::JsonObjectSupport
41
+ end
42
+
43
+ class DeadLetterPolicy
44
+ class Representation < Google::Apis::Core::JsonRepresentation; end
45
+
46
+ include Google::Apis::Core::JsonObjectSupport
47
+ end
48
+
49
+ class DetachSubscriptionResponse
50
+ class Representation < Google::Apis::Core::JsonRepresentation; end
51
+
52
+ include Google::Apis::Core::JsonObjectSupport
53
+ end
54
+
55
+ class Empty
56
+ class Representation < Google::Apis::Core::JsonRepresentation; end
57
+
58
+ include Google::Apis::Core::JsonObjectSupport
59
+ end
60
+
61
+ class ExpirationPolicy
62
+ class Representation < Google::Apis::Core::JsonRepresentation; end
63
+
64
+ include Google::Apis::Core::JsonObjectSupport
65
+ end
66
+
67
+ class Expr
68
+ class Representation < Google::Apis::Core::JsonRepresentation; end
69
+
70
+ include Google::Apis::Core::JsonObjectSupport
71
+ end
72
+
73
+ class ListSnapshotsResponse
74
+ class Representation < Google::Apis::Core::JsonRepresentation; end
75
+
76
+ include Google::Apis::Core::JsonObjectSupport
77
+ end
78
+
79
+ class ListSubscriptionsResponse
80
+ class Representation < Google::Apis::Core::JsonRepresentation; end
81
+
82
+ include Google::Apis::Core::JsonObjectSupport
83
+ end
84
+
85
+ class ListTopicSnapshotsResponse
86
+ class Representation < Google::Apis::Core::JsonRepresentation; end
87
+
88
+ include Google::Apis::Core::JsonObjectSupport
89
+ end
90
+
91
+ class ListTopicSubscriptionsResponse
92
+ class Representation < Google::Apis::Core::JsonRepresentation; end
93
+
94
+ include Google::Apis::Core::JsonObjectSupport
95
+ end
96
+
97
+ class ListTopicsResponse
98
+ class Representation < Google::Apis::Core::JsonRepresentation; end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
103
+ class MessageStoragePolicy
104
+ class Representation < Google::Apis::Core::JsonRepresentation; end
105
+
106
+ include Google::Apis::Core::JsonObjectSupport
107
+ end
108
+
109
+ class ModifyAckDeadlineRequest
110
+ class Representation < Google::Apis::Core::JsonRepresentation; end
111
+
112
+ include Google::Apis::Core::JsonObjectSupport
113
+ end
114
+
115
+ class ModifyPushConfigRequest
116
+ class Representation < Google::Apis::Core::JsonRepresentation; end
117
+
118
+ include Google::Apis::Core::JsonObjectSupport
119
+ end
120
+
121
+ class OidcToken
122
+ class Representation < Google::Apis::Core::JsonRepresentation; end
123
+
124
+ include Google::Apis::Core::JsonObjectSupport
125
+ end
126
+
127
+ class Policy
128
+ class Representation < Google::Apis::Core::JsonRepresentation; end
129
+
130
+ include Google::Apis::Core::JsonObjectSupport
131
+ end
132
+
133
+ class PublishRequest
134
+ class Representation < Google::Apis::Core::JsonRepresentation; end
135
+
136
+ include Google::Apis::Core::JsonObjectSupport
137
+ end
138
+
139
+ class PublishResponse
140
+ class Representation < Google::Apis::Core::JsonRepresentation; end
141
+
142
+ include Google::Apis::Core::JsonObjectSupport
143
+ end
144
+
145
+ class Message
146
+ class Representation < Google::Apis::Core::JsonRepresentation; end
147
+
148
+ include Google::Apis::Core::JsonObjectSupport
149
+ end
150
+
151
+ class PullRequest
152
+ class Representation < Google::Apis::Core::JsonRepresentation; end
153
+
154
+ include Google::Apis::Core::JsonObjectSupport
155
+ end
156
+
157
+ class PullResponse
158
+ class Representation < Google::Apis::Core::JsonRepresentation; end
159
+
160
+ include Google::Apis::Core::JsonObjectSupport
161
+ end
162
+
163
+ class PushConfig
164
+ class Representation < Google::Apis::Core::JsonRepresentation; end
165
+
166
+ include Google::Apis::Core::JsonObjectSupport
167
+ end
168
+
169
+ class ReceivedMessage
170
+ class Representation < Google::Apis::Core::JsonRepresentation; end
171
+
172
+ include Google::Apis::Core::JsonObjectSupport
173
+ end
174
+
175
+ class RetryPolicy
176
+ class Representation < Google::Apis::Core::JsonRepresentation; end
177
+
178
+ include Google::Apis::Core::JsonObjectSupport
179
+ end
180
+
181
+ class SeekRequest
182
+ class Representation < Google::Apis::Core::JsonRepresentation; end
183
+
184
+ include Google::Apis::Core::JsonObjectSupport
185
+ end
186
+
187
+ class SeekResponse
188
+ class Representation < Google::Apis::Core::JsonRepresentation; end
189
+
190
+ include Google::Apis::Core::JsonObjectSupport
191
+ end
192
+
193
+ class SetIamPolicyRequest
194
+ class Representation < Google::Apis::Core::JsonRepresentation; end
195
+
196
+ include Google::Apis::Core::JsonObjectSupport
197
+ end
198
+
199
+ class Snapshot
200
+ class Representation < Google::Apis::Core::JsonRepresentation; end
201
+
202
+ include Google::Apis::Core::JsonObjectSupport
203
+ end
204
+
205
+ class Subscription
206
+ class Representation < Google::Apis::Core::JsonRepresentation; end
207
+
208
+ include Google::Apis::Core::JsonObjectSupport
209
+ end
210
+
211
+ class TestIamPermissionsRequest
212
+ class Representation < Google::Apis::Core::JsonRepresentation; end
213
+
214
+ include Google::Apis::Core::JsonObjectSupport
215
+ end
216
+
217
+ class TestIamPermissionsResponse
218
+ class Representation < Google::Apis::Core::JsonRepresentation; end
219
+
220
+ include Google::Apis::Core::JsonObjectSupport
221
+ end
222
+
223
+ class Topic
224
+ class Representation < Google::Apis::Core::JsonRepresentation; end
225
+
226
+ include Google::Apis::Core::JsonObjectSupport
227
+ end
228
+
229
+ class UpdateSnapshotRequest
230
+ class Representation < Google::Apis::Core::JsonRepresentation; end
231
+
232
+ include Google::Apis::Core::JsonObjectSupport
233
+ end
234
+
235
+ class UpdateSubscriptionRequest
236
+ class Representation < Google::Apis::Core::JsonRepresentation; end
237
+
238
+ include Google::Apis::Core::JsonObjectSupport
239
+ end
240
+
241
+ class UpdateTopicRequest
242
+ class Representation < Google::Apis::Core::JsonRepresentation; end
243
+
244
+ include Google::Apis::Core::JsonObjectSupport
245
+ end
246
+
247
+ class AcknowledgeRequest
248
+ # @private
249
+ class Representation < Google::Apis::Core::JsonRepresentation
250
+ collection :ack_ids, as: 'ackIds'
251
+ end
252
+ end
253
+
254
+ class Binding
255
+ # @private
256
+ class Representation < Google::Apis::Core::JsonRepresentation
257
+ property :condition, as: 'condition', class: Google::Apis::PubsubV1::Expr, decorator: Google::Apis::PubsubV1::Expr::Representation
258
+
259
+ collection :members, as: 'members'
260
+ property :role, as: 'role'
261
+ end
262
+ end
263
+
264
+ class CreateSnapshotRequest
265
+ # @private
266
+ class Representation < Google::Apis::Core::JsonRepresentation
267
+ hash :labels, as: 'labels'
268
+ property :subscription, as: 'subscription'
269
+ end
270
+ end
271
+
272
+ class DeadLetterPolicy
273
+ # @private
274
+ class Representation < Google::Apis::Core::JsonRepresentation
275
+ property :dead_letter_topic, as: 'deadLetterTopic'
276
+ property :max_delivery_attempts, as: 'maxDeliveryAttempts'
277
+ end
278
+ end
279
+
280
+ class DetachSubscriptionResponse
281
+ # @private
282
+ class Representation < Google::Apis::Core::JsonRepresentation
283
+ end
284
+ end
285
+
286
+ class Empty
287
+ # @private
288
+ class Representation < Google::Apis::Core::JsonRepresentation
289
+ end
290
+ end
291
+
292
+ class ExpirationPolicy
293
+ # @private
294
+ class Representation < Google::Apis::Core::JsonRepresentation
295
+ property :ttl, as: 'ttl'
296
+ end
297
+ end
298
+
299
+ class Expr
300
+ # @private
301
+ class Representation < Google::Apis::Core::JsonRepresentation
302
+ property :description, as: 'description'
303
+ property :expression, as: 'expression'
304
+ property :location, as: 'location'
305
+ property :title, as: 'title'
306
+ end
307
+ end
308
+
309
+ class ListSnapshotsResponse
310
+ # @private
311
+ class Representation < Google::Apis::Core::JsonRepresentation
312
+ property :next_page_token, as: 'nextPageToken'
313
+ collection :snapshots, as: 'snapshots', class: Google::Apis::PubsubV1::Snapshot, decorator: Google::Apis::PubsubV1::Snapshot::Representation
314
+
315
+ end
316
+ end
317
+
318
+ class ListSubscriptionsResponse
319
+ # @private
320
+ class Representation < Google::Apis::Core::JsonRepresentation
321
+ property :next_page_token, as: 'nextPageToken'
322
+ collection :subscriptions, as: 'subscriptions', class: Google::Apis::PubsubV1::Subscription, decorator: Google::Apis::PubsubV1::Subscription::Representation
323
+
324
+ end
325
+ end
326
+
327
+ class ListTopicSnapshotsResponse
328
+ # @private
329
+ class Representation < Google::Apis::Core::JsonRepresentation
330
+ property :next_page_token, as: 'nextPageToken'
331
+ collection :snapshots, as: 'snapshots'
332
+ end
333
+ end
334
+
335
+ class ListTopicSubscriptionsResponse
336
+ # @private
337
+ class Representation < Google::Apis::Core::JsonRepresentation
338
+ property :next_page_token, as: 'nextPageToken'
339
+ collection :subscriptions, as: 'subscriptions'
340
+ end
341
+ end
342
+
343
+ class ListTopicsResponse
344
+ # @private
345
+ class Representation < Google::Apis::Core::JsonRepresentation
346
+ property :next_page_token, as: 'nextPageToken'
347
+ collection :topics, as: 'topics', class: Google::Apis::PubsubV1::Topic, decorator: Google::Apis::PubsubV1::Topic::Representation
348
+
349
+ end
350
+ end
351
+
352
+ class MessageStoragePolicy
353
+ # @private
354
+ class Representation < Google::Apis::Core::JsonRepresentation
355
+ collection :allowed_persistence_regions, as: 'allowedPersistenceRegions'
356
+ end
357
+ end
358
+
359
+ class ModifyAckDeadlineRequest
360
+ # @private
361
+ class Representation < Google::Apis::Core::JsonRepresentation
362
+ property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
363
+ collection :ack_ids, as: 'ackIds'
364
+ end
365
+ end
366
+
367
+ class ModifyPushConfigRequest
368
+ # @private
369
+ class Representation < Google::Apis::Core::JsonRepresentation
370
+ property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
371
+
372
+ end
373
+ end
374
+
375
+ class OidcToken
376
+ # @private
377
+ class Representation < Google::Apis::Core::JsonRepresentation
378
+ property :audience, as: 'audience'
379
+ property :service_account_email, as: 'serviceAccountEmail'
380
+ end
381
+ end
382
+
383
+ class Policy
384
+ # @private
385
+ class Representation < Google::Apis::Core::JsonRepresentation
386
+ collection :bindings, as: 'bindings', class: Google::Apis::PubsubV1::Binding, decorator: Google::Apis::PubsubV1::Binding::Representation
387
+
388
+ property :etag, :base64 => true, as: 'etag'
389
+ property :version, as: 'version'
390
+ end
391
+ end
392
+
393
+ class PublishRequest
394
+ # @private
395
+ class Representation < Google::Apis::Core::JsonRepresentation
396
+ collection :messages, as: 'messages', class: Google::Apis::PubsubV1::Message, decorator: Google::Apis::PubsubV1::Message::Representation
397
+
398
+ end
399
+ end
400
+
401
+ class PublishResponse
402
+ # @private
403
+ class Representation < Google::Apis::Core::JsonRepresentation
404
+ collection :message_ids, as: 'messageIds'
405
+ end
406
+ end
407
+
408
+ class Message
409
+ # @private
410
+ class Representation < Google::Apis::Core::JsonRepresentation
411
+ hash :attributes, as: 'attributes'
412
+ property :data, :base64 => true, as: 'data'
413
+ property :message_id, as: 'messageId'
414
+ property :ordering_key, as: 'orderingKey'
415
+ property :publish_time, as: 'publishTime'
416
+ end
417
+ end
418
+
419
+ class PullRequest
420
+ # @private
421
+ class Representation < Google::Apis::Core::JsonRepresentation
422
+ property :max_messages, as: 'maxMessages'
423
+ property :return_immediately, as: 'returnImmediately'
424
+ end
425
+ end
426
+
427
+ class PullResponse
428
+ # @private
429
+ class Representation < Google::Apis::Core::JsonRepresentation
430
+ collection :received_messages, as: 'receivedMessages', class: Google::Apis::PubsubV1::ReceivedMessage, decorator: Google::Apis::PubsubV1::ReceivedMessage::Representation
431
+
432
+ end
433
+ end
434
+
435
+ class PushConfig
436
+ # @private
437
+ class Representation < Google::Apis::Core::JsonRepresentation
438
+ hash :attributes, as: 'attributes'
439
+ property :oidc_token, as: 'oidcToken', class: Google::Apis::PubsubV1::OidcToken, decorator: Google::Apis::PubsubV1::OidcToken::Representation
440
+
441
+ property :push_endpoint, as: 'pushEndpoint'
442
+ end
443
+ end
444
+
445
+ class ReceivedMessage
446
+ # @private
447
+ class Representation < Google::Apis::Core::JsonRepresentation
448
+ property :ack_id, as: 'ackId'
449
+ property :delivery_attempt, as: 'deliveryAttempt'
450
+ property :message, as: 'message', class: Google::Apis::PubsubV1::Message, decorator: Google::Apis::PubsubV1::Message::Representation
451
+
452
+ end
453
+ end
454
+
455
+ class RetryPolicy
456
+ # @private
457
+ class Representation < Google::Apis::Core::JsonRepresentation
458
+ property :maximum_backoff, as: 'maximumBackoff'
459
+ property :minimum_backoff, as: 'minimumBackoff'
460
+ end
461
+ end
462
+
463
+ class SeekRequest
464
+ # @private
465
+ class Representation < Google::Apis::Core::JsonRepresentation
466
+ property :snapshot, as: 'snapshot'
467
+ property :time, as: 'time'
468
+ end
469
+ end
470
+
471
+ class SeekResponse
472
+ # @private
473
+ class Representation < Google::Apis::Core::JsonRepresentation
474
+ end
475
+ end
476
+
477
+ class SetIamPolicyRequest
478
+ # @private
479
+ class Representation < Google::Apis::Core::JsonRepresentation
480
+ property :policy, as: 'policy', class: Google::Apis::PubsubV1::Policy, decorator: Google::Apis::PubsubV1::Policy::Representation
481
+
482
+ end
483
+ end
484
+
485
+ class Snapshot
486
+ # @private
487
+ class Representation < Google::Apis::Core::JsonRepresentation
488
+ property :expire_time, as: 'expireTime'
489
+ hash :labels, as: 'labels'
490
+ property :name, as: 'name'
491
+ property :topic, as: 'topic'
492
+ end
493
+ end
494
+
495
+ class Subscription
496
+ # @private
497
+ class Representation < Google::Apis::Core::JsonRepresentation
498
+ property :ack_deadline_seconds, as: 'ackDeadlineSeconds'
499
+ property :dead_letter_policy, as: 'deadLetterPolicy', class: Google::Apis::PubsubV1::DeadLetterPolicy, decorator: Google::Apis::PubsubV1::DeadLetterPolicy::Representation
500
+
501
+ property :detached, as: 'detached'
502
+ property :enable_message_ordering, as: 'enableMessageOrdering'
503
+ property :expiration_policy, as: 'expirationPolicy', class: Google::Apis::PubsubV1::ExpirationPolicy, decorator: Google::Apis::PubsubV1::ExpirationPolicy::Representation
504
+
505
+ property :filter, as: 'filter'
506
+ hash :labels, as: 'labels'
507
+ property :message_retention_duration, as: 'messageRetentionDuration'
508
+ property :name, as: 'name'
509
+ property :push_config, as: 'pushConfig', class: Google::Apis::PubsubV1::PushConfig, decorator: Google::Apis::PubsubV1::PushConfig::Representation
510
+
511
+ property :retain_acked_messages, as: 'retainAckedMessages'
512
+ property :retry_policy, as: 'retryPolicy', class: Google::Apis::PubsubV1::RetryPolicy, decorator: Google::Apis::PubsubV1::RetryPolicy::Representation
513
+
514
+ property :topic, as: 'topic'
515
+ end
516
+ end
517
+
518
+ class TestIamPermissionsRequest
519
+ # @private
520
+ class Representation < Google::Apis::Core::JsonRepresentation
521
+ collection :permissions, as: 'permissions'
522
+ end
523
+ end
524
+
525
+ class TestIamPermissionsResponse
526
+ # @private
527
+ class Representation < Google::Apis::Core::JsonRepresentation
528
+ collection :permissions, as: 'permissions'
529
+ end
530
+ end
531
+
532
+ class Topic
533
+ # @private
534
+ class Representation < Google::Apis::Core::JsonRepresentation
535
+ property :kms_key_name, as: 'kmsKeyName'
536
+ hash :labels, as: 'labels'
537
+ property :message_storage_policy, as: 'messageStoragePolicy', class: Google::Apis::PubsubV1::MessageStoragePolicy, decorator: Google::Apis::PubsubV1::MessageStoragePolicy::Representation
538
+
539
+ property :name, as: 'name'
540
+ property :satisfies_pzs, as: 'satisfiesPzs'
541
+ end
542
+ end
543
+
544
+ class UpdateSnapshotRequest
545
+ # @private
546
+ class Representation < Google::Apis::Core::JsonRepresentation
547
+ property :snapshot, as: 'snapshot', class: Google::Apis::PubsubV1::Snapshot, decorator: Google::Apis::PubsubV1::Snapshot::Representation
548
+
549
+ property :update_mask, as: 'updateMask'
550
+ end
551
+ end
552
+
553
+ class UpdateSubscriptionRequest
554
+ # @private
555
+ class Representation < Google::Apis::Core::JsonRepresentation
556
+ property :subscription, as: 'subscription', class: Google::Apis::PubsubV1::Subscription, decorator: Google::Apis::PubsubV1::Subscription::Representation
557
+
558
+ property :update_mask, as: 'updateMask'
559
+ end
560
+ end
561
+
562
+ class UpdateTopicRequest
563
+ # @private
564
+ class Representation < Google::Apis::Core::JsonRepresentation
565
+ property :topic, as: 'topic', class: Google::Apis::PubsubV1::Topic, decorator: Google::Apis::PubsubV1::Topic::Representation
566
+
567
+ property :update_mask, as: 'updateMask'
568
+ end
569
+ end
570
+ end
571
+ end
572
+ end