Skip to content

Commit

Permalink
feat(games): update the API
Browse files Browse the repository at this point in the history
#### games:v1
The following keys were added:
- resources.snapshotsExtended.methods.resolveSnapshotHead.description
- resources.snapshotsExtended.methods.resolveSnapshotHead.flatPath
- resources.snapshotsExtended.methods.resolveSnapshotHead.httpMethod
- resources.snapshotsExtended.methods.resolveSnapshotHead.id
- resources.snapshotsExtended.methods.resolveSnapshotHead.parameterOrder
- resources.snapshotsExtended.methods.resolveSnapshotHead.parameters.snapshotName.description
- resources.snapshotsExtended.methods.resolveSnapshotHead.parameters.snapshotName.location
- resources.snapshotsExtended.methods.resolveSnapshotHead.parameters.snapshotName.required
- resources.snapshotsExtended.methods.resolveSnapshotHead.parameters.snapshotName.type
- resources.snapshotsExtended.methods.resolveSnapshotHead.path
- resources.snapshotsExtended.methods.resolveSnapshotHead.request.$ref
- resources.snapshotsExtended.methods.resolveSnapshotHead.response.$ref
- resources.snapshotsExtended.methods.resolveSnapshotHead.scopes
- schemas.ResolveSnapshotHeadRequest.description
- schemas.ResolveSnapshotHeadRequest.id
- schemas.ResolveSnapshotHeadRequest.properties.resolutionPolicy.description
- schemas.ResolveSnapshotHeadRequest.properties.resolutionPolicy.enum
- schemas.ResolveSnapshotHeadRequest.properties.resolutionPolicy.enumDescriptions
- schemas.ResolveSnapshotHeadRequest.properties.resolutionPolicy.type
- schemas.ResolveSnapshotHeadRequest.type
- schemas.ResolveSnapshotHeadResponse.description
- schemas.ResolveSnapshotHeadResponse.id
- schemas.ResolveSnapshotHeadResponse.properties.snapshot.$ref
- schemas.ResolveSnapshotHeadResponse.properties.snapshot.description
- schemas.ResolveSnapshotHeadResponse.type
- schemas.SnapshotCoverImageResource.description
- schemas.SnapshotCoverImageResource.id
- schemas.SnapshotCoverImageResource.properties.contentHash.description
- schemas.SnapshotCoverImageResource.properties.contentHash.readOnly
- schemas.SnapshotCoverImageResource.properties.contentHash.type
- schemas.SnapshotCoverImageResource.properties.downloadUrl.description
- schemas.SnapshotCoverImageResource.properties.downloadUrl.readOnly
- schemas.SnapshotCoverImageResource.properties.downloadUrl.type
- schemas.SnapshotCoverImageResource.properties.height.description
- schemas.SnapshotCoverImageResource.properties.height.format
- schemas.SnapshotCoverImageResource.properties.height.readOnly
- schemas.SnapshotCoverImageResource.properties.height.type
- schemas.SnapshotCoverImageResource.properties.mimeType.description
- schemas.SnapshotCoverImageResource.properties.mimeType.readOnly
- schemas.SnapshotCoverImageResource.properties.mimeType.type
- schemas.SnapshotCoverImageResource.properties.resourceId.description
- schemas.SnapshotCoverImageResource.properties.resourceId.type
- schemas.SnapshotCoverImageResource.properties.width.description
- schemas.SnapshotCoverImageResource.properties.width.format
- schemas.SnapshotCoverImageResource.properties.width.readOnly
- schemas.SnapshotCoverImageResource.properties.width.type
- schemas.SnapshotCoverImageResource.type
- schemas.SnapshotDataResource.description
- schemas.SnapshotDataResource.id
- schemas.SnapshotDataResource.properties.contentHash.description
- schemas.SnapshotDataResource.properties.contentHash.readOnly
- schemas.SnapshotDataResource.properties.contentHash.type
- schemas.SnapshotDataResource.properties.downloadUrl.description
- schemas.SnapshotDataResource.properties.downloadUrl.readOnly
- schemas.SnapshotDataResource.properties.downloadUrl.type
- schemas.SnapshotDataResource.properties.resourceId.description
- schemas.SnapshotDataResource.properties.resourceId.type
- schemas.SnapshotDataResource.properties.size.description
- schemas.SnapshotDataResource.properties.size.format
- schemas.SnapshotDataResource.properties.size.type
- schemas.SnapshotDataResource.type
- schemas.SnapshotExtended.description
- schemas.SnapshotExtended.id
- schemas.SnapshotExtended.properties.conflictingRevisions.description
- schemas.SnapshotExtended.properties.conflictingRevisions.items.$ref
- schemas.SnapshotExtended.properties.conflictingRevisions.type
- schemas.SnapshotExtended.properties.hasConflictingRevisions.description
- schemas.SnapshotExtended.properties.hasConflictingRevisions.type
- schemas.SnapshotExtended.properties.headRevision.$ref
- schemas.SnapshotExtended.properties.headRevision.description
- schemas.SnapshotExtended.properties.name.description
- schemas.SnapshotExtended.properties.name.type
- schemas.SnapshotExtended.type
- schemas.SnapshotMetadata.description
- schemas.SnapshotMetadata.id
- schemas.SnapshotMetadata.properties.description.description
- schemas.SnapshotMetadata.properties.description.type
- schemas.SnapshotMetadata.properties.deviceName.description
- schemas.SnapshotMetadata.properties.deviceName.type
- schemas.SnapshotMetadata.properties.duration.description
- schemas.SnapshotMetadata.properties.duration.format
- schemas.SnapshotMetadata.properties.duration.type
- schemas.SnapshotMetadata.properties.lastModifyTime.description
- schemas.SnapshotMetadata.properties.lastModifyTime.format
- schemas.SnapshotMetadata.properties.lastModifyTime.type
- schemas.SnapshotMetadata.properties.progressValue.description
- schemas.SnapshotMetadata.properties.progressValue.format
- schemas.SnapshotMetadata.properties.progressValue.type
- schemas.SnapshotMetadata.properties.title.description
- schemas.SnapshotMetadata.properties.title.type
- schemas.SnapshotMetadata.type
- schemas.SnapshotRevision.description
- schemas.SnapshotRevision.id
- schemas.SnapshotRevision.properties.blob.$ref
- schemas.SnapshotRevision.properties.blob.description
- schemas.SnapshotRevision.properties.coverImage.$ref
- schemas.SnapshotRevision.properties.coverImage.description
- schemas.SnapshotRevision.properties.id.description
- schemas.SnapshotRevision.properties.id.readOnly
- schemas.SnapshotRevision.properties.id.type
- schemas.SnapshotRevision.properties.metadata.$ref
- schemas.SnapshotRevision.properties.metadata.description
- schemas.SnapshotRevision.type
  • Loading branch information
yoshi-automation authored and sofisl committed Oct 20, 2020
1 parent 93478c3 commit 7d186d9
Show file tree
Hide file tree
Showing 2 changed files with 529 additions and 1 deletion.
220 changes: 219 additions & 1 deletion discovery/games-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -1168,6 +1168,38 @@
}
}
},
"snapshotsExtended": {
"methods": {
"resolveSnapshotHead": {
"description": "Resolves any potential conflicts according to the resolution policy specified in the request and returns the snapshot head after the resolution.",
"flatPath": "games/v1/snapshotsExtended/{snapshotName}:resolveHead",
"httpMethod": "POST",
"id": "games.snapshotsExtended.resolveSnapshotHead",
"parameterOrder": [
"snapshotName"
],
"parameters": {
"snapshotName": {
"description": "Required. Name of the snapshot.",
"location": "path",
"required": true,
"type": "string"
}
},
"path": "games/v1/snapshotsExtended/{snapshotName}:resolveHead",
"request": {
"$ref": "ResolveSnapshotHeadRequest"
},
"response": {
"$ref": "ResolveSnapshotHeadResponse"
},
"scopes": [
"https://www.googleapis.com/auth/drive.appdata",
"https://www.googleapis.com/auth/games"
]
}
}
},
"stats": {
"methods": {
"get": {
Expand All @@ -1188,7 +1220,7 @@
}
}
},
"revision": "20200924",
"revision": "20201015",
"rootUrl": "https://games.googleapis.com/",
"schemas": {
"AchievementDefinition": {
Expand Down Expand Up @@ -2856,6 +2888,44 @@
},
"type": "object"
},
"ResolveSnapshotHeadRequest": {
"description": "Request for ResolveSnapshotHead RPC.",
"id": "ResolveSnapshotHeadRequest",
"properties": {
"resolutionPolicy": {
"description": "Required. The automatic resolution policy. All conflicts are resolved in chronological order, starting from the/ least recent. If the comparison metric is equal for the tentative head and the conflict, the head wins.",
"enum": [
"RESOLUTION_POLICY_UNSPECIFIED",
"USE_HEAD",
"LONGEST_PLAYTIME",
"MOST_RECENTLY_MODIFIED",
"HIGHEST_PROGRESS",
"NO_AUTOMATIC_RESOLUTION"
],
"enumDescriptions": [
"Safe default, don't use explicitly.",
"Drops all conflicts and keeps the current head only.",
"Use the snapshot with the longest played time.",
"Use the snapshot that was most recently modified.",
"Use the snapshot with the highest progress value.",
"Don't resolve conflicts at all. Effectively only returns the current head revision of the snapshot. Corresponds to a game opening the snapshot with manual resolution policy."
],
"type": "string"
}
},
"type": "object"
},
"ResolveSnapshotHeadResponse": {
"description": "Response for ResolveSnapshotHead RPC.",
"id": "ResolveSnapshotHeadResponse",
"properties": {
"snapshot": {
"$ref": "SnapshotExtended",
"description": "The state of the snapshot."
}
},
"type": "object"
},
"RevisionCheckResponse": {
"description": "A third party checking a revision response.",
"id": "RevisionCheckResponse",
Expand Down Expand Up @@ -2977,6 +3047,96 @@
},
"type": "object"
},
"SnapshotCoverImageResource": {
"description": "Identifies a snapshot cover image resource. The image is provided by the game.",
"id": "SnapshotCoverImageResource",
"properties": {
"contentHash": {
"description": "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.",
"readOnly": true,
"type": "string"
},
"downloadUrl": {
"description": "Output only. A URL the client can use to download the image. May vary across requests, and only guaranteed to be valid for a short time after it is returned.",
"readOnly": true,
"type": "string"
},
"height": {
"description": "Output only. The height of the image in pixels.",
"format": "int32",
"readOnly": true,
"type": "integer"
},
"mimeType": {
"description": "Output only. The MIME type of the image.",
"readOnly": true,
"type": "string"
},
"resourceId": {
"description": "The ID of the image resource. It's guaranteed that if two IDs are equal then the contents are equal as well. It's not guaranteed that two identical blobs coming from separate uploads have the same ID. The resource ID can only be used within the application, user and resource type it was originally returned for. For example, it's not possible to use SnapshotDataResource's resource ID as the resource_id of a SnapshotCoverImageResource, even if the blob is a valid image file.",
"type": "string"
},
"width": {
"description": "Output only. The width of the image in pixels.",
"format": "int32",
"readOnly": true,
"type": "integer"
}
},
"type": "object"
},
"SnapshotDataResource": {
"description": "Identifies a snapshot data resource. The data is provided by the game.",
"id": "SnapshotDataResource",
"properties": {
"contentHash": {
"description": "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.",
"readOnly": true,
"type": "string"
},
"downloadUrl": {
"description": "Output only. A URL that the client can use to download the blob. May vary across requests, and only guaranteed to be valid for a short time after it is returned.",
"readOnly": true,
"type": "string"
},
"resourceId": {
"description": "The ID of the blob resource. It's guaranteed that if two IDs are equal then the contents are equal as well. It's not guaranteed that two identical blobs coming from separate uploads have the same resource ID. The resource ID can only be used within the application, user and resource type it was originally returned for. For example, it's not possible to use SnapshotDataResource's resource ID as the resource_id of a SnapshotCoverImageResource, even if the blob is a valid image file.",
"type": "string"
},
"size": {
"description": "Size of the saved game blob in bytes.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"SnapshotExtended": {
"description": "A snapshot represents a saved game state referred to using the developer-provided snapshot_id (think of it as a file's path). The set of attributes and binary data for a specific state is called a revision. Each revision is itself immutable, and referred to by a snapshot_revision_id. At any time, a snapshot has a \"head\" revision, and updates are made against that revision. If a snapshot update is received that isn't against the current head revision, then instead of changing the head revision it will result in a conflicting revision that must be specifically resolved.",
"id": "SnapshotExtended",
"properties": {
"conflictingRevisions": {
"description": "A list of conflicting revisions. Only set if explicitly requested (e.g. using a field mask or a request flag), or if the RPC guarantees that this field is set. The conflicting revisions are sorted chronologically by their server creation time (oldest first). If there are too many conflicting revisions to return all of them in a single request this will only contain the first batch. In such case, the presented conflicting revisions must be resolved first in order to fetch the next batch.",
"items": {
"$ref": "SnapshotRevision"
},
"type": "array"
},
"hasConflictingRevisions": {
"description": "An indicator whether the snapshot has any conflicting revisions or not. Always set.",
"type": "boolean"
},
"headRevision": {
"$ref": "SnapshotRevision",
"description": "The current head revision (the canonical revision as understood by the server)."
},
"name": {
"description": "An identifier of the snapshot,developer-specified.",
"type": "string"
}
},
"type": "object"
},
"SnapshotImage": {
"description": "An image of a snapshot.",
"id": "SnapshotImage",
Expand Down Expand Up @@ -3028,6 +3188,64 @@
},
"type": "object"
},
"SnapshotMetadata": {
"description": "Metadata about a snapshot revision. Snapshot metadata is immutable - a metadata change corresponds to a new snapshot revision.",
"id": "SnapshotMetadata",
"properties": {
"description": {
"description": "The description of this snapshot.",
"type": "string"
},
"deviceName": {
"description": "The device that created the current revision.",
"type": "string"
},
"duration": {
"description": "The duration associated with this snapshot. Values with sub-millisecond precision can be rounded or trimmed to the closest millisecond.",
"format": "google-duration",
"type": "string"
},
"lastModifyTime": {
"description": "The timestamp of the last modification to this snapshot. Values with sub-millisecond precision can be rounded or trimmed to the closest millisecond.",
"format": "google-datetime",
"type": "string"
},
"progressValue": {
"description": "The progress value (64-bit integer set by developer) associated with this snapshot.",
"format": "int64",
"type": "string"
},
"title": {
"description": "The title of this snapshot.",
"type": "string"
}
},
"type": "object"
},
"SnapshotRevision": {
"description": "A Snapshot revision resource. Snapshot revisions are immutable.",
"id": "SnapshotRevision",
"properties": {
"blob": {
"$ref": "SnapshotDataResource",
"description": "Reference to the game provided blob for this revision."
},
"coverImage": {
"$ref": "SnapshotCoverImageResource",
"description": "Reference to the cover image for this revision."
},
"id": {
"description": "Output only. A server generated identifier of the snapshot revision.",
"readOnly": true,
"type": "string"
},
"metadata": {
"$ref": "SnapshotMetadata",
"description": "Metadata for this snapshot revision."
}
},
"type": "object"
},
"StatsResponse": {
"description": "A third party stats resource.",
"id": "StatsResponse",
Expand Down
Loading

0 comments on commit 7d186d9

Please sign in to comment.