diff --git a/api_names_out.yaml b/api_names_out.yaml index a7d68a5df..11e632930 100644 --- a/api_names_out.yaml +++ b/api_names_out.yaml @@ -40486,6 +40486,7 @@ "/dataflow:v1b3/Job": job "/dataflow:v1b3/Job/clientRequestId": client_request_id "/dataflow:v1b3/Job/createTime": create_time +"/dataflow:v1b3/Job/createdFromSnapshotId": created_from_snapshot_id "/dataflow:v1b3/Job/currentState": current_state "/dataflow:v1b3/Job/currentStateTime": current_state_time "/dataflow:v1b3/Job/environment": environment @@ -40506,6 +40507,7 @@ "/dataflow:v1b3/Job/startTime": start_time "/dataflow:v1b3/Job/steps": steps "/dataflow:v1b3/Job/steps/step": step +"/dataflow:v1b3/Job/stepsLocation": steps_location "/dataflow:v1b3/Job/tempFiles": temp_files "/dataflow:v1b3/Job/tempFiles/temp_file": temp_file "/dataflow:v1b3/Job/transformNameMapping": transform_name_mapping @@ -40761,6 +40763,15 @@ "/dataflow:v1b3/Sink/codec/codec": codec "/dataflow:v1b3/Sink/spec": spec "/dataflow:v1b3/Sink/spec/spec": spec +"/dataflow:v1b3/Snapshot": snapshot +"/dataflow:v1b3/Snapshot/creationTime": creation_time +"/dataflow:v1b3/Snapshot/id": id +"/dataflow:v1b3/Snapshot/projectId": project_id +"/dataflow:v1b3/Snapshot/sourceJobId": source_job_id +"/dataflow:v1b3/Snapshot/ttl": ttl +"/dataflow:v1b3/SnapshotJobRequest": snapshot_job_request +"/dataflow:v1b3/SnapshotJobRequest/location": location +"/dataflow:v1b3/SnapshotJobRequest/ttl": ttl "/dataflow:v1b3/Source": source "/dataflow:v1b3/Source/baseSpecs": base_specs "/dataflow:v1b3/Source/baseSpecs/base_spec": base_spec @@ -41090,6 +41101,9 @@ "/dataflow:v1b3/dataflow.projects.jobs.messages.list/pageToken": page_token "/dataflow:v1b3/dataflow.projects.jobs.messages.list/projectId": project_id "/dataflow:v1b3/dataflow.projects.jobs.messages.list/startTime": start_time +"/dataflow:v1b3/dataflow.projects.jobs.snapshot": snapshot_project_job +"/dataflow:v1b3/dataflow.projects.jobs.snapshot/jobId": job_id +"/dataflow:v1b3/dataflow.projects.jobs.snapshot/projectId": project_id "/dataflow:v1b3/dataflow.projects.jobs.update": update_project_job "/dataflow:v1b3/dataflow.projects.jobs.update/jobId": job_id "/dataflow:v1b3/dataflow.projects.jobs.update/location": location @@ -41139,6 +41153,10 @@ "/dataflow:v1b3/dataflow.projects.locations.jobs.messages.list/pageToken": page_token "/dataflow:v1b3/dataflow.projects.locations.jobs.messages.list/projectId": project_id "/dataflow:v1b3/dataflow.projects.locations.jobs.messages.list/startTime": start_time +"/dataflow:v1b3/dataflow.projects.locations.jobs.snapshot": snapshot_project_location_job +"/dataflow:v1b3/dataflow.projects.locations.jobs.snapshot/jobId": job_id +"/dataflow:v1b3/dataflow.projects.locations.jobs.snapshot/location": location +"/dataflow:v1b3/dataflow.projects.locations.jobs.snapshot/projectId": project_id "/dataflow:v1b3/dataflow.projects.locations.jobs.update": update_project_location_job "/dataflow:v1b3/dataflow.projects.locations.jobs.update/jobId": job_id "/dataflow:v1b3/dataflow.projects.locations.jobs.update/location": location @@ -41160,6 +41178,8 @@ "/dataflow:v1b3/dataflow.projects.locations.templates.get/projectId": project_id "/dataflow:v1b3/dataflow.projects.locations.templates.get/view": view "/dataflow:v1b3/dataflow.projects.locations.templates.launch": launch_project_location_template +"/dataflow:v1b3/dataflow.projects.locations.templates.launch/dynamicTemplate.gcsPath": dynamic_template_gcs_path +"/dataflow:v1b3/dataflow.projects.locations.templates.launch/dynamicTemplate.stagingLocation": dynamic_template_staging_location "/dataflow:v1b3/dataflow.projects.locations.templates.launch/gcsPath": gcs_path "/dataflow:v1b3/dataflow.projects.locations.templates.launch/location": location "/dataflow:v1b3/dataflow.projects.locations.templates.launch/projectId": project_id @@ -41175,6 +41195,8 @@ "/dataflow:v1b3/dataflow.projects.templates.get/projectId": project_id "/dataflow:v1b3/dataflow.projects.templates.get/view": view "/dataflow:v1b3/dataflow.projects.templates.launch": launch_project_template +"/dataflow:v1b3/dataflow.projects.templates.launch/dynamicTemplate.gcsPath": dynamic_template_gcs_path +"/dataflow:v1b3/dataflow.projects.templates.launch/dynamicTemplate.stagingLocation": dynamic_template_staging_location "/dataflow:v1b3/dataflow.projects.templates.launch/gcsPath": gcs_path "/dataflow:v1b3/dataflow.projects.templates.launch/location": location "/dataflow:v1b3/dataflow.projects.templates.launch/projectId": project_id @@ -64048,6 +64070,178 @@ "/drive:v3/key": key "/drive:v3/quotaUser": quota_user "/drive:v3/userIp": user_ip +"/driveactivity:v2/Action": action +"/driveactivity:v2/Action/actor": actor +"/driveactivity:v2/Action/detail": detail +"/driveactivity:v2/Action/target": target +"/driveactivity:v2/Action/timeRange": time_range +"/driveactivity:v2/Action/timestamp": timestamp +"/driveactivity:v2/ActionDetail": action_detail +"/driveactivity:v2/ActionDetail/comment": comment +"/driveactivity:v2/ActionDetail/create": create +"/driveactivity:v2/ActionDetail/delete": delete +"/driveactivity:v2/ActionDetail/dlpChange": dlp_change +"/driveactivity:v2/ActionDetail/edit": edit +"/driveactivity:v2/ActionDetail/move": move +"/driveactivity:v2/ActionDetail/permissionChange": permission_change +"/driveactivity:v2/ActionDetail/reference": reference +"/driveactivity:v2/ActionDetail/rename": rename +"/driveactivity:v2/ActionDetail/restore": restore +"/driveactivity:v2/ActionDetail/settingsChange": settings_change +"/driveactivity:v2/Actor": actor +"/driveactivity:v2/Actor/administrator": administrator +"/driveactivity:v2/Actor/anonymous": anonymous +"/driveactivity:v2/Actor/impersonation": impersonation +"/driveactivity:v2/Actor/system": system +"/driveactivity:v2/Actor/user": user +"/driveactivity:v2/Administrator": administrator +"/driveactivity:v2/AnonymousUser": anonymous_user +"/driveactivity:v2/Anyone": anyone +"/driveactivity:v2/ApplicationReference": application_reference +"/driveactivity:v2/ApplicationReference/type": type +"/driveactivity:v2/Assignment": assignment +"/driveactivity:v2/Assignment/subtype": subtype +"/driveactivity:v2/Comment": comment +"/driveactivity:v2/Comment/assignment": assignment +"/driveactivity:v2/Comment/mentionedUsers": mentioned_users +"/driveactivity:v2/Comment/mentionedUsers/mentioned_user": mentioned_user +"/driveactivity:v2/Comment/post": post +"/driveactivity:v2/Comment/suggestion": suggestion +"/driveactivity:v2/ConsolidationStrategy": consolidation_strategy +"/driveactivity:v2/ConsolidationStrategy/legacy": legacy +"/driveactivity:v2/ConsolidationStrategy/none": none +"/driveactivity:v2/Copy": copy +"/driveactivity:v2/Copy/originalObject": original_object +"/driveactivity:v2/Create": create +"/driveactivity:v2/Create/copy": copy +"/driveactivity:v2/Create/new": new +"/driveactivity:v2/Create/upload": upload +"/driveactivity:v2/DataLeakPreventionChange": data_leak_prevention_change +"/driveactivity:v2/DataLeakPreventionChange/type": type +"/driveactivity:v2/Delete": delete +"/driveactivity:v2/Delete/type": type +"/driveactivity:v2/DeletedUser": deleted_user +"/driveactivity:v2/Domain": domain +"/driveactivity:v2/Domain/legacyId": legacy_id +"/driveactivity:v2/Domain/name": name +"/driveactivity:v2/DriveActivity": drive_activity +"/driveactivity:v2/DriveActivity/actions": actions +"/driveactivity:v2/DriveActivity/actions/action": action +"/driveactivity:v2/DriveActivity/actors": actors +"/driveactivity:v2/DriveActivity/actors/actor": actor +"/driveactivity:v2/DriveActivity/primaryActionDetail": primary_action_detail +"/driveactivity:v2/DriveActivity/targets": targets +"/driveactivity:v2/DriveActivity/targets/target": target +"/driveactivity:v2/DriveActivity/timeRange": time_range +"/driveactivity:v2/DriveActivity/timestamp": timestamp +"/driveactivity:v2/DriveItem": drive_item +"/driveactivity:v2/DriveItem/file": file +"/driveactivity:v2/DriveItem/folder": folder +"/driveactivity:v2/DriveItem/mimeType": mime_type +"/driveactivity:v2/DriveItem/name": name +"/driveactivity:v2/DriveItem/owner": owner +"/driveactivity:v2/DriveItem/title": title +"/driveactivity:v2/DriveItemReference": drive_item_reference +"/driveactivity:v2/DriveItemReference/file": file +"/driveactivity:v2/DriveItemReference/folder": folder +"/driveactivity:v2/DriveItemReference/name": name +"/driveactivity:v2/DriveItemReference/title": title +"/driveactivity:v2/Edit": edit +"/driveactivity:v2/File": file +"/driveactivity:v2/FileComment": file_comment +"/driveactivity:v2/FileComment/legacyCommentId": legacy_comment_id +"/driveactivity:v2/FileComment/legacyDiscussionId": legacy_discussion_id +"/driveactivity:v2/FileComment/linkToDiscussion": link_to_discussion +"/driveactivity:v2/FileComment/parent": parent +"/driveactivity:v2/Folder": folder +"/driveactivity:v2/Folder/type": type +"/driveactivity:v2/Group": group +"/driveactivity:v2/Group/email": email +"/driveactivity:v2/Group/title": title +"/driveactivity:v2/Impersonation": impersonation +"/driveactivity:v2/Impersonation/impersonatedUser": impersonated_user +"/driveactivity:v2/KnownUser": known_user +"/driveactivity:v2/KnownUser/isCurrentUser": is_current_user +"/driveactivity:v2/KnownUser/personName": person_name +"/driveactivity:v2/Legacy": legacy +"/driveactivity:v2/Move": move +"/driveactivity:v2/Move/addedParents": added_parents +"/driveactivity:v2/Move/addedParents/added_parent": added_parent +"/driveactivity:v2/Move/removedParents": removed_parents +"/driveactivity:v2/Move/removedParents/removed_parent": removed_parent +"/driveactivity:v2/New": new +"/driveactivity:v2/NoConsolidation": no_consolidation +"/driveactivity:v2/Owner": owner +"/driveactivity:v2/Owner/domain": domain +"/driveactivity:v2/Owner/teamDrive": team_drive +"/driveactivity:v2/Owner/user": user +"/driveactivity:v2/Permission": permission +"/driveactivity:v2/Permission/allowDiscovery": allow_discovery +"/driveactivity:v2/Permission/anyone": anyone +"/driveactivity:v2/Permission/domain": domain +"/driveactivity:v2/Permission/group": group +"/driveactivity:v2/Permission/role": role +"/driveactivity:v2/Permission/user": user +"/driveactivity:v2/PermissionChange": permission_change +"/driveactivity:v2/PermissionChange/addedPermissions": added_permissions +"/driveactivity:v2/PermissionChange/addedPermissions/added_permission": added_permission +"/driveactivity:v2/PermissionChange/removedPermissions": removed_permissions +"/driveactivity:v2/PermissionChange/removedPermissions/removed_permission": removed_permission +"/driveactivity:v2/Post": post +"/driveactivity:v2/Post/subtype": subtype +"/driveactivity:v2/QueryDriveActivityRequest": query_drive_activity_request +"/driveactivity:v2/QueryDriveActivityRequest/ancestorName": ancestor_name +"/driveactivity:v2/QueryDriveActivityRequest/consolidationStrategy": consolidation_strategy +"/driveactivity:v2/QueryDriveActivityRequest/filter": filter +"/driveactivity:v2/QueryDriveActivityRequest/itemName": item_name +"/driveactivity:v2/QueryDriveActivityRequest/pageSize": page_size +"/driveactivity:v2/QueryDriveActivityRequest/pageToken": page_token +"/driveactivity:v2/QueryDriveActivityResponse": query_drive_activity_response +"/driveactivity:v2/QueryDriveActivityResponse/activities": activities +"/driveactivity:v2/QueryDriveActivityResponse/activities/activity": activity +"/driveactivity:v2/QueryDriveActivityResponse/nextPageToken": next_page_token +"/driveactivity:v2/Rename": rename +"/driveactivity:v2/Rename/newTitle": new_title +"/driveactivity:v2/Rename/oldTitle": old_title +"/driveactivity:v2/Restore": restore +"/driveactivity:v2/Restore/type": type +"/driveactivity:v2/RestrictionChange": restriction_change +"/driveactivity:v2/RestrictionChange/feature": feature +"/driveactivity:v2/RestrictionChange/newRestriction": new_restriction +"/driveactivity:v2/SettingsChange": settings_change +"/driveactivity:v2/SettingsChange/restrictionChanges": restriction_changes +"/driveactivity:v2/SettingsChange/restrictionChanges/restriction_change": restriction_change +"/driveactivity:v2/Suggestion": suggestion +"/driveactivity:v2/Suggestion/subtype": subtype +"/driveactivity:v2/SystemEvent": system_event +"/driveactivity:v2/SystemEvent/type": type +"/driveactivity:v2/Target": target +"/driveactivity:v2/Target/driveItem": drive_item +"/driveactivity:v2/Target/fileComment": file_comment +"/driveactivity:v2/Target/teamDrive": team_drive +"/driveactivity:v2/TargetReference": target_reference +"/driveactivity:v2/TargetReference/driveItem": drive_item +"/driveactivity:v2/TargetReference/teamDrive": team_drive +"/driveactivity:v2/TeamDrive": team_drive +"/driveactivity:v2/TeamDrive/name": name +"/driveactivity:v2/TeamDrive/root": root +"/driveactivity:v2/TeamDrive/title": title +"/driveactivity:v2/TeamDriveReference": team_drive_reference +"/driveactivity:v2/TeamDriveReference/name": name +"/driveactivity:v2/TeamDriveReference/title": title +"/driveactivity:v2/TimeRange": time_range +"/driveactivity:v2/TimeRange/endTime": end_time +"/driveactivity:v2/TimeRange/startTime": start_time +"/driveactivity:v2/UnknownUser": unknown_user +"/driveactivity:v2/Upload": upload +"/driveactivity:v2/User": user +"/driveactivity:v2/User/deletedUser": deleted_user +"/driveactivity:v2/User/knownUser": known_user +"/driveactivity:v2/User/unknownUser": unknown_user +"/driveactivity:v2/driveactivity.activity.query": query_drive_activity +"/driveactivity:v2/fields": fields +"/driveactivity:v2/key": key +"/driveactivity:v2/quotaUser": quota_user "/file:v1beta1/CancelOperationRequest": cancel_operation_request "/file:v1beta1/ClientList": client_list "/file:v1beta1/ClientList/hostNames": host_names diff --git a/generated/google/apis/adexchangebuyer2_v2beta1.rb b/generated/google/apis/adexchangebuyer2_v2beta1.rb index b5c54ff88..9cbbf6b4e 100644 --- a/generated/google/apis/adexchangebuyer2_v2beta1.rb +++ b/generated/google/apis/adexchangebuyer2_v2beta1.rb @@ -27,7 +27,7 @@ module Google # @see https://developers.google.com/authorized-buyers/apis/reference/rest/ module Adexchangebuyer2V2beta1 VERSION = 'V2beta1' - REVISION = '20181024' + REVISION = '20181113' # Manage your Ad Exchange buyer account configuration AUTH_ADEXCHANGE_BUYER = 'https://www.googleapis.com/auth/adexchange.buyer' diff --git a/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb b/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb index 0c1426384..b6f8f4fb7 100644 --- a/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +++ b/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb @@ -3712,7 +3712,9 @@ module Google include Google::Apis::Core::Hashable # The publisher identifier for this row, if a breakdown by - # BreakdownDimension.PUBLISHER_IDENTIFIER + # [BreakdownDimension.PUBLISHER_IDENTIFIER](https://developers.google.com/ + # authorized-buyers/apis/reference/rest/v2beta1/bidders.accounts.filterSets# + # FilterSet.BreakdownDimension) # was requested. # Corresponds to the JSON property `publisherIdentifier` # @return [String] diff --git a/generated/google/apis/alertcenter_v1beta1.rb b/generated/google/apis/alertcenter_v1beta1.rb index 61dd10c47..0b0e31c26 100644 --- a/generated/google/apis/alertcenter_v1beta1.rb +++ b/generated/google/apis/alertcenter_v1beta1.rb @@ -25,7 +25,7 @@ module Google # @see https://developers.google.com/admin-sdk/alertcenter/ module AlertcenterV1beta1 VERSION = 'V1beta1' - REVISION = '20181107' + REVISION = '20181110' end end end diff --git a/generated/google/apis/alertcenter_v1beta1/service.rb b/generated/google/apis/alertcenter_v1beta1/service.rb index 543758dfb..487872703 100644 --- a/generated/google/apis/alertcenter_v1beta1/service.rb +++ b/generated/google/apis/alertcenter_v1beta1/service.rb @@ -131,7 +131,8 @@ module Google # Optional. A query string for filtering alert results. # For more details, see [Query # filters](/admin-sdk/alertcenter/guides/query-filters) and [Supported - # query filter fields](/admin-sdk/alertcenter/reference/filter-fields). + # query filter fields](/admin-sdk/alertcenter/reference/filter-fields#alerts. + # list). # @param [String] order_by # Optional. The sort order of the list results. # If not specified results may be returned in arbitrary order. @@ -226,6 +227,11 @@ module Google # customer the alert feedback are associated with. # Inferred from the caller identity if not provided. # @param [String] filter + # Optional. A query string for filtering alert feedback results. + # For more details, see [Query + # filters](/admin-sdk/alertcenter/guides/query-filters) and [Supported + # query filter fields](/admin-sdk/alertcenter/reference/filter-fields#alerts. + # feedback.list). # @param [String] fields # Selector specifying which fields to include in a partial response. # @param [String] quota_user diff --git a/generated/google/apis/classroom_v1.rb b/generated/google/apis/classroom_v1.rb index d6d8f98a8..9cb4f7359 100644 --- a/generated/google/apis/classroom_v1.rb +++ b/generated/google/apis/classroom_v1.rb @@ -25,7 +25,7 @@ module Google # @see https://developers.google.com/classroom/ module ClassroomV1 VERSION = 'V1' - REVISION = '20180919' + REVISION = '20181113' # View and manage announcements in Google Classroom AUTH_CLASSROOM_ANNOUNCEMENTS = 'https://www.googleapis.com/auth/classroom.announcements' diff --git a/generated/google/apis/classroom_v1/service.rb b/generated/google/apis/classroom_v1/service.rb index c3ad7930c..e7b2ccd55 100644 --- a/generated/google/apis/classroom_v1/service.rb +++ b/generated/google/apis/classroom_v1/service.rb @@ -1309,7 +1309,7 @@ module Google # Reclaims a student submission on behalf of the student that owns it. # Reclaiming a student submission transfers ownership of attached Drive - # files to the student and update the submission state. + # files to the student and updates the submission state. # Only the student that owns the requested student submission may call this # method, and only for a student submission that has been turned in. # This request must be made by the Developer Console project of the diff --git a/generated/google/apis/dataflow_v1b3.rb b/generated/google/apis/dataflow_v1b3.rb index 67e1014c5..57bd48ee9 100644 --- a/generated/google/apis/dataflow_v1b3.rb +++ b/generated/google/apis/dataflow_v1b3.rb @@ -25,7 +25,7 @@ module Google # @see https://cloud.google.com/dataflow module DataflowV1b3 VERSION = 'V1b3' - REVISION = '20181016' + REVISION = '20181107' # View and manage your data across Google Cloud Platform services AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' diff --git a/generated/google/apis/dataflow_v1b3/classes.rb b/generated/google/apis/dataflow_v1b3/classes.rb index 6331039cc..0d4777ad9 100644 --- a/generated/google/apis/dataflow_v1b3/classes.rb +++ b/generated/google/apis/dataflow_v1b3/classes.rb @@ -1699,6 +1699,12 @@ module Google # @return [String] attr_accessor :create_time + # If this is specified, the job's initial state is populated from the given + # snapshot. + # Corresponds to the JSON property `createdFromSnapshotId` + # @return [String] + attr_accessor :created_from_snapshot_id + # The current state of the job. # Jobs are created in the `JOB_STATE_STOPPED` state unless otherwise # specified. @@ -1820,11 +1826,17 @@ module Google # @return [String] attr_accessor :start_time + # Exactly one of step or steps_location should be specified. # The top-level steps that constitute the entire job. # Corresponds to the JSON property `steps` # @return [Array] attr_accessor :steps + # The GCS location where the steps are stored. + # Corresponds to the JSON property `stepsLocation` + # @return [String] + attr_accessor :steps_location + # A set of files the system should be aware of that are used # for temporary storage. These temporary files will be # removed on job completion. @@ -1857,6 +1869,7 @@ module Google def update!(**args) @client_request_id = args[:client_request_id] if args.key?(:client_request_id) @create_time = args[:create_time] if args.key?(:create_time) + @created_from_snapshot_id = args[:created_from_snapshot_id] if args.key?(:created_from_snapshot_id) @current_state = args[:current_state] if args.key?(:current_state) @current_state_time = args[:current_state_time] if args.key?(:current_state_time) @environment = args[:environment] if args.key?(:environment) @@ -1874,6 +1887,7 @@ module Google @stage_states = args[:stage_states] if args.key?(:stage_states) @start_time = args[:start_time] if args.key?(:start_time) @steps = args[:steps] if args.key?(:steps) + @steps_location = args[:steps_location] if args.key?(:steps_location) @temp_files = args[:temp_files] if args.key?(:temp_files) @transform_name_mapping = args[:transform_name_mapping] if args.key?(:transform_name_mapping) @type = args[:type] if args.key?(:type) @@ -3561,6 +3575,74 @@ module Google end end + # Represents a snapshot of a job. + class Snapshot + include Google::Apis::Core::Hashable + + # The time this snapshot was created. + # Corresponds to the JSON property `creationTime` + # @return [String] + attr_accessor :creation_time + + # The unique ID of this snapshot. + # Corresponds to the JSON property `id` + # @return [String] + attr_accessor :id + + # The project this snapshot belongs to. + # Corresponds to the JSON property `projectId` + # @return [String] + attr_accessor :project_id + + # The job this snapshot was created from. + # Corresponds to the JSON property `sourceJobId` + # @return [String] + attr_accessor :source_job_id + + # The time after which this snapshot will be automatically deleted. + # Corresponds to the JSON property `ttl` + # @return [String] + attr_accessor :ttl + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @creation_time = args[:creation_time] if args.key?(:creation_time) + @id = args[:id] if args.key?(:id) + @project_id = args[:project_id] if args.key?(:project_id) + @source_job_id = args[:source_job_id] if args.key?(:source_job_id) + @ttl = args[:ttl] if args.key?(:ttl) + end + end + + # Request to create a snapshot of a job. + class SnapshotJobRequest + include Google::Apis::Core::Hashable + + # The location that contains this job. + # Corresponds to the JSON property `location` + # @return [String] + attr_accessor :location + + # TTL for the snapshot. + # Corresponds to the JSON property `ttl` + # @return [String] + attr_accessor :ttl + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @location = args[:location] if args.key?(:location) + @ttl = args[:ttl] if args.key?(:ttl) + end + end + # A source that records can be read and decoded from. class Source include Google::Apis::Core::Hashable diff --git a/generated/google/apis/dataflow_v1b3/representations.rb b/generated/google/apis/dataflow_v1b3/representations.rb index 65b744d16..a350c8d63 100644 --- a/generated/google/apis/dataflow_v1b3/representations.rb +++ b/generated/google/apis/dataflow_v1b3/representations.rb @@ -562,6 +562,18 @@ module Google include Google::Apis::Core::JsonObjectSupport end + class Snapshot + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class SnapshotJobRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + class Source class Representation < Google::Apis::Core::JsonRepresentation; end @@ -1294,6 +1306,7 @@ module Google class Representation < Google::Apis::Core::JsonRepresentation property :client_request_id, as: 'clientRequestId' property :create_time, as: 'createTime' + property :created_from_snapshot_id, as: 'createdFromSnapshotId' property :current_state, as: 'currentState' property :current_state_time, as: 'currentStateTime' property :environment, as: 'environment', class: Google::Apis::DataflowV1b3::Environment, decorator: Google::Apis::DataflowV1b3::Environment::Representation @@ -1317,6 +1330,7 @@ module Google property :start_time, as: 'startTime' collection :steps, as: 'steps', class: Google::Apis::DataflowV1b3::Step, decorator: Google::Apis::DataflowV1b3::Step::Representation + property :steps_location, as: 'stepsLocation' collection :temp_files, as: 'tempFiles' hash :transform_name_mapping, as: 'transformNameMapping' property :type, as: 'type' @@ -1802,6 +1816,25 @@ module Google end end + class Snapshot + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :creation_time, as: 'creationTime' + property :id, as: 'id' + property :project_id, as: 'projectId' + property :source_job_id, as: 'sourceJobId' + property :ttl, as: 'ttl' + end + end + + class SnapshotJobRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :location, as: 'location' + property :ttl, as: 'ttl' + end + end + class Source # @private class Representation < Google::Apis::Core::JsonRepresentation diff --git a/generated/google/apis/dataflow_v1b3/service.rb b/generated/google/apis/dataflow_v1b3/service.rb index 426d37749..34f73907a 100644 --- a/generated/google/apis/dataflow_v1b3/service.rb +++ b/generated/google/apis/dataflow_v1b3/service.rb @@ -297,6 +297,42 @@ module Google execute_or_queue_command(command, &block) end + # Snapshot the state of a streaming job. + # @param [String] project_id + # The project which owns the job to be snapshotted. + # @param [String] job_id + # The job to be snapshotted. + # @param [Google::Apis::DataflowV1b3::SnapshotJobRequest] snapshot_job_request_object + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # Available to use for quota purposes for server-side applications. Can be any + # arbitrary string assigned to a user, but should not exceed 40 characters. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::DataflowV1b3::Snapshot] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::DataflowV1b3::Snapshot] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def snapshot_project_job(project_id, job_id, snapshot_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1b3/projects/{projectId}/jobs/{jobId}:snapshot', options) + command.request_representation = Google::Apis::DataflowV1b3::SnapshotJobRequest::Representation + command.request_object = snapshot_job_request_object + command.response_representation = Google::Apis::DataflowV1b3::Snapshot::Representation + command.response_class = Google::Apis::DataflowV1b3::Snapshot + command.params['projectId'] = project_id unless project_id.nil? + command.params['jobId'] = job_id unless job_id.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + # Updates the state of an existing Cloud Dataflow job. # @param [String] project_id # The ID of the Cloud Platform project that the job belongs to. @@ -742,6 +778,45 @@ module Google execute_or_queue_command(command, &block) end + # Snapshot the state of a streaming job. + # @param [String] project_id + # The project which owns the job to be snapshotted. + # @param [String] location + # The location that contains this job. + # @param [String] job_id + # The job to be snapshotted. + # @param [Google::Apis::DataflowV1b3::SnapshotJobRequest] snapshot_job_request_object + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # Available to use for quota purposes for server-side applications. Can be any + # arbitrary string assigned to a user, but should not exceed 40 characters. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::DataflowV1b3::Snapshot] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::DataflowV1b3::Snapshot] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def snapshot_project_location_job(project_id, location, job_id, snapshot_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/jobs/{jobId}:snapshot', options) + command.request_representation = Google::Apis::DataflowV1b3::SnapshotJobRequest::Representation + command.request_object = snapshot_job_request_object + command.response_representation = Google::Apis::DataflowV1b3::Snapshot::Representation + command.response_class = Google::Apis::DataflowV1b3::Snapshot + command.params['projectId'] = project_id unless project_id.nil? + command.params['location'] = location unless location.nil? + command.params['jobId'] = job_id unless job_id.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + # Updates the state of an existing Cloud Dataflow job. # @param [String] project_id # The ID of the Cloud Platform project that the job belongs to. @@ -1038,7 +1113,7 @@ module Google # @param [String] gcs_path # Required. A Cloud Storage path to the template from which to # create the job. - # Must be a valid Cloud Storage URL, beginning with `gs://`. + # Must be valid Cloud Storage URL, beginning with 'gs://'. # @param [String] view # The view to retrieve. Defaults to METADATA_ONLY. # @param [String] fields @@ -1077,8 +1152,14 @@ module Google # @param [String] location # The location to which to direct the request. # @param [Google::Apis::DataflowV1b3::LaunchTemplateParameters] launch_template_parameters_object + # @param [String] dynamic_template_gcs_path + # Path to dynamic template spec file on GCS. + # The file must be a Json serialized DynamicTemplateFieSpec object. + # @param [String] dynamic_template_staging_location + # Cloud Storage path for staging dependencies. + # Must be a valid Cloud Storage URL, beginning with `gs://`. # @param [String] gcs_path - # Required. A Cloud Storage path to the template from which to create + # A Cloud Storage path to the template from which to create # the job. # Must be valid Cloud Storage URL, beginning with 'gs://'. # @param [Boolean] validate_only @@ -1101,7 +1182,7 @@ module Google # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification # @raise [Google::Apis::AuthorizationError] Authorization is required - def launch_project_location_template(project_id, location, launch_template_parameters_object = nil, gcs_path: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block) + def launch_project_location_template(project_id, location, launch_template_parameters_object = nil, dynamic_template_gcs_path: nil, dynamic_template_staging_location: nil, gcs_path: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1b3/projects/{projectId}/locations/{location}/templates:launch', options) command.request_representation = Google::Apis::DataflowV1b3::LaunchTemplateParameters::Representation command.request_object = launch_template_parameters_object @@ -1109,6 +1190,8 @@ module Google command.response_class = Google::Apis::DataflowV1b3::LaunchTemplateResponse command.params['projectId'] = project_id unless project_id.nil? command.params['location'] = location unless location.nil? + command.query['dynamicTemplate.gcsPath'] = dynamic_template_gcs_path unless dynamic_template_gcs_path.nil? + command.query['dynamicTemplate.stagingLocation'] = dynamic_template_staging_location unless dynamic_template_staging_location.nil? command.query['gcsPath'] = gcs_path unless gcs_path.nil? command.query['validateOnly'] = validate_only unless validate_only.nil? command.query['fields'] = fields unless fields.nil? @@ -1155,7 +1238,7 @@ module Google # @param [String] gcs_path # Required. A Cloud Storage path to the template from which to # create the job. - # Must be a valid Cloud Storage URL, beginning with `gs://`. + # Must be valid Cloud Storage URL, beginning with 'gs://'. # @param [String] location # The location to which to direct the request. # @param [String] view @@ -1194,8 +1277,14 @@ module Google # @param [String] project_id # Required. The ID of the Cloud Platform project that the job belongs to. # @param [Google::Apis::DataflowV1b3::LaunchTemplateParameters] launch_template_parameters_object + # @param [String] dynamic_template_gcs_path + # Path to dynamic template spec file on GCS. + # The file must be a Json serialized DynamicTemplateFieSpec object. + # @param [String] dynamic_template_staging_location + # Cloud Storage path for staging dependencies. + # Must be a valid Cloud Storage URL, beginning with `gs://`. # @param [String] gcs_path - # Required. A Cloud Storage path to the template from which to create + # A Cloud Storage path to the template from which to create # the job. # Must be valid Cloud Storage URL, beginning with 'gs://'. # @param [String] location @@ -1220,13 +1309,15 @@ module Google # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification # @raise [Google::Apis::AuthorizationError] Authorization is required - def launch_project_template(project_id, launch_template_parameters_object = nil, gcs_path: nil, location: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block) + def launch_project_template(project_id, launch_template_parameters_object = nil, dynamic_template_gcs_path: nil, dynamic_template_staging_location: nil, gcs_path: nil, location: nil, validate_only: nil, fields: nil, quota_user: nil, options: nil, &block) command = make_simple_command(:post, 'v1b3/projects/{projectId}/templates:launch', options) command.request_representation = Google::Apis::DataflowV1b3::LaunchTemplateParameters::Representation command.request_object = launch_template_parameters_object command.response_representation = Google::Apis::DataflowV1b3::LaunchTemplateResponse::Representation command.response_class = Google::Apis::DataflowV1b3::LaunchTemplateResponse command.params['projectId'] = project_id unless project_id.nil? + command.query['dynamicTemplate.gcsPath'] = dynamic_template_gcs_path unless dynamic_template_gcs_path.nil? + command.query['dynamicTemplate.stagingLocation'] = dynamic_template_staging_location unless dynamic_template_staging_location.nil? command.query['gcsPath'] = gcs_path unless gcs_path.nil? command.query['location'] = location unless location.nil? command.query['validateOnly'] = validate_only unless validate_only.nil? diff --git a/generated/google/apis/dlp_v2.rb b/generated/google/apis/dlp_v2.rb index 97f0639a1..3837b93e9 100644 --- a/generated/google/apis/dlp_v2.rb +++ b/generated/google/apis/dlp_v2.rb @@ -27,7 +27,7 @@ module Google # @see https://cloud.google.com/dlp/docs/ module DlpV2 VERSION = 'V2' - REVISION = '20181030' + REVISION = '20181113' # View and manage your data across Google Cloud Platform services AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' diff --git a/generated/google/apis/driveactivity_v2.rb b/generated/google/apis/driveactivity_v2.rb new file mode 100644 index 000000000..991570e94 --- /dev/null +++ b/generated/google/apis/driveactivity_v2.rb @@ -0,0 +1,37 @@ +# Copyright 2015 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +require 'google/apis/driveactivity_v2/service.rb' +require 'google/apis/driveactivity_v2/classes.rb' +require 'google/apis/driveactivity_v2/representations.rb' + +module Google + module Apis + # Drive Activity API + # + # + # + # @see https://developers.google.com/drive/activity/ + module DriveactivityV2 + VERSION = 'V2' + REVISION = '20181113' + + # View and add to the activity record of files in your Google Drive + AUTH_DRIVE_ACTIVITY = 'https://www.googleapis.com/auth/drive.activity' + + # View the activity record of files in your Google Drive + AUTH_DRIVE_ACTIVITY_READONLY = 'https://www.googleapis.com/auth/drive.activity.readonly' + end + end +end diff --git a/generated/google/apis/driveactivity_v2/classes.rb b/generated/google/apis/driveactivity_v2/classes.rb new file mode 100644 index 000000000..609fd67fd --- /dev/null +++ b/generated/google/apis/driveactivity_v2/classes.rb @@ -0,0 +1,1388 @@ +# Copyright 2015 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +require 'date' +require 'google/apis/core/base_service' +require 'google/apis/core/json_representation' +require 'google/apis/core/hashable' +require 'google/apis/errors' + +module Google + module Apis + module DriveactivityV2 + + # Information about the action. + class Action + include Google::Apis::Core::Hashable + + # The actor of a Drive activity. + # Corresponds to the JSON property `actor` + # @return [Google::Apis::DriveactivityV2::Actor] + attr_accessor :actor + + # Data describing the type and additional information of an action. + # Corresponds to the JSON property `detail` + # @return [Google::Apis::DriveactivityV2::ActionDetail] + attr_accessor :detail + + # Information about the target of activity. + # Corresponds to the JSON property `target` + # @return [Google::Apis::DriveactivityV2::Target] + attr_accessor :target + + # Information about time ranges. + # Corresponds to the JSON property `timeRange` + # @return [Google::Apis::DriveactivityV2::TimeRange] + attr_accessor :time_range + + # The action occurred at this specific time. + # Corresponds to the JSON property `timestamp` + # @return [String] + attr_accessor :timestamp + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @actor = args[:actor] if args.key?(:actor) + @detail = args[:detail] if args.key?(:detail) + @target = args[:target] if args.key?(:target) + @time_range = args[:time_range] if args.key?(:time_range) + @timestamp = args[:timestamp] if args.key?(:timestamp) + end + end + + # Data describing the type and additional information of an action. + class ActionDetail + include Google::Apis::Core::Hashable + + # A change about comments on an object. + # Corresponds to the JSON property `comment` + # @return [Google::Apis::DriveactivityV2::Comment] + attr_accessor :comment + + # An object was created. + # Corresponds to the JSON property `create` + # @return [Google::Apis::DriveactivityV2::Create] + attr_accessor :create + + # An object was deleted. + # Corresponds to the JSON property `delete` + # @return [Google::Apis::DriveactivityV2::Delete] + attr_accessor :delete + + # A change in the object's data leak prevention status. + # Corresponds to the JSON property `dlpChange` + # @return [Google::Apis::DriveactivityV2::DataLeakPreventionChange] + attr_accessor :dlp_change + + # An empty message indicating an object was edited. + # Corresponds to the JSON property `edit` + # @return [Google::Apis::DriveactivityV2::Edit] + attr_accessor :edit + + # An object was moved. + # Corresponds to the JSON property `move` + # @return [Google::Apis::DriveactivityV2::Move] + attr_accessor :move + + # A change of the permission setting on an item. + # Corresponds to the JSON property `permissionChange` + # @return [Google::Apis::DriveactivityV2::PermissionChange] + attr_accessor :permission_change + + # Activity in applications other than Drive. + # Corresponds to the JSON property `reference` + # @return [Google::Apis::DriveactivityV2::ApplicationReference] + attr_accessor :reference + + # An object was renamed. + # Corresponds to the JSON property `rename` + # @return [Google::Apis::DriveactivityV2::Rename] + attr_accessor :rename + + # A deleted object was restored. + # Corresponds to the JSON property `restore` + # @return [Google::Apis::DriveactivityV2::Restore] + attr_accessor :restore + + # Information about settings changes. + # Corresponds to the JSON property `settingsChange` + # @return [Google::Apis::DriveactivityV2::SettingsChange] + attr_accessor :settings_change + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @comment = args[:comment] if args.key?(:comment) + @create = args[:create] if args.key?(:create) + @delete = args[:delete] if args.key?(:delete) + @dlp_change = args[:dlp_change] if args.key?(:dlp_change) + @edit = args[:edit] if args.key?(:edit) + @move = args[:move] if args.key?(:move) + @permission_change = args[:permission_change] if args.key?(:permission_change) + @reference = args[:reference] if args.key?(:reference) + @rename = args[:rename] if args.key?(:rename) + @restore = args[:restore] if args.key?(:restore) + @settings_change = args[:settings_change] if args.key?(:settings_change) + end + end + + # The actor of a Drive activity. + class Actor + include Google::Apis::Core::Hashable + + # Empty message representing an administrator. + # Corresponds to the JSON property `administrator` + # @return [Google::Apis::DriveactivityV2::Administrator] + attr_accessor :administrator + + # Empty message representing an anonymous user or indicating the authenticated + # user should be anonymized. + # Corresponds to the JSON property `anonymous` + # @return [Google::Apis::DriveactivityV2::AnonymousUser] + attr_accessor :anonymous + + # Information about an impersonation, where an admin acts on behalf of an end + # user. Information about the acting admin is not currently available. + # Corresponds to the JSON property `impersonation` + # @return [Google::Apis::DriveactivityV2::Impersonation] + attr_accessor :impersonation + + # Event triggered by system operations instead of end users. + # Corresponds to the JSON property `system` + # @return [Google::Apis::DriveactivityV2::SystemEvent] + attr_accessor :system + + # Information about an end user. + # Corresponds to the JSON property `user` + # @return [Google::Apis::DriveactivityV2::User] + attr_accessor :user + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @administrator = args[:administrator] if args.key?(:administrator) + @anonymous = args[:anonymous] if args.key?(:anonymous) + @impersonation = args[:impersonation] if args.key?(:impersonation) + @system = args[:system] if args.key?(:system) + @user = args[:user] if args.key?(:user) + end + end + + # Empty message representing an administrator. + class Administrator + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Empty message representing an anonymous user or indicating the authenticated + # user should be anonymized. + class AnonymousUser + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Represents any user (including a logged out user). + class Anyone + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Activity in applications other than Drive. + class ApplicationReference + include Google::Apis::Core::Hashable + + # The reference type corresponding to this event. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # A comment with an assignment. + class Assignment + include Google::Apis::Core::Hashable + + # The sub-type of this event. + # Corresponds to the JSON property `subtype` + # @return [String] + attr_accessor :subtype + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @subtype = args[:subtype] if args.key?(:subtype) + end + end + + # A change about comments on an object. + class Comment + include Google::Apis::Core::Hashable + + # A comment with an assignment. + # Corresponds to the JSON property `assignment` + # @return [Google::Apis::DriveactivityV2::Assignment] + attr_accessor :assignment + + # Users who are mentioned in this comment. + # Corresponds to the JSON property `mentionedUsers` + # @return [Array] + attr_accessor :mentioned_users + + # A regular posted comment. + # Corresponds to the JSON property `post` + # @return [Google::Apis::DriveactivityV2::Post] + attr_accessor :post + + # A suggestion. + # Corresponds to the JSON property `suggestion` + # @return [Google::Apis::DriveactivityV2::Suggestion] + attr_accessor :suggestion + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @assignment = args[:assignment] if args.key?(:assignment) + @mentioned_users = args[:mentioned_users] if args.key?(:mentioned_users) + @post = args[:post] if args.key?(:post) + @suggestion = args[:suggestion] if args.key?(:suggestion) + end + end + + # How the individual activities are consolidated. A set of activities may be + # consolidated into one combined activity if they are related in some way, such + # as one actor performing the same action on multiple targets, or multiple + # actors performing the same action on a single target. The strategy defines + # the rules for which activities are related. + class ConsolidationStrategy + include Google::Apis::Core::Hashable + + # A strategy which consolidates activities using the grouping rules from the + # legacy V1 Activity API. Similar actions occurring within a window of time + # can be grouped across multiple targets (such as moving a set of files at + # once) or multiple actors (such as several users editing the same item). + # Grouping rules for this strategy are specific to each type of action. + # Corresponds to the JSON property `legacy` + # @return [Google::Apis::DriveactivityV2::Legacy] + attr_accessor :legacy + + # A strategy which does no consolidation of individual activities. + # Corresponds to the JSON property `none` + # @return [Google::Apis::DriveactivityV2::NoConsolidation] + attr_accessor :none + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @legacy = args[:legacy] if args.key?(:legacy) + @none = args[:none] if args.key?(:none) + end + end + + # An object was created by copying an existing object. + class Copy + include Google::Apis::Core::Hashable + + # A lightweight reference to the target of activity. + # Corresponds to the JSON property `originalObject` + # @return [Google::Apis::DriveactivityV2::TargetReference] + attr_accessor :original_object + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @original_object = args[:original_object] if args.key?(:original_object) + end + end + + # An object was created. + class Create + include Google::Apis::Core::Hashable + + # An object was created by copying an existing object. + # Corresponds to the JSON property `copy` + # @return [Google::Apis::DriveactivityV2::Copy] + attr_accessor :copy + + # An object was created from scratch. + # Corresponds to the JSON property `new` + # @return [Google::Apis::DriveactivityV2::New] + attr_accessor :new + + # An object was uploaded into Drive. + # Corresponds to the JSON property `upload` + # @return [Google::Apis::DriveactivityV2::Upload] + attr_accessor :upload + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @copy = args[:copy] if args.key?(:copy) + @new = args[:new] if args.key?(:new) + @upload = args[:upload] if args.key?(:upload) + end + end + + # A change in the object's data leak prevention status. + class DataLeakPreventionChange + include Google::Apis::Core::Hashable + + # The type of Data Leak Prevention (DLP) change. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # An object was deleted. + class Delete + include Google::Apis::Core::Hashable + + # The type of delete action taken. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # A user whose account has since been deleted. + class DeletedUser + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Information about a domain. + class Domain + include Google::Apis::Core::Hashable + + # An opaque string used to identify this domain. + # Corresponds to the JSON property `legacyId` + # @return [String] + attr_accessor :legacy_id + + # The name of the domain, e.g. "google.com". + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @legacy_id = args[:legacy_id] if args.key?(:legacy_id) + @name = args[:name] if args.key?(:name) + end + end + + # A single Drive activity comprising one or more Actions by one or more + # Actors on one or more Targets. Some Action groupings occur spontaneously, + # such as moving an item into a shared folder triggering a permission change. + # Other groupings of related Actions, such as multiple Actors editing one item + # or moving multiple files into a new folder, are controlled by the selection + # of a ConsolidationStrategy in the QueryDriveActivityRequest. + class DriveActivity + include Google::Apis::Core::Hashable + + # Details on all actions in this activity. + # Corresponds to the JSON property `actions` + # @return [Array] + attr_accessor :actions + + # All actor(s) responsible for the activity. + # Corresponds to the JSON property `actors` + # @return [Array] + attr_accessor :actors + + # Data describing the type and additional information of an action. + # Corresponds to the JSON property `primaryActionDetail` + # @return [Google::Apis::DriveactivityV2::ActionDetail] + attr_accessor :primary_action_detail + + # All Drive objects this activity is about (e.g. file, folder, Team Drive). + # This represents the state of the target immediately after the actions + # occurred. + # Corresponds to the JSON property `targets` + # @return [Array] + attr_accessor :targets + + # Information about time ranges. + # Corresponds to the JSON property `timeRange` + # @return [Google::Apis::DriveactivityV2::TimeRange] + attr_accessor :time_range + + # The activity occurred at this specific time. + # Corresponds to the JSON property `timestamp` + # @return [String] + attr_accessor :timestamp + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @actions = args[:actions] if args.key?(:actions) + @actors = args[:actors] if args.key?(:actors) + @primary_action_detail = args[:primary_action_detail] if args.key?(:primary_action_detail) + @targets = args[:targets] if args.key?(:targets) + @time_range = args[:time_range] if args.key?(:time_range) + @timestamp = args[:timestamp] if args.key?(:timestamp) + end + end + + # A Drive item, such as a file or folder. + class DriveItem + include Google::Apis::Core::Hashable + + # A Drive item which is a file. + # Corresponds to the JSON property `file` + # @return [Google::Apis::DriveactivityV2::File] + attr_accessor :file + + # A Drive item which is a folder. + # Corresponds to the JSON property `folder` + # @return [Google::Apis::DriveactivityV2::Folder] + attr_accessor :folder + + # The MIME type of the Drive item. See + # https://developers.google.com/drive/v3/web/mime-types. + # Corresponds to the JSON property `mimeType` + # @return [String] + attr_accessor :mime_type + + # The target Drive item. The format is "items/ITEM_ID". + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + # Information about the owner of a Drive item. + # Corresponds to the JSON property `owner` + # @return [Google::Apis::DriveactivityV2::Owner] + attr_accessor :owner + + # The title of the Drive item. + # Corresponds to the JSON property `title` + # @return [String] + attr_accessor :title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @file = args[:file] if args.key?(:file) + @folder = args[:folder] if args.key?(:folder) + @mime_type = args[:mime_type] if args.key?(:mime_type) + @name = args[:name] if args.key?(:name) + @owner = args[:owner] if args.key?(:owner) + @title = args[:title] if args.key?(:title) + end + end + + # A lightweight reference to a Drive item, such as a file or folder. + class DriveItemReference + include Google::Apis::Core::Hashable + + # A Drive item which is a file. + # Corresponds to the JSON property `file` + # @return [Google::Apis::DriveactivityV2::File] + attr_accessor :file + + # A Drive item which is a folder. + # Corresponds to the JSON property `folder` + # @return [Google::Apis::DriveactivityV2::Folder] + attr_accessor :folder + + # The target Drive item. The format is "items/ITEM_ID". + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + # The title of the Drive item. + # Corresponds to the JSON property `title` + # @return [String] + attr_accessor :title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @file = args[:file] if args.key?(:file) + @folder = args[:folder] if args.key?(:folder) + @name = args[:name] if args.key?(:name) + @title = args[:title] if args.key?(:title) + end + end + + # An empty message indicating an object was edited. + class Edit + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # A Drive item which is a file. + class File + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # A comment on a file. + class FileComment + include Google::Apis::Core::Hashable + + # The comment in the discussion thread. This identifier is an opaque string + # compatible with the Drive API; see + # https://developers.google.com/drive/v3/reference/comments/get + # Corresponds to the JSON property `legacyCommentId` + # @return [String] + attr_accessor :legacy_comment_id + + # The discussion thread to which the comment was added. This identifier is an + # opaque string compatible with the Drive API and references the first + # comment in a discussion; see + # https://developers.google.com/drive/v3/reference/comments/get + # Corresponds to the JSON property `legacyDiscussionId` + # @return [String] + attr_accessor :legacy_discussion_id + + # The link to the discussion thread containing this comment, for example, + # "https://docs.google.com/DOCUMENT_ID/edit?disco=THREAD_ID". + # Corresponds to the JSON property `linkToDiscussion` + # @return [String] + attr_accessor :link_to_discussion + + # A Drive item, such as a file or folder. + # Corresponds to the JSON property `parent` + # @return [Google::Apis::DriveactivityV2::DriveItem] + attr_accessor :parent + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @legacy_comment_id = args[:legacy_comment_id] if args.key?(:legacy_comment_id) + @legacy_discussion_id = args[:legacy_discussion_id] if args.key?(:legacy_discussion_id) + @link_to_discussion = args[:link_to_discussion] if args.key?(:link_to_discussion) + @parent = args[:parent] if args.key?(:parent) + end + end + + # A Drive item which is a folder. + class Folder + include Google::Apis::Core::Hashable + + # The type of Drive folder. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # Information about a group. + class Group + include Google::Apis::Core::Hashable + + # The email address of the group. + # Corresponds to the JSON property `email` + # @return [String] + attr_accessor :email + + # The title of the group. + # Corresponds to the JSON property `title` + # @return [String] + attr_accessor :title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @email = args[:email] if args.key?(:email) + @title = args[:title] if args.key?(:title) + end + end + + # Information about an impersonation, where an admin acts on behalf of an end + # user. Information about the acting admin is not currently available. + class Impersonation + include Google::Apis::Core::Hashable + + # Information about an end user. + # Corresponds to the JSON property `impersonatedUser` + # @return [Google::Apis::DriveactivityV2::User] + attr_accessor :impersonated_user + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @impersonated_user = args[:impersonated_user] if args.key?(:impersonated_user) + end + end + + # A known user. + class KnownUser + include Google::Apis::Core::Hashable + + # True if this is the user making the request. + # Corresponds to the JSON property `isCurrentUser` + # @return [Boolean] + attr_accessor :is_current_user + alias_method :is_current_user?, :is_current_user + + # The identifier for this user that can be used with the People API to get + # more information. The format is "people/ACCOUNT_ID". See + # https://developers.google.com/people/. + # Corresponds to the JSON property `personName` + # @return [String] + attr_accessor :person_name + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @is_current_user = args[:is_current_user] if args.key?(:is_current_user) + @person_name = args[:person_name] if args.key?(:person_name) + end + end + + # A strategy which consolidates activities using the grouping rules from the + # legacy V1 Activity API. Similar actions occurring within a window of time + # can be grouped across multiple targets (such as moving a set of files at + # once) or multiple actors (such as several users editing the same item). + # Grouping rules for this strategy are specific to each type of action. + class Legacy + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # An object was moved. + class Move + include Google::Apis::Core::Hashable + + # The added parent object(s). + # Corresponds to the JSON property `addedParents` + # @return [Array] + attr_accessor :added_parents + + # The removed parent object(s). + # Corresponds to the JSON property `removedParents` + # @return [Array] + attr_accessor :removed_parents + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @added_parents = args[:added_parents] if args.key?(:added_parents) + @removed_parents = args[:removed_parents] if args.key?(:removed_parents) + end + end + + # An object was created from scratch. + class New + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # A strategy which does no consolidation of individual activities. + class NoConsolidation + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Information about the owner of a Drive item. + class Owner + include Google::Apis::Core::Hashable + + # Information about a domain. + # Corresponds to the JSON property `domain` + # @return [Google::Apis::DriveactivityV2::Domain] + attr_accessor :domain + + # A lightweight reference to a Team Drive. + # Corresponds to the JSON property `teamDrive` + # @return [Google::Apis::DriveactivityV2::TeamDriveReference] + attr_accessor :team_drive + + # Information about an end user. + # Corresponds to the JSON property `user` + # @return [Google::Apis::DriveactivityV2::User] + attr_accessor :user + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @domain = args[:domain] if args.key?(:domain) + @team_drive = args[:team_drive] if args.key?(:team_drive) + @user = args[:user] if args.key?(:user) + end + end + + # The permission setting of an object. + class Permission + include Google::Apis::Core::Hashable + + # If true, the item can be discovered (e.g. in the user's "Shared with me" + # collection) without needing a link to the item. + # Corresponds to the JSON property `allowDiscovery` + # @return [Boolean] + attr_accessor :allow_discovery + alias_method :allow_discovery?, :allow_discovery + + # Represents any user (including a logged out user). + # Corresponds to the JSON property `anyone` + # @return [Google::Apis::DriveactivityV2::Anyone] + attr_accessor :anyone + + # Information about a domain. + # Corresponds to the JSON property `domain` + # @return [Google::Apis::DriveactivityV2::Domain] + attr_accessor :domain + + # Information about a group. + # Corresponds to the JSON property `group` + # @return [Google::Apis::DriveactivityV2::Group] + attr_accessor :group + + # Indicates the + # Google Drive permissions + # role. The role determines a user's ability to read, write, and + # comment on items. + # Corresponds to the JSON property `role` + # @return [String] + attr_accessor :role + + # Information about an end user. + # Corresponds to the JSON property `user` + # @return [Google::Apis::DriveactivityV2::User] + attr_accessor :user + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @allow_discovery = args[:allow_discovery] if args.key?(:allow_discovery) + @anyone = args[:anyone] if args.key?(:anyone) + @domain = args[:domain] if args.key?(:domain) + @group = args[:group] if args.key?(:group) + @role = args[:role] if args.key?(:role) + @user = args[:user] if args.key?(:user) + end + end + + # A change of the permission setting on an item. + class PermissionChange + include Google::Apis::Core::Hashable + + # The set of permissions added by this change. + # Corresponds to the JSON property `addedPermissions` + # @return [Array] + attr_accessor :added_permissions + + # The set of permissions removed by this change. + # Corresponds to the JSON property `removedPermissions` + # @return [Array] + attr_accessor :removed_permissions + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @added_permissions = args[:added_permissions] if args.key?(:added_permissions) + @removed_permissions = args[:removed_permissions] if args.key?(:removed_permissions) + end + end + + # A regular posted comment. + class Post + include Google::Apis::Core::Hashable + + # The sub-type of this event. + # Corresponds to the JSON property `subtype` + # @return [String] + attr_accessor :subtype + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @subtype = args[:subtype] if args.key?(:subtype) + end + end + + # The request message for querying Drive activity. + class QueryDriveActivityRequest + include Google::Apis::Core::Hashable + + # Return activities for this Drive folder and all children and descendants. + # The format is "items/ITEM_ID". + # Corresponds to the JSON property `ancestorName` + # @return [String] + attr_accessor :ancestor_name + + # How the individual activities are consolidated. A set of activities may be + # consolidated into one combined activity if they are related in some way, such + # as one actor performing the same action on multiple targets, or multiple + # actors performing the same action on a single target. The strategy defines + # the rules for which activities are related. + # Corresponds to the JSON property `consolidationStrategy` + # @return [Google::Apis::DriveactivityV2::ConsolidationStrategy] + attr_accessor :consolidation_strategy + + # The filtering for items returned from this query request. The format of the + # filter string is a sequence of expressions, joined by an optional "AND", + # where each expression is of the form "field operator value". + # Supported fields: + # - time: Uses numerical operators on date values either in + # terms of milliseconds since Jan 1, 1970 or in RFC 3339 format. + # Examples: + # - time > 1452409200000 AND time <= 1492812924310 + # - time >= "2016-01-10T01:02:03-05:00" + # - detail.action_detail_case: Uses the "has" operator (:) and + # either a singular value or a list of allowed action types enclosed in + # parentheses. + # Examples: + # - detail.action_detail_case: RENAME + # - detail.action_detail_case:(CREATE UPLOAD) + # - -detail.action_detail_case:MOVE + # Corresponds to the JSON property `filter` + # @return [String] + attr_accessor :filter + + # Return activities for this Drive item. The format is + # "items/ITEM_ID". + # Corresponds to the JSON property `itemName` + # @return [String] + attr_accessor :item_name + + # The requested number of activity to return. If not set, a default value + # will be used. + # Corresponds to the JSON property `pageSize` + # @return [Fixnum] + attr_accessor :page_size + + # The next_page_token value returned from a previous QueryDriveActivity + # request, if any. + # Corresponds to the JSON property `pageToken` + # @return [String] + attr_accessor :page_token + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @ancestor_name = args[:ancestor_name] if args.key?(:ancestor_name) + @consolidation_strategy = args[:consolidation_strategy] if args.key?(:consolidation_strategy) + @filter = args[:filter] if args.key?(:filter) + @item_name = args[:item_name] if args.key?(:item_name) + @page_size = args[:page_size] if args.key?(:page_size) + @page_token = args[:page_token] if args.key?(:page_token) + end + end + + # Response message for querying Drive activity. + class QueryDriveActivityResponse + include Google::Apis::Core::Hashable + + # List of activity requested. + # Corresponds to the JSON property `activities` + # @return [Array] + attr_accessor :activities + + # Token to retrieve the next page of results, or + # empty if there are no more results in the list. + # Corresponds to the JSON property `nextPageToken` + # @return [String] + attr_accessor :next_page_token + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @activities = args[:activities] if args.key?(:activities) + @next_page_token = args[:next_page_token] if args.key?(:next_page_token) + end + end + + # An object was renamed. + class Rename + include Google::Apis::Core::Hashable + + # The new title of the drive object. + # Corresponds to the JSON property `newTitle` + # @return [String] + attr_accessor :new_title + + # The previous title of the drive object. + # Corresponds to the JSON property `oldTitle` + # @return [String] + attr_accessor :old_title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @new_title = args[:new_title] if args.key?(:new_title) + @old_title = args[:old_title] if args.key?(:old_title) + end + end + + # A deleted object was restored. + class Restore + include Google::Apis::Core::Hashable + + # The type of restore action taken. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # Information about restriction policy changes to a feature. + class RestrictionChange + include Google::Apis::Core::Hashable + + # The feature which had a change in restriction policy. + # Corresponds to the JSON property `feature` + # @return [String] + attr_accessor :feature + + # The restriction in place after the change. + # Corresponds to the JSON property `newRestriction` + # @return [String] + attr_accessor :new_restriction + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @feature = args[:feature] if args.key?(:feature) + @new_restriction = args[:new_restriction] if args.key?(:new_restriction) + end + end + + # Information about settings changes. + class SettingsChange + include Google::Apis::Core::Hashable + + # The set of changes made to restrictions. + # Corresponds to the JSON property `restrictionChanges` + # @return [Array] + attr_accessor :restriction_changes + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @restriction_changes = args[:restriction_changes] if args.key?(:restriction_changes) + end + end + + # A suggestion. + class Suggestion + include Google::Apis::Core::Hashable + + # The sub-type of this event. + # Corresponds to the JSON property `subtype` + # @return [String] + attr_accessor :subtype + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @subtype = args[:subtype] if args.key?(:subtype) + end + end + + # Event triggered by system operations instead of end users. + class SystemEvent + include Google::Apis::Core::Hashable + + # The type of the system event that may triggered activity. + # Corresponds to the JSON property `type` + # @return [String] + attr_accessor :type + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @type = args[:type] if args.key?(:type) + end + end + + # Information about the target of activity. + class Target + include Google::Apis::Core::Hashable + + # A Drive item, such as a file or folder. + # Corresponds to the JSON property `driveItem` + # @return [Google::Apis::DriveactivityV2::DriveItem] + attr_accessor :drive_item + + # A comment on a file. + # Corresponds to the JSON property `fileComment` + # @return [Google::Apis::DriveactivityV2::FileComment] + attr_accessor :file_comment + + # Information about a Team Drive. + # Corresponds to the JSON property `teamDrive` + # @return [Google::Apis::DriveactivityV2::TeamDrive] + attr_accessor :team_drive + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @drive_item = args[:drive_item] if args.key?(:drive_item) + @file_comment = args[:file_comment] if args.key?(:file_comment) + @team_drive = args[:team_drive] if args.key?(:team_drive) + end + end + + # A lightweight reference to the target of activity. + class TargetReference + include Google::Apis::Core::Hashable + + # A lightweight reference to a Drive item, such as a file or folder. + # Corresponds to the JSON property `driveItem` + # @return [Google::Apis::DriveactivityV2::DriveItemReference] + attr_accessor :drive_item + + # A lightweight reference to a Team Drive. + # Corresponds to the JSON property `teamDrive` + # @return [Google::Apis::DriveactivityV2::TeamDriveReference] + attr_accessor :team_drive + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @drive_item = args[:drive_item] if args.key?(:drive_item) + @team_drive = args[:team_drive] if args.key?(:team_drive) + end + end + + # Information about a Team Drive. + class TeamDrive + include Google::Apis::Core::Hashable + + # The resource name of the Team Drive. The format is + # "teamDrives/TEAM_DRIVE_ID". + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + # A Drive item, such as a file or folder. + # Corresponds to the JSON property `root` + # @return [Google::Apis::DriveactivityV2::DriveItem] + attr_accessor :root + + # The title of the Team Drive. + # Corresponds to the JSON property `title` + # @return [String] + attr_accessor :title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @name = args[:name] if args.key?(:name) + @root = args[:root] if args.key?(:root) + @title = args[:title] if args.key?(:title) + end + end + + # A lightweight reference to a Team Drive. + class TeamDriveReference + include Google::Apis::Core::Hashable + + # The resource name of the Team Drive. The format is + # "teamDrives/TEAM_DRIVE_ID". + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + # The title of the Team Drive. + # Corresponds to the JSON property `title` + # @return [String] + attr_accessor :title + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @name = args[:name] if args.key?(:name) + @title = args[:title] if args.key?(:title) + end + end + + # Information about time ranges. + class TimeRange + include Google::Apis::Core::Hashable + + # The end of the time range. + # Corresponds to the JSON property `endTime` + # @return [String] + attr_accessor :end_time + + # The start of the time range. + # Corresponds to the JSON property `startTime` + # @return [String] + attr_accessor :start_time + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @end_time = args[:end_time] if args.key?(:end_time) + @start_time = args[:start_time] if args.key?(:start_time) + end + end + + # A user about whom nothing is currently known. + class UnknownUser + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # An object was uploaded into Drive. + class Upload + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Information about an end user. + class User + include Google::Apis::Core::Hashable + + # A user whose account has since been deleted. + # Corresponds to the JSON property `deletedUser` + # @return [Google::Apis::DriveactivityV2::DeletedUser] + attr_accessor :deleted_user + + # A known user. + # Corresponds to the JSON property `knownUser` + # @return [Google::Apis::DriveactivityV2::KnownUser] + attr_accessor :known_user + + # A user about whom nothing is currently known. + # Corresponds to the JSON property `unknownUser` + # @return [Google::Apis::DriveactivityV2::UnknownUser] + attr_accessor :unknown_user + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @deleted_user = args[:deleted_user] if args.key?(:deleted_user) + @known_user = args[:known_user] if args.key?(:known_user) + @unknown_user = args[:unknown_user] if args.key?(:unknown_user) + end + end + end + end +end diff --git a/generated/google/apis/driveactivity_v2/representations.rb b/generated/google/apis/driveactivity_v2/representations.rb new file mode 100644 index 000000000..1784685dd --- /dev/null +++ b/generated/google/apis/driveactivity_v2/representations.rb @@ -0,0 +1,799 @@ +# Copyright 2015 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +require 'date' +require 'google/apis/core/base_service' +require 'google/apis/core/json_representation' +require 'google/apis/core/hashable' +require 'google/apis/errors' + +module Google + module Apis + module DriveactivityV2 + + class Action + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ActionDetail + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Actor + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Administrator + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class AnonymousUser + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Anyone + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ApplicationReference + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Assignment + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Comment + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ConsolidationStrategy + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Copy + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Create + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class DataLeakPreventionChange + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Delete + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class DeletedUser + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Domain + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class DriveActivity + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class DriveItem + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class DriveItemReference + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Edit + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class File + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class FileComment + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Folder + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Group + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Impersonation + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class KnownUser + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Legacy + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Move + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class New + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class NoConsolidation + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Owner + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Permission + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class PermissionChange + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Post + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class QueryDriveActivityRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class QueryDriveActivityResponse + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Rename + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Restore + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class RestrictionChange + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class SettingsChange + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Suggestion + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class SystemEvent + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Target + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class TargetReference + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class TeamDrive + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class TeamDriveReference + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class TimeRange + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class UnknownUser + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Upload + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class User + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Action + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :actor, as: 'actor', class: Google::Apis::DriveactivityV2::Actor, decorator: Google::Apis::DriveactivityV2::Actor::Representation + + property :detail, as: 'detail', class: Google::Apis::DriveactivityV2::ActionDetail, decorator: Google::Apis::DriveactivityV2::ActionDetail::Representation + + property :target, as: 'target', class: Google::Apis::DriveactivityV2::Target, decorator: Google::Apis::DriveactivityV2::Target::Representation + + property :time_range, as: 'timeRange', class: Google::Apis::DriveactivityV2::TimeRange, decorator: Google::Apis::DriveactivityV2::TimeRange::Representation + + property :timestamp, as: 'timestamp' + end + end + + class ActionDetail + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :comment, as: 'comment', class: Google::Apis::DriveactivityV2::Comment, decorator: Google::Apis::DriveactivityV2::Comment::Representation + + property :create, as: 'create', class: Google::Apis::DriveactivityV2::Create, decorator: Google::Apis::DriveactivityV2::Create::Representation + + property :delete, as: 'delete', class: Google::Apis::DriveactivityV2::Delete, decorator: Google::Apis::DriveactivityV2::Delete::Representation + + property :dlp_change, as: 'dlpChange', class: Google::Apis::DriveactivityV2::DataLeakPreventionChange, decorator: Google::Apis::DriveactivityV2::DataLeakPreventionChange::Representation + + property :edit, as: 'edit', class: Google::Apis::DriveactivityV2::Edit, decorator: Google::Apis::DriveactivityV2::Edit::Representation + + property :move, as: 'move', class: Google::Apis::DriveactivityV2::Move, decorator: Google::Apis::DriveactivityV2::Move::Representation + + property :permission_change, as: 'permissionChange', class: Google::Apis::DriveactivityV2::PermissionChange, decorator: Google::Apis::DriveactivityV2::PermissionChange::Representation + + property :reference, as: 'reference', class: Google::Apis::DriveactivityV2::ApplicationReference, decorator: Google::Apis::DriveactivityV2::ApplicationReference::Representation + + property :rename, as: 'rename', class: Google::Apis::DriveactivityV2::Rename, decorator: Google::Apis::DriveactivityV2::Rename::Representation + + property :restore, as: 'restore', class: Google::Apis::DriveactivityV2::Restore, decorator: Google::Apis::DriveactivityV2::Restore::Representation + + property :settings_change, as: 'settingsChange', class: Google::Apis::DriveactivityV2::SettingsChange, decorator: Google::Apis::DriveactivityV2::SettingsChange::Representation + + end + end + + class Actor + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :administrator, as: 'administrator', class: Google::Apis::DriveactivityV2::Administrator, decorator: Google::Apis::DriveactivityV2::Administrator::Representation + + property :anonymous, as: 'anonymous', class: Google::Apis::DriveactivityV2::AnonymousUser, decorator: Google::Apis::DriveactivityV2::AnonymousUser::Representation + + property :impersonation, as: 'impersonation', class: Google::Apis::DriveactivityV2::Impersonation, decorator: Google::Apis::DriveactivityV2::Impersonation::Representation + + property :system, as: 'system', class: Google::Apis::DriveactivityV2::SystemEvent, decorator: Google::Apis::DriveactivityV2::SystemEvent::Representation + + property :user, as: 'user', class: Google::Apis::DriveactivityV2::User, decorator: Google::Apis::DriveactivityV2::User::Representation + + end + end + + class Administrator + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class AnonymousUser + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Anyone + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class ApplicationReference + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class Assignment + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :subtype, as: 'subtype' + end + end + + class Comment + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :assignment, as: 'assignment', class: Google::Apis::DriveactivityV2::Assignment, decorator: Google::Apis::DriveactivityV2::Assignment::Representation + + collection :mentioned_users, as: 'mentionedUsers', class: Google::Apis::DriveactivityV2::User, decorator: Google::Apis::DriveactivityV2::User::Representation + + property :post, as: 'post', class: Google::Apis::DriveactivityV2::Post, decorator: Google::Apis::DriveactivityV2::Post::Representation + + property :suggestion, as: 'suggestion', class: Google::Apis::DriveactivityV2::Suggestion, decorator: Google::Apis::DriveactivityV2::Suggestion::Representation + + end + end + + class ConsolidationStrategy + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :legacy, as: 'legacy', class: Google::Apis::DriveactivityV2::Legacy, decorator: Google::Apis::DriveactivityV2::Legacy::Representation + + property :none, as: 'none', class: Google::Apis::DriveactivityV2::NoConsolidation, decorator: Google::Apis::DriveactivityV2::NoConsolidation::Representation + + end + end + + class Copy + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :original_object, as: 'originalObject', class: Google::Apis::DriveactivityV2::TargetReference, decorator: Google::Apis::DriveactivityV2::TargetReference::Representation + + end + end + + class Create + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :copy, as: 'copy', class: Google::Apis::DriveactivityV2::Copy, decorator: Google::Apis::DriveactivityV2::Copy::Representation + + property :new, as: 'new', class: Google::Apis::DriveactivityV2::New, decorator: Google::Apis::DriveactivityV2::New::Representation + + property :upload, as: 'upload', class: Google::Apis::DriveactivityV2::Upload, decorator: Google::Apis::DriveactivityV2::Upload::Representation + + end + end + + class DataLeakPreventionChange + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class Delete + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class DeletedUser + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Domain + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :legacy_id, as: 'legacyId' + property :name, as: 'name' + end + end + + class DriveActivity + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :actions, as: 'actions', class: Google::Apis::DriveactivityV2::Action, decorator: Google::Apis::DriveactivityV2::Action::Representation + + collection :actors, as: 'actors', class: Google::Apis::DriveactivityV2::Actor, decorator: Google::Apis::DriveactivityV2::Actor::Representation + + property :primary_action_detail, as: 'primaryActionDetail', class: Google::Apis::DriveactivityV2::ActionDetail, decorator: Google::Apis::DriveactivityV2::ActionDetail::Representation + + collection :targets, as: 'targets', class: Google::Apis::DriveactivityV2::Target, decorator: Google::Apis::DriveactivityV2::Target::Representation + + property :time_range, as: 'timeRange', class: Google::Apis::DriveactivityV2::TimeRange, decorator: Google::Apis::DriveactivityV2::TimeRange::Representation + + property :timestamp, as: 'timestamp' + end + end + + class DriveItem + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :file, as: 'file', class: Google::Apis::DriveactivityV2::File, decorator: Google::Apis::DriveactivityV2::File::Representation + + property :folder, as: 'folder', class: Google::Apis::DriveactivityV2::Folder, decorator: Google::Apis::DriveactivityV2::Folder::Representation + + property :mime_type, as: 'mimeType' + property :name, as: 'name' + property :owner, as: 'owner', class: Google::Apis::DriveactivityV2::Owner, decorator: Google::Apis::DriveactivityV2::Owner::Representation + + property :title, as: 'title' + end + end + + class DriveItemReference + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :file, as: 'file', class: Google::Apis::DriveactivityV2::File, decorator: Google::Apis::DriveactivityV2::File::Representation + + property :folder, as: 'folder', class: Google::Apis::DriveactivityV2::Folder, decorator: Google::Apis::DriveactivityV2::Folder::Representation + + property :name, as: 'name' + property :title, as: 'title' + end + end + + class Edit + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class File + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class FileComment + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :legacy_comment_id, as: 'legacyCommentId' + property :legacy_discussion_id, as: 'legacyDiscussionId' + property :link_to_discussion, as: 'linkToDiscussion' + property :parent, as: 'parent', class: Google::Apis::DriveactivityV2::DriveItem, decorator: Google::Apis::DriveactivityV2::DriveItem::Representation + + end + end + + class Folder + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class Group + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :email, as: 'email' + property :title, as: 'title' + end + end + + class Impersonation + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :impersonated_user, as: 'impersonatedUser', class: Google::Apis::DriveactivityV2::User, decorator: Google::Apis::DriveactivityV2::User::Representation + + end + end + + class KnownUser + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :is_current_user, as: 'isCurrentUser' + property :person_name, as: 'personName' + end + end + + class Legacy + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Move + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :added_parents, as: 'addedParents', class: Google::Apis::DriveactivityV2::TargetReference, decorator: Google::Apis::DriveactivityV2::TargetReference::Representation + + collection :removed_parents, as: 'removedParents', class: Google::Apis::DriveactivityV2::TargetReference, decorator: Google::Apis::DriveactivityV2::TargetReference::Representation + + end + end + + class New + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class NoConsolidation + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Owner + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :domain, as: 'domain', class: Google::Apis::DriveactivityV2::Domain, decorator: Google::Apis::DriveactivityV2::Domain::Representation + + property :team_drive, as: 'teamDrive', class: Google::Apis::DriveactivityV2::TeamDriveReference, decorator: Google::Apis::DriveactivityV2::TeamDriveReference::Representation + + property :user, as: 'user', class: Google::Apis::DriveactivityV2::User, decorator: Google::Apis::DriveactivityV2::User::Representation + + end + end + + class Permission + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :allow_discovery, as: 'allowDiscovery' + property :anyone, as: 'anyone', class: Google::Apis::DriveactivityV2::Anyone, decorator: Google::Apis::DriveactivityV2::Anyone::Representation + + property :domain, as: 'domain', class: Google::Apis::DriveactivityV2::Domain, decorator: Google::Apis::DriveactivityV2::Domain::Representation + + property :group, as: 'group', class: Google::Apis::DriveactivityV2::Group, decorator: Google::Apis::DriveactivityV2::Group::Representation + + property :role, as: 'role' + property :user, as: 'user', class: Google::Apis::DriveactivityV2::User, decorator: Google::Apis::DriveactivityV2::User::Representation + + end + end + + class PermissionChange + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :added_permissions, as: 'addedPermissions', class: Google::Apis::DriveactivityV2::Permission, decorator: Google::Apis::DriveactivityV2::Permission::Representation + + collection :removed_permissions, as: 'removedPermissions', class: Google::Apis::DriveactivityV2::Permission, decorator: Google::Apis::DriveactivityV2::Permission::Representation + + end + end + + class Post + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :subtype, as: 'subtype' + end + end + + class QueryDriveActivityRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :ancestor_name, as: 'ancestorName' + property :consolidation_strategy, as: 'consolidationStrategy', class: Google::Apis::DriveactivityV2::ConsolidationStrategy, decorator: Google::Apis::DriveactivityV2::ConsolidationStrategy::Representation + + property :filter, as: 'filter' + property :item_name, as: 'itemName' + property :page_size, as: 'pageSize' + property :page_token, as: 'pageToken' + end + end + + class QueryDriveActivityResponse + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :activities, as: 'activities', class: Google::Apis::DriveactivityV2::DriveActivity, decorator: Google::Apis::DriveactivityV2::DriveActivity::Representation + + property :next_page_token, as: 'nextPageToken' + end + end + + class Rename + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :new_title, as: 'newTitle' + property :old_title, as: 'oldTitle' + end + end + + class Restore + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class RestrictionChange + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :feature, as: 'feature' + property :new_restriction, as: 'newRestriction' + end + end + + class SettingsChange + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :restriction_changes, as: 'restrictionChanges', class: Google::Apis::DriveactivityV2::RestrictionChange, decorator: Google::Apis::DriveactivityV2::RestrictionChange::Representation + + end + end + + class Suggestion + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :subtype, as: 'subtype' + end + end + + class SystemEvent + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :type, as: 'type' + end + end + + class Target + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :drive_item, as: 'driveItem', class: Google::Apis::DriveactivityV2::DriveItem, decorator: Google::Apis::DriveactivityV2::DriveItem::Representation + + property :file_comment, as: 'fileComment', class: Google::Apis::DriveactivityV2::FileComment, decorator: Google::Apis::DriveactivityV2::FileComment::Representation + + property :team_drive, as: 'teamDrive', class: Google::Apis::DriveactivityV2::TeamDrive, decorator: Google::Apis::DriveactivityV2::TeamDrive::Representation + + end + end + + class TargetReference + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :drive_item, as: 'driveItem', class: Google::Apis::DriveactivityV2::DriveItemReference, decorator: Google::Apis::DriveactivityV2::DriveItemReference::Representation + + property :team_drive, as: 'teamDrive', class: Google::Apis::DriveactivityV2::TeamDriveReference, decorator: Google::Apis::DriveactivityV2::TeamDriveReference::Representation + + end + end + + class TeamDrive + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :name, as: 'name' + property :root, as: 'root', class: Google::Apis::DriveactivityV2::DriveItem, decorator: Google::Apis::DriveactivityV2::DriveItem::Representation + + property :title, as: 'title' + end + end + + class TeamDriveReference + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :name, as: 'name' + property :title, as: 'title' + end + end + + class TimeRange + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :end_time, as: 'endTime' + property :start_time, as: 'startTime' + end + end + + class UnknownUser + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Upload + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class User + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :deleted_user, as: 'deletedUser', class: Google::Apis::DriveactivityV2::DeletedUser, decorator: Google::Apis::DriveactivityV2::DeletedUser::Representation + + property :known_user, as: 'knownUser', class: Google::Apis::DriveactivityV2::KnownUser, decorator: Google::Apis::DriveactivityV2::KnownUser::Representation + + property :unknown_user, as: 'unknownUser', class: Google::Apis::DriveactivityV2::UnknownUser, decorator: Google::Apis::DriveactivityV2::UnknownUser::Representation + + end + end + end + end +end diff --git a/generated/google/apis/driveactivity_v2/service.rb b/generated/google/apis/driveactivity_v2/service.rb new file mode 100644 index 000000000..ecc2248a6 --- /dev/null +++ b/generated/google/apis/driveactivity_v2/service.rb @@ -0,0 +1,89 @@ +# Copyright 2015 Google Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +require 'google/apis/core/base_service' +require 'google/apis/core/json_representation' +require 'google/apis/core/hashable' +require 'google/apis/errors' + +module Google + module Apis + module DriveactivityV2 + # Drive Activity API + # + # + # + # @example + # require 'google/apis/driveactivity_v2' + # + # Driveactivity = Google::Apis::DriveactivityV2 # Alias the module + # service = Driveactivity::DriveActivityService.new + # + # @see https://developers.google.com/drive/activity/ + class DriveActivityService < Google::Apis::Core::BaseService + # @return [String] + # API key. Your API key identifies your project and provides you with API access, + # quota, and reports. Required unless you provide an OAuth 2.0 token. + attr_accessor :key + + # @return [String] + # Available to use for quota purposes for server-side applications. Can be any + # arbitrary string assigned to a user, but should not exceed 40 characters. + attr_accessor :quota_user + + def initialize + super('https://driveactivity.googleapis.com/', '') + @batch_path = 'batch' + end + + # Query past activity in Google Drive. + # @param [Google::Apis::DriveactivityV2::QueryDriveActivityRequest] query_drive_activity_request_object + # @param [String] fields + # Selector specifying which fields to include in a partial response. + # @param [String] quota_user + # Available to use for quota purposes for server-side applications. Can be any + # arbitrary string assigned to a user, but should not exceed 40 characters. + # @param [Google::Apis::RequestOptions] options + # Request-specific options + # + # @yield [result, err] Result & error if block supplied + # @yieldparam result [Google::Apis::DriveactivityV2::QueryDriveActivityResponse] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::DriveactivityV2::QueryDriveActivityResponse] + # + # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried + # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification + # @raise [Google::Apis::AuthorizationError] Authorization is required + def query_drive_activity(query_drive_activity_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v2/activity:query', options) + command.request_representation = Google::Apis::DriveactivityV2::QueryDriveActivityRequest::Representation + command.request_object = query_drive_activity_request_object + command.response_representation = Google::Apis::DriveactivityV2::QueryDriveActivityResponse::Representation + command.response_class = Google::Apis::DriveactivityV2::QueryDriveActivityResponse + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + protected + + def apply_command_defaults(command) + command.query['key'] = key unless key.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + end + end + end + end +end