diff --git a/api_names_out.yaml b/api_names_out.yaml index 337f9881c56..5ed13d42678 100644 --- a/api_names_out.yaml +++ b/api_names_out.yaml @@ -105470,6 +105470,11 @@ "/games:v1/CategoryListResponse/items/item": item "/games:v1/CategoryListResponse/kind": kind "/games:v1/CategoryListResponse/nextPageToken": next_page_token +"/games:v1/ContentHash": content_hash +"/games:v1/ContentHash/digest": digest +"/games:v1/ContentHash/version": version +"/games:v1/EndPoint": end_point +"/games:v1/EndPoint/url": url "/games:v1/EventBatchRecordFailure": event_batch_record_failure "/games:v1/EventBatchRecordFailure/failureCause": failure_cause "/games:v1/EventBatchRecordFailure/kind": kind @@ -105912,6 +105917,7 @@ "/games:v1/Snapshot/uniqueName": unique_name "/games:v1/SnapshotCoverImageResource": snapshot_cover_image_resource "/games:v1/SnapshotCoverImageResource/contentHash": content_hash +"/games:v1/SnapshotCoverImageResource/contentHash/content_hash": content_hash "/games:v1/SnapshotCoverImageResource/downloadUrl": download_url "/games:v1/SnapshotCoverImageResource/height": height "/games:v1/SnapshotCoverImageResource/mimeType": mime_type @@ -105919,6 +105925,7 @@ "/games:v1/SnapshotCoverImageResource/width": width "/games:v1/SnapshotDataResource": snapshot_data_resource "/games:v1/SnapshotDataResource/contentHash": content_hash +"/games:v1/SnapshotDataResource/contentHash/content_hash": content_hash "/games:v1/SnapshotDataResource/downloadUrl": download_url "/games:v1/SnapshotDataResource/resourceId": resource_id "/games:v1/SnapshotDataResource/size": size @@ -106081,6 +106088,9 @@ "/games:v1/games.applications.get/consistencyToken": consistency_token "/games:v1/games.applications.get/language": language "/games:v1/games.applications.get/platformType": platform_type +"/games:v1/games.applications.getEndPoint": get_application_end_point +"/games:v1/games.applications.getEndPoint/applicationId": application_id +"/games:v1/games.applications.getEndPoint/endPointType": end_point_type "/games:v1/games.applications.played": played_application "/games:v1/games.applications.played/builtinGameId": builtin_game_id "/games:v1/games.applications.played/consistencyToken": consistency_token diff --git a/generated/google/apis/games_v1.rb b/generated/google/apis/games_v1.rb index 985915e715b..5f1af1d3bad 100644 --- a/generated/google/apis/games_v1.rb +++ b/generated/google/apis/games_v1.rb @@ -26,7 +26,7 @@ module Apis # @see https://developers.google.com/games/ module GamesV1 VERSION = 'V1' - REVISION = '20201022' + REVISION = '20201125' # View and manage its own configuration data in your Google Drive AUTH_DRIVE_APPDATA = 'https://www.googleapis.com/auth/drive.appdata' diff --git a/generated/google/apis/games_v1/classes.rb b/generated/google/apis/games_v1/classes.rb index 5a409278705..b2dbc90b212 100644 --- a/generated/google/apis/games_v1/classes.rb +++ b/generated/google/apis/games_v1/classes.rb @@ -644,6 +644,55 @@ def update!(**args) end end + # Hash-like weak identifier of uploaded content bytes (saved game data blob, or + # cover image). Consistent per player per application per hash version. Within + # the context of a single player/application, it's guaranteed that two identical + # blobs coming from two different uploads will have the same content hash. It's + # extremely likely, though not guaranteed, that if two content hashes are equal, + # the blobs are identical. + class ContentHash + include Google::Apis::Core::Hashable + + # Hash-like digest of the content. + # Corresponds to the JSON property `digest` + # @return [String] + attr_accessor :digest + + # Version of the Hash encoding algorithm to hash the content. + # Corresponds to the JSON property `version` + # @return [Fixnum] + attr_accessor :version + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @digest = args[:digest] if args.key?(:digest) + @version = args[:version] if args.key?(:version) + end + end + + # Container for a URL end point of the requested type. + class EndPoint + include Google::Apis::Core::Hashable + + # A URL suitable for loading in a web browser for the requested endpoint. + # Corresponds to the JSON property `url` + # @return [String] + attr_accessor :url + + def initialize(**args) + update!(**args) + end + + # Update properties of this object + def update!(**args) + @url = args[:url] if args.key?(:url) + end + end + # A batch update failure resource. class EventBatchRecordFailure include Google::Apis::Core::Hashable @@ -2501,12 +2550,14 @@ class SnapshotCoverImageResource include Google::Apis::Core::Hashable # Output only. Hash-like weak identifier of the uploaded image bytes, consistent - # per player per application. Within the context of a single player/application, - # it's guaranteed that two identical blobs coming from two different uploads - # will have the same content hash. It's extremely likely, though not guaranteed, - # that if two content hashes are equal, the images are identical. + # per player per application per hash version. Within the context of a single + # player/application, it's guaranteed that two identical images coming from two + # different uploads will have the same content hash for the same hash algorithm + # version. It's extremely likely, though not guaranteed, that if two content + # hashes are equal, the images are identical. More than one content hash can be + # returned if more than one hash versions are supported. # Corresponds to the JSON property `contentHash` - # @return [String] + # @return [Array] attr_accessor :content_hash # Output only. A URL the client can use to download the image. May vary across @@ -2516,12 +2567,12 @@ class SnapshotCoverImageResource # @return [String] attr_accessor :download_url - # Output only. The height of the image in pixels. + # The height of the image in pixels. # Corresponds to the JSON property `height` # @return [Fixnum] attr_accessor :height - # Output only. The MIME type of the image. + # The MIME type of the image. # Corresponds to the JSON property `mimeType` # @return [String] attr_accessor :mime_type @@ -2537,7 +2588,7 @@ class SnapshotCoverImageResource # @return [String] attr_accessor :resource_id - # Output only. The width of the image in pixels. + # The width of the image in pixels. # Corresponds to the JSON property `width` # @return [Fixnum] attr_accessor :width @@ -2562,12 +2613,14 @@ class SnapshotDataResource include Google::Apis::Core::Hashable # Output only. Hash-like weak identifier of the uploaded blob, consistent per - # player per application. Within the context of a single player/application, it' - # s guaranteed that two identical blobs coming from two different uploads will - # have the same content hash. It's extremely likely, though not guaranteed, that - # if two content hashes are equal, the blobs are identical. + # player per application per hash version. Within the context of a single player/ + # application, it's guaranteed that two identical blobs coming from two + # different uploads will have the same content hash for the same hash algorithm + # version. It's extremely likely, though not guaranteed, that if two content + # hashes are equal, the blobs are identical. More than one content hash can be + # returned if more than one hash versions are supported. # Corresponds to the JSON property `contentHash` - # @return [String] + # @return [Array] attr_accessor :content_hash # Output only. A URL that the client can use to download the blob. May vary @@ -2588,7 +2641,7 @@ class SnapshotDataResource # @return [String] attr_accessor :resource_id - # Size of the saved game blob in bytes. + # Output only. Size of the saved game blob in bytes. # Corresponds to the JSON property `size` # @return [Fixnum] attr_accessor :size diff --git a/generated/google/apis/games_v1/representations.rb b/generated/google/apis/games_v1/representations.rb index daaf22de5b1..ef7c0b8a705 100644 --- a/generated/google/apis/games_v1/representations.rb +++ b/generated/google/apis/games_v1/representations.rb @@ -112,6 +112,18 @@ class Representation < Google::Apis::Core::JsonRepresentation; end include Google::Apis::Core::JsonObjectSupport end + class ContentHash + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + + class EndPoint + class Representation < Google::Apis::Core::JsonRepresentation; end + + include Google::Apis::Core::JsonObjectSupport + end + class EventBatchRecordFailure class Representation < Google::Apis::Core::JsonRepresentation; end @@ -589,6 +601,21 @@ class Representation < Google::Apis::Core::JsonRepresentation end end + class ContentHash + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :digest, as: 'digest' + property :version, as: 'version' + end + end + + class EndPoint + # @private + class Representation < Google::Apis::Core::JsonRepresentation + property :url, as: 'url' + end + end + class EventBatchRecordFailure # @private class Representation < Google::Apis::Core::JsonRepresentation @@ -1089,7 +1116,8 @@ class Representation < Google::Apis::Core::JsonRepresentation class SnapshotCoverImageResource # @private class Representation < Google::Apis::Core::JsonRepresentation - property :content_hash, as: 'contentHash' + collection :content_hash, as: 'contentHash', class: Google::Apis::GamesV1::ContentHash, decorator: Google::Apis::GamesV1::ContentHash::Representation + property :download_url, as: 'downloadUrl' property :height, as: 'height' property :mime_type, as: 'mimeType' @@ -1101,7 +1129,8 @@ class Representation < Google::Apis::Core::JsonRepresentation class SnapshotDataResource # @private class Representation < Google::Apis::Core::JsonRepresentation - property :content_hash, as: 'contentHash' + collection :content_hash, as: 'contentHash', class: Google::Apis::GamesV1::ContentHash, decorator: Google::Apis::GamesV1::ContentHash::Representation + property :download_url, as: 'downloadUrl' property :resource_id, as: 'resourceId' property :size, :numeric_string => true, as: 'size' diff --git a/generated/google/apis/games_v1/service.rb b/generated/google/apis/games_v1/service.rb index dcf67c434f6..2cf922a67d9 100644 --- a/generated/google/apis/games_v1/service.rb +++ b/generated/google/apis/games_v1/service.rb @@ -337,6 +337,39 @@ def get_application(application_id, language: nil, platform_type: nil, fields: n execute_or_queue_command(command, &block) end + # Returns a URL for the requested end point type. + # @param [String] application_id + # The application ID from the Google Play developer console. + # @param [String] end_point_type + # Type of endpoint being requested. + # @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::GamesV1::EndPoint] parsed result object + # @yieldparam err [StandardError] error object if request failed + # + # @return [Google::Apis::GamesV1::EndPoint] + # + # @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_application_end_point(application_id: nil, end_point_type: nil, fields: nil, quota_user: nil, options: nil, &block) + command = make_simple_command(:post, 'games/v1/applications/getEndPoint', options) + command.response_representation = Google::Apis::GamesV1::EndPoint::Representation + command.response_class = Google::Apis::GamesV1::EndPoint + command.query['applicationId'] = application_id unless application_id.nil? + command.query['endPointType'] = end_point_type unless end_point_type.nil? + command.query['fields'] = fields unless fields.nil? + command.query['quotaUser'] = quota_user unless quota_user.nil? + execute_or_queue_command(command, &block) + end + # Indicate that the currently authenticated user is playing your application. # @param [String] fields # Selector specifying which fields to include in a partial response. diff --git a/generated/google/apis/games_v1/synth.metadata b/generated/google/apis/games_v1/synth.metadata index fb5a74b21fe..91f4591fba1 100644 --- a/generated/google/apis/games_v1/synth.metadata +++ b/generated/google/apis/games_v1/synth.metadata @@ -4,7 +4,7 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/google-api-ruby-client.git", - "sha": "9840c481849200572321532ecc3b128bebbc1583" + "sha": "be6850161c57715f479f158662bb4c3e385e44cc" } } ]