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