Autogenerated update (2020-05-07)
Delete: - commentanalyzer_v1alpha1 - osconfig_v1beta Update: - adexchangebuyer2_v2beta1 - androidenterprise_v1 - androidpublisher_v1 - androidpublisher_v1_1 - androidpublisher_v2 - androidpublisher_v3 - bigquery_v2 - bigqueryconnection_v1beta1 - bigqueryreservation_v1 - bigqueryreservation_v1beta1 - binaryauthorization_v1 - binaryauthorization_v1beta1 - calendar_v3 - cloudasset_v1p1beta1 - cloudbilling_v1 - cloudbuild_v1 - clouddebugger_v2 - cloudidentity_v1beta1 - cloudiot_v1 - cloudresourcemanager_v1 - cloudresourcemanager_v1beta1 - cloudresourcemanager_v2 - cloudresourcemanager_v2beta1 - cloudscheduler_v1 - cloudscheduler_v1beta1 - cloudsearch_v1 - cloudshell_v1alpha1 - cloudtasks_v2 - cloudtasks_v2beta2 - cloudtasks_v2beta3 - cloudtrace_v2 - composer_v1beta1 - compute_alpha - compute_beta - compute_v1 - container_v1 - container_v1beta1 - containeranalysis_v1alpha1 - containeranalysis_v1beta1 - content_v2 - content_v2_1 - customsearch_v1 - datacatalog_v1beta1 - dataproc_v1 - dataproc_v1beta2 - dialogflow_v2 - dialogflow_v2beta1 - displayvideo_v1 - dlp_v2 - drive_v2 - drive_v3 - driveactivity_v2 - file_v1 - file_v1beta1 - firebase_v1beta1 - firebasehosting_v1beta1 - games_configuration_v1configuration - games_management_v1management - games_v1 - gameservices_v1beta - healthcare_v1 - healthcare_v1beta1 - homegraph_v1 - iamcredentials_v1 - managedidentities_v1 - managedidentities_v1alpha1 - managedidentities_v1beta1 - memcache_v1beta2 - ml_v1 - monitoring_v3 - people_v1 - policytroubleshooter_v1 - policytroubleshooter_v1beta - prod_tt_sasportal_v1alpha1 - remotebuildexecution_v1 - remotebuildexecution_v1alpha - remotebuildexecution_v2 - run_v1 - run_v1alpha1 - runtimeconfig_v1beta1 - sasportal_v1alpha1 - script_v1 - secretmanager_v1 - secretmanager_v1beta1 - serviceconsumermanagement_v1 - serviceconsumermanagement_v1beta1 - servicecontrol_v1 - servicedirectory_v1beta1 - servicemanagement_v1 - servicenetworking_v1 - servicenetworking_v1beta - serviceusage_v1 - serviceusage_v1beta1 - sheets_v4 - sourcerepo_v1 - speech_v1 - speech_v1p1beta1 - storage_v1 - tagmanager_v1 - tagmanager_v2 - testing_v1 - toolresults_v1beta3 - vault_v1 - videointelligence_v1 - videointelligence_v1beta2 - videointelligence_v1p1beta1 - videointelligence_v1p2beta1 - videointelligence_v1p3beta1 - youtube_partner_v1 - youtube_v3
This commit is contained in:
1 parent
334a41b6f9
commit
2aab01171a
308 files changed
+40747
-16123
No files matched your search
@@ -21,47 +21,6 @@ require 'google/apis/errors'
|
||||
module Google
|
||||
module Apis
|
||||
module AndroidpublisherV1
|
||||
|
||||
# A SubscriptionPurchase resource indicates the status of a user's subscription
|
||||
# purchase.
|
||||
class SubscriptionPurchase
|
||||
include Google::Apis::Core::Hashable
|
||||
|
||||
# Whether the subscription will automatically be renewed when it reaches its
|
||||
# current expiry time.
|
||||
# Corresponds to the JSON property `autoRenewing`
|
||||
# @return [Boolean]
|
||||
attr_accessor :auto_renewing
|
||||
alias_method :auto_renewing?, :auto_renewing
|
||||
|
||||
# Time at which the subscription was granted, in milliseconds since the Epoch.
|
||||
# Corresponds to the JSON property `initiationTimestampMsec`
|
||||
# @return [Fixnum]
|
||||
attr_accessor :initiation_timestamp_msec
|
||||
|
||||
# This kind represents a subscriptionPurchase object in the androidpublisher
|
||||
# service.
|
||||
# Corresponds to the JSON property `kind`
|
||||
# @return [String]
|
||||
attr_accessor :kind
|
||||
|
||||
# Time at which the subscription will expire, in milliseconds since the Epoch.
|
||||
# Corresponds to the JSON property `validUntilTimestampMsec`
|
||||
# @return [Fixnum]
|
||||
attr_accessor :valid_until_timestamp_msec
|
||||
|
||||
def initialize(**args)
|
||||
update!(**args)
|
||||
end
|
||||
|
||||
# Update properties of this object
|
||||
def update!(**args)
|
||||
@auto_renewing = args[:auto_renewing] if args.key?(:auto_renewing)
|
||||
@initiation_timestamp_msec = args[:initiation_timestamp_msec] if args.key?(:initiation_timestamp_msec)
|
||||
@kind = args[:kind] if args.key?(:kind)
|
||||
@valid_until_timestamp_msec = args[:valid_until_timestamp_msec] if args.key?(:valid_until_timestamp_msec)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -21,22 +21,6 @@ require 'google/apis/errors'
|
||||
module Google
|
||||
module Apis
|
||||
module AndroidpublisherV1
|
||||
|
||||
class SubscriptionPurchase
|
||||
class Representation < Google::Apis::Core::JsonRepresentation; end
|
||||
|
||||
include Google::Apis::Core::JsonObjectSupport
|
||||
end
|
||||
|
||||
class SubscriptionPurchase
|
||||
# @private
|
||||
class Representation < Google::Apis::Core::JsonRepresentation
|
||||
property :auto_renewing, as: 'autoRenewing'
|
||||
property :initiation_timestamp_msec, :numeric_string => true, as: 'initiationTimestampMsec'
|
||||
property :kind, as: 'kind'
|
||||
property :valid_until_timestamp_msec, :numeric_string => true, as: 'validUntilTimestampMsec'
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -47,89 +47,9 @@ module Google
|
||||
attr_accessor :user_ip
|
||||
|
||||
def initialize
|
||||
super('https://www.googleapis.com/', 'androidpublisher/v1/applications/')
|
||||
super('https://www.googleapis.com/', '')
|
||||
@batch_path = 'batch/androidpublisher/v1'
|
||||
end
|
||||
|
||||
# Cancels a user's subscription purchase. The subscription remains valid until
|
||||
# its expiration time.
|
||||
# @param [String] package_name
|
||||
# The package name of the application for which this subscription was purchased (
|
||||
# for example, 'com.some.thing').
|
||||
# @param [String] subscription_id
|
||||
# The purchased subscription ID (for example, 'monthly001').
|
||||
# @param [String] token
|
||||
# The token provided to the user's device when the subscription was purchased.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# An opaque string that represents a user for quota purposes. Must not exceed 40
|
||||
# characters.
|
||||
# @param [String] user_ip
|
||||
# Deprecated. Please use quotaUser instead.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [NilClass] No result returned for this method
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [void]
|
||||
#
|
||||
# @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_purchase(package_name, subscription_id, token, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, '{packageName}/subscriptions/{subscriptionId}/purchases/{token}/cancel', options)
|
||||
command.params['packageName'] = package_name unless package_name.nil?
|
||||
command.params['subscriptionId'] = subscription_id unless subscription_id.nil?
|
||||
command.params['token'] = token unless token.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['userIp'] = user_ip unless user_ip.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Checks whether a user's subscription purchase is valid and returns its expiry
|
||||
# time.
|
||||
# @param [String] package_name
|
||||
# The package name of the application for which this subscription was purchased (
|
||||
# for example, 'com.some.thing').
|
||||
# @param [String] subscription_id
|
||||
# The purchased subscription ID (for example, 'monthly001').
|
||||
# @param [String] token
|
||||
# The token provided to the user's device when the subscription was purchased.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# An opaque string that represents a user for quota purposes. Must not exceed 40
|
||||
# characters.
|
||||
# @param [String] user_ip
|
||||
# Deprecated. Please use quotaUser instead.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::AndroidpublisherV1::SubscriptionPurchase] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::AndroidpublisherV1::SubscriptionPurchase]
|
||||
#
|
||||
# @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_purchase(package_name, subscription_id, token, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, '{packageName}/subscriptions/{subscriptionId}/purchases/{token}', options)
|
||||
command.response_representation = Google::Apis::AndroidpublisherV1::SubscriptionPurchase::Representation
|
||||
command.response_class = Google::Apis::AndroidpublisherV1::SubscriptionPurchase
|
||||
command.params['packageName'] = package_name unless package_name.nil?
|
||||
command.params['subscriptionId'] = subscription_id unless subscription_id.nil?
|
||||
command.params['token'] = token unless token.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['userIp'] = user_ip unless user_ip.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
protected
|
||||
|
||||
|
||||
Reference in new issue
Block a user