Skip to content
Kumquat
Esc
↑↓navigate↵open⌘Jpreview

Get Asset

One asset by its storage key — the address an asset is shared as.

Declared last on purpose. :path matches slashes, so this route would swallow /assets/tags if it came first: FastAPI tries routes in the order they were added, and the specific one has to be tried before the greedy one.

GET/api/v1/assets/{key}
Authorization
AuthorizationBearer token · headerrequired
or
AuthorizationOAuth2 access token · headerrequired
Path parameters
keystringrequired
Responses
200Successful Response
successboolean
default: true
dataAssetDetail | any
Show properties
Any of:
AssetDetail
assetGeneratedAssetrequired
One file a run produced. The `_id` is the object's storage key, which is derived from the sha256 of the bytes — so the same result generated twice is one asset, and a replayed run re-records what it already had instead of duplicating it.
Show properties
idstringrequired
urlstringrequired
sha256stringrequired
kindAssetKindrequired
What a generated file is. The values match the engine's media `PortType`s deliberately: the harvest that finds these files reads the kind off a node's declared output port, and hands the value over as a plain string so neither package has to import the other.
Allowed:imagevideoaudio
node_typestringrequired
node_idstringrequired
modelstring | any
Show properties
Any of:
string
string
any
any
promptstring | any
Show properties
Any of:
string
string
any
any
run_idstringrequired
run_generationinteger | any
Show properties
Any of:
integer
integer
any
any
graph_idstring | any
Show properties
Any of:
string
string
any
any
owner_idstringrequired
tagsstring[]
created_atstring<date-time>
includedUserIncludes
People referenced by the payload, keyed by id — same contract as `CreativeIncludes`. Comment authors, mentions and reactors on the comments feed, transition actors on the history one.
Show properties
usersobject
any
any
messagestring | any
Show properties
Any of:
string
string
any
any
errorsstring[] | any
Show properties
Any of:
string[]
Array of string
string
any
any
422Validation Error
detailValidationError[]
Show properties
Array of ValidationError
locstring | integer[]required
Show properties
Array of string | integer
Any of:
string
string
integer
integer
msgstringrequired
typestringrequired
inputany
ctxobject
Request
curl -X GET "/api/v1/assets/string" \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "success": true,
  "data": {
    "asset": {
      "id": "string",
      "url": "string",
      "sha256": "string",
      "kind": "image",
      "node_type": "string",
      "node_id": "string",
      "model": "string",
      "prompt": "string",
      "run_id": "string",
      "run_generation": 0,
      "graph_id": "string",
      "owner_id": "string",
      "tags": [
        "string"
      ],
      "created_at": "2019-08-24T14:15:22Z"
    },
    "included": {
      "users": {
        "property1": {
          "id": "string",
          "name": "string",
          "email": "string",
          "image_url": "string"
        },
        "property2": {
          "id": "string",
          "name": "string",
          "email": "string",
          "image_url": "string"
        }
      }
    }
  },
  "message": "string",
  "errors": [
    "string"
  ]
}