google-api-client 0.47.0 → 0.48.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (149) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/release-please.yml +77 -0
  3. data/CHANGELOG.md +64 -0
  4. data/generated/google/apis/bigquery_v2.rb +1 -1
  5. data/generated/google/apis/bigquery_v2/service.rb +1 -1
  6. data/generated/google/apis/billingbudgets_v1.rb +1 -1
  7. data/generated/google/apis/billingbudgets_v1/classes.rb +11 -0
  8. data/generated/google/apis/billingbudgets_v1/representations.rb +1 -0
  9. data/generated/google/apis/billingbudgets_v1beta1.rb +1 -1
  10. data/generated/google/apis/billingbudgets_v1beta1/classes.rb +11 -0
  11. data/generated/google/apis/billingbudgets_v1beta1/representations.rb +1 -0
  12. data/generated/google/apis/cloudasset_v1.rb +1 -1
  13. data/generated/google/apis/cloudasset_v1/classes.rb +697 -0
  14. data/generated/google/apis/cloudasset_v1/representations.rb +304 -0
  15. data/generated/google/apis/cloudasset_v1/service.rb +171 -0
  16. data/generated/google/apis/compute_v1.rb +1 -1
  17. data/generated/google/apis/compute_v1/classes.rb +238 -14
  18. data/generated/google/apis/compute_v1/representations.rb +41 -0
  19. data/generated/google/apis/compute_v1/service.rb +2 -0
  20. data/generated/google/apis/content_v2.rb +1 -1
  21. data/generated/google/apis/content_v2/service.rb +7 -7
  22. data/generated/google/apis/content_v2_1.rb +3 -4
  23. data/generated/google/apis/content_v2_1/classes.rb +899 -1054
  24. data/generated/google/apis/content_v2_1/representations.rb +206 -0
  25. data/generated/google/apis/content_v2_1/service.rb +912 -808
  26. data/generated/google/apis/datacatalog_v1beta1.rb +1 -1
  27. data/generated/google/apis/datacatalog_v1beta1/classes.rb +24 -0
  28. data/generated/google/apis/datacatalog_v1beta1/representations.rb +5 -0
  29. data/generated/google/apis/dataflow_v1b3.rb +1 -1
  30. data/generated/google/apis/dataflow_v1b3/classes.rb +12 -0
  31. data/generated/google/apis/dataflow_v1b3/representations.rb +3 -0
  32. data/generated/google/apis/datalabeling_v1beta1.rb +34 -0
  33. data/generated/google/apis/datalabeling_v1beta1/classes.rb +6207 -0
  34. data/generated/google/apis/datalabeling_v1beta1/representations.rb +3156 -0
  35. data/generated/google/apis/datalabeling_v1beta1/service.rb +1762 -0
  36. data/generated/google/apis/datastore_v1.rb +1 -1
  37. data/generated/google/apis/datastore_v1/classes.rb +4 -4
  38. data/generated/google/apis/datastore_v1beta3.rb +1 -1
  39. data/generated/google/apis/datastore_v1beta3/classes.rb +4 -4
  40. data/generated/google/apis/deploymentmanager_v2.rb +6 -4
  41. data/generated/google/apis/deploymentmanager_v2/classes.rb +203 -558
  42. data/generated/google/apis/deploymentmanager_v2/representations.rb +0 -132
  43. data/generated/google/apis/deploymentmanager_v2/service.rb +169 -213
  44. data/generated/google/apis/deploymentmanager_v2beta.rb +6 -5
  45. data/generated/google/apis/deploymentmanager_v2beta/classes.rb +247 -609
  46. data/generated/google/apis/deploymentmanager_v2beta/representations.rb +0 -132
  47. data/generated/google/apis/deploymentmanager_v2beta/service.rb +278 -359
  48. data/generated/google/apis/dialogflow_v2.rb +1 -1
  49. data/generated/google/apis/dialogflow_v2/classes.rb +20 -2
  50. data/generated/google/apis/dialogflow_v2/representations.rb +5 -2
  51. data/generated/google/apis/dialogflow_v2beta1.rb +1 -1
  52. data/generated/google/apis/dialogflow_v2beta1/classes.rb +20 -2
  53. data/generated/google/apis/dialogflow_v2beta1/representations.rb +5 -2
  54. data/generated/google/apis/dialogflow_v3beta1.rb +1 -1
  55. data/generated/google/apis/dialogflow_v3beta1/classes.rb +40 -2
  56. data/generated/google/apis/dialogflow_v3beta1/representations.rb +7 -2
  57. data/generated/google/apis/displayvideo_v1.rb +1 -1
  58. data/generated/google/apis/displayvideo_v1/classes.rb +178 -0
  59. data/generated/google/apis/displayvideo_v1/representations.rb +77 -0
  60. data/generated/google/apis/displayvideo_v1/service.rb +249 -9
  61. data/generated/google/apis/domains_v1alpha2.rb +1 -1
  62. data/generated/google/apis/domains_v1alpha2/classes.rb +6 -0
  63. data/generated/google/apis/domains_v1alpha2/representations.rb +1 -0
  64. data/generated/google/apis/domains_v1beta1.rb +1 -1
  65. data/generated/google/apis/domains_v1beta1/classes.rb +6 -0
  66. data/generated/google/apis/domains_v1beta1/representations.rb +1 -0
  67. data/generated/google/apis/eventarc_v1beta1.rb +1 -1
  68. data/generated/google/apis/eventarc_v1beta1/classes.rb +1 -3
  69. data/generated/google/apis/firebase_v1beta1.rb +1 -1
  70. data/generated/google/apis/firebase_v1beta1/service.rb +17 -4
  71. data/generated/google/apis/firebasehosting_v1beta1.rb +1 -1
  72. data/generated/google/apis/firebasehosting_v1beta1/classes.rb +2 -0
  73. data/generated/google/apis/firestore_v1.rb +1 -1
  74. data/generated/google/apis/firestore_v1/classes.rb +4 -4
  75. data/generated/google/apis/firestore_v1beta1.rb +1 -1
  76. data/generated/google/apis/firestore_v1beta1/classes.rb +4 -4
  77. data/generated/google/apis/games_v1.rb +1 -1
  78. data/generated/google/apis/games_v1/classes.rb +300 -0
  79. data/generated/google/apis/games_v1/representations.rb +116 -0
  80. data/generated/google/apis/games_v1/service.rb +34 -0
  81. data/generated/google/apis/gameservices_v1.rb +1 -1
  82. data/generated/google/apis/gameservices_v1beta.rb +1 -1
  83. data/generated/google/apis/iam_v1.rb +2 -5
  84. data/generated/google/apis/iam_v1/service.rb +1 -4
  85. data/generated/google/apis/iamcredentials_v1.rb +3 -4
  86. data/generated/google/apis/iamcredentials_v1/service.rb +2 -3
  87. data/generated/google/apis/logging_v2.rb +1 -1
  88. data/generated/google/apis/logging_v2/classes.rb +72 -0
  89. data/generated/google/apis/logging_v2/representations.rb +32 -0
  90. data/generated/google/apis/logging_v2/service.rb +345 -0
  91. data/generated/google/apis/people_v1.rb +1 -1
  92. data/generated/google/apis/people_v1/classes.rb +4 -4
  93. data/generated/google/apis/people_v1/service.rb +12 -12
  94. data/generated/google/apis/privateca_v1beta1.rb +34 -0
  95. data/generated/google/apis/privateca_v1beta1/classes.rb +2466 -0
  96. data/generated/google/apis/privateca_v1beta1/representations.rb +996 -0
  97. data/generated/google/apis/privateca_v1beta1/service.rb +1487 -0
  98. data/generated/google/apis/recommendationengine_v1beta1.rb +1 -1
  99. data/generated/google/apis/recommendationengine_v1beta1/classes.rb +32 -0
  100. data/generated/google/apis/recommendationengine_v1beta1/representations.rb +25 -0
  101. data/generated/google/apis/runtimeconfig_v1beta1.rb +1 -1
  102. data/generated/google/apis/runtimeconfig_v1beta1/classes.rb +1 -2
  103. data/generated/google/apis/safebrowsing_v4.rb +35 -0
  104. data/generated/google/apis/safebrowsing_v4/classes.rb +909 -0
  105. data/generated/google/apis/safebrowsing_v4/representations.rb +445 -0
  106. data/generated/google/apis/safebrowsing_v4/service.rb +286 -0
  107. data/generated/google/apis/secretmanager_v1.rb +1 -1
  108. data/generated/google/apis/secretmanager_v1/classes.rb +1 -2
  109. data/generated/google/apis/secretmanager_v1beta1.rb +1 -1
  110. data/generated/google/apis/secretmanager_v1beta1/classes.rb +1 -2
  111. data/generated/google/apis/servicecontrol_v1.rb +1 -1
  112. data/generated/google/apis/servicecontrol_v1/classes.rb +45 -0
  113. data/generated/google/apis/servicecontrol_v1/representations.rb +6 -0
  114. data/generated/google/apis/servicecontrol_v2.rb +1 -1
  115. data/generated/google/apis/servicecontrol_v2/classes.rb +45 -0
  116. data/generated/google/apis/servicecontrol_v2/representations.rb +6 -0
  117. data/generated/google/apis/servicemanagement_v1.rb +1 -1
  118. data/generated/google/apis/servicemanagement_v1/classes.rb +1 -60
  119. data/generated/google/apis/servicemanagement_v1/representations.rb +0 -18
  120. data/generated/google/apis/serviceusage_v1beta1.rb +1 -1
  121. data/generated/google/apis/serviceusage_v1beta1/classes.rb +30 -0
  122. data/generated/google/apis/serviceusage_v1beta1/representations.rb +15 -0
  123. data/generated/google/apis/serviceusage_v1beta1/service.rb +36 -0
  124. data/generated/google/apis/smartdevicemanagement_v1.rb +1 -1
  125. data/generated/google/apis/smartdevicemanagement_v1/classes.rb +0 -34
  126. data/generated/google/apis/smartdevicemanagement_v1/representations.rb +0 -16
  127. data/generated/google/apis/smartdevicemanagement_v1/service.rb +3 -8
  128. data/generated/google/apis/sqladmin_v1beta4.rb +1 -1
  129. data/generated/google/apis/sqladmin_v1beta4/classes.rb +28 -4
  130. data/generated/google/apis/sqladmin_v1beta4/representations.rb +3 -0
  131. data/generated/google/apis/storagetransfer_v1.rb +1 -1
  132. data/generated/google/apis/storagetransfer_v1/classes.rb +14 -5
  133. data/generated/google/apis/toolresults_v1beta3.rb +1 -1
  134. data/generated/google/apis/toolresults_v1beta3/classes.rb +13 -0
  135. data/generated/google/apis/toolresults_v1beta3/representations.rb +12 -0
  136. data/generated/google/apis/translate_v3.rb +1 -1
  137. data/generated/google/apis/translate_v3/classes.rb +2 -1
  138. data/generated/google/apis/translate_v3beta1.rb +1 -1
  139. data/generated/google/apis/translate_v3beta1/classes.rb +2 -1
  140. data/generated/google/apis/vision_v1.rb +1 -1
  141. data/generated/google/apis/vision_v1/classes.rb +16 -16
  142. data/generated/google/apis/vision_v1p1beta1.rb +1 -1
  143. data/generated/google/apis/vision_v1p1beta1/classes.rb +16 -16
  144. data/generated/google/apis/vision_v1p2beta1.rb +1 -1
  145. data/generated/google/apis/vision_v1p2beta1/classes.rb +16 -16
  146. data/generated/google/apis/youtube_v3.rb +1 -1
  147. data/generated/google/apis/youtube_v3/service.rb +2 -2
  148. data/lib/google/apis/version.rb +1 -1
  149. metadata +16 -3
@@ -27,7 +27,7 @@ module Google
27
27
  # @see https://cloud.google.com/recommendations-ai/docs
28
28
  module RecommendationengineV1beta1
29
29
  VERSION = 'V1beta1'
30
- REVISION = '20200810'
30
+ REVISION = '20201027'
31
31
 
32
32
  # View and manage your data across Google Cloud Platform services
33
33
  AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
@@ -1562,6 +1562,19 @@ module Google
1562
1562
  end
1563
1563
  end
1564
1564
 
1565
+ # Metadata for RejoinUserEvents method.
1566
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsMetadata
1567
+ include Google::Apis::Core::Hashable
1568
+
1569
+ def initialize(**args)
1570
+ update!(**args)
1571
+ end
1572
+
1573
+ # Update properties of this object
1574
+ def update!(**args)
1575
+ end
1576
+ end
1577
+
1565
1578
  # Request message for CatalogRejoin method.
1566
1579
  class GoogleCloudRecommendationengineV1beta1RejoinUserEventsRequest
1567
1580
  include Google::Apis::Core::Hashable
@@ -1582,6 +1595,25 @@ module Google
1582
1595
  end
1583
1596
  end
1584
1597
 
1598
+ # Response message for RejoinUserEvents method.
1599
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsResponse
1600
+ include Google::Apis::Core::Hashable
1601
+
1602
+ # Number of user events that were joined with latest catalog items.
1603
+ # Corresponds to the JSON property `rejoinedUserEventsCount`
1604
+ # @return [Fixnum]
1605
+ attr_accessor :rejoined_user_events_count
1606
+
1607
+ def initialize(**args)
1608
+ update!(**args)
1609
+ end
1610
+
1611
+ # Update properties of this object
1612
+ def update!(**args)
1613
+ @rejoined_user_events_count = args[:rejoined_user_events_count] if args.key?(:rejoined_user_events_count)
1614
+ end
1615
+ end
1616
+
1585
1617
  # UserEvent captures all metadata information recommendation engine needs to
1586
1618
  # know about how end users interact with customers' website.
1587
1619
  class GoogleCloudRecommendationengineV1beta1UserEvent
@@ -274,12 +274,24 @@ module Google
274
274
  include Google::Apis::Core::JsonObjectSupport
275
275
  end
276
276
 
277
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsMetadata
278
+ class Representation < Google::Apis::Core::JsonRepresentation; end
279
+
280
+ include Google::Apis::Core::JsonObjectSupport
281
+ end
282
+
277
283
  class GoogleCloudRecommendationengineV1beta1RejoinUserEventsRequest
278
284
  class Representation < Google::Apis::Core::JsonRepresentation; end
279
285
 
280
286
  include Google::Apis::Core::JsonObjectSupport
281
287
  end
282
288
 
289
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsResponse
290
+ class Representation < Google::Apis::Core::JsonRepresentation; end
291
+
292
+ include Google::Apis::Core::JsonObjectSupport
293
+ end
294
+
283
295
  class GoogleCloudRecommendationengineV1beta1UserEvent
284
296
  class Representation < Google::Apis::Core::JsonRepresentation; end
285
297
 
@@ -743,6 +755,12 @@ module Google
743
755
  end
744
756
  end
745
757
 
758
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsMetadata
759
+ # @private
760
+ class Representation < Google::Apis::Core::JsonRepresentation
761
+ end
762
+ end
763
+
746
764
  class GoogleCloudRecommendationengineV1beta1RejoinUserEventsRequest
747
765
  # @private
748
766
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -750,6 +768,13 @@ module Google
750
768
  end
751
769
  end
752
770
 
771
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsResponse
772
+ # @private
773
+ class Representation < Google::Apis::Core::JsonRepresentation
774
+ property :rejoined_user_events_count, :numeric_string => true, as: 'rejoinedUserEventsCount'
775
+ end
776
+ end
777
+
753
778
  class GoogleCloudRecommendationengineV1beta1UserEvent
754
779
  # @private
755
780
  class Representation < Google::Apis::Core::JsonRepresentation
@@ -28,7 +28,7 @@ module Google
28
28
  # @see https://cloud.google.com/deployment-manager/runtime-configurator/
29
29
  module RuntimeconfigV1beta1
30
30
  VERSION = 'V1beta1'
31
- REVISION = '20200831'
31
+ REVISION = '20201026'
32
32
 
33
33
  # View and manage your data across Google Cloud Platform services
34
34
  AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
@@ -26,8 +26,7 @@ module Google
26
26
  class Binding
27
27
  include Google::Apis::Core::Hashable
28
28
 
29
- # A client-specified ID for this binding. Expected to be globally unique to
30
- # support the internal bindings-by-ID API.
29
+ #
31
30
  # Corresponds to the JSON property `bindingId`
32
31
  # @return [String]
33
32
  attr_accessor :binding_id
@@ -0,0 +1,35 @@
1
+ # Copyright 2015 Google Inc.
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 'google/apis/safebrowsing_v4/service.rb'
16
+ require 'google/apis/safebrowsing_v4/classes.rb'
17
+ require 'google/apis/safebrowsing_v4/representations.rb'
18
+
19
+ module Google
20
+ module Apis
21
+ # Safe Browsing API
22
+ #
23
+ # Enables client applications to check web resources (most commonly URLs)
24
+ # against Google-generated lists of unsafe web resources. The Safe Browsing APIs
25
+ # are for non-commercial use only. If you need to use APIs to detect malicious
26
+ # URLs for commercial purposes – meaning “for sale or revenue-generating
27
+ # purposes” – please refer to the Web Risk API.
28
+ #
29
+ # @see https://developers.google.com/safe-browsing/
30
+ module SafebrowsingV4
31
+ VERSION = 'V4'
32
+ REVISION = '20201017'
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,909 @@
1
+ # Copyright 2015 Google Inc.
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 SafebrowsingV4
24
+
25
+ # The expected state of a client's local database.
26
+ class Checksum
27
+ include Google::Apis::Core::Hashable
28
+
29
+ # The SHA256 hash of the client state; that is, of the sorted list of all hashes
30
+ # present in the database.
31
+ # Corresponds to the JSON property `sha256`
32
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
33
+ # @return [String]
34
+ attr_accessor :sha256
35
+
36
+ def initialize(**args)
37
+ update!(**args)
38
+ end
39
+
40
+ # Update properties of this object
41
+ def update!(**args)
42
+ @sha256 = args[:sha256] if args.key?(:sha256)
43
+ end
44
+ end
45
+
46
+ # The client metadata associated with Safe Browsing API requests.
47
+ class ClientInfo
48
+ include Google::Apis::Core::Hashable
49
+
50
+ # A client ID that (hopefully) uniquely identifies the client implementation of
51
+ # the Safe Browsing API.
52
+ # Corresponds to the JSON property `clientId`
53
+ # @return [String]
54
+ attr_accessor :client_id
55
+
56
+ # The version of the client implementation.
57
+ # Corresponds to the JSON property `clientVersion`
58
+ # @return [String]
59
+ attr_accessor :client_version
60
+
61
+ def initialize(**args)
62
+ update!(**args)
63
+ end
64
+
65
+ # Update properties of this object
66
+ def update!(**args)
67
+ @client_id = args[:client_id] if args.key?(:client_id)
68
+ @client_version = args[:client_version] if args.key?(:client_version)
69
+ end
70
+ end
71
+
72
+ # The constraints for this update.
73
+ class Constraints
74
+ include Google::Apis::Core::Hashable
75
+
76
+ # A client's physical location, expressed as a ISO 31166-1 alpha-2 region code.
77
+ # Corresponds to the JSON property `deviceLocation`
78
+ # @return [String]
79
+ attr_accessor :device_location
80
+
81
+ # Requests the lists for a specific language. Expects ISO 639 alpha-2 format.
82
+ # Corresponds to the JSON property `language`
83
+ # @return [String]
84
+ attr_accessor :language
85
+
86
+ # Sets the maximum number of entries that the client is willing to have in the
87
+ # local database for the specified list. This should be a power of 2 between 2**
88
+ # 10 and 2**20. If zero, no database size limit is set.
89
+ # Corresponds to the JSON property `maxDatabaseEntries`
90
+ # @return [Fixnum]
91
+ attr_accessor :max_database_entries
92
+
93
+ # The maximum size in number of entries. The update will not contain more
94
+ # entries than this value. This should be a power of 2 between 2**10 and 2**20.
95
+ # If zero, no update size limit is set.
96
+ # Corresponds to the JSON property `maxUpdateEntries`
97
+ # @return [Fixnum]
98
+ attr_accessor :max_update_entries
99
+
100
+ # Requests the list for a specific geographic location. If not set the server
101
+ # may pick that value based on the user's IP address. Expects ISO 3166-1 alpha-2
102
+ # format.
103
+ # Corresponds to the JSON property `region`
104
+ # @return [String]
105
+ attr_accessor :region
106
+
107
+ # The compression types supported by the client.
108
+ # Corresponds to the JSON property `supportedCompressions`
109
+ # @return [Array<String>]
110
+ attr_accessor :supported_compressions
111
+
112
+ def initialize(**args)
113
+ update!(**args)
114
+ end
115
+
116
+ # Update properties of this object
117
+ def update!(**args)
118
+ @device_location = args[:device_location] if args.key?(:device_location)
119
+ @language = args[:language] if args.key?(:language)
120
+ @max_database_entries = args[:max_database_entries] if args.key?(:max_database_entries)
121
+ @max_update_entries = args[:max_update_entries] if args.key?(:max_update_entries)
122
+ @region = args[:region] if args.key?(:region)
123
+ @supported_compressions = args[:supported_compressions] if args.key?(:supported_compressions)
124
+ end
125
+ end
126
+
127
+ # A generic empty message that you can re-use to avoid defining duplicated empty
128
+ # messages in your APIs. A typical example is to use it as the request or the
129
+ # response type of an API method. For instance: service Foo ` rpc Bar(google.
130
+ # protobuf.Empty) returns (google.protobuf.Empty); ` The JSON representation for
131
+ # `Empty` is empty JSON object ````.
132
+ class Empty
133
+ include Google::Apis::Core::Hashable
134
+
135
+ def initialize(**args)
136
+ update!(**args)
137
+ end
138
+
139
+ # Update properties of this object
140
+ def update!(**args)
141
+ end
142
+ end
143
+
144
+ # Describes a Safe Browsing API update request. Clients can request updates for
145
+ # multiple lists in a single request. NOTE: Field index 2 is unused. NEXT: 5
146
+ class FetchThreatListUpdatesRequest
147
+ include Google::Apis::Core::Hashable
148
+
149
+ # The client metadata associated with Safe Browsing API requests.
150
+ # Corresponds to the JSON property `client`
151
+ # @return [Google::Apis::SafebrowsingV4::ClientInfo]
152
+ attr_accessor :client
153
+
154
+ # The requested threat list updates.
155
+ # Corresponds to the JSON property `listUpdateRequests`
156
+ # @return [Array<Google::Apis::SafebrowsingV4::ListUpdateRequest>]
157
+ attr_accessor :list_update_requests
158
+
159
+ def initialize(**args)
160
+ update!(**args)
161
+ end
162
+
163
+ # Update properties of this object
164
+ def update!(**args)
165
+ @client = args[:client] if args.key?(:client)
166
+ @list_update_requests = args[:list_update_requests] if args.key?(:list_update_requests)
167
+ end
168
+ end
169
+
170
+ #
171
+ class FetchThreatListUpdatesResponse
172
+ include Google::Apis::Core::Hashable
173
+
174
+ # The list updates requested by the clients.
175
+ # Corresponds to the JSON property `listUpdateResponses`
176
+ # @return [Array<Google::Apis::SafebrowsingV4::ListUpdateResponse>]
177
+ attr_accessor :list_update_responses
178
+
179
+ # The minimum duration the client must wait before issuing any update request.
180
+ # If this field is not set clients may update as soon as they want.
181
+ # Corresponds to the JSON property `minimumWaitDuration`
182
+ # @return [String]
183
+ attr_accessor :minimum_wait_duration
184
+
185
+ def initialize(**args)
186
+ update!(**args)
187
+ end
188
+
189
+ # Update properties of this object
190
+ def update!(**args)
191
+ @list_update_responses = args[:list_update_responses] if args.key?(:list_update_responses)
192
+ @minimum_wait_duration = args[:minimum_wait_duration] if args.key?(:minimum_wait_duration)
193
+ end
194
+ end
195
+
196
+ # Request to return full hashes matched by the provided hash prefixes.
197
+ class FindFullHashesRequest
198
+ include Google::Apis::Core::Hashable
199
+
200
+ # The client metadata associated with Safe Browsing API requests.
201
+ # Corresponds to the JSON property `apiClient`
202
+ # @return [Google::Apis::SafebrowsingV4::ClientInfo]
203
+ attr_accessor :api_client
204
+
205
+ # The client metadata associated with Safe Browsing API requests.
206
+ # Corresponds to the JSON property `client`
207
+ # @return [Google::Apis::SafebrowsingV4::ClientInfo]
208
+ attr_accessor :client
209
+
210
+ # The current client states for each of the client's local threat lists.
211
+ # Corresponds to the JSON property `clientStates`
212
+ # @return [Array<String>]
213
+ attr_accessor :client_states
214
+
215
+ # The information regarding one or more threats that a client submits when
216
+ # checking for matches in threat lists.
217
+ # Corresponds to the JSON property `threatInfo`
218
+ # @return [Google::Apis::SafebrowsingV4::ThreatInfo]
219
+ attr_accessor :threat_info
220
+
221
+ def initialize(**args)
222
+ update!(**args)
223
+ end
224
+
225
+ # Update properties of this object
226
+ def update!(**args)
227
+ @api_client = args[:api_client] if args.key?(:api_client)
228
+ @client = args[:client] if args.key?(:client)
229
+ @client_states = args[:client_states] if args.key?(:client_states)
230
+ @threat_info = args[:threat_info] if args.key?(:threat_info)
231
+ end
232
+ end
233
+
234
+ #
235
+ class FindFullHashesResponse
236
+ include Google::Apis::Core::Hashable
237
+
238
+ # The full hashes that matched the requested prefixes.
239
+ # Corresponds to the JSON property `matches`
240
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatMatch>]
241
+ attr_accessor :matches
242
+
243
+ # The minimum duration the client must wait before issuing any find hashes
244
+ # request. If this field is not set, clients can issue a request as soon as they
245
+ # want.
246
+ # Corresponds to the JSON property `minimumWaitDuration`
247
+ # @return [String]
248
+ attr_accessor :minimum_wait_duration
249
+
250
+ # For requested entities that did not match the threat list, how long to cache
251
+ # the response.
252
+ # Corresponds to the JSON property `negativeCacheDuration`
253
+ # @return [String]
254
+ attr_accessor :negative_cache_duration
255
+
256
+ def initialize(**args)
257
+ update!(**args)
258
+ end
259
+
260
+ # Update properties of this object
261
+ def update!(**args)
262
+ @matches = args[:matches] if args.key?(:matches)
263
+ @minimum_wait_duration = args[:minimum_wait_duration] if args.key?(:minimum_wait_duration)
264
+ @negative_cache_duration = args[:negative_cache_duration] if args.key?(:negative_cache_duration)
265
+ end
266
+ end
267
+
268
+ # Request to check entries against lists.
269
+ class FindThreatMatchesRequest
270
+ include Google::Apis::Core::Hashable
271
+
272
+ # The client metadata associated with Safe Browsing API requests.
273
+ # Corresponds to the JSON property `client`
274
+ # @return [Google::Apis::SafebrowsingV4::ClientInfo]
275
+ attr_accessor :client
276
+
277
+ # The information regarding one or more threats that a client submits when
278
+ # checking for matches in threat lists.
279
+ # Corresponds to the JSON property `threatInfo`
280
+ # @return [Google::Apis::SafebrowsingV4::ThreatInfo]
281
+ attr_accessor :threat_info
282
+
283
+ def initialize(**args)
284
+ update!(**args)
285
+ end
286
+
287
+ # Update properties of this object
288
+ def update!(**args)
289
+ @client = args[:client] if args.key?(:client)
290
+ @threat_info = args[:threat_info] if args.key?(:threat_info)
291
+ end
292
+ end
293
+
294
+ #
295
+ class FindThreatMatchesResponse
296
+ include Google::Apis::Core::Hashable
297
+
298
+ # The threat list matches.
299
+ # Corresponds to the JSON property `matches`
300
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatMatch>]
301
+ attr_accessor :matches
302
+
303
+ def initialize(**args)
304
+ update!(**args)
305
+ end
306
+
307
+ # Update properties of this object
308
+ def update!(**args)
309
+ @matches = args[:matches] if args.key?(:matches)
310
+ end
311
+ end
312
+
313
+ #
314
+ class ListThreatListsResponse
315
+ include Google::Apis::Core::Hashable
316
+
317
+ # The lists available for download by the client.
318
+ # Corresponds to the JSON property `threatLists`
319
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatListDescriptor>]
320
+ attr_accessor :threat_lists
321
+
322
+ def initialize(**args)
323
+ update!(**args)
324
+ end
325
+
326
+ # Update properties of this object
327
+ def update!(**args)
328
+ @threat_lists = args[:threat_lists] if args.key?(:threat_lists)
329
+ end
330
+ end
331
+
332
+ # A single list update request.
333
+ class ListUpdateRequest
334
+ include Google::Apis::Core::Hashable
335
+
336
+ # The constraints for this update.
337
+ # Corresponds to the JSON property `constraints`
338
+ # @return [Google::Apis::SafebrowsingV4::Constraints]
339
+ attr_accessor :constraints
340
+
341
+ # The type of platform at risk by entries present in the list.
342
+ # Corresponds to the JSON property `platformType`
343
+ # @return [String]
344
+ attr_accessor :platform_type
345
+
346
+ # The current state of the client for the requested list (the encrypted client
347
+ # state that was received from the last successful list update).
348
+ # Corresponds to the JSON property `state`
349
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
350
+ # @return [String]
351
+ attr_accessor :state
352
+
353
+ # The types of entries present in the list.
354
+ # Corresponds to the JSON property `threatEntryType`
355
+ # @return [String]
356
+ attr_accessor :threat_entry_type
357
+
358
+ # The type of threat posed by entries present in the list.
359
+ # Corresponds to the JSON property `threatType`
360
+ # @return [String]
361
+ attr_accessor :threat_type
362
+
363
+ def initialize(**args)
364
+ update!(**args)
365
+ end
366
+
367
+ # Update properties of this object
368
+ def update!(**args)
369
+ @constraints = args[:constraints] if args.key?(:constraints)
370
+ @platform_type = args[:platform_type] if args.key?(:platform_type)
371
+ @state = args[:state] if args.key?(:state)
372
+ @threat_entry_type = args[:threat_entry_type] if args.key?(:threat_entry_type)
373
+ @threat_type = args[:threat_type] if args.key?(:threat_type)
374
+ end
375
+ end
376
+
377
+ # An update to an individual list.
378
+ class ListUpdateResponse
379
+ include Google::Apis::Core::Hashable
380
+
381
+ # A set of entries to add to a local threat type's list. Repeated to allow for a
382
+ # combination of compressed and raw data to be sent in a single response.
383
+ # Corresponds to the JSON property `additions`
384
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatEntrySet>]
385
+ attr_accessor :additions
386
+
387
+ # The expected state of a client's local database.
388
+ # Corresponds to the JSON property `checksum`
389
+ # @return [Google::Apis::SafebrowsingV4::Checksum]
390
+ attr_accessor :checksum
391
+
392
+ # The new client state, in encrypted format. Opaque to clients.
393
+ # Corresponds to the JSON property `newClientState`
394
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
395
+ # @return [String]
396
+ attr_accessor :new_client_state
397
+
398
+ # The platform type for which data is returned.
399
+ # Corresponds to the JSON property `platformType`
400
+ # @return [String]
401
+ attr_accessor :platform_type
402
+
403
+ # A set of entries to remove from a local threat type's list. In practice, this
404
+ # field is empty or contains exactly one ThreatEntrySet.
405
+ # Corresponds to the JSON property `removals`
406
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatEntrySet>]
407
+ attr_accessor :removals
408
+
409
+ # The type of response. This may indicate that an action is required by the
410
+ # client when the response is received.
411
+ # Corresponds to the JSON property `responseType`
412
+ # @return [String]
413
+ attr_accessor :response_type
414
+
415
+ # The format of the threats.
416
+ # Corresponds to the JSON property `threatEntryType`
417
+ # @return [String]
418
+ attr_accessor :threat_entry_type
419
+
420
+ # The threat type for which data is returned.
421
+ # Corresponds to the JSON property `threatType`
422
+ # @return [String]
423
+ attr_accessor :threat_type
424
+
425
+ def initialize(**args)
426
+ update!(**args)
427
+ end
428
+
429
+ # Update properties of this object
430
+ def update!(**args)
431
+ @additions = args[:additions] if args.key?(:additions)
432
+ @checksum = args[:checksum] if args.key?(:checksum)
433
+ @new_client_state = args[:new_client_state] if args.key?(:new_client_state)
434
+ @platform_type = args[:platform_type] if args.key?(:platform_type)
435
+ @removals = args[:removals] if args.key?(:removals)
436
+ @response_type = args[:response_type] if args.key?(:response_type)
437
+ @threat_entry_type = args[:threat_entry_type] if args.key?(:threat_entry_type)
438
+ @threat_type = args[:threat_type] if args.key?(:threat_type)
439
+ end
440
+ end
441
+
442
+ # A single metadata entry.
443
+ class MetadataEntry
444
+ include Google::Apis::Core::Hashable
445
+
446
+ # The metadata entry key. For JSON requests, the key is base64-encoded.
447
+ # Corresponds to the JSON property `key`
448
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
449
+ # @return [String]
450
+ attr_accessor :key
451
+
452
+ # The metadata entry value. For JSON requests, the value is base64-encoded.
453
+ # Corresponds to the JSON property `value`
454
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
455
+ # @return [String]
456
+ attr_accessor :value
457
+
458
+ def initialize(**args)
459
+ update!(**args)
460
+ end
461
+
462
+ # Update properties of this object
463
+ def update!(**args)
464
+ @key = args[:key] if args.key?(:key)
465
+ @value = args[:value] if args.key?(:value)
466
+ end
467
+ end
468
+
469
+ # The uncompressed threat entries in hash format of a particular prefix length.
470
+ # Hashes can be anywhere from 4 to 32 bytes in size. A large majority are 4
471
+ # bytes, but some hashes are lengthened if they collide with the hash of a
472
+ # popular URL. Used for sending ThreatEntrySet to clients that do not support
473
+ # compression, or when sending non-4-byte hashes to clients that do support
474
+ # compression.
475
+ class RawHashes
476
+ include Google::Apis::Core::Hashable
477
+
478
+ # The number of bytes for each prefix encoded below. This field can be anywhere
479
+ # from 4 (shortest prefix) to 32 (full SHA256 hash).
480
+ # Corresponds to the JSON property `prefixSize`
481
+ # @return [Fixnum]
482
+ attr_accessor :prefix_size
483
+
484
+ # The hashes, in binary format, concatenated into one long string. Hashes are
485
+ # sorted in lexicographic order. For JSON API users, hashes are base64-encoded.
486
+ # Corresponds to the JSON property `rawHashes`
487
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
488
+ # @return [String]
489
+ attr_accessor :raw_hashes
490
+
491
+ def initialize(**args)
492
+ update!(**args)
493
+ end
494
+
495
+ # Update properties of this object
496
+ def update!(**args)
497
+ @prefix_size = args[:prefix_size] if args.key?(:prefix_size)
498
+ @raw_hashes = args[:raw_hashes] if args.key?(:raw_hashes)
499
+ end
500
+ end
501
+
502
+ # A set of raw indices to remove from a local list.
503
+ class RawIndices
504
+ include Google::Apis::Core::Hashable
505
+
506
+ # The indices to remove from a lexicographically-sorted local list.
507
+ # Corresponds to the JSON property `indices`
508
+ # @return [Array<Fixnum>]
509
+ attr_accessor :indices
510
+
511
+ def initialize(**args)
512
+ update!(**args)
513
+ end
514
+
515
+ # Update properties of this object
516
+ def update!(**args)
517
+ @indices = args[:indices] if args.key?(:indices)
518
+ end
519
+ end
520
+
521
+ # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or
522
+ # compressed removal indices.
523
+ class RiceDeltaEncoding
524
+ include Google::Apis::Core::Hashable
525
+
526
+ # The encoded deltas that are encoded using the Golomb-Rice coder.
527
+ # Corresponds to the JSON property `encodedData`
528
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
529
+ # @return [String]
530
+ attr_accessor :encoded_data
531
+
532
+ # The offset of the first entry in the encoded data, or, if only a single
533
+ # integer was encoded, that single integer's value. If the field is empty or
534
+ # missing, assume zero.
535
+ # Corresponds to the JSON property `firstValue`
536
+ # @return [Fixnum]
537
+ attr_accessor :first_value
538
+
539
+ # The number of entries that are delta encoded in the encoded data. If only a
540
+ # single integer was encoded, this will be zero and the single value will be
541
+ # stored in `first_value`.
542
+ # Corresponds to the JSON property `numEntries`
543
+ # @return [Fixnum]
544
+ attr_accessor :num_entries
545
+
546
+ # The Golomb-Rice parameter, which is a number between 2 and 28. This field is
547
+ # missing (that is, zero) if `num_entries` is zero.
548
+ # Corresponds to the JSON property `riceParameter`
549
+ # @return [Fixnum]
550
+ attr_accessor :rice_parameter
551
+
552
+ def initialize(**args)
553
+ update!(**args)
554
+ end
555
+
556
+ # Update properties of this object
557
+ def update!(**args)
558
+ @encoded_data = args[:encoded_data] if args.key?(:encoded_data)
559
+ @first_value = args[:first_value] if args.key?(:first_value)
560
+ @num_entries = args[:num_entries] if args.key?(:num_entries)
561
+ @rice_parameter = args[:rice_parameter] if args.key?(:rice_parameter)
562
+ end
563
+ end
564
+
565
+ # An individual threat; for example, a malicious URL or its hash representation.
566
+ # Only one of these fields should be set.
567
+ class ThreatEntry
568
+ include Google::Apis::Core::Hashable
569
+
570
+ # The digest of an executable in SHA256 format. The API supports both binary and
571
+ # hex digests. For JSON requests, digests are base64-encoded.
572
+ # Corresponds to the JSON property `digest`
573
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
574
+ # @return [String]
575
+ attr_accessor :digest
576
+
577
+ # A hash prefix, consisting of the most significant 4-32 bytes of a SHA256 hash.
578
+ # This field is in binary format. For JSON requests, hashes are base64-encoded.
579
+ # Corresponds to the JSON property `hash`
580
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
581
+ # @return [String]
582
+ attr_accessor :hash_prop
583
+
584
+ # A URL.
585
+ # Corresponds to the JSON property `url`
586
+ # @return [String]
587
+ attr_accessor :url
588
+
589
+ def initialize(**args)
590
+ update!(**args)
591
+ end
592
+
593
+ # Update properties of this object
594
+ def update!(**args)
595
+ @digest = args[:digest] if args.key?(:digest)
596
+ @hash_prop = args[:hash_prop] if args.key?(:hash_prop)
597
+ @url = args[:url] if args.key?(:url)
598
+ end
599
+ end
600
+
601
+ # The metadata associated with a specific threat entry. The client is expected
602
+ # to know the metadata key/value pairs associated with each threat type.
603
+ class ThreatEntryMetadata
604
+ include Google::Apis::Core::Hashable
605
+
606
+ # The metadata entries.
607
+ # Corresponds to the JSON property `entries`
608
+ # @return [Array<Google::Apis::SafebrowsingV4::MetadataEntry>]
609
+ attr_accessor :entries
610
+
611
+ def initialize(**args)
612
+ update!(**args)
613
+ end
614
+
615
+ # Update properties of this object
616
+ def update!(**args)
617
+ @entries = args[:entries] if args.key?(:entries)
618
+ end
619
+ end
620
+
621
+ # A set of threats that should be added or removed from a client's local
622
+ # database.
623
+ class ThreatEntrySet
624
+ include Google::Apis::Core::Hashable
625
+
626
+ # The compression type for the entries in this set.
627
+ # Corresponds to the JSON property `compressionType`
628
+ # @return [String]
629
+ attr_accessor :compression_type
630
+
631
+ # The uncompressed threat entries in hash format of a particular prefix length.
632
+ # Hashes can be anywhere from 4 to 32 bytes in size. A large majority are 4
633
+ # bytes, but some hashes are lengthened if they collide with the hash of a
634
+ # popular URL. Used for sending ThreatEntrySet to clients that do not support
635
+ # compression, or when sending non-4-byte hashes to clients that do support
636
+ # compression.
637
+ # Corresponds to the JSON property `rawHashes`
638
+ # @return [Google::Apis::SafebrowsingV4::RawHashes]
639
+ attr_accessor :raw_hashes
640
+
641
+ # A set of raw indices to remove from a local list.
642
+ # Corresponds to the JSON property `rawIndices`
643
+ # @return [Google::Apis::SafebrowsingV4::RawIndices]
644
+ attr_accessor :raw_indices
645
+
646
+ # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or
647
+ # compressed removal indices.
648
+ # Corresponds to the JSON property `riceHashes`
649
+ # @return [Google::Apis::SafebrowsingV4::RiceDeltaEncoding]
650
+ attr_accessor :rice_hashes
651
+
652
+ # The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or
653
+ # compressed removal indices.
654
+ # Corresponds to the JSON property `riceIndices`
655
+ # @return [Google::Apis::SafebrowsingV4::RiceDeltaEncoding]
656
+ attr_accessor :rice_indices
657
+
658
+ def initialize(**args)
659
+ update!(**args)
660
+ end
661
+
662
+ # Update properties of this object
663
+ def update!(**args)
664
+ @compression_type = args[:compression_type] if args.key?(:compression_type)
665
+ @raw_hashes = args[:raw_hashes] if args.key?(:raw_hashes)
666
+ @raw_indices = args[:raw_indices] if args.key?(:raw_indices)
667
+ @rice_hashes = args[:rice_hashes] if args.key?(:rice_hashes)
668
+ @rice_indices = args[:rice_indices] if args.key?(:rice_indices)
669
+ end
670
+ end
671
+
672
+ #
673
+ class ThreatHit
674
+ include Google::Apis::Core::Hashable
675
+
676
+ # The client metadata associated with Safe Browsing API requests.
677
+ # Corresponds to the JSON property `clientInfo`
678
+ # @return [Google::Apis::SafebrowsingV4::ClientInfo]
679
+ attr_accessor :client_info
680
+
681
+ # An individual threat; for example, a malicious URL or its hash representation.
682
+ # Only one of these fields should be set.
683
+ # Corresponds to the JSON property `entry`
684
+ # @return [Google::Apis::SafebrowsingV4::ThreatEntry]
685
+ attr_accessor :entry
686
+
687
+ # The platform type reported.
688
+ # Corresponds to the JSON property `platformType`
689
+ # @return [String]
690
+ attr_accessor :platform_type
691
+
692
+ # The resources related to the threat hit.
693
+ # Corresponds to the JSON property `resources`
694
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatSource>]
695
+ attr_accessor :resources
696
+
697
+ # The threat type reported.
698
+ # Corresponds to the JSON property `threatType`
699
+ # @return [String]
700
+ attr_accessor :threat_type
701
+
702
+ # Details about the user that encountered the threat.
703
+ # Corresponds to the JSON property `userInfo`
704
+ # @return [Google::Apis::SafebrowsingV4::UserInfo]
705
+ attr_accessor :user_info
706
+
707
+ def initialize(**args)
708
+ update!(**args)
709
+ end
710
+
711
+ # Update properties of this object
712
+ def update!(**args)
713
+ @client_info = args[:client_info] if args.key?(:client_info)
714
+ @entry = args[:entry] if args.key?(:entry)
715
+ @platform_type = args[:platform_type] if args.key?(:platform_type)
716
+ @resources = args[:resources] if args.key?(:resources)
717
+ @threat_type = args[:threat_type] if args.key?(:threat_type)
718
+ @user_info = args[:user_info] if args.key?(:user_info)
719
+ end
720
+ end
721
+
722
+ # The information regarding one or more threats that a client submits when
723
+ # checking for matches in threat lists.
724
+ class ThreatInfo
725
+ include Google::Apis::Core::Hashable
726
+
727
+ # The platform types to be checked.
728
+ # Corresponds to the JSON property `platformTypes`
729
+ # @return [Array<String>]
730
+ attr_accessor :platform_types
731
+
732
+ # The threat entries to be checked.
733
+ # Corresponds to the JSON property `threatEntries`
734
+ # @return [Array<Google::Apis::SafebrowsingV4::ThreatEntry>]
735
+ attr_accessor :threat_entries
736
+
737
+ # The entry types to be checked.
738
+ # Corresponds to the JSON property `threatEntryTypes`
739
+ # @return [Array<String>]
740
+ attr_accessor :threat_entry_types
741
+
742
+ # The threat types to be checked.
743
+ # Corresponds to the JSON property `threatTypes`
744
+ # @return [Array<String>]
745
+ attr_accessor :threat_types
746
+
747
+ def initialize(**args)
748
+ update!(**args)
749
+ end
750
+
751
+ # Update properties of this object
752
+ def update!(**args)
753
+ @platform_types = args[:platform_types] if args.key?(:platform_types)
754
+ @threat_entries = args[:threat_entries] if args.key?(:threat_entries)
755
+ @threat_entry_types = args[:threat_entry_types] if args.key?(:threat_entry_types)
756
+ @threat_types = args[:threat_types] if args.key?(:threat_types)
757
+ end
758
+ end
759
+
760
+ # Describes an individual threat list. A list is defined by three parameters:
761
+ # the type of threat posed, the type of platform targeted by the threat, and the
762
+ # type of entries in the list.
763
+ class ThreatListDescriptor
764
+ include Google::Apis::Core::Hashable
765
+
766
+ # The platform type targeted by the list's entries.
767
+ # Corresponds to the JSON property `platformType`
768
+ # @return [String]
769
+ attr_accessor :platform_type
770
+
771
+ # The entry types contained in the list.
772
+ # Corresponds to the JSON property `threatEntryType`
773
+ # @return [String]
774
+ attr_accessor :threat_entry_type
775
+
776
+ # The threat type posed by the list's entries.
777
+ # Corresponds to the JSON property `threatType`
778
+ # @return [String]
779
+ attr_accessor :threat_type
780
+
781
+ def initialize(**args)
782
+ update!(**args)
783
+ end
784
+
785
+ # Update properties of this object
786
+ def update!(**args)
787
+ @platform_type = args[:platform_type] if args.key?(:platform_type)
788
+ @threat_entry_type = args[:threat_entry_type] if args.key?(:threat_entry_type)
789
+ @threat_type = args[:threat_type] if args.key?(:threat_type)
790
+ end
791
+ end
792
+
793
+ # A match when checking a threat entry in the Safe Browsing threat lists.
794
+ class ThreatMatch
795
+ include Google::Apis::Core::Hashable
796
+
797
+ # The cache lifetime for the returned match. Clients must not cache this
798
+ # response for more than this duration to avoid false positives.
799
+ # Corresponds to the JSON property `cacheDuration`
800
+ # @return [String]
801
+ attr_accessor :cache_duration
802
+
803
+ # The platform type matching this threat.
804
+ # Corresponds to the JSON property `platformType`
805
+ # @return [String]
806
+ attr_accessor :platform_type
807
+
808
+ # An individual threat; for example, a malicious URL or its hash representation.
809
+ # Only one of these fields should be set.
810
+ # Corresponds to the JSON property `threat`
811
+ # @return [Google::Apis::SafebrowsingV4::ThreatEntry]
812
+ attr_accessor :threat
813
+
814
+ # The metadata associated with a specific threat entry. The client is expected
815
+ # to know the metadata key/value pairs associated with each threat type.
816
+ # Corresponds to the JSON property `threatEntryMetadata`
817
+ # @return [Google::Apis::SafebrowsingV4::ThreatEntryMetadata]
818
+ attr_accessor :threat_entry_metadata
819
+
820
+ # The threat entry type matching this threat.
821
+ # Corresponds to the JSON property `threatEntryType`
822
+ # @return [String]
823
+ attr_accessor :threat_entry_type
824
+
825
+ # The threat type matching this threat.
826
+ # Corresponds to the JSON property `threatType`
827
+ # @return [String]
828
+ attr_accessor :threat_type
829
+
830
+ def initialize(**args)
831
+ update!(**args)
832
+ end
833
+
834
+ # Update properties of this object
835
+ def update!(**args)
836
+ @cache_duration = args[:cache_duration] if args.key?(:cache_duration)
837
+ @platform_type = args[:platform_type] if args.key?(:platform_type)
838
+ @threat = args[:threat] if args.key?(:threat)
839
+ @threat_entry_metadata = args[:threat_entry_metadata] if args.key?(:threat_entry_metadata)
840
+ @threat_entry_type = args[:threat_entry_type] if args.key?(:threat_entry_type)
841
+ @threat_type = args[:threat_type] if args.key?(:threat_type)
842
+ end
843
+ end
844
+
845
+ # A single resource related to a threat hit.
846
+ class ThreatSource
847
+ include Google::Apis::Core::Hashable
848
+
849
+ # Referrer of the resource. Only set if the referrer is available.
850
+ # Corresponds to the JSON property `referrer`
851
+ # @return [String]
852
+ attr_accessor :referrer
853
+
854
+ # The remote IP of the resource in ASCII format. Either IPv4 or IPv6.
855
+ # Corresponds to the JSON property `remoteIp`
856
+ # @return [String]
857
+ attr_accessor :remote_ip
858
+
859
+ # The type of source reported.
860
+ # Corresponds to the JSON property `type`
861
+ # @return [String]
862
+ attr_accessor :type
863
+
864
+ # The URL of the resource.
865
+ # Corresponds to the JSON property `url`
866
+ # @return [String]
867
+ attr_accessor :url
868
+
869
+ def initialize(**args)
870
+ update!(**args)
871
+ end
872
+
873
+ # Update properties of this object
874
+ def update!(**args)
875
+ @referrer = args[:referrer] if args.key?(:referrer)
876
+ @remote_ip = args[:remote_ip] if args.key?(:remote_ip)
877
+ @type = args[:type] if args.key?(:type)
878
+ @url = args[:url] if args.key?(:url)
879
+ end
880
+ end
881
+
882
+ # Details about the user that encountered the threat.
883
+ class UserInfo
884
+ include Google::Apis::Core::Hashable
885
+
886
+ # The UN M.49 region code associated with the user's location.
887
+ # Corresponds to the JSON property `regionCode`
888
+ # @return [String]
889
+ attr_accessor :region_code
890
+
891
+ # Unique user identifier defined by the client.
892
+ # Corresponds to the JSON property `userId`
893
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
894
+ # @return [String]
895
+ attr_accessor :user_id
896
+
897
+ def initialize(**args)
898
+ update!(**args)
899
+ end
900
+
901
+ # Update properties of this object
902
+ def update!(**args)
903
+ @region_code = args[:region_code] if args.key?(:region_code)
904
+ @user_id = args[:user_id] if args.key?(:user_id)
905
+ end
906
+ end
907
+ end
908
+ end
909
+ end