Skip to content

request_file_upload_url

Request a signed URL to upload a file directly to storage.

Returns a signed upload URL, file_id and upload_headers. After receiving the URL, perform
the upload using this two-step resumable upload flow:

Step 1 — Initiate the resumable upload:
POST {upload_url}
Headers: every entry of {upload_headers}, exactly as given:
Content-Type: {content_type}
x-goog-resumable: start
x-goog-content-length-range: 0,{file_size_bytes}
Body: (empty)
Response: 201 with Location header containing the session URI.

Step 2 — Upload file content:
PUT {session_uri_from_Location_header}
Headers:
Content-Type: {content_type}
Body: raw file bytes
Response: 200 on success.

After upload completes, use the returned file_id as input to generation tools.
The upload URL expires in 15 minutes. Maximum file size: 100 MB for video and 3D meshes, 64 MB for images and
audio.

IMPORTANT: Call tool `get_instructions` first for general platform guidance.

Parameters

ParameterTypeDefaultDescription
workspace_idrequiredstring (uuid)—The user's workspace id.
content_typerequiredstring—MIME type of the file. Allowed: application/fbx, audio/mpeg, audio/wav, image/jpeg, image/png, image/webp, model/gltf+json, model/gltf-binary, model/obj, model/ply, model/stl, video/mp4. A 3D mesh in OBJ, STL, PLY or glTF is converted into a GLB after upload, keeping the original; GLB and FBX are kept as uploaded. A .gltf must embed its buffers and textures; send a GLB otherwise.
file_size_bytesrequiredinteger>0—Expected file size in bytes. Maximum 100 MB for video and 3D meshes, 64 MB for images and audio.
file_namestring—Optional file name. Auto-generated from content_type if omitted.
project_idstring (uuid)—Optional project to add the result to; use list_projects to find project ids.