Skip to main content
The API client is exported from @useflex/media-studio/api. It has no React runtime dependency. In this development checkout, import packages/react/dist/api.js after building. Package publication and installation availability are separate from the local build.

Folder and file operations

Upload a file

Keep the same retry key when retrying the same upload. For larger files use the documented resumable upload endpoints through studio.request(). A chunk is sent as raw bytes with its SHA-256 header; direct S3 parts use the URL returned by the sign operation and must not receive the Studio bearer token.

Call another documented endpoint

request<T>() accepts a relative path inside the configured workspace, plus method, body, headers and signal. It returns bounded JSON; use a streaming HTTP client for binary file downloads. JSON responses larger than 4 MiB are rejected and their stream is cancelled.

Handle failures

The client omits browser cookies, rejects redirects that could forward credentials, applies a timeout and never automatically retries mutations. Use returned data URLs only with an appropriate delivery client; externally configured CDN redirects are not followed by the JSON client.