Create (or find) one imported take for a user, with signed PUT links for its files
const url = 'http://localhost:8300/v1/studio/admin/imports/takes';const options = { method: 'POST', headers: { 'x-api-key': '<x-api-key>', Authorization: 'Bearer <token>', 'Content-Type': 'application/json' }, body: '{"owner_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","key":"example","kind":"image","filename":"example","content_type":"image/png","bytes":1,"width":1,"height":1,"created_at":"2026-04-15T12:00:00Z","starred":true,"title":"example","legacy":{},"parents":["example"],"video":{"duration_s":1,"fps":1,"frames":1,"has_audio":true,"poster":{"content_type":"image/png","bytes":1,"width":1,"height":1}}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url http://localhost:8300/v1/studio/admin/imports/takes \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --header 'x-api-key: <x-api-key>' \ --data '{ "owner_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "key": "example", "kind": "image", "filename": "example", "content_type": "image/png", "bytes": 1, "width": 1, "height": 1, "created_at": "2026-04-15T12:00:00Z", "starred": true, "title": "example", "legacy": {}, "parents": [ "example" ], "video": { "duration_s": 1, "fps": 1, "frames": 1, "has_audio": true, "poster": { "content_type": "image/png", "bytes": 1, "width": 1, "height": 1 } } }'Used by helm import. Admin only (403). Idempotent on (owner_id, key): a new key stores a pending take (source: import, owner owner_id) and answers 201 with single-use 24-hour PUT links for u/<owner_id>/imports/<take_id>.<png|jpg|webp|mp4> (and, for a video, …/<take_id>.poster.<png|jpg|webp>), exactly as uploads sign them; a key already pending answers 200 with fresh links; a key already complete answers 200 state: ready without links and changes nothing but adding parents edges not stored yet. Every parents key is stored as an edge and shows once both takes are complete, in either order. A pending import not completed in 24 hours is deleted. 422 for a body that breaks the schema, legacy is larger than 64 KB.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”object
The user whose gallery receives it (the CLI resolves --user <email> with GET /auth/admin/users)
The idempotency key: stable for one old item across runs
The old file’s name, for logs
An image at most 50 MB, a video at most 2 GB
The old item’s creation time: the take’s created_at (its place in the gallery)
object
Keys of the imported items it was made from, in input order (lineage)
object
object
Responses
Section titled “Responses”The key was seen: still pending (fresh links), or ready
object
Pending: the signed PUT link for the file (exactly its content_type and bytes); ready: null
Pending video: the poster’s link; null otherwise
Pending: when the links expire
Example
{ "state": "pending"}Created, pending
object
Pending: the signed PUT link for the file (exactly its content_type and bytes); ready: null
Pending video: the poster’s link; null otherwise
Pending: when the links expire
Example
{ "state": "pending"}Missing or invalid x-api-key (Kong), or missing/invalid/expired/revoked bearer token
object
Example generated
{ "detail": "example"}Valid token without the admin role: “admin role required”
object
Example generated
{ "detail": "example"}Invalid input
object
Example generated
{ "detail": "example"}Retryable
object
Example generated
{ "detail": "example"}