From e5f65e78524073932e3d387ddb17ed1c69eef6ed Mon Sep 17 00:00:00 2001 From: Google APIs Date: Thu, 29 Nov 2018 00:36:25 +0000 Subject: [PATCH] Autogenerated update (2018-11-29) Update: - adexchangebuyer2_v2beta1 - appengine_v1beta - calendar_v3 - content_v2 - dialogflow_v2 - pubsub_v1 - serviceconsumermanagement_v1 - vault_v1 --- api_names_out.yaml | 116 +++ .../google/apis/adexchangebuyer2_v2beta1.rb | 2 +- generated/google/apis/appengine_v1beta.rb | 2 +- generated/google/apis/calendar_v3.rb | 2 +- generated/google/apis/calendar_v3/classes.rb | 20 +- .../google/apis/cloudscheduler_v1beta1.rb | 34 + .../apis/cloudscheduler_v1beta1/classes.rb | 882 ++++++++++++++++++ .../cloudscheduler_v1beta1/representations.rb | 264 ++++++ .../apis/cloudscheduler_v1beta1/service.rb | 445 +++++++++ generated/google/apis/content_v2.rb | 2 +- generated/google/apis/content_v2/classes.rb | 8 +- generated/google/apis/dialogflow_v2.rb | 2 +- .../google/apis/dialogflow_v2/classes.rb | 8 +- generated/google/apis/pubsub_v1.rb | 2 +- generated/google/apis/pubsub_v1/classes.rb | 10 +- .../apis/serviceconsumermanagement_v1.rb | 2 +- .../serviceconsumermanagement_v1/classes.rb | 65 ++ .../representations.rb | 30 + .../serviceconsumermanagement_v1/service.rb | 89 ++ generated/google/apis/vault_v1.rb | 2 +- generated/google/apis/vault_v1/classes.rb | 13 +- .../google/apis/vault_v1/representations.rb | 2 +- 22 files changed, 1969 insertions(+), 33 deletions(-) create mode 100644 generated/google/apis/cloudscheduler_v1beta1.rb create mode 100644 generated/google/apis/cloudscheduler_v1beta1/classes.rb create mode 100644 generated/google/apis/cloudscheduler_v1beta1/representations.rb create mode 100644 generated/google/apis/cloudscheduler_v1beta1/service.rb diff --git a/api_names_out.yaml b/api_names_out.yaml index 23ad8a6f8..b967bd84c 100644 --- a/api_names_out.yaml +++ b/api_names_out.yaml @@ -16746,6 +16746,110 @@ "/cloudresourcemanager:v2beta1/fields": fields "/cloudresourcemanager:v2beta1/key": key "/cloudresourcemanager:v2beta1/quotaUser": quota_user +"/cloudscheduler:v1beta1/AppEngineHttpTarget": app_engine_http_target +"/cloudscheduler:v1beta1/AppEngineHttpTarget/appEngineRouting": app_engine_routing +"/cloudscheduler:v1beta1/AppEngineHttpTarget/body": body +"/cloudscheduler:v1beta1/AppEngineHttpTarget/headers": headers +"/cloudscheduler:v1beta1/AppEngineHttpTarget/headers/header": header +"/cloudscheduler:v1beta1/AppEngineHttpTarget/httpMethod": http_method +"/cloudscheduler:v1beta1/AppEngineHttpTarget/relativeUri": relative_uri +"/cloudscheduler:v1beta1/AppEngineRouting": app_engine_routing +"/cloudscheduler:v1beta1/AppEngineRouting/host": host +"/cloudscheduler:v1beta1/AppEngineRouting/instance": instance +"/cloudscheduler:v1beta1/AppEngineRouting/service": service +"/cloudscheduler:v1beta1/AppEngineRouting/version": version +"/cloudscheduler:v1beta1/Empty": empty +"/cloudscheduler:v1beta1/HttpTarget": http_target +"/cloudscheduler:v1beta1/HttpTarget/body": body +"/cloudscheduler:v1beta1/HttpTarget/headers": headers +"/cloudscheduler:v1beta1/HttpTarget/headers/header": header +"/cloudscheduler:v1beta1/HttpTarget/httpMethod": http_method +"/cloudscheduler:v1beta1/HttpTarget/uri": uri +"/cloudscheduler:v1beta1/Job": job +"/cloudscheduler:v1beta1/Job/appEngineHttpTarget": app_engine_http_target +"/cloudscheduler:v1beta1/Job/description": description +"/cloudscheduler:v1beta1/Job/httpTarget": http_target +"/cloudscheduler:v1beta1/Job/lastAttemptTime": last_attempt_time +"/cloudscheduler:v1beta1/Job/name": name +"/cloudscheduler:v1beta1/Job/pubsubTarget": pubsub_target +"/cloudscheduler:v1beta1/Job/retryConfig": retry_config +"/cloudscheduler:v1beta1/Job/schedule": schedule +"/cloudscheduler:v1beta1/Job/scheduleTime": schedule_time +"/cloudscheduler:v1beta1/Job/state": state +"/cloudscheduler:v1beta1/Job/status": status +"/cloudscheduler:v1beta1/Job/timeZone": time_zone +"/cloudscheduler:v1beta1/Job/userUpdateTime": user_update_time +"/cloudscheduler:v1beta1/ListJobsResponse": list_jobs_response +"/cloudscheduler:v1beta1/ListJobsResponse/jobs": jobs +"/cloudscheduler:v1beta1/ListJobsResponse/jobs/job": job +"/cloudscheduler:v1beta1/ListJobsResponse/nextPageToken": next_page_token +"/cloudscheduler:v1beta1/ListLocationsResponse": list_locations_response +"/cloudscheduler:v1beta1/ListLocationsResponse/locations": locations +"/cloudscheduler:v1beta1/ListLocationsResponse/locations/location": location +"/cloudscheduler:v1beta1/ListLocationsResponse/nextPageToken": next_page_token +"/cloudscheduler:v1beta1/Location": location +"/cloudscheduler:v1beta1/Location/displayName": display_name +"/cloudscheduler:v1beta1/Location/labels": labels +"/cloudscheduler:v1beta1/Location/labels/label": label +"/cloudscheduler:v1beta1/Location/locationId": location_id +"/cloudscheduler:v1beta1/Location/metadata": metadata +"/cloudscheduler:v1beta1/Location/metadata/metadatum": metadatum +"/cloudscheduler:v1beta1/Location/name": name +"/cloudscheduler:v1beta1/PauseJobRequest": pause_job_request +"/cloudscheduler:v1beta1/PubsubMessage": pubsub_message +"/cloudscheduler:v1beta1/PubsubMessage/attributes": attributes +"/cloudscheduler:v1beta1/PubsubMessage/attributes/attribute": attribute +"/cloudscheduler:v1beta1/PubsubMessage/data": data +"/cloudscheduler:v1beta1/PubsubMessage/messageId": message_id +"/cloudscheduler:v1beta1/PubsubMessage/publishTime": publish_time +"/cloudscheduler:v1beta1/PubsubTarget": pubsub_target +"/cloudscheduler:v1beta1/PubsubTarget/attributes": attributes +"/cloudscheduler:v1beta1/PubsubTarget/attributes/attribute": attribute +"/cloudscheduler:v1beta1/PubsubTarget/data": data +"/cloudscheduler:v1beta1/PubsubTarget/topicName": topic_name +"/cloudscheduler:v1beta1/ResumeJobRequest": resume_job_request +"/cloudscheduler:v1beta1/RetryConfig": retry_config +"/cloudscheduler:v1beta1/RetryConfig/maxBackoffDuration": max_backoff_duration +"/cloudscheduler:v1beta1/RetryConfig/maxDoublings": max_doublings +"/cloudscheduler:v1beta1/RetryConfig/maxRetryDuration": max_retry_duration +"/cloudscheduler:v1beta1/RetryConfig/minBackoffDuration": min_backoff_duration +"/cloudscheduler:v1beta1/RetryConfig/retryCount": retry_count +"/cloudscheduler:v1beta1/RunJobRequest": run_job_request +"/cloudscheduler:v1beta1/Status": status +"/cloudscheduler:v1beta1/Status/code": code +"/cloudscheduler:v1beta1/Status/details": details +"/cloudscheduler:v1beta1/Status/details/detail": detail +"/cloudscheduler:v1beta1/Status/details/detail/detail": detail +"/cloudscheduler:v1beta1/Status/message": message +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.get": get_project_location +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.get/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.create": create_project_location_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.create/parent": parent +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.delete": delete_project_location_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.delete/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.get": get_project_location_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.get/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.list": list_project_location_jobs +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.list/pageSize": page_size +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.list/pageToken": page_token +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.list/parent": parent +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.patch": patch_project_location_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.patch/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.patch/updateMask": update_mask +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.pause": pause_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.pause/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.resume": resume_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.resume/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.run": run_job +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.jobs.run/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.list": list_project_locations +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.list/filter": filter +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.list/name": name +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.list/pageSize": page_size +"/cloudscheduler:v1beta1/cloudscheduler.projects.locations.list/pageToken": page_token +"/cloudscheduler:v1beta1/fields": fields +"/cloudscheduler:v1beta1/key": key +"/cloudscheduler:v1beta1/quotaUser": quota_user "/cloudsearch:v1/BooleanOperatorOptions": boolean_operator_options "/cloudsearch:v1/BooleanOperatorOptions/operatorName": operator_name "/cloudsearch:v1/BooleanPropertyOptions": boolean_property_options @@ -79476,6 +79580,13 @@ "/serviceconsumermanagement:v1/Api/sourceContext": source_context "/serviceconsumermanagement:v1/Api/syntax": syntax "/serviceconsumermanagement:v1/Api/version": version +"/serviceconsumermanagement:v1/ApplyTenantProjectConfigRequest": apply_tenant_project_config_request +"/serviceconsumermanagement:v1/ApplyTenantProjectConfigRequest/projectConfig": project_config +"/serviceconsumermanagement:v1/ApplyTenantProjectConfigRequest/tag": tag +"/serviceconsumermanagement:v1/AttachTenantProjectRequest": attach_tenant_project_request +"/serviceconsumermanagement:v1/AttachTenantProjectRequest/externalResource": external_resource +"/serviceconsumermanagement:v1/AttachTenantProjectRequest/reservedResource": reserved_resource +"/serviceconsumermanagement:v1/AttachTenantProjectRequest/tag": tag "/serviceconsumermanagement:v1/AuthProvider": auth_provider "/serviceconsumermanagement:v1/AuthProvider/audiences": audiences "/serviceconsumermanagement:v1/AuthProvider/authorizationUrl": authorization_url @@ -79893,6 +80004,10 @@ "/serviceconsumermanagement:v1/serviceconsumermanagement.services.search/query": query "/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.addProject": add_service_tenancy_unit_project "/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.addProject/parent": parent +"/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.applyProjectConfig": apply_service_tenancy_unit_project_config +"/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.applyProjectConfig/name": name +"/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.attachProject": attach_service_tenancy_unit_project +"/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.attachProject/name": name "/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.create": create_tenancy_unit "/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.create/parent": parent "/serviceconsumermanagement:v1/serviceconsumermanagement.services.tenancyUnits.delete": delete_service_tenancy_unit @@ -90308,6 +90423,7 @@ "/vault:v1/ExportOptions/groupsOptions": groups_options "/vault:v1/ExportOptions/hangoutsChatOptions": hangouts_chat_options "/vault:v1/ExportOptions/mailOptions": mail_options +"/vault:v1/ExportOptions/region": region "/vault:v1/ExportStats": export_stats "/vault:v1/ExportStats/exportedArtifactCount": exported_artifact_count "/vault:v1/ExportStats/sizeInBytes": size_in_bytes diff --git a/generated/google/apis/adexchangebuyer2_v2beta1.rb b/generated/google/apis/adexchangebuyer2_v2beta1.rb index 9cbbf6b4e..17d6de0f2 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 = '20181113' + REVISION = '20181127' # Manage your Ad Exchange buyer account configuration AUTH_ADEXCHANGE_BUYER = 'https://www.googleapis.com/auth/adexchange.buyer' diff --git a/generated/google/apis/appengine_v1beta.rb b/generated/google/apis/appengine_v1beta.rb index f227db765..13b935935 100644 --- a/generated/google/apis/appengine_v1beta.rb +++ b/generated/google/apis/appengine_v1beta.rb @@ -25,7 +25,7 @@ module Google # @see https://cloud.google.com/appengine/docs/admin-api/ module AppengineV1beta VERSION = 'V1beta' - REVISION = '20181020' + REVISION = '20181120' # View and manage your applications deployed on Google App Engine AUTH_APPENGINE_ADMIN = 'https://www.googleapis.com/auth/appengine.admin' diff --git a/generated/google/apis/calendar_v3.rb b/generated/google/apis/calendar_v3.rb index 4d0324e66..ad72e367e 100644 --- a/generated/google/apis/calendar_v3.rb +++ b/generated/google/apis/calendar_v3.rb @@ -25,7 +25,7 @@ module Google # @see https://developers.google.com/google-apps/calendar/firstapp module CalendarV3 VERSION = 'V3' - REVISION = '20181023' + REVISION = '20181125' # See, edit, share, and permanently delete all the calendars you can access using Google Calendar AUTH_CALENDAR = 'https://www.googleapis.com/auth/calendar' diff --git a/generated/google/apis/calendar_v3/classes.rb b/generated/google/apis/calendar_v3/classes.rb index 1d1353886..93915f05a 100644 --- a/generated/google/apis/calendar_v3/classes.rb +++ b/generated/google/apis/calendar_v3/classes.rb @@ -439,10 +439,14 @@ module Google include Google::Apis::Core::Hashable # The method used to deliver the notification. Possible values are: - # - "email" - Reminders are sent via email. - # - "sms" - Reminders are sent via SMS. This value is read-only and is ignored - # on inserts and updates. SMS reminders are only available for G Suite customers. - # + # - "email" - Notifications are sent via email. + # - "sms" - Deprecated. Once this feature is shutdown, the API will no longer + # return notifications using this method. Any newly added SMS notifications will + # be ignored. See Google Calendar SMS notifications to be removed for more + # information. + # Notifications are sent via SMS. This value is read-only and is ignored on + # inserts and updates. SMS notifications are only available for G Suite + # customers. # Required when adding a notification. # Corresponds to the JSON property `method` # @return [String] @@ -1777,8 +1781,12 @@ module Google # The method used by this reminder. Possible values are: # - "email" - Reminders are sent via email. - # - "sms" - Reminders are sent via SMS. These are only available for G Suite - # customers. Requests to set SMS reminders for other account types are ignored. + # - "sms" - Deprecated. Once this feature is shutdown, the API will no longer + # return reminders using this method. Any newly added SMS reminders will be + # ignored. See Google Calendar SMS notifications to be removed for more + # information. + # Reminders are sent via SMS. These are only available for G Suite customers. + # Requests to set SMS reminders for other account types are ignored. # - "popup" - Reminders are sent via a UI popup. # Required when adding a reminder. # Corresponds to the JSON property `method` diff --git a/generated/google/apis/cloudscheduler_v1beta1.rb b/generated/google/apis/cloudscheduler_v1beta1.rb new file mode 100644 index 000000000..07cd7b7c8 --- /dev/null +++ b/generated/google/apis/cloudscheduler_v1beta1.rb @@ -0,0 +1,34 @@ +# 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/cloudscheduler_v1beta1/service.rb' +require 'google/apis/cloudscheduler_v1beta1/classes.rb' +require 'google/apis/cloudscheduler_v1beta1/representations.rb' + +module Google + module Apis + # Cloud Scheduler API + # + # Creates and manages jobs run on a regular recurring schedule. + # + # @see https://cloud.google.com/scheduler/ + module CloudschedulerV1beta1 + VERSION = 'V1beta1' + REVISION = '20181120' + + # View and manage your data across Google Cloud Platform services + AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform' + end + end +end diff --git a/generated/google/apis/cloudscheduler_v1beta1/classes.rb b/generated/google/apis/cloudscheduler_v1beta1/classes.rb new file mode 100644 index 000000000..8d7ef830a --- /dev/null +++ b/generated/google/apis/cloudscheduler_v1beta1/classes.rb @@ -0,0 +1,882 @@ +# 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 CloudschedulerV1beta1 + + # App Engine target. The job will be pushed to a job handler by means + # of an HTTP request via an http_method such + # as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an + # HTTP response code in the range [200 - 299]. Error 503 is + # considered an App Engine system error instead of an application + # error. Requests returning error 503 will be retried regardless of + # retry configuration and not counted against retry counts. Any other + # response code, or a failure to receive a response before the + # deadline, constitutes a failed attempt. + class AppEngineHttpTarget + include Google::Apis::Core::Hashable + + # App Engine Routing. + # For more information about services, versions, and instances see + # [An Overview of App Engine](https://cloud.google.com/appengine/docs/python/an- + # overview-of-app-engine), + # [Microservices Architecture on Google App Engine](https://cloud.google.com/ + # appengine/docs/python/microservices-on-app-engine), + # [App Engine Standard request routing](https://cloud.google.com/appengine/docs/ + # standard/python/how-requests-are-routed), and + # [App Engine Flex request routing](https://cloud.google.com/appengine/docs/ + # flexible/python/how-requests-are-routed). + # Corresponds to the JSON property `appEngineRouting` + # @return [Google::Apis::CloudschedulerV1beta1::AppEngineRouting] + attr_accessor :app_engine_routing + + # Body. + # HTTP request body. A request body is allowed only if the HTTP method is + # POST or PUT. It will result in invalid argument error to set a body on a + # job with an incompatible HttpMethod. + # Corresponds to the JSON property `body` + # NOTE: Values are automatically base64 encoded/decoded in the client library. + # @return [String] + attr_accessor :body + + # HTTP request headers. + # This map contains the header field names and values. Headers can be set + # when the job is created. + # Cloud Scheduler sets some headers to default values: + # * `User-Agent`: By default, this header is + # `"AppEngine-Google; (+http://code.google.com/appengine)"`. + # This header can be modified, but Cloud Scheduler will append + # `"AppEngine-Google; (+http://code.google.com/appengine)"` to the + # modified `User-Agent`. + # If the job has an body, Cloud Scheduler sets the + # following headers: + # * `Content-Type`: By default, the `Content-Type` header is set to + # `"application/octet-stream"`. The default can be overridden by explictly + # setting `Content-Type` to a particular media type when the job is + # created. + # For example, `Content-Type` can be set to `"application/json"`. + # * `Content-Length`: This is computed by Cloud Scheduler. This value is + # output only. It cannot be changed. + # The headers below are output only. They cannot be set or overridden: + # * `X-Google-*`: For Google internal use only. + # * `X-AppEngine-*`: For Google internal use only. See + # [Reading request headers](https://cloud.google.com/appengine/docs/python/ + # taskqueue/push/creating-handlers#reading_request_headers). + # In addition, some App Engine headers, which contain + # job-specific information, are also be sent to the job handler; see + # [request headers](https://cloud.google.comappengine/docs/standard/python/ + # config/cron#securing_urls_for_cron). + # Corresponds to the JSON property `headers` + # @return [Hash] + attr_accessor :headers + + # The HTTP method to use for the request. PATCH and OPTIONS are not + # permitted. + # Corresponds to the JSON property `httpMethod` + # @return [String] + attr_accessor :http_method + + # The relative URI. + # The relative URL must begin with "/" and must be a valid HTTP relative URL. + # It can contain a path, query string arguments, and `#` fragments. + # If the relative URL is empty, then the root path "/" will be used. + # No spaces are allowed, and the maximum length allowed is 2083 characters. + # Corresponds to the JSON property `relativeUri` + # @return [String] + attr_accessor :relative_uri + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @app_engine_routing = args[:app_engine_routing] if args.key?(:app_engine_routing) + @body = args[:body] if args.key?(:body) + @headers = args[:headers] if args.key?(:headers) + @http_method = args[:http_method] if args.key?(:http_method) + @relative_uri = args[:relative_uri] if args.key?(:relative_uri) + end + end + + # App Engine Routing. + # For more information about services, versions, and instances see + # [An Overview of App Engine](https://cloud.google.com/appengine/docs/python/an- + # overview-of-app-engine), + # [Microservices Architecture on Google App Engine](https://cloud.google.com/ + # appengine/docs/python/microservices-on-app-engine), + # [App Engine Standard request routing](https://cloud.google.com/appengine/docs/ + # standard/python/how-requests-are-routed), and + # [App Engine Flex request routing](https://cloud.google.com/appengine/docs/ + # flexible/python/how-requests-are-routed). + class AppEngineRouting + include Google::Apis::Core::Hashable + + # Output only. The host that the job is sent to. + # For more information about how App Engine requests are routed, see + # [here](https://cloud.google.com/appengine/docs/standard/python/how-requests- + # are-routed). + # The host is constructed as: + # * `host = [application_domain_name]`
+ # `| [service] + '.' + [application_domain_name]`
+ # `| [version] + '.' + [application_domain_name]`
+ # `| [version_dot_service]+ '.' + [application_domain_name]`
+ # `| [instance] + '.' + [application_domain_name]`
+ # `| [instance_dot_service] + '.' + [application_domain_name]`
+ # `| [instance_dot_version] + '.' + [application_domain_name]`
+ # `| [instance_dot_version_dot_service] + '.' + [application_domain_name]` + # * `application_domain_name` = The domain name of the app, for + # example .appspot.com, which is associated with the + # job's project ID. + # * `service =` service + # * `version =` version + # * `version_dot_service =` + # version `+ '.' +` + # service + # * `instance =` instance + # * `instance_dot_service =` + # instance `+ '.' +` + # service + # * `instance_dot_version =` + # instance `+ '.' +` + # version + # * `instance_dot_version_dot_service =` + # instance `+ '.' +` + # version `+ '.' +` + # service + # If service is empty, then the job will be sent + # to the service which is the default service when the job is attempted. + # If version is empty, then the job will be sent + # to the version which is the default version when the job is attempted. + # If instance is empty, then the job will be + # sent to an instance which is available when the job is attempted. + # If service, + # version, or + # instance is invalid, then the job will be sent + # to the default version of the default service when the job is attempted. + # Corresponds to the JSON property `host` + # @return [String] + attr_accessor :host + + # App instance. + # By default, the job is sent to an instance which is available when + # the job is attempted. + # Requests can only be sent to a specific instance if + # [manual scaling is used in App Engine Standard](https://cloud.google.com/ + # appengine/docs/python/an-overview-of-app-engine?hl=en_US# + # scaling_types_and_instance_classes). + # App Engine Flex does not support instances. For more information, see + # [App Engine Standard request routing](https://cloud.google.com/appengine/docs/ + # standard/python/how-requests-are-routed) and + # [App Engine Flex request routing](https://cloud.google.com/appengine/docs/ + # flexible/python/how-requests-are-routed). + # Corresponds to the JSON property `instance` + # @return [String] + attr_accessor :instance + + # App service. + # By default, the job is sent to the service which is the default + # service when the job is attempted. + # Corresponds to the JSON property `service` + # @return [String] + attr_accessor :service + + # App version. + # By default, the job is sent to the version which is the default + # version when the job is attempted. + # Corresponds to the JSON property `version` + # @return [String] + attr_accessor :version + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @host = args[:host] if args.key?(:host) + @instance = args[:instance] if args.key?(:instance) + @service = args[:service] if args.key?(:service) + @version = args[:version] if args.key?(:version) + end + end + + # A generic empty message that you can re-use to avoid defining duplicated + # empty messages in your APIs. A typical example is to use it as the request + # or the response type of an API method. For instance: + # service Foo ` + # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); + # ` + # The JSON representation for `Empty` is empty JSON object ````. + class Empty + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Http target. The job will be pushed to the job handler by means of + # an HTTP request via an http_method such as HTTP + # POST, HTTP GET, etc. The job is acknowledged by means of an HTTP + # response code in the range [200 - 299]. A failure to receive a response + # constitutes a failed execution. For a redirected request, the response + # returned by the redirected request is considered. + class HttpTarget + include Google::Apis::Core::Hashable + + # HTTP request body. A request body is allowed only if the HTTP + # method is POST, PUT, or PATCH. It is an error to set body on a job with an + # incompatible HttpMethod. + # Corresponds to the JSON property `body` + # NOTE: Values are automatically base64 encoded/decoded in the client library. + # @return [String] + attr_accessor :body + + # The user can specify HTTP request headers to send with the job's + # HTTP request. This map contains the header field names and + # values. Repeated headers are not supported, but a header value can + # contain commas. These headers represent a subset of the headers + # that will accompany the job's HTTP request. Some HTTP request + # headers will be ignored or replaced. A partial list of headers that + # will be ignored or replaced is below: + # - Host: This will be computed by Cloud Scheduler and derived from + # uri. + # * `Content-Length`: This will be computed by Cloud Scheduler. + # * `User-Agent`: This will be set to `"Google-Cloud-Scheduler"`. + # * `X-Google-*`: Google internal use only. + # * `X-AppEngine-*`: Google internal use only. + # The total size of headers must be less than 80KB. + # Corresponds to the JSON property `headers` + # @return [Hash] + attr_accessor :headers + + # Which HTTP method to use for the request. + # Corresponds to the JSON property `httpMethod` + # @return [String] + attr_accessor :http_method + + # Required. + # The full URI path that the request will be sent to. This string + # must begin with either "http://" or "https://". Some examples of + # valid values for uri are: + # `http://acme.com` and `https://acme.com/sales:8080`. Cloud Scheduler will + # encode some characters for safety and compatibility. The maximum allowed + # URL length is 2083 characters after encoding. + # Corresponds to the JSON property `uri` + # @return [String] + attr_accessor :uri + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @body = args[:body] if args.key?(:body) + @headers = args[:headers] if args.key?(:headers) + @http_method = args[:http_method] if args.key?(:http_method) + @uri = args[:uri] if args.key?(:uri) + end + end + + # Configuration for a job. + # The maximum allowed size for a job is 100KB. + class Job + include Google::Apis::Core::Hashable + + # App Engine target. The job will be pushed to a job handler by means + # of an HTTP request via an http_method such + # as HTTP POST, HTTP GET, etc. The job is acknowledged by means of an + # HTTP response code in the range [200 - 299]. Error 503 is + # considered an App Engine system error instead of an application + # error. Requests returning error 503 will be retried regardless of + # retry configuration and not counted against retry counts. Any other + # response code, or a failure to receive a response before the + # deadline, constitutes a failed attempt. + # Corresponds to the JSON property `appEngineHttpTarget` + # @return [Google::Apis::CloudschedulerV1beta1::AppEngineHttpTarget] + attr_accessor :app_engine_http_target + + # A human-readable description for the job. This string must not contain + # more than 500 characters. + # Corresponds to the JSON property `description` + # @return [String] + attr_accessor :description + + # Http target. The job will be pushed to the job handler by means of + # an HTTP request via an http_method such as HTTP + # POST, HTTP GET, etc. The job is acknowledged by means of an HTTP + # response code in the range [200 - 299]. A failure to receive a response + # constitutes a failed execution. For a redirected request, the response + # returned by the redirected request is considered. + # Corresponds to the JSON property `httpTarget` + # @return [Google::Apis::CloudschedulerV1beta1::HttpTarget] + attr_accessor :http_target + + # Output only. The time the last job attempt started. + # Corresponds to the JSON property `lastAttemptTime` + # @return [String] + attr_accessor :last_attempt_time + + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]), + # hyphens (-), colons (:), or periods (.). + # For more information, see + # [Identifying projects](https://cloud.google.com/resource-manager/docs/ + # creating-managing-projects#identifying_projects) + # * `LOCATION_ID` is the canonical ID for the job's location. + # The list of available locations can be obtained by calling + # ListLocations. + # For more information, see https://cloud.google.com/about/locations/. + # * `JOB_ID` can contain only letters ([A-Za-z]), numbers ([0-9]), + # hyphens (-), or underscores (_). The maximum length is 500 characters. + # Corresponds to the JSON property `name` + # @return [String] + attr_accessor :name + + # Pub/Sub target. The job will be delivered by publishing a message to + # the given Pub/Sub topic. + # Corresponds to the JSON property `pubsubTarget` + # @return [Google::Apis::CloudschedulerV1beta1::PubsubTarget] + attr_accessor :pubsub_target + + # Settings that determine the retry behavior. + # By default, if a job does not complete successfully (meaning that + # an acknowledgement is not received from the handler, then it will be retried + # with exponential backoff according to the settings in RetryConfig. + # Corresponds to the JSON property `retryConfig` + # @return [Google::Apis::CloudschedulerV1beta1::RetryConfig] + attr_accessor :retry_config + + # Required. + # Describes the schedule on which the job will be executed. + # As a general rule, execution `n + 1` of a job will not begin + # until execution `n` has finished. Cloud Scheduler will never + # allow two simultaneously outstanding executions. For example, + # this implies that if the `n+1`th execution is scheduled to run at + # 16:00 but the `n`th execution takes until 16:15, the `n+1`th + # execution will not start until `16:15`. + # A scheduled start time will be delayed if the previous + # execution has not ended when its scheduled time occurs. + # If retry_count > 0 and a job attempt fails, + # the job will be tried a total of retry_count + # times, with exponential backoff, until the next scheduled start + # time. + # The schedule can be either of the following types: + # * [Crontab](http://en.wikipedia.org/wiki/Cron#Overview) + # * English-like [schedule](https://cloud.google.com/scheduler/docs/configuring/ + # cron-job-schedules) + # Corresponds to the JSON property `schedule` + # @return [String] + attr_accessor :schedule + + # Output only. The next time the job is scheduled. Note that this may be a + # retry of a previously failed attempt or the next execution time + # according to the schedule. + # Corresponds to the JSON property `scheduleTime` + # @return [String] + attr_accessor :schedule_time + + # Output only. State of the job. + # Corresponds to the JSON property `state` + # @return [String] + attr_accessor :state + + # The `Status` type defines a logical error model that is suitable for different + # programming environments, including REST APIs and RPC APIs. It is used by + # [gRPC](https://github.com/grpc). The error model is designed to be: + # - Simple to use and understand for most users + # - Flexible enough to meet unexpected needs + # # Overview + # The `Status` message contains three pieces of data: error code, error message, + # and error details. The error code should be an enum value of + # google.rpc.Code, but it may accept additional error codes if needed. The + # error message should be a developer-facing English message that helps + # developers *understand* and *resolve* the error. If a localized user-facing + # error message is needed, put the localized message in the error details or + # localize it in the client. The optional error details may contain arbitrary + # information about the error. There is a predefined set of error detail types + # in the package `google.rpc` that can be used for common error conditions. + # # Language mapping + # The `Status` message is the logical representation of the error model, but it + # is not necessarily the actual wire format. When the `Status` message is + # exposed in different client libraries and different wire protocols, it can be + # mapped differently. For example, it will likely be mapped to some exceptions + # in Java, but more likely mapped to some error codes in C. + # # Other uses + # The error model and the `Status` message can be used in a variety of + # environments, either with or without APIs, to provide a + # consistent developer experience across different environments. + # Example uses of this error model include: + # - Partial errors. If a service needs to return partial errors to the client, + # it may embed the `Status` in the normal response to indicate the partial + # errors. + # - Workflow errors. A typical workflow has multiple steps. Each step may + # have a `Status` message for error reporting. + # - Batch operations. If a client uses batch request and batch response, the + # `Status` message should be used directly inside batch response, one for + # each error sub-response. + # - Asynchronous operations. If an API call embeds asynchronous operation + # results in its response, the status of those operations should be + # represented directly using the `Status` message. + # - Logging. If some API errors are stored in logs, the message `Status` could + # be used directly after any stripping needed for security/privacy reasons. + # Corresponds to the JSON property `status` + # @return [Google::Apis::CloudschedulerV1beta1::Status] + attr_accessor :status + + # Specifies the time zone to be used in interpreting + # schedule. The value of this field must be a time + # zone name from the [tz database](http://en.wikipedia.org/wiki/Tz_database). + # Note that some time zones include a provision for + # daylight savings time. The rules for daylight saving time are + # determined by the chosen tz. For UTC use the string "utc". If a + # time zone is not specified, the default will be in UTC (also known + # as GMT). + # Corresponds to the JSON property `timeZone` + # @return [String] + attr_accessor :time_zone + + # Output only. The creation time of the job. + # Corresponds to the JSON property `userUpdateTime` + # @return [String] + attr_accessor :user_update_time + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @app_engine_http_target = args[:app_engine_http_target] if args.key?(:app_engine_http_target) + @description = args[:description] if args.key?(:description) + @http_target = args[:http_target] if args.key?(:http_target) + @last_attempt_time = args[:last_attempt_time] if args.key?(:last_attempt_time) + @name = args[:name] if args.key?(:name) + @pubsub_target = args[:pubsub_target] if args.key?(:pubsub_target) + @retry_config = args[:retry_config] if args.key?(:retry_config) + @schedule = args[:schedule] if args.key?(:schedule) + @schedule_time = args[:schedule_time] if args.key?(:schedule_time) + @state = args[:state] if args.key?(:state) + @status = args[:status] if args.key?(:status) + @time_zone = args[:time_zone] if args.key?(:time_zone) + @user_update_time = args[:user_update_time] if args.key?(:user_update_time) + end + end + + # Response message for listing jobs using ListJobs. + class ListJobsResponse + include Google::Apis::Core::Hashable + + # The list of jobs. + # Corresponds to the JSON property `jobs` + # @return [Array] + attr_accessor :jobs + + # A token to retrieve next page of results. Pass this value in the + # page_token field in the subsequent call to + # ListJobs to retrieve the next page of results. + # If this is empty it indicates that there are no more results + # through which to paginate. + # The page token is valid for only 2 hours. + # 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) + @jobs = args[:jobs] if args.key?(:jobs) + @next_page_token = args[:next_page_token] if args.key?(:next_page_token) + end + end + + # The response message for Locations.ListLocations. + class ListLocationsResponse + include Google::Apis::Core::Hashable + + # A list of locations that matches the specified filter in the request. + # Corresponds to the JSON property `locations` + # @return [Array] + attr_accessor :locations + + # The standard List next-page token. + # 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) + @locations = args[:locations] if args.key?(:locations) + @next_page_token = args[:next_page_token] if args.key?(:next_page_token) + end + end + + # A resource that represents Google Cloud Platform location. + class Location + include Google::Apis::Core::Hashable + + # The friendly name for this location, typically a nearby city name. + # For example, "Tokyo". + # Corresponds to the JSON property `displayName` + # @return [String] + attr_accessor :display_name + + # Cross-service attributes for the location. For example + # `"cloud.googleapis.com/region": "us-east1"` + # Corresponds to the JSON property `labels` + # @return [Hash] + attr_accessor :labels + + # The canonical id for this location. For example: `"us-east1"`. + # Corresponds to the JSON property `locationId` + # @return [String] + attr_accessor :location_id + + # Service-specific metadata. For example the available capacity at the given + # location. + # Corresponds to the JSON property `metadata` + # @return [Hash] + attr_accessor :metadata + + # Resource name for the location, which may vary between implementations. + # For example: `"projects/example-project/locations/us-east1"` + # 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) + @display_name = args[:display_name] if args.key?(:display_name) + @labels = args[:labels] if args.key?(:labels) + @location_id = args[:location_id] if args.key?(:location_id) + @metadata = args[:metadata] if args.key?(:metadata) + @name = args[:name] if args.key?(:name) + end + end + + # Request message for PauseJob. + class PauseJobRequest + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # A message that is published by publishers and consumed by subscribers. The + # message must contain either a non-empty data field or at least one attribute. + # Note that client libraries represent this object differently + # depending on the language. See the corresponding + # client + # library documentation for more information. See + # Quotas and limits + # for more information about message limits. + class PubsubMessage + include Google::Apis::Core::Hashable + + # Optional attributes for this message. + # Corresponds to the JSON property `attributes` + # @return [Hash] + attr_accessor :attributes + + # The message data field. If this field is empty, the message must contain + # at least one attribute. + # Corresponds to the JSON property `data` + # NOTE: Values are automatically base64 encoded/decoded in the client library. + # @return [String] + attr_accessor :data + + # ID of this message, assigned by the server when the message is published. + # Guaranteed to be unique within the topic. This value may be read by a + # subscriber that receives a `PubsubMessage` via a `Pull` call or a push + # delivery. It must not be populated by the publisher in a `Publish` call. + # Corresponds to the JSON property `messageId` + # @return [String] + attr_accessor :message_id + + # The time at which the message was published, populated by the server when + # it receives the `Publish` call. It must not be populated by the + # publisher in a `Publish` call. + # Corresponds to the JSON property `publishTime` + # @return [String] + attr_accessor :publish_time + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @attributes = args[:attributes] if args.key?(:attributes) + @data = args[:data] if args.key?(:data) + @message_id = args[:message_id] if args.key?(:message_id) + @publish_time = args[:publish_time] if args.key?(:publish_time) + end + end + + # Pub/Sub target. The job will be delivered by publishing a message to + # the given Pub/Sub topic. + class PubsubTarget + include Google::Apis::Core::Hashable + + # Attributes for PubsubMessage. + # Pubsub message must contain either non-empty data, or at least one + # attribute. + # Corresponds to the JSON property `attributes` + # @return [Hash] + attr_accessor :attributes + + # The message payload for PubsubMessage. + # Pubsub message must contain either non-empty data, or at least one + # attribute. + # Corresponds to the JSON property `data` + # NOTE: Values are automatically base64 encoded/decoded in the client library. + # @return [String] + attr_accessor :data + + # Required. + # The name of the Cloud Pub/Sub topic to which messages will + # be published when a job is delivered. The topic name must be in the + # same format as required by PubSub's + # [PublishRequest.name](https://cloud.google.com/pubsub/docs/reference/rpc/ + # google.pubsub.v1#publishrequest), + # for example `projects/PROJECT_ID/topics/TOPIC_ID`. + # The topic must be in the same project as the Cloud Scheduler job. + # Corresponds to the JSON property `topicName` + # @return [String] + attr_accessor :topic_name + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @attributes = args[:attributes] if args.key?(:attributes) + @data = args[:data] if args.key?(:data) + @topic_name = args[:topic_name] if args.key?(:topic_name) + end + end + + # Request message for ResumeJob. + class ResumeJobRequest + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # Settings that determine the retry behavior. + # By default, if a job does not complete successfully (meaning that + # an acknowledgement is not received from the handler, then it will be retried + # with exponential backoff according to the settings in RetryConfig. + class RetryConfig + include Google::Apis::Core::Hashable + + # The maximum amount of time to wait before retrying a job after + # it fails. + # The default value of this field is 1 hour. + # Corresponds to the JSON property `maxBackoffDuration` + # @return [String] + attr_accessor :max_backoff_duration + + # The time between retries will double `max_doublings` times. + # A job's retry interval starts at + # min_backoff_duration, then doubles + # `max_doublings` times, then increases linearly, and finally + # retries retries at intervals of + # max_backoff_duration up to + # retry_count times. + # For example, if min_backoff_duration is + # 10s, max_backoff_duration is 300s, and + # `max_doublings` is 3, then the a job will first be retried in 10s. The + # retry interval will double three times, and then increase linearly by + # 2^3 * 10s. Finally, the job will retry at intervals of + # max_backoff_duration until the job has + # been attempted retry_count times. Thus, the + # requests will retry at 10s, 20s, 40s, 80s, 160s, 240s, 300s, 300s, .... + # The default value of this field is 5. + # Corresponds to the JSON property `maxDoublings` + # @return [Fixnum] + attr_accessor :max_doublings + + # The time limit for retrying a failed job, measured from time when an + # execution was first attempted. If specified with + # retry_count, the job will be retried until both limits are + # reached. + # The default value for max_retry_duration is zero, which means retry + # duration is unlimited. + # Corresponds to the JSON property `maxRetryDuration` + # @return [String] + attr_accessor :max_retry_duration + + # The minimum amount of time to wait before retrying a job after + # it fails. + # The default value of this field is 5 seconds. + # Corresponds to the JSON property `minBackoffDuration` + # @return [String] + attr_accessor :min_backoff_duration + + # The number of attempts that the system will make to run a job using the + # exponential backoff procedure described by + # max_doublings. + # The default value of retry_count is zero. + # If retry_count is zero, a job attempt will *not* be retried if + # it fails. Instead the Cloud Scheduler system will wait for the + # next scheduled execution time. + # If retry_count is set to a non-zero number then Cloud Scheduler + # will retry failed attempts, using exponential backoff, + # retry_count times, or until the next scheduled execution time, + # whichever comes first. + # Values greater than 5 and negative values are not allowed. + # Corresponds to the JSON property `retryCount` + # @return [Fixnum] + attr_accessor :retry_count + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @max_backoff_duration = args[:max_backoff_duration] if args.key?(:max_backoff_duration) + @max_doublings = args[:max_doublings] if args.key?(:max_doublings) + @max_retry_duration = args[:max_retry_duration] if args.key?(:max_retry_duration) + @min_backoff_duration = args[:min_backoff_duration] if args.key?(:min_backoff_duration) + @retry_count = args[:retry_count] if args.key?(:retry_count) + end + end + + # Request message for forcing a job to run now using + # RunJob. + class RunJobRequest + include Google::Apis::Core::Hashable + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + end + end + + # The `Status` type defines a logical error model that is suitable for different + # programming environments, including REST APIs and RPC APIs. It is used by + # [gRPC](https://github.com/grpc). The error model is designed to be: + # - Simple to use and understand for most users + # - Flexible enough to meet unexpected needs + # # Overview + # The `Status` message contains three pieces of data: error code, error message, + # and error details. The error code should be an enum value of + # google.rpc.Code, but it may accept additional error codes if needed. The + # error message should be a developer-facing English message that helps + # developers *understand* and *resolve* the error. If a localized user-facing + # error message is needed, put the localized message in the error details or + # localize it in the client. The optional error details may contain arbitrary + # information about the error. There is a predefined set of error detail types + # in the package `google.rpc` that can be used for common error conditions. + # # Language mapping + # The `Status` message is the logical representation of the error model, but it + # is not necessarily the actual wire format. When the `Status` message is + # exposed in different client libraries and different wire protocols, it can be + # mapped differently. For example, it will likely be mapped to some exceptions + # in Java, but more likely mapped to some error codes in C. + # # Other uses + # The error model and the `Status` message can be used in a variety of + # environments, either with or without APIs, to provide a + # consistent developer experience across different environments. + # Example uses of this error model include: + # - Partial errors. If a service needs to return partial errors to the client, + # it may embed the `Status` in the normal response to indicate the partial + # errors. + # - Workflow errors. A typical workflow has multiple steps. Each step may + # have a `Status` message for error reporting. + # - Batch operations. If a client uses batch request and batch response, the + # `Status` message should be used directly inside batch response, one for + # each error sub-response. + # - Asynchronous operations. If an API call embeds asynchronous operation + # results in its response, the status of those operations should be + # represented directly using the `Status` message. + # - Logging. If some API errors are stored in logs, the message `Status` could + # be used directly after any stripping needed for security/privacy reasons. + class Status + include Google::Apis::Core::Hashable + + # The status code, which should be an enum value of google.rpc.Code. + # Corresponds to the JSON property `code` + # @return [Fixnum] + attr_accessor :code + + # A list of messages that carry the error details. There is a common set of + # message types for APIs to use. + # Corresponds to the JSON property `details` + # @return [Array>] + attr_accessor :details + + # A developer-facing error message, which should be in English. Any + # user-facing error message should be localized and sent in the + # google.rpc.Status.details field, or localized by the client. + # Corresponds to the JSON property `message` + # @return [String] + attr_accessor :message + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @code = args[:code] if args.key?(:code) + @details = args[:details] if args.key?(:details) + @message = args[:message] if args.key?(:message) + end + end + end + end +end diff --git a/generated/google/apis/cloudscheduler_v1beta1/representations.rb b/generated/google/apis/cloudscheduler_v1beta1/representations.rb new file mode 100644 index 000000000..c12e98d3a --- /dev/null +++ b/generated/google/apis/cloudscheduler_v1beta1/representations.rb @@ -0,0 +1,264 @@ +# 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 CloudschedulerV1beta1 + + class AppEngineHttpTarget + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class AppEngineRouting + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Empty + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class HttpTarget + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Job + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ListJobsResponse + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ListLocationsResponse + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Location + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class PauseJobRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class PubsubMessage + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class PubsubTarget + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class ResumeJobRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class RetryConfig + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class RunJobRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class Status + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class AppEngineHttpTarget + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :app_engine_routing, as: 'appEngineRouting', class: Google::Apis::CloudschedulerV1beta1::AppEngineRouting, decorator: Google::Apis::CloudschedulerV1beta1::AppEngineRouting::Representation + + property :body, :base64 => true, as: 'body' + hash :headers, as: 'headers' + property :http_method, as: 'httpMethod' + property :relative_uri, as: 'relativeUri' + end + end + + class AppEngineRouting + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :host, as: 'host' + property :instance, as: 'instance' + property :service, as: 'service' + property :version, as: 'version' + end + end + + class Empty + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class HttpTarget + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :body, :base64 => true, as: 'body' + hash :headers, as: 'headers' + property :http_method, as: 'httpMethod' + property :uri, as: 'uri' + end + end + + class Job + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :app_engine_http_target, as: 'appEngineHttpTarget', class: Google::Apis::CloudschedulerV1beta1::AppEngineHttpTarget, decorator: Google::Apis::CloudschedulerV1beta1::AppEngineHttpTarget::Representation + + property :description, as: 'description' + property :http_target, as: 'httpTarget', class: Google::Apis::CloudschedulerV1beta1::HttpTarget, decorator: Google::Apis::CloudschedulerV1beta1::HttpTarget::Representation + + property :last_attempt_time, as: 'lastAttemptTime' + property :name, as: 'name' + property :pubsub_target, as: 'pubsubTarget', class: Google::Apis::CloudschedulerV1beta1::PubsubTarget, decorator: Google::Apis::CloudschedulerV1beta1::PubsubTarget::Representation + + property :retry_config, as: 'retryConfig', class: Google::Apis::CloudschedulerV1beta1::RetryConfig, decorator: Google::Apis::CloudschedulerV1beta1::RetryConfig::Representation + + property :schedule, as: 'schedule' + property :schedule_time, as: 'scheduleTime' + property :state, as: 'state' + property :status, as: 'status', class: Google::Apis::CloudschedulerV1beta1::Status, decorator: Google::Apis::CloudschedulerV1beta1::Status::Representation + + property :time_zone, as: 'timeZone' + property :user_update_time, as: 'userUpdateTime' + end + end + + class ListJobsResponse + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :jobs, as: 'jobs', class: Google::Apis::CloudschedulerV1beta1::Job, decorator: Google::Apis::CloudschedulerV1beta1::Job::Representation + + property :next_page_token, as: 'nextPageToken' + end + end + + class ListLocationsResponse + # @private + class Representation < Google::Apis::Core::JsonRepresentation + collection :locations, as: 'locations', class: Google::Apis::CloudschedulerV1beta1::Location, decorator: Google::Apis::CloudschedulerV1beta1::Location::Representation + + property :next_page_token, as: 'nextPageToken' + end + end + + class Location + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :display_name, as: 'displayName' + hash :labels, as: 'labels' + property :location_id, as: 'locationId' + hash :metadata, as: 'metadata' + property :name, as: 'name' + end + end + + class PauseJobRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class PubsubMessage + # @private + class Representation < Google::Apis::Core::JsonRepresentation + hash :attributes, as: 'attributes' + property :data, :base64 => true, as: 'data' + property :message_id, as: 'messageId' + property :publish_time, as: 'publishTime' + end + end + + class PubsubTarget + # @private + class Representation < Google::Apis::Core::JsonRepresentation + hash :attributes, as: 'attributes' + property :data, :base64 => true, as: 'data' + property :topic_name, as: 'topicName' + end + end + + class ResumeJobRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class RetryConfig + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :max_backoff_duration, as: 'maxBackoffDuration' + property :max_doublings, as: 'maxDoublings' + property :max_retry_duration, as: 'maxRetryDuration' + property :min_backoff_duration, as: 'minBackoffDuration' + property :retry_count, as: 'retryCount' + end + end + + class RunJobRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + end + end + + class Status + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :code, as: 'code' + collection :details, as: 'details' + property :message, as: 'message' + end + end + end + end +end diff --git a/generated/google/apis/cloudscheduler_v1beta1/service.rb b/generated/google/apis/cloudscheduler_v1beta1/service.rb new file mode 100644 index 000000000..e6b6fa261 --- /dev/null +++ b/generated/google/apis/cloudscheduler_v1beta1/service.rb @@ -0,0 +1,445 @@ +# 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 CloudschedulerV1beta1 + # Cloud Scheduler API + # + # Creates and manages jobs run on a regular recurring schedule. + # + # @example + # require 'google/apis/cloudscheduler_v1beta1' + # + # Cloudscheduler = Google::Apis::CloudschedulerV1beta1 # Alias the module + # service = Cloudscheduler::CloudSchedulerService.new + # + # @see https://cloud.google.com/scheduler/ + class CloudSchedulerService < 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://cloudscheduler.googleapis.com/', '') + @batch_path = 'batch' + end + + # Gets information about a location. + # @param [String] name + # Resource name for the location. + # @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::CloudschedulerV1beta1::Location] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Location] + # + # @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 get_project_location(name, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:get, 'v1beta1/{+name}', options) + command.response_representation = Google::Apis::CloudschedulerV1beta1::Location::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Location + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Lists information about the supported locations for this service. + # @param [String] name + # The resource that owns the locations collection, if applicable. + # @param [String] filter + # The standard list filter. + # @param [Fixnum] page_size + # The standard list page size. + # @param [String] page_token + # The standard list page token. + # @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::CloudschedulerV1beta1::ListLocationsResponse] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::ListLocationsResponse] + # + # @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 list_project_locations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:get, 'v1beta1/{+name}/locations', options) + command.response_representation = Google::Apis::CloudschedulerV1beta1::ListLocationsResponse::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::ListLocationsResponse + command.params['name'] = name unless name.nil? + command.query['filter'] = filter unless filter.nil? + command.query['pageSize'] = page_size unless page_size.nil? + command.query['pageToken'] = page_token unless page_token.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Creates a job. + # @param [String] parent + # Required. + # The location name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID`. + # @param [Google::Apis::CloudschedulerV1beta1::Job] job_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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 create_project_location_job(parent, job_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1beta1/{+parent}/jobs', options) + command.request_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.request_object = job_object + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['parent'] = parent unless parent.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Deletes a job. + # @param [String] name + # Required. + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # @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::CloudschedulerV1beta1::Empty] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Empty] + # + # @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 delete_project_location_job(name, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:delete, 'v1beta1/{+name}', options) + command.response_representation = Google::Apis::CloudschedulerV1beta1::Empty::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Empty + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Gets a job. + # @param [String] name + # Required. + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # @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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 get_project_location_job(name, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:get, 'v1beta1/{+name}', options) + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Lists jobs. + # @param [String] parent + # Required. + # The location name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID`. + # @param [Fixnum] page_size + # Requested page size. + # The maximum page size is 500. If unspecified, the page size will + # be the maximum. Fewer jobs than requested might be returned, + # even if more jobs exist; use next_page_token to determine if more + # jobs exist. + # @param [String] page_token + # A token identifying a page of results the server will return. To + # request the first page results, page_token must be empty. To + # request the next page of results, page_token must be the value of + # next_page_token returned from + # the previous call to ListJobs. It is an error to + # switch the value of filter or + # order_by while iterating through pages. + # @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::CloudschedulerV1beta1::ListJobsResponse] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::ListJobsResponse] + # + # @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 list_project_location_jobs(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:get, 'v1beta1/{+parent}/jobs', options) + command.response_representation = Google::Apis::CloudschedulerV1beta1::ListJobsResponse::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::ListJobsResponse + command.params['parent'] = parent unless parent.nil? + command.query['pageSize'] = page_size unless page_size.nil? + command.query['pageToken'] = page_token unless page_token.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 a job. + # If successful, the updated Job is returned. If the job does + # not exist, `NOT_FOUND` is returned. + # If UpdateJob does not successfully return, it is possible for the + # job to be in an Job.State.UPDATE_FAILED state. A job in this state may + # not be executed. If this happens, retry the UpdateJob request + # until a successful response is received. + # @param [String] name + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # * `PROJECT_ID` can contain letters ([A-Za-z]), numbers ([0-9]), + # hyphens (-), colons (:), or periods (.). + # For more information, see + # [Identifying projects](https://cloud.google.com/resource-manager/docs/ + # creating-managing-projects#identifying_projects) + # * `LOCATION_ID` is the canonical ID for the job's location. + # The list of available locations can be obtained by calling + # ListLocations. + # For more information, see https://cloud.google.com/about/locations/. + # * `JOB_ID` can contain only letters ([A-Za-z]), numbers ([0-9]), + # hyphens (-), or underscores (_). The maximum length is 500 characters. + # @param [Google::Apis::CloudschedulerV1beta1::Job] job_object + # @param [String] update_mask + # A mask used to specify which fields of the job are being updated. + # @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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 patch_project_location_job(name, job_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:patch, 'v1beta1/{+name}', options) + command.request_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.request_object = job_object + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['name'] = name unless name.nil? + command.query['updateMask'] = update_mask unless update_mask.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Pauses a job. + # If a job is paused then the system will stop executing the job + # until it is re-enabled via ResumeJob. The + # state of the job is stored in state; if paused it + # will be set to Job.State.PAUSED. A job must be in Job.State.ENABLED + # to be paused. + # @param [String] name + # Required. + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # @param [Google::Apis::CloudschedulerV1beta1::PauseJobRequest] pause_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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 pause_job(name, pause_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1beta1/{+name}:pause', options) + command.request_representation = Google::Apis::CloudschedulerV1beta1::PauseJobRequest::Representation + command.request_object = pause_job_request_object + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Resume a job. + # This method reenables a job after it has been Job.State.PAUSED. The + # state of a job is stored in Job.state; after calling this method it + # will be set to Job.State.ENABLED. A job must be in + # Job.State.PAUSED to be resumed. + # @param [String] name + # Required. + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # @param [Google::Apis::CloudschedulerV1beta1::ResumeJobRequest] resume_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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 resume_job(name, resume_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1beta1/{+name}:resume', options) + command.request_representation = Google::Apis::CloudschedulerV1beta1::ResumeJobRequest::Representation + command.request_object = resume_job_request_object + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Forces a job to run now. + # When this method is called, Cloud Scheduler will dispatch the job, even + # if the job is already running. + # @param [String] name + # Required. + # The job name. For example: + # `projects/PROJECT_ID/locations/LOCATION_ID/jobs/JOB_ID`. + # @param [Google::Apis::CloudschedulerV1beta1::RunJobRequest] run_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::CloudschedulerV1beta1::Job] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::CloudschedulerV1beta1::Job] + # + # @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 run_job(name, run_job_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1beta1/{+name}:run', options) + command.request_representation = Google::Apis::CloudschedulerV1beta1::RunJobRequest::Representation + command.request_object = run_job_request_object + command.response_representation = Google::Apis::CloudschedulerV1beta1::Job::Representation + command.response_class = Google::Apis::CloudschedulerV1beta1::Job + command.params['name'] = name unless name.nil? + 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 diff --git a/generated/google/apis/content_v2.rb b/generated/google/apis/content_v2.rb index cd6dc98e7..401e2db41 100644 --- a/generated/google/apis/content_v2.rb +++ b/generated/google/apis/content_v2.rb @@ -26,7 +26,7 @@ module Google # @see https://developers.google.com/shopping-content module ContentV2 VERSION = 'V2' - REVISION = '20181106' + REVISION = '20181126' # Manage your product listings and accounts for Google Shopping AUTH_CONTENT = 'https://www.googleapis.com/auth/content' diff --git a/generated/google/apis/content_v2/classes.rb b/generated/google/apis/content_v2/classes.rb index d4d1d25d9..930b8f624 100644 --- a/generated/google/apis/content_v2/classes.rb +++ b/generated/google/apis/content_v2/classes.rb @@ -5086,7 +5086,7 @@ module Google include Google::Apis::Core::Hashable # The carrier handling the shipment. - # Acceptable values are: + # Acceptable values for US are: # - "gsx" # - "ups" # - "usps" @@ -5103,6 +5103,9 @@ module Google # - "lasership" # - "mpx" # - "uds" + # Acceptable values for FR are: + # - "colissimo" + # - "chronopost" # Corresponds to the JSON property `carrier` # @return [String] attr_accessor :carrier @@ -9072,9 +9075,6 @@ module Google include Google::Apis::Core::Hashable # The unit of value. - # Acceptable values are: - # - "cm" - # - "in" # Corresponds to the JSON property `unit` # @return [String] attr_accessor :unit diff --git a/generated/google/apis/dialogflow_v2.rb b/generated/google/apis/dialogflow_v2.rb index 28fbfe946..1b5ebc6a0 100644 --- a/generated/google/apis/dialogflow_v2.rb +++ b/generated/google/apis/dialogflow_v2.rb @@ -26,7 +26,7 @@ module Google # @see https://cloud.google.com/dialogflow-enterprise/ module DialogflowV2 VERSION = 'V2' - REVISION = '20181109' + REVISION = '20181121' # 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/dialogflow_v2/classes.rb b/generated/google/apis/dialogflow_v2/classes.rb index 735db53cb..af987a047 100644 --- a/generated/google/apis/dialogflow_v2/classes.rb +++ b/generated/google/apis/dialogflow_v2/classes.rb @@ -913,7 +913,9 @@ module Google attr_accessor :parent_followup_intent_name # Optional. The priority of this intent. Higher numbers represent higher - # priorities. Zero or negative numbers mean that the intent is disabled. + # priorities. If this is zero or unspecified, we use the default + # priority 500000. + # Negative numbers mean that the intent is disabled. # Corresponds to the JSON property `priority` # @return [Fixnum] attr_accessor :priority @@ -2869,7 +2871,9 @@ module Google attr_accessor :parent_followup_intent_name # Optional. The priority of this intent. Higher numbers represent higher - # priorities. Zero or negative numbers mean that the intent is disabled. + # priorities. If this is zero or unspecified, we use the default + # priority 500000. + # Negative numbers mean that the intent is disabled. # Corresponds to the JSON property `priority` # @return [Fixnum] attr_accessor :priority diff --git a/generated/google/apis/pubsub_v1.rb b/generated/google/apis/pubsub_v1.rb index 8ab8a7e0b..a9db66f3f 100644 --- a/generated/google/apis/pubsub_v1.rb +++ b/generated/google/apis/pubsub_v1.rb @@ -25,7 +25,7 @@ module Google # @see https://cloud.google.com/pubsub/docs module PubsubV1 VERSION = 'V1' - REVISION = '20181107' + REVISION = '20181119' # 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/pubsub_v1/classes.rb b/generated/google/apis/pubsub_v1/classes.rb index 8af6ada16..d08304f60 100644 --- a/generated/google/apis/pubsub_v1/classes.rb +++ b/generated/google/apis/pubsub_v1/classes.rb @@ -868,11 +868,11 @@ module Google class Subscription include Google::Apis::Core::Hashable - # This value is the maximum time after a subscriber receives a message - # before the subscriber should acknowledge the message. After message - # delivery but before the ack deadline expires and before the message is - # acknowledged, it is an outstanding message and will not be delivered - # again during that time (on a best-effort basis). + # The approximate amount of time (on a best-effort basis) Pub/Sub waits for + # the subscriber to acknowledge receipt before resending the message. In the + # interval after the message is delivered and before it is acknowledged, it + # is considered to be outstanding. During that time period, the + # message will not be redelivered (on a best-effort basis). # For pull subscriptions, this value is used as the initial value for the ack # deadline. To override this value for a given message, call # `ModifyAckDeadline` with the corresponding `ack_id` if using diff --git a/generated/google/apis/serviceconsumermanagement_v1.rb b/generated/google/apis/serviceconsumermanagement_v1.rb index c7307f777..d66d8a3d2 100644 --- a/generated/google/apis/serviceconsumermanagement_v1.rb +++ b/generated/google/apis/serviceconsumermanagement_v1.rb @@ -25,7 +25,7 @@ module Google # @see https://cloud.google.com/service-consumer-management/docs/overview module ServiceconsumermanagementV1 VERSION = 'V1' - REVISION = '20181030' + REVISION = '20181121' # 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/serviceconsumermanagement_v1/classes.rb b/generated/google/apis/serviceconsumermanagement_v1/classes.rb index ed73b6849..5f743d74a 100644 --- a/generated/google/apis/serviceconsumermanagement_v1/classes.rb +++ b/generated/google/apis/serviceconsumermanagement_v1/classes.rb @@ -132,6 +132,71 @@ module Google end end + # Request to apply configuration to an existing tenant project. + class ApplyTenantProjectConfigRequest + include Google::Apis::Core::Hashable + + # This structure defines a tenant project to be added to the specified tenancy + # unit and its initial configuration and properties. A project lien will be + # created for the tenant project to prevent the tenant project from being + # deleted accidentally. The lien will be deleted as part of tenant project + # removal. + # Corresponds to the JSON property `projectConfig` + # @return [Google::Apis::ServiceconsumermanagementV1::TenantProjectConfig] + attr_accessor :project_config + + # Tag of the project. Must be less than 128 characters. Required. + # Corresponds to the JSON property `tag` + # @return [String] + attr_accessor :tag + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @project_config = args[:project_config] if args.key?(:project_config) + @tag = args[:tag] if args.key?(:tag) + end + end + + # Request to attach an existing project to the tenancy unit as a new tenant + # resource. + class AttachTenantProjectRequest + include Google::Apis::Core::Hashable + + # When attaching an external project, this is in the format of + # `projects/`project_number`’. + # Corresponds to the JSON property `externalResource` + # @return [String] + attr_accessor :external_resource + + # When attaching a reserved project already in Tenancy Units, this is the + # tag of tenant resource under the tenancy unit for the service's producer + # project. The reserved tenant resource must be in active state. + # Corresponds to the JSON property `reservedResource` + # @return [String] + attr_accessor :reserved_resource + + # Tag of the tenant resource after attachment. + # Must be less than 128 characters. Required. + # Corresponds to the JSON property `tag` + # @return [String] + attr_accessor :tag + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @external_resource = args[:external_resource] if args.key?(:external_resource) + @reserved_resource = args[:reserved_resource] if args.key?(:reserved_resource) + @tag = args[:tag] if args.key?(:tag) + end + end + # Configuration for an anthentication provider, including support for # [JSON Web Token (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web- # token-32). diff --git a/generated/google/apis/serviceconsumermanagement_v1/representations.rb b/generated/google/apis/serviceconsumermanagement_v1/representations.rb index 334100aef..a2b6a7772 100644 --- a/generated/google/apis/serviceconsumermanagement_v1/representations.rb +++ b/generated/google/apis/serviceconsumermanagement_v1/representations.rb @@ -34,6 +34,18 @@ module Google include Google::Apis::Core::JsonObjectSupport end + class ApplyTenantProjectConfigRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class AttachTenantProjectRequest + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + class AuthProvider class Representation < Google::Apis::Core::JsonRepresentation; end @@ -456,6 +468,24 @@ module Google end end + class ApplyTenantProjectConfigRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :project_config, as: 'projectConfig', class: Google::Apis::ServiceconsumermanagementV1::TenantProjectConfig, decorator: Google::Apis::ServiceconsumermanagementV1::TenantProjectConfig::Representation + + property :tag, as: 'tag' + end + end + + class AttachTenantProjectRequest + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :external_resource, as: 'externalResource' + property :reserved_resource, as: 'reservedResource' + property :tag, as: 'tag' + end + end + class AuthProvider # @private class Representation < Google::Apis::Core::JsonRepresentation diff --git a/generated/google/apis/serviceconsumermanagement_v1/service.rb b/generated/google/apis/serviceconsumermanagement_v1/service.rb index 01e3a3f85..dce2efdc9 100644 --- a/generated/google/apis/serviceconsumermanagement_v1/service.rb +++ b/generated/google/apis/serviceconsumermanagement_v1/service.rb @@ -299,6 +299,95 @@ module Google execute_or_queue_command(command, &block) end + # Apply configuration to an existing tenant project. + # This project must exist in active state and have the original owner + # account. Caller must have the permission to add a project to the given + # tenancy unit. Configuration will be applied, but any existing settings on + # the project will not be modified. + # Specified policy bindings will be applied. Existing binding will not be + # modified. + # Specified services will be activated. No service will be deactivated. + # New billing configuration will be applied if specified. + # Omit billing configuration to keep the existing one. + # Service account in the project will be created if previously non existing. + # Operation fails if any of the steps fail, but no rollback of already + # applied configuration changes is attempted. + # Operation. + # @param [String] name + # Name of the tenancy unit. + # @param [Google::Apis::ServiceconsumermanagementV1::ApplyTenantProjectConfigRequest] apply_tenant_project_config_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::ServiceconsumermanagementV1::Operation] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::ServiceconsumermanagementV1::Operation] + # + # @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 apply_service_tenancy_unit_project_config(name, apply_tenant_project_config_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1/{+name}:applyProjectConfig', options) + command.request_representation = Google::Apis::ServiceconsumermanagementV1::ApplyTenantProjectConfigRequest::Representation + command.request_object = apply_tenant_project_config_request_object + command.response_representation = Google::Apis::ServiceconsumermanagementV1::Operation::Representation + command.response_class = Google::Apis::ServiceconsumermanagementV1::Operation + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + + # Attach an existing project to the tenancy unit as a new tenant + # resource. The project could be either the tenant project reserved by + # calling AddTenantProject under tenancy unit for the producer project of + # service, or from outside. + # Caller will be checked against the permission as if calling + # AddTenantProject on the same consumer. + # To trigger the attachement, the targeted tenant project must be in a + # folder. Please also make sure ServiceConsumerManagement service account is + # the owner of that project. Note that these two requirements are already met + # if the project is reserved through AddTenantProject. + # Operation. + # @param [String] name + # Name of the tenancy unit that project will be attached to. + # @param [Google::Apis::ServiceconsumermanagementV1::AttachTenantProjectRequest] attach_tenant_project_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::ServiceconsumermanagementV1::Operation] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::ServiceconsumermanagementV1::Operation] + # + # @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 attach_service_tenancy_unit_project(name, attach_tenant_project_request_object = nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'v1/{+name}:attachProject', options) + command.request_representation = Google::Apis::ServiceconsumermanagementV1::AttachTenantProjectRequest::Representation + command.request_object = attach_tenant_project_request_object + command.response_representation = Google::Apis::ServiceconsumermanagementV1::Operation::Representation + command.response_class = Google::Apis::ServiceconsumermanagementV1::Operation + command.params['name'] = name unless name.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + # Creates a tenancy unit with no tenant resources. # @param [String] parent # services/`service`/`collection id`/`resource id` diff --git a/generated/google/apis/vault_v1.rb b/generated/google/apis/vault_v1.rb index 6c81da54c..29ef78c90 100644 --- a/generated/google/apis/vault_v1.rb +++ b/generated/google/apis/vault_v1.rb @@ -25,7 +25,7 @@ module Google # @see https://developers.google.com/vault module VaultV1 VERSION = 'V1' - REVISION = '20181106' + REVISION = '20181128' # Manage your eDiscovery data AUTH_EDISCOVERY = 'https://www.googleapis.com/auth/ediscovery' diff --git a/generated/google/apis/vault_v1/classes.rb b/generated/google/apis/vault_v1/classes.rb index 3ec7f6cb0..d0ee12b03 100644 --- a/generated/google/apis/vault_v1/classes.rb +++ b/generated/google/apis/vault_v1/classes.rb @@ -486,6 +486,11 @@ module Google # @return [Google::Apis::VaultV1::MailExportOptions] attr_accessor :mail_options + # The requested export location. + # Corresponds to the JSON property `region` + # @return [String] + attr_accessor :region + def initialize(**args) update!(**args) end @@ -496,6 +501,7 @@ module Google @groups_options = args[:groups_options] if args.key?(:groups_options) @hangouts_chat_options = args[:hangouts_chat_options] if args.key?(:hangouts_chat_options) @mail_options = args[:mail_options] if args.key?(:mail_options) + @region = args[:region] if args.key?(:region) end end @@ -956,12 +962,6 @@ module Google # @return [String] attr_accessor :export_format - # Set to true to export confidential mode content - # Corresponds to the JSON property `showConfidentialModeContent` - # @return [Boolean] - attr_accessor :show_confidential_mode_content - alias_method :show_confidential_mode_content?, :show_confidential_mode_content - def initialize(**args) update!(**args) end @@ -969,7 +969,6 @@ module Google # Update properties of this object def update!(**args) @export_format = args[:export_format] if args.key?(:export_format) - @show_confidential_mode_content = args[:show_confidential_mode_content] if args.key?(:show_confidential_mode_content) end end diff --git a/generated/google/apis/vault_v1/representations.rb b/generated/google/apis/vault_v1/representations.rb index ced938203..b13503ab1 100644 --- a/generated/google/apis/vault_v1/representations.rb +++ b/generated/google/apis/vault_v1/representations.rb @@ -452,6 +452,7 @@ module Google property :mail_options, as: 'mailOptions', class: Google::Apis::VaultV1::MailExportOptions, decorator: Google::Apis::VaultV1::MailExportOptions::Representation + property :region, as: 'region' end end @@ -604,7 +605,6 @@ module Google # @private class Representation < Google::Apis::Core::JsonRepresentation property :export_format, as: 'exportFormat' - property :show_confidential_mode_content, as: 'showConfidentialModeContent' end end