Autogenerated update (2018-02-13)

Update:
- androidmanagement_v1
- slides_v1
This commit is contained in:
Google APIs committed 2018-02-13 00:35:58 +00:00
1 parent 6f96104e4f
commit 7d31a91417
11 files changed
+5995 -10

No files matched your search

@@ -26,7 +26,7 @@ module Google
# @see https://developers.google.com/android/management
module AndroidmanagementV1
VERSION = 'V1'
REVISION = '20180129'
REVISION = '20180207'
# Manage Android devices and apps for your customers
AUTH_ANDROIDMANAGEMENT = 'https://www.googleapis.com/auth/androidmanagement'
@@ -152,6 +152,11 @@ module Google
# @return [String]
attr_accessor :default_permission_policy
# The scopes delegated to the app from Android Device Policy.
# Corresponds to the JSON property `delegatedScopes`
# @return [Array<String>]
attr_accessor :delegated_scopes
# The type of installation to perform.
# Corresponds to the JSON property `installType`
# @return [String]
@@ -177,6 +182,16 @@ module Google
# @return [Hash<String,Object>]
attr_accessor :managed_configuration
# The minimum version of the app that runs on the device. If set, the device
# attempts to update the app to at least this version code. If the app is not up-
# to-date, the device will contain a NonComplianceDetail with
# non_compliance_reason set to APP_NOT_UPDATED. The app must already be
# published to Google Play with a version code greater than or equal to this
# value. At most 20 apps may specify a minimum version code per policy.
# Corresponds to the JSON property `minimumVersionCode`
# @return [Fixnum]
attr_accessor :minimum_version_code
# The package name of the app. For example, com.google.android.youtube for the
# YouTube app.
# Corresponds to the JSON property `packageName`
@@ -196,9 +211,11 @@ module Google
# Update properties of this object
def update!(**args)
@default_permission_policy = args[:default_permission_policy] if args.key?(:default_permission_policy)
@delegated_scopes = args[:delegated_scopes] if args.key?(:delegated_scopes)
@install_type = args[:install_type] if args.key?(:install_type)
@lock_task_allowed = args[:lock_task_allowed] if args.key?(:lock_task_allowed)
@managed_configuration = args[:managed_configuration] if args.key?(:managed_configuration)
@minimum_version_code = args[:minimum_version_code] if args.key?(:minimum_version_code)
@package_name = args[:package_name] if args.key?(:package_name)
@permission_grants = args[:permission_grants] if args.key?(:permission_grants)
end
@@ -501,13 +518,14 @@ module Google
class DeviceSettings
include Google::Apis::Core::Hashable
# If the ADB is enabled Settings.Global.ADB_ENABLED.
# Whether ADB (https://developer.android.com/studio/command-line/adb.html) is
# enabled on the device.
# Corresponds to the JSON property `adbEnabled`
# @return [Boolean]
attr_accessor :adb_enabled
alias_method :adb_enabled?, :adb_enabled
# If the developer mode is enabled Settings.Global.DEVELOPMENT_SETTINGS_ENABLED.
# Whether developer mode is enabled on the device.
# Corresponds to the JSON property `developmentSettingsEnabled`
# @return [Boolean]
attr_accessor :development_settings_enabled
@@ -518,27 +536,31 @@ module Google
# @return [String]
attr_accessor :encryption_status
# Device secured with PIN/password.
# Whether the device is secured with PIN/password.
# Corresponds to the JSON property `isDeviceSecure`
# @return [Boolean]
attr_accessor :is_device_secure
alias_method :is_device_secure?, :is_device_secure
# Whether the storage encryption is enabled DevicePolicyManager.
# ENCRYPTION_STATUS_ACTIVE or DevicePolicyManager.
# ENCRYPTION_STATUS_ACTIVE_PER_USER in N+ devices.
# Whether the storage encryption is enabled.
# Corresponds to the JSON property `isEncrypted`
# @return [Boolean]
attr_accessor :is_encrypted
alias_method :is_encrypted?, :is_encrypted
# If installing apps from unknown sources is enabled. Settings.Secure.
# INSTALL_NON_MARKET_APPS.
# Whether installing apps from unknown sources is enabled.
# Corresponds to the JSON property `unknownSourcesEnabled`
# @return [Boolean]
attr_accessor :unknown_sources_enabled
alias_method :unknown_sources_enabled?, :unknown_sources_enabled
# Whether Verify Apps (Google Play Protect (https://support.google.com/
# googleplay/answer/2812853)) is enabled on the device.
# Corresponds to the JSON property `verifyAppsEnabled`
# @return [Boolean]
attr_accessor :verify_apps_enabled
alias_method :verify_apps_enabled?, :verify_apps_enabled
def initialize(**args)
update!(**args)
end
@@ -551,6 +573,7 @@ module Google
@is_device_secure = args[:is_device_secure] if args.key?(:is_device_secure)
@is_encrypted = args[:is_encrypted] if args.key?(:is_encrypted)
@unknown_sources_enabled = args[:unknown_sources_enabled] if args.key?(:unknown_sources_enabled)
@verify_apps_enabled = args[:verify_apps_enabled] if args.key?(:verify_apps_enabled)
end
end
@@ -1187,6 +1210,11 @@ module Google
# @return [String]
attr_accessor :meid
# Alphabetic name of current registered operator. For example, Vodafone.
# Corresponds to the JSON property `networkOperatorName`
# @return [String]
attr_accessor :network_operator_name
# Wi-Fi MAC address of the device. For example, 7c:11:11:11:11:11.
# Corresponds to the JSON property `wifiMacAddress`
# @return [String]
@@ -1200,6 +1228,7 @@ module Google
def update!(**args)
@imei = args[:imei] if args.key?(:imei)
@meid = args[:meid] if args.key?(:meid)
@network_operator_name = args[:network_operator_name] if args.key?(:network_operator_name)
@wifi_mac_address = args[:wifi_mac_address] if args.key?(:wifi_mac_address)
end
end
@@ -1592,6 +1621,13 @@ module Google
# @return [Google::Apis::AndroidmanagementV1::AlwaysOnVpnPackage]
attr_accessor :always_on_vpn_package
# The app tracks for Android Device Policy the device can access. The device
# receives the latest version among all accessible tracks. If no tracks are
# specified, then the device only uses the production track.
# Corresponds to the JSON property `androidDevicePolicyTracks`
# @return [Array<String>]
attr_accessor :android_device_policy_tracks
# Policy applied to apps.
# Corresponds to the JSON property `applications`
# @return [Array<Google::Apis::AndroidmanagementV1::ApplicationPolicy>]
@@ -1961,6 +1997,7 @@ module Google
@add_user_disabled = args[:add_user_disabled] if args.key?(:add_user_disabled)
@adjust_volume_disabled = args[:adjust_volume_disabled] if args.key?(:adjust_volume_disabled)
@always_on_vpn_package = args[:always_on_vpn_package] if args.key?(:always_on_vpn_package)
@android_device_policy_tracks = args[:android_device_policy_tracks] if args.key?(:android_device_policy_tracks)
@applications = args[:applications] if args.key?(:applications)
@auto_time_required = args[:auto_time_required] if args.key?(:auto_time_required)
@block_applications_enabled = args[:block_applications_enabled] if args.key?(:block_applications_enabled)
@@ -2153,6 +2190,14 @@ module Google
# @return [String]
attr_accessor :bootloader_version
# SHA-256 hash of android.content.pm.Signature (https://developer.android.com/
# reference/android/content/pm/Signature.html) associated with the system
# package, which can be used to verify that the system build hasn't been
# modified.
# Corresponds to the JSON property `deviceBuildSignature`
# @return [String]
attr_accessor :device_build_signature
# Kernel version, for example, 2.6.32.9-g103d848.
# Corresponds to the JSON property `deviceKernelVersion`
# @return [String]
@@ -2175,6 +2220,7 @@ module Google
@android_device_policy_version_name = args[:android_device_policy_version_name] if args.key?(:android_device_policy_version_name)
@android_version = args[:android_version] if args.key?(:android_version)
@bootloader_version = args[:bootloader_version] if args.key?(:bootloader_version)
@device_build_signature = args[:device_build_signature] if args.key?(:device_build_signature)
@device_kernel_version = args[:device_kernel_version] if args.key?(:device_kernel_version)
@security_patch_level = args[:security_patch_level] if args.key?(:security_patch_level)
end
@@ -308,9 +308,11 @@ module Google
# @private
class Representation < Google::Apis::Core::JsonRepresentation
property :default_permission_policy, as: 'defaultPermissionPolicy'
collection :delegated_scopes, as: 'delegatedScopes'
property :install_type, as: 'installType'
property :lock_task_allowed, as: 'lockTaskAllowed'
hash :managed_configuration, as: 'managedConfiguration'
property :minimum_version_code, as: 'minimumVersionCode'
property :package_name, as: 'packageName'
collection :permission_grants, as: 'permissionGrants', class: Google::Apis::AndroidmanagementV1::PermissionGrant, decorator: Google::Apis::AndroidmanagementV1::PermissionGrant::Representation
@@ -392,6 +394,7 @@ module Google
property :is_device_secure, as: 'isDeviceSecure'
property :is_encrypted, as: 'isEncrypted'
property :unknown_sources_enabled, as: 'unknownSourcesEnabled'
property :verify_apps_enabled, as: 'verifyAppsEnabled'
end
end
@@ -554,6 +557,7 @@ module Google
class Representation < Google::Apis::Core::JsonRepresentation
property :imei, as: 'imei'
property :meid, as: 'meid'
property :network_operator_name, as: 'networkOperatorName'
property :wifi_mac_address, as: 'wifiMacAddress'
end
end
@@ -640,6 +644,7 @@ module Google
property :adjust_volume_disabled, as: 'adjustVolumeDisabled'
property :always_on_vpn_package, as: 'alwaysOnVpnPackage', class: Google::Apis::AndroidmanagementV1::AlwaysOnVpnPackage, decorator: Google::Apis::AndroidmanagementV1::AlwaysOnVpnPackage::Representation
collection :android_device_policy_tracks, as: 'androidDevicePolicyTracks'
collection :applications, as: 'applications', class: Google::Apis::AndroidmanagementV1::ApplicationPolicy, decorator: Google::Apis::AndroidmanagementV1::ApplicationPolicy::Representation
property :auto_time_required, as: 'autoTimeRequired'
@@ -746,6 +751,7 @@ module Google
property :android_device_policy_version_name, as: 'androidDevicePolicyVersionName'
property :android_version, as: 'androidVersion'
property :bootloader_version, as: 'bootloaderVersion'
property :device_build_signature, as: 'deviceBuildSignature'
property :device_kernel_version, as: 'deviceKernelVersion'
property :security_patch_level, as: 'securityPatchLevel'
end
+42
View File
@@ -0,0 +1,42 @@
# 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/serviceusage_v1/service.rb'
require 'google/apis/serviceusage_v1/classes.rb'
require 'google/apis/serviceusage_v1/representations.rb'
module Google
module Apis
# Service Usage API
#
# Enables services that service consumers want to use on Google Cloud Platform,
# lists the available or enabled services, or disables services that service
# consumers no longer use.
#
# @see https://cloud.google.com/service-usage/
module ServiceusageV1
VERSION = 'V1'
REVISION = '20180210'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
# View your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM_READ_ONLY = 'https://www.googleapis.com/auth/cloud-platform.read-only'
# Manage your Google API service configuration
AUTH_SERVICE_MANAGEMENT = 'https://www.googleapis.com/auth/service.management'
end
end
end
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,406 @@
# 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 ServiceusageV1
# Service Usage API
#
# Enables services that service consumers want to use on Google Cloud Platform,
# lists the available or enabled services, or disables services that service
# consumers no longer use.
#
# @example
# require 'google/apis/serviceusage_v1'
#
# Serviceusage = Google::Apis::ServiceusageV1 # Alias the module
# service = Serviceusage::ServiceUsageService.new
#
# @see https://cloud.google.com/service-usage/
class ServiceUsageService < 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://serviceusage.googleapis.com/', '')
@batch_path = 'batch'
end
# Starts asynchronous cancellation on a long-running operation. The server
# makes a best effort to cancel the operation, but success is not
# guaranteed. If the server doesn't support this method, it returns
# `google.rpc.Code.UNIMPLEMENTED`. Clients can use
# Operations.GetOperation or
# other methods to check whether the cancellation succeeded or whether the
# operation completed despite cancellation. On successful cancellation,
# the operation is not deleted; instead, it becomes an operation with
# an Operation.error value with a google.rpc.Status.code of 1,
# corresponding to `Code.CANCELLED`.
# @param [String] name
# The name of the operation resource to be cancelled.
# @param [Google::Apis::ServiceusageV1::CancelOperationRequest] cancel_operation_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::ServiceusageV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::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 cancel_operation(name, cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:cancel', options)
command.request_representation = Google::Apis::ServiceusageV1::CancelOperationRequest::Representation
command.request_object = cancel_operation_request_object
command.response_representation = Google::Apis::ServiceusageV1::Empty::Representation
command.response_class = Google::Apis::ServiceusageV1::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
# Deletes a long-running operation. This method indicates that the client is
# no longer interested in the operation result. It does not cancel the
# operation. If the server doesn't support this method, it returns
# `google.rpc.Code.UNIMPLEMENTED`.
# @param [String] name
# The name of the operation resource to be deleted.
# @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::ServiceusageV1::Empty] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::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_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:delete, 'v1/{+name}', options)
command.response_representation = Google::Apis::ServiceusageV1::Empty::Representation
command.response_class = Google::Apis::ServiceusageV1::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 the latest state of a long-running operation. Clients can use this
# method to poll the operation result at intervals as recommended by the API
# service.
# @param [String] name
# The name of the operation resource.
# @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::ServiceusageV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::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 get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::ServiceusageV1::Operation::Representation
command.response_class = Google::Apis::ServiceusageV1::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
# Lists operations that match the specified filter in the request. If the
# server doesn't support this method, it returns `UNIMPLEMENTED`.
# NOTE: the `name` binding allows API services to override the binding
# to use different resource name schemes, such as `users/*/operations`. To
# override the binding, API services can add a binding such as
# `"/v1/`name=users/*`/operations"` to their service configuration.
# For backwards compatibility, the default name includes the operations
# collection id, however overriding users must ensure the name binding
# is the parent resource, without the operations collection id.
# @param [String] filter
# The standard list filter.
# @param [String] name
# The name of the operation's parent resource.
# @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::ServiceusageV1::ListOperationsResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::ListOperationsResponse]
#
# @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_operations(filter: nil, name: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/operations', options)
command.response_representation = Google::Apis::ServiceusageV1::ListOperationsResponse::Representation
command.response_class = Google::Apis::ServiceusageV1::ListOperationsResponse
command.query['filter'] = filter unless filter.nil?
command.query['name'] = name unless name.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
# Disable a service so it can no longer be used with a
# project. This prevents unintended usage that may cause unexpected billing
# charges or security leaks.
# It is not valid to call the disable method on a service that is not
# currently enabled. Callers will receive a FAILED_PRECONDITION status if
# the target service is not currently enabled.
# Operation<response: google.protobuf.Empty>
# @param [String] name
# Name of the consumer and service to disable the service on.
# The enable and disable methods currently only support projects.
# An example name would be:
# projects/123/services/serviceusage.googleapis.com
# @param [Google::Apis::ServiceusageV1::DisableServiceRequest] disable_service_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::ServiceusageV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::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 disable_service(name, disable_service_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:disable', options)
command.request_representation = Google::Apis::ServiceusageV1::DisableServiceRequest::Representation
command.request_object = disable_service_request_object
command.response_representation = Google::Apis::ServiceusageV1::Operation::Representation
command.response_class = Google::Apis::ServiceusageV1::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
# Enable a service so it can be used with a project.
# See [Cloud Auth Guide](https://cloud.google.com/docs/authentication) for
# more information.
# Operation<response: google.protobuf.Empty>
# @param [String] name
# Name of the consumer and service to enable the service on.
# The enable and disable methods currently only support projects.
# Enabling a service requires that the service is public or is shared with
# the user enabling the service.
# An example name would be:
# projects/123/services/serviceusage.googleapis.com
# @param [Google::Apis::ServiceusageV1::EnableServiceRequest] enable_service_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::ServiceusageV1::Operation] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::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 enable_service(name, enable_service_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:post, 'v1/{+name}:enable', options)
command.request_representation = Google::Apis::ServiceusageV1::EnableServiceRequest::Representation
command.request_object = enable_service_request_object
command.response_representation = Google::Apis::ServiceusageV1::Operation::Representation
command.response_class = Google::Apis::ServiceusageV1::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
# Returns the service definition and EnabledState for a given service.
# @param [String] name
# Name of the consumer and service to get the ConsumerState for.
# An example name would be:
# projects/123/services/serviceusage.googleapis.com
# @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::ServiceusageV1::ServiceState] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::ServiceState]
#
# @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_service(name, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+name}', options)
command.response_representation = Google::Apis::ServiceusageV1::ServiceState::Representation
command.response_class = Google::Apis::ServiceusageV1::ServiceState
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
# List enabled services.
# @param [String] parent
# Parent to search for services on.
# An example name would be:
# projects/123
# @param [Fixnum] page_size
# Requested size of the next page of data.
# @param [String] page_token
# Token identifying which result to start with; returned by a previous list
# call.
# @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::ServiceusageV1::ListEnabledServicesResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::ListEnabledServicesResponse]
#
# @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_service_enabled(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/{+parent}/services:enabled', options)
command.response_representation = Google::Apis::ServiceusageV1::ListEnabledServicesResponse::Representation
command.response_class = Google::Apis::ServiceusageV1::ListEnabledServicesResponse
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
# Search available services.
# When no filter is specified, returns all accessible services. This includes
# public services and services for which the calling user has the
# "servicemanagement.services.bind" permission.
# @param [Fixnum] page_size
# Requested size of the next page of data.
# @param [String] page_token
# Token identifying which result to start with; returned by a previous search
# call.
# @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::ServiceusageV1::SearchServicesResponse] parsed result object
# @yieldparam err [StandardError] error object if request failed
#
# @return [Google::Apis::ServiceusageV1::SearchServicesResponse]
#
# @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 search_services(page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
command = make_simple_command(:get, 'v1/services:search', options)
command.response_representation = Google::Apis::ServiceusageV1::SearchServicesResponse::Representation
command.response_class = Google::Apis::ServiceusageV1::SearchServicesResponse
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
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
+1 -1
View File
@@ -25,7 +25,7 @@ module Google
# @see https://developers.google.com/slides/
module SlidesV1
VERSION = 'V1'
REVISION = '20180201'
REVISION = '20180208'
# View and manage the files in your Google Drive
AUTH_DRIVE = 'https://www.googleapis.com/auth/drive'
@@ -170,6 +170,11 @@ module Google
# @return [Array<Google::Apis::SlidesV1::Response>]
attr_accessor :replies
# Provides control over how write requests are executed.
# Corresponds to the JSON property `writeControl`
# @return [Google::Apis::SlidesV1::WriteControl]
attr_accessor :write_control
def initialize(**args)
update!(**args)
end
@@ -178,6 +183,7 @@ module Google
def update!(**args)
@presentation_id = args[:presentation_id] if args.key?(:presentation_id)
@replies = args[:replies] if args.key?(:replies)
@write_control = args[:write_control] if args.key?(:write_control)
end
end
@@ -1189,6 +1195,12 @@ module Google
# @return [Google::Apis::SlidesV1::ImageProperties]
attr_accessor :image_properties
# The source URL is the URL used to insert the image. The source URL can be
# empty.
# Corresponds to the JSON property `sourceUrl`
# @return [String]
attr_accessor :source_url
def initialize(**args)
update!(**args)
end
@@ -1197,6 +1209,7 @@ module Google
def update!(**args)
@content_url = args[:content_url] if args.key?(:content_url)
@image_properties = args[:image_properties] if args.key?(:image_properties)
@source_url = args[:source_url] if args.key?(:source_url)
end
end
@@ -823,6 +823,8 @@ module Google
property :presentation_id, as: 'presentationId'
collection :replies, as: 'replies', class: Google::Apis::SlidesV1::Response, decorator: Google::Apis::SlidesV1::Response::Representation
property :write_control, as: 'writeControl', class: Google::Apis::SlidesV1::WriteControl, decorator: Google::Apis::SlidesV1::WriteControl::Representation
end
end
@@ -1102,6 +1104,7 @@ module Google
property :content_url, as: 'contentUrl'
property :image_properties, as: 'imageProperties', class: Google::Apis::SlidesV1::ImageProperties, decorator: Google::Apis::SlidesV1::ImageProperties::Representation
property :source_url, as: 'sourceUrl'
end
end