google-apis-admin_reports_v1 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.
@@ -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 AdminReportsV1
18
+ # Version of the google-apis-admin_reports_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 = "20201208"
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,309 @@
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 AdminReportsV1
24
+
25
+ class Activities
26
+ class Representation < Google::Apis::Core::JsonRepresentation; end
27
+
28
+ include Google::Apis::Core::JsonObjectSupport
29
+ end
30
+
31
+ class Activity
32
+ class Representation < Google::Apis::Core::JsonRepresentation; end
33
+
34
+ class Actor
35
+ class Representation < Google::Apis::Core::JsonRepresentation; end
36
+
37
+ include Google::Apis::Core::JsonObjectSupport
38
+ end
39
+
40
+ class Event
41
+ class Representation < Google::Apis::Core::JsonRepresentation; end
42
+
43
+ class Parameter
44
+ class Representation < Google::Apis::Core::JsonRepresentation; end
45
+
46
+ class MessageValue
47
+ class Representation < Google::Apis::Core::JsonRepresentation; end
48
+
49
+ include Google::Apis::Core::JsonObjectSupport
50
+ end
51
+
52
+ class MultiMessageValue
53
+ class Representation < Google::Apis::Core::JsonRepresentation; end
54
+
55
+ include Google::Apis::Core::JsonObjectSupport
56
+ end
57
+
58
+ include Google::Apis::Core::JsonObjectSupport
59
+ end
60
+
61
+ include Google::Apis::Core::JsonObjectSupport
62
+ end
63
+
64
+ class Id
65
+ class Representation < Google::Apis::Core::JsonRepresentation; end
66
+
67
+ include Google::Apis::Core::JsonObjectSupport
68
+ end
69
+
70
+ include Google::Apis::Core::JsonObjectSupport
71
+ end
72
+
73
+ class Channel
74
+ class Representation < Google::Apis::Core::JsonRepresentation; end
75
+
76
+ include Google::Apis::Core::JsonObjectSupport
77
+ end
78
+
79
+ class NestedParameter
80
+ class Representation < Google::Apis::Core::JsonRepresentation; end
81
+
82
+ include Google::Apis::Core::JsonObjectSupport
83
+ end
84
+
85
+ class UsageReport
86
+ class Representation < Google::Apis::Core::JsonRepresentation; end
87
+
88
+ class Entity
89
+ class Representation < Google::Apis::Core::JsonRepresentation; end
90
+
91
+ include Google::Apis::Core::JsonObjectSupport
92
+ end
93
+
94
+ class Parameter
95
+ class Representation < Google::Apis::Core::JsonRepresentation; end
96
+
97
+ include Google::Apis::Core::JsonObjectSupport
98
+ end
99
+
100
+ include Google::Apis::Core::JsonObjectSupport
101
+ end
102
+
103
+ class UsageReports
104
+ class Representation < Google::Apis::Core::JsonRepresentation; end
105
+
106
+ class Warning
107
+ class Representation < Google::Apis::Core::JsonRepresentation; end
108
+
109
+ class Datum
110
+ class Representation < Google::Apis::Core::JsonRepresentation; end
111
+
112
+ include Google::Apis::Core::JsonObjectSupport
113
+ end
114
+
115
+ include Google::Apis::Core::JsonObjectSupport
116
+ end
117
+
118
+ include Google::Apis::Core::JsonObjectSupport
119
+ end
120
+
121
+ class Activities
122
+ # @private
123
+ class Representation < Google::Apis::Core::JsonRepresentation
124
+ property :etag, as: 'etag'
125
+ collection :items, as: 'items', class: Google::Apis::AdminReportsV1::Activity, decorator: Google::Apis::AdminReportsV1::Activity::Representation
126
+
127
+ property :kind, as: 'kind'
128
+ property :next_page_token, as: 'nextPageToken'
129
+ end
130
+ end
131
+
132
+ class Activity
133
+ # @private
134
+ class Representation < Google::Apis::Core::JsonRepresentation
135
+ property :actor, as: 'actor', class: Google::Apis::AdminReportsV1::Activity::Actor, decorator: Google::Apis::AdminReportsV1::Activity::Actor::Representation
136
+
137
+ property :etag, as: 'etag'
138
+ collection :events, as: 'events', class: Google::Apis::AdminReportsV1::Activity::Event, decorator: Google::Apis::AdminReportsV1::Activity::Event::Representation
139
+
140
+ property :id, as: 'id', class: Google::Apis::AdminReportsV1::Activity::Id, decorator: Google::Apis::AdminReportsV1::Activity::Id::Representation
141
+
142
+ property :ip_address, as: 'ipAddress'
143
+ property :kind, as: 'kind'
144
+ property :owner_domain, as: 'ownerDomain'
145
+ end
146
+
147
+ class Actor
148
+ # @private
149
+ class Representation < Google::Apis::Core::JsonRepresentation
150
+ property :caller_type, as: 'callerType'
151
+ property :email, as: 'email'
152
+ property :key, as: 'key'
153
+ property :profile_id, as: 'profileId'
154
+ end
155
+ end
156
+
157
+ class Event
158
+ # @private
159
+ class Representation < Google::Apis::Core::JsonRepresentation
160
+ property :name, as: 'name'
161
+ collection :parameters, as: 'parameters', class: Google::Apis::AdminReportsV1::Activity::Event::Parameter, decorator: Google::Apis::AdminReportsV1::Activity::Event::Parameter::Representation
162
+
163
+ property :type, as: 'type'
164
+ end
165
+
166
+ class Parameter
167
+ # @private
168
+ class Representation < Google::Apis::Core::JsonRepresentation
169
+ property :bool_value, as: 'boolValue'
170
+ property :int_value, :numeric_string => true, as: 'intValue'
171
+ property :message_value, as: 'messageValue', class: Google::Apis::AdminReportsV1::Activity::Event::Parameter::MessageValue, decorator: Google::Apis::AdminReportsV1::Activity::Event::Parameter::MessageValue::Representation
172
+
173
+ collection :multi_int_value, as: 'multiIntValue'
174
+ collection :multi_message_value, as: 'multiMessageValue', class: Google::Apis::AdminReportsV1::Activity::Event::Parameter::MultiMessageValue, decorator: Google::Apis::AdminReportsV1::Activity::Event::Parameter::MultiMessageValue::Representation
175
+
176
+ collection :multi_value, as: 'multiValue'
177
+ property :name, as: 'name'
178
+ property :value, as: 'value'
179
+ end
180
+
181
+ class MessageValue
182
+ # @private
183
+ class Representation < Google::Apis::Core::JsonRepresentation
184
+ collection :parameter, as: 'parameter', class: Google::Apis::AdminReportsV1::NestedParameter, decorator: Google::Apis::AdminReportsV1::NestedParameter::Representation
185
+
186
+ end
187
+ end
188
+
189
+ class MultiMessageValue
190
+ # @private
191
+ class Representation < Google::Apis::Core::JsonRepresentation
192
+ collection :parameter, as: 'parameter', class: Google::Apis::AdminReportsV1::NestedParameter, decorator: Google::Apis::AdminReportsV1::NestedParameter::Representation
193
+
194
+ end
195
+ end
196
+ end
197
+ end
198
+
199
+ class Id
200
+ # @private
201
+ class Representation < Google::Apis::Core::JsonRepresentation
202
+ property :application_name, as: 'applicationName'
203
+ property :customer_id, as: 'customerId'
204
+ property :time, as: 'time', type: DateTime
205
+
206
+ property :unique_qualifier, :numeric_string => true, as: 'uniqueQualifier'
207
+ end
208
+ end
209
+ end
210
+
211
+ class Channel
212
+ # @private
213
+ class Representation < Google::Apis::Core::JsonRepresentation
214
+ property :address, as: 'address'
215
+ property :expiration, :numeric_string => true, as: 'expiration'
216
+ property :id, as: 'id'
217
+ property :kind, as: 'kind'
218
+ hash :params, as: 'params'
219
+ property :payload, as: 'payload'
220
+ property :resource_id, as: 'resourceId'
221
+ property :resource_uri, as: 'resourceUri'
222
+ property :token, as: 'token'
223
+ property :type, as: 'type'
224
+ end
225
+ end
226
+
227
+ class NestedParameter
228
+ # @private
229
+ class Representation < Google::Apis::Core::JsonRepresentation
230
+ property :bool_value, as: 'boolValue'
231
+ property :int_value, :numeric_string => true, as: 'intValue'
232
+ collection :multi_bool_value, as: 'multiBoolValue'
233
+ collection :multi_int_value, as: 'multiIntValue'
234
+ collection :multi_value, as: 'multiValue'
235
+ property :name, as: 'name'
236
+ property :value, as: 'value'
237
+ end
238
+ end
239
+
240
+ class UsageReport
241
+ # @private
242
+ class Representation < Google::Apis::Core::JsonRepresentation
243
+ property :date, as: 'date'
244
+ property :entity, as: 'entity', class: Google::Apis::AdminReportsV1::UsageReport::Entity, decorator: Google::Apis::AdminReportsV1::UsageReport::Entity::Representation
245
+
246
+ property :etag, as: 'etag'
247
+ property :kind, as: 'kind'
248
+ collection :parameters, as: 'parameters', class: Google::Apis::AdminReportsV1::UsageReport::Parameter, decorator: Google::Apis::AdminReportsV1::UsageReport::Parameter::Representation
249
+
250
+ end
251
+
252
+ class Entity
253
+ # @private
254
+ class Representation < Google::Apis::Core::JsonRepresentation
255
+ property :customer_id, as: 'customerId'
256
+ property :entity_id, as: 'entityId'
257
+ property :profile_id, as: 'profileId'
258
+ property :type, as: 'type'
259
+ property :user_email, as: 'userEmail'
260
+ end
261
+ end
262
+
263
+ class Parameter
264
+ # @private
265
+ class Representation < Google::Apis::Core::JsonRepresentation
266
+ property :bool_value, as: 'boolValue'
267
+ property :datetime_value, as: 'datetimeValue', type: DateTime
268
+
269
+ property :int_value, :numeric_string => true, as: 'intValue'
270
+ collection :msg_value, as: 'msgValue'
271
+ property :name, as: 'name'
272
+ property :string_value, as: 'stringValue'
273
+ end
274
+ end
275
+ end
276
+
277
+ class UsageReports
278
+ # @private
279
+ class Representation < Google::Apis::Core::JsonRepresentation
280
+ property :etag, as: 'etag'
281
+ property :kind, as: 'kind'
282
+ property :next_page_token, as: 'nextPageToken'
283
+ collection :usage_reports, as: 'usageReports', class: Google::Apis::AdminReportsV1::UsageReport, decorator: Google::Apis::AdminReportsV1::UsageReport::Representation
284
+
285
+ collection :warnings, as: 'warnings', class: Google::Apis::AdminReportsV1::UsageReports::Warning, decorator: Google::Apis::AdminReportsV1::UsageReports::Warning::Representation
286
+
287
+ end
288
+
289
+ class Warning
290
+ # @private
291
+ class Representation < Google::Apis::Core::JsonRepresentation
292
+ property :code, as: 'code'
293
+ collection :data, as: 'data', class: Google::Apis::AdminReportsV1::UsageReports::Warning::Datum, decorator: Google::Apis::AdminReportsV1::UsageReports::Warning::Datum::Representation
294
+
295
+ property :message, as: 'message'
296
+ end
297
+
298
+ class Datum
299
+ # @private
300
+ class Representation < Google::Apis::Core::JsonRepresentation
301
+ property :key, as: 'key'
302
+ property :value, as: 'value'
303
+ end
304
+ end
305
+ end
306
+ end
307
+ end
308
+ end
309
+ end
@@ -0,0 +1,604 @@
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 'google/apis/core/base_service'
16
+ require 'google/apis/core/json_representation'
17
+ require 'google/apis/core/hashable'
18
+ require 'google/apis/errors'
19
+
20
+ module Google
21
+ module Apis
22
+ module AdminReportsV1
23
+ # Admin SDK API
24
+ #
25
+ # Admin SDK lets administrators of enterprise domains to view and manage
26
+ # resources like user, groups etc. It also provides audit and usage reports of
27
+ # domain.
28
+ #
29
+ # @example
30
+ # require 'google/apis/admin_reports_v1'
31
+ #
32
+ # Admin = Google::Apis::AdminReportsV1 # Alias the module
33
+ # service = Admin::ReportsService.new
34
+ #
35
+ # @see http://developers.google.com/admin-sdk/
36
+ class ReportsService < Google::Apis::Core::BaseService
37
+ # @return [String]
38
+ # API key. Your API key identifies your project and provides you with API access,
39
+ # quota, and reports. Required unless you provide an OAuth 2.0 token.
40
+ attr_accessor :key
41
+
42
+ # @return [String]
43
+ # Available to use for quota purposes for server-side applications. Can be any
44
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
45
+ attr_accessor :quota_user
46
+
47
+ def initialize
48
+ super('https://admin.googleapis.com/', '',
49
+ client_name: 'google-apis-admin_reports_v1',
50
+ client_version: Google::Apis::AdminReportsV1::GEM_VERSION)
51
+ @batch_path = 'batch'
52
+ end
53
+
54
+ # Retrieves a list of activities for a specific customer's account and
55
+ # application such as the Admin console application or the Google Drive
56
+ # application. For more information, see the guides for administrator and Google
57
+ # Drive activity reports. For more information about the activity report's
58
+ # parameters, see the activity parameters reference guides.
59
+ # @param [String] user_key
60
+ # Represents the profile ID or the user email for which the data should be
61
+ # filtered. Can be `all` for all information, or `userKey` for a user's unique G
62
+ # Suite profile ID or their primary email address.
63
+ # @param [String] application_name
64
+ # Application name for which the events are to be retrieved.
65
+ # @param [String] actor_ip_address
66
+ # The Internet Protocol (IP) Address of host where the event was performed. This
67
+ # is an additional way to filter a report's summary using the IP address of the
68
+ # user whose activity is being reported. This IP address may or may not reflect
69
+ # the user's physical location. For example, the IP address can be the user's
70
+ # proxy server's address or a virtual private network (VPN) address. This
71
+ # parameter supports both IPv4 and IPv6 address versions.
72
+ # @param [String] customer_id
73
+ # The unique ID of the customer to retrieve data for.
74
+ # @param [String] end_time
75
+ # Sets the end of the range of time shown in the report. The date is in the RFC
76
+ # 3339 format, for example 2010-10-28T10:26:35.000Z. The default value is the
77
+ # approximate time of the API request. An API report has three basic time
78
+ # concepts: - *Date of the API's request for a report*: When the API created and
79
+ # retrieved the report. - *Report's start time*: The beginning of the timespan
80
+ # shown in the report. The `startTime` must be before the `endTime` (if
81
+ # specified) and the current time when the request is made, or the API returns
82
+ # an error. - *Report's end time*: The end of the timespan shown in the report.
83
+ # For example, the timespan of events summarized in a report can start in April
84
+ # and end in May. The report itself can be requested in August. If the `endTime`
85
+ # is not specified, the report returns all activities from the `startTime` until
86
+ # the current time or the most recent 180 days if the `startTime` is more than
87
+ # 180 days in the past.
88
+ # @param [String] event_name
89
+ # The name of the event being queried by the API. Each `eventName` is related to
90
+ # a specific G Suite service or feature which the API organizes into types of
91
+ # events. An example is the Google Calendar events in the Admin console
92
+ # application's reports. The Calendar Settings `type` structure has all of the
93
+ # Calendar `eventName` activities reported by the API. When an administrator
94
+ # changes a Calendar setting, the API reports this activity in the Calendar
95
+ # Settings `type` and `eventName` parameters. For more information about `
96
+ # eventName` query strings and parameters, see the list of event names for
97
+ # various applications above in `applicationName`.
98
+ # @param [String] filters
99
+ # The `filters` query string is a comma-separated list. The list is composed of
100
+ # event parameters that are manipulated by relational operators. Event
101
+ # parameters are in the form `parameter1 name[parameter1 value],parameter2 name[
102
+ # parameter2 value],...` These event parameters are associated with a specific `
103
+ # eventName`. An empty report is returned if the filtered request's parameter
104
+ # does not belong to the `eventName`. For more information about `eventName`
105
+ # parameters, see the list of event names for various applications above in `
106
+ # applicationName`. In the following Admin Activity example, the <> operator is
107
+ # URL-encoded in the request's query string (%3C%3E): GET...&eventName=
108
+ # CHANGE_CALENDAR_SETTING &filters=NEW_VALUE%3C%3EREAD_ONLY_ACCESS In the
109
+ # following Drive example, the list can be a view or edit event's `doc_id`
110
+ # parameter with a value that is manipulated by an 'equal to' (==) or 'not equal
111
+ # to' (<>) relational operator. In the first example, the report returns each
112
+ # edited document's `doc_id`. In the second example, the report returns each
113
+ # viewed document's `doc_id` that equals the value 12345 and does not return any
114
+ # viewed document's which have a `doc_id` value of 98765. The <> operator is URL-
115
+ # encoded in the request's query string (%3C%3E): GET...&eventName=edit&filters=
116
+ # doc_id GET...&eventName=view&filters=doc_id==12345,doc_id%3C%3E98765 The
117
+ # relational operators include: - `==` - 'equal to'. - `<>` - 'not equal to'. It
118
+ # is URL-encoded (%3C%3E). - `<` - 'less than'. It is URL-encoded (%3C). - `<=` -
119
+ # 'less than or equal to'. It is URL-encoded (%3C=). - `>` - 'greater than'. It
120
+ # is URL-encoded (%3E). - `>=` - 'greater than or equal to'. It is URL-encoded (%
121
+ # 3E=). *Note:* The API doesn't accept multiple values of a parameter. If a
122
+ # particular parameter is supplied more than once in the API request, the API
123
+ # only accepts the last value of that request parameter. In addition, if an
124
+ # invalid request parameter is supplied in the API request, the API ignores that
125
+ # request parameter and returns the response corresponding to the remaining
126
+ # valid request parameters. If no parameters are requested, all parameters are
127
+ # returned.
128
+ # @param [String] group_id_filter
129
+ # Comma separated group ids (obfuscated) on which user activities are filtered,
130
+ # i.e, the response will contain activities for only those users that are a part
131
+ # of at least one of the group ids mentioned here. Format: "id:abc123,id:xyz456"
132
+ # @param [Fixnum] max_results
133
+ # Determines how many activity records are shown on each response page. For
134
+ # example, if the request sets `maxResults=1` and the report has two activities,
135
+ # the report has two pages. The response's `nextPageToken` property has the
136
+ # token to the second page. The `maxResults` query string is optional in the
137
+ # request. The default value is 1000.
138
+ # @param [String] org_unit_id
139
+ # ID of the organizational unit to report on. Activity records will be shown
140
+ # only for users who belong to the specified organizational unit. Data before
141
+ # Dec 17, 2018 doesn't appear in the filtered results.
142
+ # @param [String] page_token
143
+ # The token to specify next page. A report with multiple pages has a `
144
+ # nextPageToken` property in the response. In your follow-on request getting the
145
+ # next page of the report, enter the `nextPageToken` value in the `pageToken`
146
+ # query string.
147
+ # @param [String] start_time
148
+ # Sets the beginning of the range of time shown in the report. The date is in
149
+ # the RFC 3339 format, for example 2010-10-28T10:26:35.000Z. The report returns
150
+ # all activities from `startTime` until `endTime`. The `startTime` must be
151
+ # before the `endTime` (if specified) and the current time when the request is
152
+ # made, or the API returns an error.
153
+ # @param [String] fields
154
+ # Selector specifying which fields to include in a partial response.
155
+ # @param [String] quota_user
156
+ # Available to use for quota purposes for server-side applications. Can be any
157
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
158
+ # @param [Google::Apis::RequestOptions] options
159
+ # Request-specific options
160
+ #
161
+ # @yield [result, err] Result & error if block supplied
162
+ # @yieldparam result [Google::Apis::AdminReportsV1::Activities] parsed result object
163
+ # @yieldparam err [StandardError] error object if request failed
164
+ #
165
+ # @return [Google::Apis::AdminReportsV1::Activities]
166
+ #
167
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
168
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
169
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
170
+ def list_activities(user_key, application_name, actor_ip_address: nil, customer_id: nil, end_time: nil, event_name: nil, filters: nil, group_id_filter: nil, max_results: nil, org_unit_id: nil, page_token: nil, start_time: nil, fields: nil, quota_user: nil, options: nil, &block)
171
+ command = make_simple_command(:get, 'admin/reports/v1/activity/users/{userKey}/applications/{applicationName}', options)
172
+ command.response_representation = Google::Apis::AdminReportsV1::Activities::Representation
173
+ command.response_class = Google::Apis::AdminReportsV1::Activities
174
+ command.params['userKey'] = user_key unless user_key.nil?
175
+ command.params['applicationName'] = application_name unless application_name.nil?
176
+ command.query['actorIpAddress'] = actor_ip_address unless actor_ip_address.nil?
177
+ command.query['customerId'] = customer_id unless customer_id.nil?
178
+ command.query['endTime'] = end_time unless end_time.nil?
179
+ command.query['eventName'] = event_name unless event_name.nil?
180
+ command.query['filters'] = filters unless filters.nil?
181
+ command.query['groupIdFilter'] = group_id_filter unless group_id_filter.nil?
182
+ command.query['maxResults'] = max_results unless max_results.nil?
183
+ command.query['orgUnitID'] = org_unit_id unless org_unit_id.nil?
184
+ command.query['pageToken'] = page_token unless page_token.nil?
185
+ command.query['startTime'] = start_time unless start_time.nil?
186
+ command.query['fields'] = fields unless fields.nil?
187
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
188
+ execute_or_queue_command(command, &block)
189
+ end
190
+
191
+ # Start receiving notifications for account activities. For more information,
192
+ # see Receiving Push Notifications.
193
+ # @param [String] user_key
194
+ # Represents the profile ID or the user email for which the data should be
195
+ # filtered. Can be `all` for all information, or `userKey` for a user's unique G
196
+ # Suite profile ID or their primary email address.
197
+ # @param [String] application_name
198
+ # Application name for which the events are to be retrieved.
199
+ # @param [Google::Apis::AdminReportsV1::Channel] channel_object
200
+ # @param [String] actor_ip_address
201
+ # The Internet Protocol (IP) Address of host where the event was performed. This
202
+ # is an additional way to filter a report's summary using the IP address of the
203
+ # user whose activity is being reported. This IP address may or may not reflect
204
+ # the user's physical location. For example, the IP address can be the user's
205
+ # proxy server's address or a virtual private network (VPN) address. This
206
+ # parameter supports both IPv4 and IPv6 address versions.
207
+ # @param [String] customer_id
208
+ # The unique ID of the customer to retrieve data for.
209
+ # @param [String] end_time
210
+ # Sets the end of the range of time shown in the report. The date is in the RFC
211
+ # 3339 format, for example 2010-10-28T10:26:35.000Z. The default value is the
212
+ # approximate time of the API request. An API report has three basic time
213
+ # concepts: - *Date of the API's request for a report*: When the API created and
214
+ # retrieved the report. - *Report's start time*: The beginning of the timespan
215
+ # shown in the report. The `startTime` must be before the `endTime` (if
216
+ # specified) and the current time when the request is made, or the API returns
217
+ # an error. - *Report's end time*: The end of the timespan shown in the report.
218
+ # For example, the timespan of events summarized in a report can start in April
219
+ # and end in May. The report itself can be requested in August. If the `endTime`
220
+ # is not specified, the report returns all activities from the `startTime` until
221
+ # the current time or the most recent 180 days if the `startTime` is more than
222
+ # 180 days in the past.
223
+ # @param [String] event_name
224
+ # The name of the event being queried by the API. Each `eventName` is related to
225
+ # a specific G Suite service or feature which the API organizes into types of
226
+ # events. An example is the Google Calendar events in the Admin console
227
+ # application's reports. The Calendar Settings `type` structure has all of the
228
+ # Calendar `eventName` activities reported by the API. When an administrator
229
+ # changes a Calendar setting, the API reports this activity in the Calendar
230
+ # Settings `type` and `eventName` parameters. For more information about `
231
+ # eventName` query strings and parameters, see the list of event names for
232
+ # various applications above in `applicationName`.
233
+ # @param [String] filters
234
+ # The `filters` query string is a comma-separated list. The list is composed of
235
+ # event parameters that are manipulated by relational operators. Event
236
+ # parameters are in the form `parameter1 name[parameter1 value],parameter2 name[
237
+ # parameter2 value],...` These event parameters are associated with a specific `
238
+ # eventName`. An empty report is returned if the filtered request's parameter
239
+ # does not belong to the `eventName`. For more information about `eventName`
240
+ # parameters, see the list of event names for various applications above in `
241
+ # applicationName`. In the following Admin Activity example, the <> operator is
242
+ # URL-encoded in the request's query string (%3C%3E): GET...&eventName=
243
+ # CHANGE_CALENDAR_SETTING &filters=NEW_VALUE%3C%3EREAD_ONLY_ACCESS In the
244
+ # following Drive example, the list can be a view or edit event's `doc_id`
245
+ # parameter with a value that is manipulated by an 'equal to' (==) or 'not equal
246
+ # to' (<>) relational operator. In the first example, the report returns each
247
+ # edited document's `doc_id`. In the second example, the report returns each
248
+ # viewed document's `doc_id` that equals the value 12345 and does not return any
249
+ # viewed document's which have a `doc_id` value of 98765. The <> operator is URL-
250
+ # encoded in the request's query string (%3C%3E): GET...&eventName=edit&filters=
251
+ # doc_id GET...&eventName=view&filters=doc_id==12345,doc_id%3C%3E98765 The
252
+ # relational operators include: - `==` - 'equal to'. - `<>` - 'not equal to'. It
253
+ # is URL-encoded (%3C%3E). - `<` - 'less than'. It is URL-encoded (%3C). - `<=` -
254
+ # 'less than or equal to'. It is URL-encoded (%3C=). - `>` - 'greater than'. It
255
+ # is URL-encoded (%3E). - `>=` - 'greater than or equal to'. It is URL-encoded (%
256
+ # 3E=). *Note:* The API doesn't accept multiple values of a parameter. If a
257
+ # particular parameter is supplied more than once in the API request, the API
258
+ # only accepts the last value of that request parameter. In addition, if an
259
+ # invalid request parameter is supplied in the API request, the API ignores that
260
+ # request parameter and returns the response corresponding to the remaining
261
+ # valid request parameters. If no parameters are requested, all parameters are
262
+ # returned.
263
+ # @param [String] group_id_filter
264
+ # Comma separated group ids (obfuscated) on which user activities are filtered,
265
+ # i.e, the response will contain activities for only those users that are a part
266
+ # of at least one of the group ids mentioned here. Format: "id:abc123,id:xyz456"
267
+ # @param [Fixnum] max_results
268
+ # Determines how many activity records are shown on each response page. For
269
+ # example, if the request sets `maxResults=1` and the report has two activities,
270
+ # the report has two pages. The response's `nextPageToken` property has the
271
+ # token to the second page. The `maxResults` query string is optional in the
272
+ # request. The default value is 1000.
273
+ # @param [String] org_unit_id
274
+ # ID of the organizational unit to report on. Activity records will be shown
275
+ # only for users who belong to the specified organizational unit. Data before
276
+ # Dec 17, 2018 doesn't appear in the filtered results.
277
+ # @param [String] page_token
278
+ # The token to specify next page. A report with multiple pages has a `
279
+ # nextPageToken` property in the response. In your follow-on request getting the
280
+ # next page of the report, enter the `nextPageToken` value in the `pageToken`
281
+ # query string.
282
+ # @param [String] start_time
283
+ # Sets the beginning of the range of time shown in the report. The date is in
284
+ # the RFC 3339 format, for example 2010-10-28T10:26:35.000Z. The report returns
285
+ # all activities from `startTime` until `endTime`. The `startTime` must be
286
+ # before the `endTime` (if specified) and the current time when the request is
287
+ # made, or the API returns an error.
288
+ # @param [String] fields
289
+ # Selector specifying which fields to include in a partial response.
290
+ # @param [String] quota_user
291
+ # Available to use for quota purposes for server-side applications. Can be any
292
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
293
+ # @param [Google::Apis::RequestOptions] options
294
+ # Request-specific options
295
+ #
296
+ # @yield [result, err] Result & error if block supplied
297
+ # @yieldparam result [Google::Apis::AdminReportsV1::Channel] parsed result object
298
+ # @yieldparam err [StandardError] error object if request failed
299
+ #
300
+ # @return [Google::Apis::AdminReportsV1::Channel]
301
+ #
302
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
303
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
304
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
305
+ def watch_activity(user_key, application_name, channel_object = nil, actor_ip_address: nil, customer_id: nil, end_time: nil, event_name: nil, filters: nil, group_id_filter: nil, max_results: nil, org_unit_id: nil, page_token: nil, start_time: nil, fields: nil, quota_user: nil, options: nil, &block)
306
+ command = make_simple_command(:post, 'admin/reports/v1/activity/users/{userKey}/applications/{applicationName}/watch', options)
307
+ command.request_representation = Google::Apis::AdminReportsV1::Channel::Representation
308
+ command.request_object = channel_object
309
+ command.response_representation = Google::Apis::AdminReportsV1::Channel::Representation
310
+ command.response_class = Google::Apis::AdminReportsV1::Channel
311
+ command.params['userKey'] = user_key unless user_key.nil?
312
+ command.params['applicationName'] = application_name unless application_name.nil?
313
+ command.query['actorIpAddress'] = actor_ip_address unless actor_ip_address.nil?
314
+ command.query['customerId'] = customer_id unless customer_id.nil?
315
+ command.query['endTime'] = end_time unless end_time.nil?
316
+ command.query['eventName'] = event_name unless event_name.nil?
317
+ command.query['filters'] = filters unless filters.nil?
318
+ command.query['groupIdFilter'] = group_id_filter unless group_id_filter.nil?
319
+ command.query['maxResults'] = max_results unless max_results.nil?
320
+ command.query['orgUnitID'] = org_unit_id unless org_unit_id.nil?
321
+ command.query['pageToken'] = page_token unless page_token.nil?
322
+ command.query['startTime'] = start_time unless start_time.nil?
323
+ command.query['fields'] = fields unless fields.nil?
324
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
325
+ execute_or_queue_command(command, &block)
326
+ end
327
+
328
+ # Stop watching resources through this channel.
329
+ # @param [Google::Apis::AdminReportsV1::Channel] channel_object
330
+ # @param [String] fields
331
+ # Selector specifying which fields to include in a partial response.
332
+ # @param [String] quota_user
333
+ # Available to use for quota purposes for server-side applications. Can be any
334
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
335
+ # @param [Google::Apis::RequestOptions] options
336
+ # Request-specific options
337
+ #
338
+ # @yield [result, err] Result & error if block supplied
339
+ # @yieldparam result [NilClass] No result returned for this method
340
+ # @yieldparam err [StandardError] error object if request failed
341
+ #
342
+ # @return [void]
343
+ #
344
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
345
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
346
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
347
+ def stop_channel(channel_object = nil, fields: nil, quota_user: nil, options: nil, &block)
348
+ command = make_simple_command(:post, 'admin/reports_v1/channels/stop', options)
349
+ command.request_representation = Google::Apis::AdminReportsV1::Channel::Representation
350
+ command.request_object = channel_object
351
+ command.query['fields'] = fields unless fields.nil?
352
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
353
+ execute_or_queue_command(command, &block)
354
+ end
355
+
356
+ # Retrieves a report which is a collection of properties and statistics for a
357
+ # specific customer's account. For more information, see the Customers Usage
358
+ # Report guide. For more information about the customer report's parameters, see
359
+ # the Customers Usage parameters reference guides.
360
+ # @param [String] date
361
+ # Represents the date the usage occurred. The timestamp is in the ISO 8601
362
+ # format, yyyy-mm-dd. We recommend you use your account's time zone for this.
363
+ # @param [String] customer_id
364
+ # The unique ID of the customer to retrieve data for.
365
+ # @param [String] page_token
366
+ # Token to specify next page. A report with multiple pages has a `nextPageToken`
367
+ # property in the response. For your follow-on requests getting all of the
368
+ # report's pages, enter the `nextPageToken` value in the `pageToken` query
369
+ # string.
370
+ # @param [String] parameters
371
+ # The `parameters` query string is a comma-separated list of event parameters
372
+ # that refine a report's results. The parameter is associated with a specific
373
+ # application. The application values for the Customers usage report include `
374
+ # accounts`, `app_maker`, `apps_scripts`, `calendar`, `classroom`, `cros`, `docs`
375
+ # , `gmail`, `gplus`, `device_management`, `meet`, and `sites`. A `parameters`
376
+ # query string is in the CSV form of `app_name1:param_name1, app_name2:
377
+ # param_name2`. *Note:* The API doesn't accept multiple values of a parameter.
378
+ # If a particular parameter is supplied more than once in the API request, the
379
+ # API only accepts the last value of that request parameter. In addition, if an
380
+ # invalid request parameter is supplied in the API request, the API ignores that
381
+ # request parameter and returns the response corresponding to the remaining
382
+ # valid request parameters. An example of an invalid request parameter is one
383
+ # that does not belong to the application. If no parameters are requested, all
384
+ # parameters are returned.
385
+ # @param [String] fields
386
+ # Selector specifying which fields to include in a partial response.
387
+ # @param [String] quota_user
388
+ # Available to use for quota purposes for server-side applications. Can be any
389
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
390
+ # @param [Google::Apis::RequestOptions] options
391
+ # Request-specific options
392
+ #
393
+ # @yield [result, err] Result & error if block supplied
394
+ # @yieldparam result [Google::Apis::AdminReportsV1::UsageReports] parsed result object
395
+ # @yieldparam err [StandardError] error object if request failed
396
+ #
397
+ # @return [Google::Apis::AdminReportsV1::UsageReports]
398
+ #
399
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
400
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
401
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
402
+ def get_customer_usage_report(date, customer_id: nil, page_token: nil, parameters: nil, fields: nil, quota_user: nil, options: nil, &block)
403
+ command = make_simple_command(:get, 'admin/reports/v1/usage/dates/{date}', options)
404
+ command.response_representation = Google::Apis::AdminReportsV1::UsageReports::Representation
405
+ command.response_class = Google::Apis::AdminReportsV1::UsageReports
406
+ command.params['date'] = date unless date.nil?
407
+ command.query['customerId'] = customer_id unless customer_id.nil?
408
+ command.query['pageToken'] = page_token unless page_token.nil?
409
+ command.query['parameters'] = parameters unless parameters.nil?
410
+ command.query['fields'] = fields unless fields.nil?
411
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
412
+ execute_or_queue_command(command, &block)
413
+ end
414
+
415
+ # Retrieves a report which is a collection of properties and statistics for
416
+ # entities used by users within the account. For more information, see the
417
+ # Entities Usage Report guide. For more information about the entities report's
418
+ # parameters, see the Entities Usage parameters reference guides.
419
+ # @param [String] entity_type
420
+ # Represents the type of entity for the report.
421
+ # @param [String] entity_key
422
+ # Represents the key of the object to filter the data with.
423
+ # @param [String] date
424
+ # Represents the date the usage occurred. The timestamp is in the ISO 8601
425
+ # format, yyyy-mm-dd. We recommend you use your account's time zone for this.
426
+ # @param [String] customer_id
427
+ # The unique ID of the customer to retrieve data for.
428
+ # @param [String] filters
429
+ # The `filters` query string is a comma-separated list of an application's event
430
+ # parameters where the parameter's value is manipulated by a relational operator.
431
+ # The `filters` query string includes the name of the application whose usage
432
+ # is returned in the report. The application values for the Entities usage
433
+ # report include `accounts`, `docs`, and `gmail`. Filters are in the form `[
434
+ # application name]:parameter name[parameter value],...`. In this example, the `<
435
+ # >` 'not equal to' operator is URL-encoded in the request's query string (%3C%
436
+ # 3E): GET https://www.googleapis.com/admin/reports/v1/usage/gplus_communities/
437
+ # all/dates/2017-12-01 ?parameters=gplus:community_name,gplus:num_total_members &
438
+ # filters=gplus:num_total_members%3C%3E0 The relational operators include: - `==`
439
+ # - 'equal to'. - `<>` - 'not equal to'. It is URL-encoded (%3C%3E). - `<` - '
440
+ # less than'. It is URL-encoded (%3C). - `<=` - 'less than or equal to'. It is
441
+ # URL-encoded (%3C=). - `>` - 'greater than'. It is URL-encoded (%3E). - `>=` - '
442
+ # greater than or equal to'. It is URL-encoded (%3E=). Filters can only be
443
+ # applied to numeric parameters.
444
+ # @param [Fixnum] max_results
445
+ # Determines how many activity records are shown on each response page. For
446
+ # example, if the request sets `maxResults=1` and the report has two activities,
447
+ # the report has two pages. The response's `nextPageToken` property has the
448
+ # token to the second page.
449
+ # @param [String] page_token
450
+ # Token to specify next page. A report with multiple pages has a `nextPageToken`
451
+ # property in the response. In your follow-on request getting the next page of
452
+ # the report, enter the `nextPageToken` value in the `pageToken` query string.
453
+ # @param [String] parameters
454
+ # The `parameters` query string is a comma-separated list of event parameters
455
+ # that refine a report's results. The parameter is associated with a specific
456
+ # application. The application values for the Entities usage report are only `
457
+ # gplus`. A `parameter` query string is in the CSV form of `[app_name1:
458
+ # param_name1], [app_name2:param_name2]...`. *Note:* The API doesn't accept
459
+ # multiple values of a parameter. If a particular parameter is supplied more
460
+ # than once in the API request, the API only accepts the last value of that
461
+ # request parameter. In addition, if an invalid request parameter is supplied in
462
+ # the API request, the API ignores that request parameter and returns the
463
+ # response corresponding to the remaining valid request parameters. An example
464
+ # of an invalid request parameter is one that does not belong to the application.
465
+ # If no parameters are requested, all parameters are returned.
466
+ # @param [String] fields
467
+ # Selector specifying which fields to include in a partial response.
468
+ # @param [String] quota_user
469
+ # Available to use for quota purposes for server-side applications. Can be any
470
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
471
+ # @param [Google::Apis::RequestOptions] options
472
+ # Request-specific options
473
+ #
474
+ # @yield [result, err] Result & error if block supplied
475
+ # @yieldparam result [Google::Apis::AdminReportsV1::UsageReports] parsed result object
476
+ # @yieldparam err [StandardError] error object if request failed
477
+ #
478
+ # @return [Google::Apis::AdminReportsV1::UsageReports]
479
+ #
480
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
481
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
482
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
483
+ def get_entity_usage_report(entity_type, entity_key, date, customer_id: nil, filters: nil, max_results: nil, page_token: nil, parameters: nil, fields: nil, quota_user: nil, options: nil, &block)
484
+ command = make_simple_command(:get, 'admin/reports/v1/usage/{entityType}/{entityKey}/dates/{date}', options)
485
+ command.response_representation = Google::Apis::AdminReportsV1::UsageReports::Representation
486
+ command.response_class = Google::Apis::AdminReportsV1::UsageReports
487
+ command.params['entityType'] = entity_type unless entity_type.nil?
488
+ command.params['entityKey'] = entity_key unless entity_key.nil?
489
+ command.params['date'] = date unless date.nil?
490
+ command.query['customerId'] = customer_id unless customer_id.nil?
491
+ command.query['filters'] = filters unless filters.nil?
492
+ command.query['maxResults'] = max_results unless max_results.nil?
493
+ command.query['pageToken'] = page_token unless page_token.nil?
494
+ command.query['parameters'] = parameters unless parameters.nil?
495
+ command.query['fields'] = fields unless fields.nil?
496
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
497
+ execute_or_queue_command(command, &block)
498
+ end
499
+
500
+ # Retrieves a report which is a collection of properties and statistics for a
501
+ # set of users with the account. For more information, see the User Usage Report
502
+ # guide. For more information about the user report's parameters, see the Users
503
+ # Usage parameters reference guides.
504
+ # @param [String] user_key
505
+ # Represents the profile ID or the user email for which the data should be
506
+ # filtered. Can be `all` for all information, or `userKey` for a user's unique G
507
+ # Suite profile ID or their primary email address.
508
+ # @param [String] date
509
+ # Represents the date the usage occurred. The timestamp is in the ISO 8601
510
+ # format, yyyy-mm-dd. We recommend you use your account's time zone for this.
511
+ # @param [String] customer_id
512
+ # The unique ID of the customer to retrieve data for.
513
+ # @param [String] filters
514
+ # The `filters` query string is a comma-separated list of an application's event
515
+ # parameters where the parameter's value is manipulated by a relational operator.
516
+ # The `filters` query string includes the name of the application whose usage
517
+ # is returned in the report. The application values for the Users Usage Report
518
+ # include `accounts`, `docs`, and `gmail`. Filters are in the form `[application
519
+ # name]:parameter name[parameter value],...`. In this example, the `<>` 'not
520
+ # equal to' operator is URL-encoded in the request's query string (%3C%3E): GET
521
+ # https://www.googleapis.com/admin/reports/v1/usage/users/all/dates/2013-03-03 ?
522
+ # parameters=accounts:last_login_time &filters=accounts:last_login_time%3C%
523
+ # 3E2010-10-28T10:26:35.000Z The relational operators include: - `==` - 'equal
524
+ # to'. - `<>` - 'not equal to'. It is URL-encoded (%3C%3E). - `<` - 'less than'.
525
+ # It is URL-encoded (%3C). - `<=` - 'less than or equal to'. It is URL-encoded (%
526
+ # 3C=). - `>` - 'greater than'. It is URL-encoded (%3E). - `>=` - 'greater than
527
+ # or equal to'. It is URL-encoded (%3E=).
528
+ # @param [String] group_id_filter
529
+ # Comma separated group ids (obfuscated) on which user activities are filtered,
530
+ # i.e, the response will contain activities for only those users that are a part
531
+ # of at least one of the group ids mentioned here. Format: "id:abc123,id:xyz456"
532
+ # @param [Fixnum] max_results
533
+ # Determines how many activity records are shown on each response page. For
534
+ # example, if the request sets `maxResults=1` and the report has two activities,
535
+ # the report has two pages. The response's `nextPageToken` property has the
536
+ # token to the second page. The `maxResults` query string is optional.
537
+ # @param [String] org_unit_id
538
+ # ID of the organizational unit to report on. User activity will be shown only
539
+ # for users who belong to the specified organizational unit. Data before Dec 17,
540
+ # 2018 doesn't appear in the filtered results.
541
+ # @param [String] page_token
542
+ # Token to specify next page. A report with multiple pages has a `nextPageToken`
543
+ # property in the response. In your follow-on request getting the next page of
544
+ # the report, enter the `nextPageToken` value in the `pageToken` query string.
545
+ # @param [String] parameters
546
+ # The `parameters` query string is a comma-separated list of event parameters
547
+ # that refine a report's results. The parameter is associated with a specific
548
+ # application. The application values for the Customers Usage report include `
549
+ # accounts`, `app_maker`, `apps_scripts`, `calendar`, `classroom`, `cros`, `docs`
550
+ # , `gmail`, `gplus`, `device_management`, `meet`, and `sites`. A `parameters`
551
+ # query string is in the CSV form of `app_name1:param_name1, app_name2:
552
+ # param_name2`. *Note:* The API doesn't accept multiple values of a parameter.
553
+ # If a particular parameter is supplied more than once in the API request, the
554
+ # API only accepts the last value of that request parameter. In addition, if an
555
+ # invalid request parameter is supplied in the API request, the API ignores that
556
+ # request parameter and returns the response corresponding to the remaining
557
+ # valid request parameters. An example of an invalid request parameter is one
558
+ # that does not belong to the application. If no parameters are requested, all
559
+ # parameters are returned.
560
+ # @param [String] fields
561
+ # Selector specifying which fields to include in a partial response.
562
+ # @param [String] quota_user
563
+ # Available to use for quota purposes for server-side applications. Can be any
564
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
565
+ # @param [Google::Apis::RequestOptions] options
566
+ # Request-specific options
567
+ #
568
+ # @yield [result, err] Result & error if block supplied
569
+ # @yieldparam result [Google::Apis::AdminReportsV1::UsageReports] parsed result object
570
+ # @yieldparam err [StandardError] error object if request failed
571
+ #
572
+ # @return [Google::Apis::AdminReportsV1::UsageReports]
573
+ #
574
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
575
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
576
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
577
+ def get_user_usage_report(user_key, date, customer_id: nil, filters: nil, group_id_filter: nil, max_results: nil, org_unit_id: nil, page_token: nil, parameters: nil, fields: nil, quota_user: nil, options: nil, &block)
578
+ command = make_simple_command(:get, 'admin/reports/v1/usage/users/{userKey}/dates/{date}', options)
579
+ command.response_representation = Google::Apis::AdminReportsV1::UsageReports::Representation
580
+ command.response_class = Google::Apis::AdminReportsV1::UsageReports
581
+ command.params['userKey'] = user_key unless user_key.nil?
582
+ command.params['date'] = date unless date.nil?
583
+ command.query['customerId'] = customer_id unless customer_id.nil?
584
+ command.query['filters'] = filters unless filters.nil?
585
+ command.query['groupIdFilter'] = group_id_filter unless group_id_filter.nil?
586
+ command.query['maxResults'] = max_results unless max_results.nil?
587
+ command.query['orgUnitID'] = org_unit_id unless org_unit_id.nil?
588
+ command.query['pageToken'] = page_token unless page_token.nil?
589
+ command.query['parameters'] = parameters unless parameters.nil?
590
+ command.query['fields'] = fields unless fields.nil?
591
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
592
+ execute_or_queue_command(command, &block)
593
+ end
594
+
595
+ protected
596
+
597
+ def apply_command_defaults(command)
598
+ command.query['key'] = key unless key.nil?
599
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
600
+ end
601
+ end
602
+ end
603
+ end
604
+ end