Up - API Reference - Home
Requires JWT.
Get a worksheet with paginated children.
This endpoint is meant to power a UI where we show the current asset, optional ancestor assets, and a scrolling list of children. The UI keeps track of the scroll position (page.top
) and panel size (page.size
, how many children fit in the panel) for the children.
POST /api/p/<project gid>/assets/worksheet
Authorization: Bearer <JWT>
{
"asset": "<asset gid>",
"page.top": 0,
"page.size": 10
}
asset
is the main entrypoint for the worksheet.
page.top
(default 0) only return children starting from the top-index (0-based).
page.size
(default 20) only return this many children.
Authorization: <JWT>
{
"success": true,
"result": {
"asset": "f2e64fe0-9ffa-4d9a-8750-d561d6542453",
"path": [
"d96073b1-69da-493e-8433-3820c8cca3a8",
"e8c7a57f-c83f-408b-b0a1-7625894dabd6",
"4aa680cf-b43e-4769-bd09-5d298abbcac7",
"9a7fa996-3c7f-4707-9bf7-7a251fc63ab1",
"f2e64fe0-9ffa-4d9a-8750-d561d6542453"
],
"children": [
"96ec02b2-fb8d-4fb4-b952-fad0c4b88a74",
"726427c2-8c72-4d2e-a09b-937a6f16d3c0",
"98437ffb-ef37-431a-afc2-d6023e0db58c",
"7c136ddb-4dfa-4ec1-bad4-15067cbf80d9",
"7e52202a-90bb-430b-8ac5-e9c015da4369"
],
"children.size": 5
},
"data": {
"assets": {
"d96073b1-69da-493e-8433-3820c8cca3a8": {
…
},
…
}
}
}
asset
the requested asset.
path
the path from the root to the requested asset (inclusive), in tree order.
children
the paginated children of the asset, folders first, then files, ordered by name.
children.size
the size of the non-paginated children for the asset.
assets
Asset info with hierarchy, type, name. Unordered.
400
Bad request - missing parameters or wrong type or value
401
Unauthorized - missing or expired JWT
403
Forbidden - not a member of this project
422
Unprocessable entity - asset doesn't exist