Download a workspace file

October 12, 2026 (November 16, 2026)

Table of contents

  1. Request Headers
  2. Query Parameters
  3. Responses
  4. Model
  5. Examples
  6. Try It

Download any file from the Muse workspace of an account: code, documents, data or media, for example a report or a script the agent wrote. The response body is the file itself, streamed from the workspace, with its Content-Type.

Files and assets are two views of the same workspace. Assets are the images, videos and audio files, each with an assetId for jobs and chats. /files covers the whole workspace, including the code, documents and data the agent writes. A media file listed here also carries its assetId.

Paths always start with workspace/, for example workspace/your_files/report.pdf. Find a path with GET /files or GET /files/search.

https://api.useapi.net/v1/muse/files/content?email=email&path=path

Request Headers
Authorization: Bearer {API token}
Query Parameters
  • email is optional when the API token has one Muse account, and required when it has more. URL-encode it.
  • path is required, the file’s path in the workspace.
Responses
  • 200 OK — the raw file bytes (not JSON), for example:

    Content-Type: text/plain; charset=utf-8
    Content-Length: 769
    
  • 400 Bad Request — path is a folder, or not a path in the workspace.

    {
      "error": "Path is a folder: list it with GET /files",
      "code": 400
    }
    
  • 401 Unauthorized — Invalid API token.

    {
      "error": "useapi.net ⁝ Unauthorized",
      "code": 401
    }
    
  • 404 Not Found — the path is not in the workspace, or the account named by email is not added.

    {
      "error": "File not found",
      "code": 404
    }
    
  • 503 Service Unavailable — Muse could not be reached. Retry shortly.

    {
      "error": "Muse could not do it right now (…), please retry",
      "code": 503
    }
    
  • 596 Account Error

    The account needs your attention, and it is paused until you add it again. You receive an email when this happens. There are three causes.

    Meta asks for a security check on the account. Sign in once at muse.ai in a browser, complete the check, then add the account again with POST /accounts using the same email and password. The API keeps using its session, so no new sign-in is needed.

    {
      "error": "Account example@gmail.com: Meta asks for a security check on account example@gmail.com (\"This account must complete a security checkpoint on the web\"). Sign in once at https://muse.ai in a browser, complete the check, then add the account again with POST /accounts",
      "code": 596
    }
    

    Or Muse refused to sign the account in again when its session needed renewing, most often because the password was changed. Add the account again with the current password.

    {
      "error": "Account example@gmail.com: Muse refused to sign in account example@gmail.com (…). Update its password with POST /accounts, or sign in at https://muse.ai to clear the block, then re-add it",
      "code": 596
    }
    

    Or Muse disabled the account’s computer and refuses to start it again. Sign in at muse.ai in a browser to see why, and ask Muse support to restore it with the form Muse shows there. Add the account again only after Muse has restored it.

    {
      "error": "Account example@gmail.com: Muse has disabled the computer of account example@gmail.com (\"VM wake unavailable\"). Sign in at https://muse.ai in a browser to see why and contact Muse support there, then add the account again with POST /accounts",
      "code": 596
    }
    
Model

A successful response is the file itself (not JSON). Errors return:

The error answer, field by field
{ // TypeScript, all fields are optional
  error: string
  code: number
}
Examples
  • curl -H "Authorization: Bearer …" \
         "https://api.useapi.net/v1/muse/files/content?email=example%40gmail.com&path=workspace%2Fyour_files%2Fsunkissed-lyrics.txt" \
         --output sunkissed-lyrics.txt
    
  • const token = "API token";
    const params = new URLSearchParams({ email: "example@gmail.com", path: "workspace/your_files/sunkissed-lyrics.txt" });
    const response = await fetch(`https://api.useapi.net/v1/muse/files/content?${params}`, {
      method: "GET",
      headers: {
        "Authorization": `Bearer ${token}`,
      }
    });
    const file = await response.arrayBuffer();
    console.log("downloaded", response.status, file.byteLength, response.headers.get("content-type"));
    
  • import requests
    token = "API token"
    apiUrl = "https://api.useapi.net/v1/muse/files/content"
    headers = {
        "Authorization" : f"Bearer {token}"
    }
    response = requests.get(apiUrl, headers=headers, params={"email": "example@gmail.com", "path": "workspace/your_files/sunkissed-lyrics.txt"})
    with open("lyrics.txt", "wb") as f:
        f.write(response.content)
    print(response, len(response.content))
    
Try It