1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265
|
<html><body>
<style>
body, h1, h2, h3, div, span, p, pre, a {
margin: 0;
padding: 0;
border: 0;
font-weight: inherit;
font-style: inherit;
font-size: 100%;
font-family: inherit;
vertical-align: baseline;
}
body {
font-size: 13px;
padding: 1em;
}
h1 {
font-size: 26px;
margin-bottom: 1em;
}
h2 {
font-size: 24px;
margin-bottom: 1em;
}
h3 {
font-size: 20px;
margin-bottom: 1em;
margin-top: 1em;
}
pre, code {
line-height: 1.5;
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}
pre {
margin-top: 0.5em;
}
h1, h2, h3, p {
font-family: Arial, sans serif;
}
h1, h2, h3 {
border-bottom: solid #CCC 1px;
}
.toc_element {
margin-top: 0.5em;
}
.firstline {
margin-left: 2 em;
}
.method {
margin-top: 1em;
border: solid 1px #CCC;
padding: 1em;
background: #EEE;
}
.details {
font-weight: bold;
font-size: 14px;
}
</style>
<h1><a href="poly_v1.html">Poly API</a> . <a href="poly_v1.users.html">users</a> . <a href="poly_v1.users.likedassets.html">likedassets</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#list">list(name, orderBy=None, pageSize=None, format=None, pageToken=None, x__xgafv=None)</a></code></p>
<p class="firstline">Lists assets that the user has liked. Only the value 'me', representing</p>
<p class="toc_element">
<code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
<p class="firstline">Retrieves the next page of results.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="list">list(name, orderBy=None, pageSize=None, format=None, pageToken=None, x__xgafv=None)</code>
<pre>Lists assets that the user has liked. Only the value 'me', representing
the currently-authenticated user, is supported. May include assets with an
access level of UNLISTED.
Args:
name: string, A valid user id. Currently, only the special value 'me', representing the
currently-authenticated user is supported. To use 'me', you must pass
an OAuth token with the request. (required)
orderBy: string, Specifies an ordering for assets. Acceptable values are:
`BEST`, `NEWEST`, `OLDEST`, 'LIKED_TIME'. Defaults to `LIKED_TIME`, which
ranks assets based on how recently they were liked.
pageSize: integer, The maximum number of assets to be returned. This value must be between `1`
and `100`. Defaults to `20`.
format: string, Return only assets with the matching format. Acceptable values are:
`BLOCKS`, `FBX`, `GLTF`, `GLTF2`, `OBJ`, `TILT`.
pageToken: string, Specifies a continuation token from a previous search whose results were
split into multiple pages. To get the next page, submit the same request
specifying the value from
next_page_token.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format
Returns:
An object of the form:
{ # A response message from a request to list.
"nextPageToken": "A String", # The continuation token for retrieving the next page. If empty,
# indicates that there are no more pages. To get the next page, submit the
# same request specifying this value as the
# page_token.
"totalSize": 42, # The total number of assets in the list, without pagination.
"assets": [ # A list of assets that match the criteria specified in the request.
{ # Represents and describes an asset in the Poly library. An asset is a 3D model
# or scene created using [Tilt Brush](//www.tiltbrush.com),
# [Blocks](//vr.google.com/blocks/), or any 3D program that produces a file
# that can be upload to Poly.
"updateTime": "A String", # The time when the asset was last modified. For published assets, whose
# contents are immutable, the update time changes only when metadata
# properties, such as visibility, are updated.
"displayName": "A String", # The human-readable name, set by the asset's author.
"description": "A String", # The human-readable description, set by the asset's author.
"license": "A String", # The license under which the author has made the asset available
# for use, if any.
"visibility": "A String", # The visibility of the asset and who can access it.
"thumbnail": { # Represents a file in Poly, which can be a root, # The thumbnail image for the asset.
# resource, or thumbnail file.
"url": "A String", # The URL where the file data can be retrieved.
"relativePath": "A String", # The path of the resource file relative to the
# root file. For root or thumbnail files,
# this is just the filename.
"contentType": "A String", # The MIME content-type, such as `image/png`.
# For more information, see
# [MIME
# types](//developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types).
},
"presentationParams": { # Hints for displaying the asset, based on information available when the asset # Hints for displaying the asset. Note that these parameters are not
# immutable; the author of an asset may change them post-publication.
# was uploaded.
"orientingRotation": { # A [Quaternion](//en.wikipedia.org/wiki/Quaternion). Please note: if in the # A rotation that should be applied to the object root to make it upright.
# More precisely, this quaternion transforms from "object space" (the space
# in which the object is defined) to "presentation space", a coordinate
# system where +Y is up, +X is right, -Z is forward. For example, if
# the object is the Eiffel Tower, in its local coordinate system the
# object might be laid out such that the base of the tower is on the
# YZ plane and the tip of the tower is towards positive X. In this case
# this quaternion would specify a rotation (of 90 degrees about the Z
# axis) such that in the presentation space the base of the tower is
# aligned with the XZ plane, and the tip of the tower lies towards +Y.
#
# This rotation is unrelated to the object's pose in the web preview,
# which is just a camera position setting and is *not* reflected in this
# rotation.
#
# Please note: this is applicable only to the gLTF.
# response you see "w: 1" and nothing else this is the default value of
# [0, 0, 0, 1] where x,y, and z are 0.
"y": 3.14, # The y component.
"x": 3.14, # The x component.
"z": 3.14, # The z component.
"w": 3.14, # The scalar component.
},
"colorSpace": "A String", # The materials' diffuse/albedo color. This does not apply to vertex colors
# or texture maps.
"backgroundColor": "A String", # A background color which could be used for displaying the 3D asset in a
# 'thumbnail' or 'palette' style view. Authors have the option to set this
# background color when publishing or editing their asset.
#
# This is represented as a six-digit hexademical triplet specifying the
# RGB components of the background color, e.g. #FF0000 for Red.
},
"authorName": "A String", # The author's publicly visible name. Use this name when giving credit to the
# author. For more information, see [Licensing](/poly/discover/licensing).
"isCurated": True or False, # Whether this asset has been curated by the Poly team.
"formats": [ # A list of Formats where each
# format describes one representation of the asset.
{ # The same asset can be represented in different formats, for example,
# a [WaveFront .obj](//en.wikipedia.org/wiki/Wavefront_.obj_file) file with its
# corresponding .mtl file or a [Khronos glTF](//www.khronos.org/gltf) file
# with its corresponding .glb binary data. A format refers to a specific
# representation of an asset and contains all information needed to
# retrieve and describe this representation.
"formatType": "A String", # A short string that identifies the format type of this representation.
# Possible values are: `FBX`, `GLTF`, `GLTF2`, `OBJ`, and `TILT`.
"root": { # Represents a file in Poly, which can be a root, # The root of the file hierarchy. This will always be populated.
# For some format_types - such as `TILT`, which are
# self-contained - this is all of the data.
#
# Other types - such as `OBJ` - often reference other data elements.
# These are contained in the resources field.
# resource, or thumbnail file.
"url": "A String", # The URL where the file data can be retrieved.
"relativePath": "A String", # The path of the resource file relative to the
# root file. For root or thumbnail files,
# this is just the filename.
"contentType": "A String", # The MIME content-type, such as `image/png`.
# For more information, see
# [MIME
# types](//developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types).
},
"formatComplexity": { # Information on the complexity of this Format. # Complexity stats about this representation of the asset.
"triangleCount": "A String", # The estimated number of triangles.
"lodHint": 42, # A non-negative integer that represents the level of detail (LOD) of this
# format relative to other formats of the same asset with the same
# format_type.
# This hint allows you to sort formats from the most-detailed (0) to
# least-detailed (integers greater than 0).
},
"resources": [ # A list of dependencies of the root element. May include, but is not
# limited to, materials, textures, and shader programs.
{ # Represents a file in Poly, which can be a root,
# resource, or thumbnail file.
"url": "A String", # The URL where the file data can be retrieved.
"relativePath": "A String", # The path of the resource file relative to the
# root file. For root or thumbnail files,
# this is just the filename.
"contentType": "A String", # The MIME content-type, such as `image/png`.
# For more information, see
# [MIME
# types](//developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types).
},
],
},
],
"metadata": "A String", # Application-defined opaque metadata for this asset. This field is only
# returned when querying for the signed-in user's own assets, not for public
# assets. This string is limited to 1K chars. It is up to the creator of
# the asset to define the format for this string (for example, JSON).
"createTime": "A String", # For published assets, the time when the asset was published.
# For unpublished assets, the time when the asset was created.
"remixInfo": { # Info about the sources of this asset (i.e. assets that were remixed to # The remix info for the asset.
# create this asset).
"sourceAsset": [ # Resource ids for the sources of this remix, of the form:
# `assets/{ASSET_ID}`
"A String",
],
},
"name": "A String", # The unique identifier for the asset in the form:
# `assets/{ASSET_ID}`.
},
],
}</pre>
</div>
<div class="method">
<code class="details" id="list_next">list_next(previous_request, previous_response)</code>
<pre>Retrieves the next page of results.
Args:
previous_request: The request for the previous page. (required)
previous_response: The response from the request for the previous page. (required)
Returns:
A request object that you can call 'execute()' on to request the next
page. Returns None if there are no more items in the collection.
</pre>
</div>
</body></html>
|