REST Resource: assets

Resource: Asset

Represents and describes an asset in the Poly library. An asset is a 3D model or scene created using Tilt Brush, Blocks, or any 3D program that produces a file that can be upload to Poly.

JSON representation
{
  "name": string,
  "displayName": string,
  "authorName": string,
  "description": string,
  "createTime": string,
  "updateTime": string,
  "formats": [
    {
      object(Format)
    }
  ],
  "thumbnail": {
    object(File)
  },
  "license": enum(AssetLicense),
  "visibility": enum(Visibility),
  "isCurated": boolean,
  "presentationParams": {
    object(PresentationParams)
  },
  "metadata": string,
  "remixInfo": {
    object(RemixInfo)
  }
}
Fields
name

string

The unique identifier for the asset in the form: assets/{ASSET_ID}.

displayName

string

The human-readable name, set by the asset's author.

authorName

string

The author's publicly visible name. Use this name when giving credit to the author. For more information, see Licensing.

description

string

The human-readable description, set by the asset's author.

createTime

string (Timestamp format)

For published assets, the time when the asset was published. For unpublished assets, the time when the asset was created.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".

updateTime

string (Timestamp format)

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.

A timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds. Example: "2014-10-02T15:01:23.045123456Z".

formats[]

object(Format)

A list of Formats where each format describes one representation of the asset.

thumbnail

object(File)

The thumbnail image for the asset.

license

enum(AssetLicense)

The license under which the author has made the asset available for use, if any.

visibility

enum(Visibility)

The visibility of the asset and who can access it.

isCurated

boolean

Whether this asset has been curated by the Poly team.

presentationParams

object(PresentationParams)

Hints for displaying the asset. Note that these parameters are not immutable; the author of an asset may change them post-publication.

metadata

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).

remixInfo

object(RemixInfo)

The remix info for the asset.

Format

The same asset can be represented in different formats, for example, a WaveFront .obj file with its corresponding .mtl file or a Khronos 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.

JSON representation
{
  "root": {
    object(File)
  },
  "resources": [
    {
      object(File)
    }
  ],
  "formatComplexity": {
    object(FormatComplexity)
  },
  "formatType": string
}
Fields
root

object(File)

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.

resources[]

object(File)

A list of dependencies of the root element. May include, but is not limited to, materials, textures, and shader programs.

formatComplexity

object(FormatComplexity)

Complexity stats about this representation of the asset.

formatType

string

A short string that identifies the format type of this representation. Possible values are: FBX, GLTF, GLTF2, OBJ, and TILT.

File

Represents a file in Poly, which can be a root, resource, or thumbnail file.

JSON representation
{
  "relativePath": string,
  "url": string,
  "contentType": string
}
Fields
relativePath

string

The path of the resource file relative to the root file. For root or thumbnail files, this is just the filename.

url

string

The URL where the file data can be retrieved.

contentType

string

The MIME content-type, such as image/png. For more information, see MIME types.

FormatComplexity

Information on the complexity of this Format.

JSON representation
{
  "triangleCount": string,
  "lodHint": number
}
Fields
triangleCount

string (int64 format)

The estimated number of triangles.

lodHint

number

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 formatType. This hint allows you to sort formats from the most-detailed (0) to least-detailed (integers greater than 0).

AssetLicense

License types that are supported by Poly.

Enums
UNKNOWN Unknown license value.
CREATIVE_COMMONS_BY Creative Commons CC-BY 3.0. https://creativecommons.org/licenses/by/3.0/
ALL_RIGHTS_RESERVED Unlicensed: All Rights Reserved by the author. Unlicensed assets are not returned by List Assets.

Visibility

Access levels of assets that are supported by VR assets service.

Enums
VISIBILITY_UNSPECIFIED Unknown (and invalid) visibility.
PRIVATE Access to the asset and its underlying files and resources is restricted to the author. Authentication: You must supply an OAuth token that corresponds to the author's account.
UNLISTED Access to the asset and its underlying files and resources is available to anyone with the asset's name. Unlisted assets are not returned by List Assets.
PUBLIC Access to the asset and its underlying files and resources is available to anyone.

PresentationParams

Hints for displaying the asset, based on information available when the asset was uploaded.

JSON representation
{
  "orientingRotation": {
    object(Quaternion)
  },
  "colorSpace": enum(ColorSpace),
  "backgroundColor": string
}
Fields
orientingRotation

object(Quaternion)

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.

colorSpace

enum(ColorSpace)

The materials' diffuse/albedo color. This does not apply to vertex colors or texture maps.

backgroundColor

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.

Quaternion

A Quaternion. Please note: if in the 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.

JSON representation
{
  "x": number,
  "y": number,
  "z": number,
  "w": number
}
Fields
x

number

The x component.

y

number

The y component.

z

number

The z component.

w

number

The scalar component.

ColorSpace

How color values in representations of the asset should be interpreted.

Enums
UNKNOWN Invalid color value.
LINEAR Linear color values. Default.
GAMMA Colors should be converted to linear by assuming gamma = 2.0.

RemixInfo

Info about the sources of this asset (i.e. assets that were remixed to create this asset).

JSON representation
{
  "sourceAsset": [
    string
  ]
}
Fields
sourceAsset[]

string

Resource ids for the sources of this remix, of the form: assets/{ASSET_ID}

Methods

get

Returns detailed information about an asset given its name.

list

Lists all public, remixable assets.

startImport

Begin the import of an asset that the user has already uploaded via our upload endpoint.