Skip to main content
Glama

List media library files

list_media_files
Read-onlyIdempotent

[Admin] List the company's media library: images, MP4 video, audio and WOFF2 fonts, newest first. A file's url is what page blocks, brand logos and font settings take. Filter by folder ("" is the top). include_folders=true adds every folder (empty ones included) with how many files each holds; a folder name is the folder value here, in start_media_upload and in manage_media_file. A sub-company also sees its parent's files, marked read_only: usable, not changeable.

Every argument in full, with examples: get_tool_reference.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "list_media_files"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNoOnly files of this kind: image, video, audio or font.
limitNoMaximum number of records to return (1–1000).
folderNoOnly files in this library folder.
offsetNoNumber of records to skip from the start of the result set.
searchNoOnly files whose name contains this text.
llm_modelNoYour model id, e.g. "claude-opus-4-8"; "unknown" if unsure. For analytics.
merchant_idNoOptional merchant to scope to. Admins and sub-merchant operators only; other callers always use their token's merchant.
include_parentNoAlso list the parent company's files, read only, when this company is a sub-company. Default true.
conversation_idNoThe conversation_id this server returned earlier in this conversation, unchanged, including after later user messages. Omit it if you have none. Recorded for the server developer's analytics.
include_foldersNoAlso return `folders`: the company's library folders with how many files each holds (what manage_media_folder lists). Default false.

Output Schema

NameRequiredDescriptionDefault
dataYes
foldersNo
paginationYes
_mcp_instructionsNoServer-issued metadata for this conversation.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • changedInput schema / properties / include_folders / default
      Previous value: -"false"New value: +false
    • changedInput schema / properties / include_folders / description
      Previous value: -"Also return `folders`: the company's library folders with how many files each holds (what media-folders lists). Default false."New value: +"Also return `folders`: the company's library folders with how many files each holds (what manage_media_folder lists). Default false."
    • removedInput schema / properties / include_folders / enum
      Removed value: -[
      -  "true",
      -  "false"
      -]
    • changedInput schema / properties / include_folders / type
      Previous value: -"string"New value: +"boolean"
    • changedInput schema / properties / include_parent / default
      Previous value: -"true"New value: +true
    • removedInput schema / properties / include_parent / enum
      Removed value: -[
      -  "true",
      -  "false"
      -]
    • changedInput schema / properties / include_parent / type
      Previous value: -"string"New value: +"boolean"
  2. Changed45 schema fields changed
    • changedInput schema / properties / folder / description
      Previous value: -"Only files in this library folder. Send an empty value for the top folder."New value: +"Only files in this library folder."
    • removedInput schema / properties / include_folders / example
      Removed value: -"false"
    • removedInput schema / properties / include_parent / example
      Removed value: -"true"
    • removedInput schema / properties / kind / example
      Removed value: -"image"
    • removedInput schema / properties / limit / example
      Removed value: -50
    • addedInput schema / properties / llm_model
      Added value: +{
      +  "description": "Your model id, e.g. \"claude-opus-4-8\"; \"unknown\" if unsure. For analytics.",
      +  "type": "string"
      +}
    • removedInput schema / properties / merchant_id / example
      Removed value: -"28106cba-1c27-4e53-b149-32113e5e8e31"
    • removedInput schema / properties / offset / example
      Removed value: -0
    • removedOutput schema / properties / data / description
      Removed value: -"Files that finished uploading, newest first."
    • removedOutput schema / properties / data / items / properties / alt / description
      Removed value: -"Alt text per language code, such as {\"en\": \"Our team\"}."
    • removedOutput schema / properties / data / items / properties / content_type / description
      Removed value: -"Content type of the file."
    • removedOutput schema / properties / data / items / properties / content_type / example
      Removed value: -"image/jpeg"
    • removedOutput schema / properties / data / items / properties / duration_seconds / description
      Removed value: -"Length of a video or audio file in seconds, as sent to media-upload-finish."
    • removedOutput schema / properties / data / items / properties / file_name / description
      Removed value: -"Display name in the library."
    • removedOutput schema / properties / data / items / properties / file_name / example
      Removed value: -"team-photo.jpg"
    • removedOutput schema / properties / data / items / properties / focal_x / description
      Removed value: -"Horizontal focal point, 0 (left) to 1 (right)."
    • removedOutput schema / properties / data / items / properties / focal_y / description
      Removed value: -"Vertical focal point, 0 (top) to 1 (bottom)."
    • removedOutput schema / properties / data / items / properties / folder / description
      Removed value: -"Library folder; \"\" is the top. It is the directory of the file in storage."
    • removedOutput schema / properties / data / items / properties / folder / example
      Removed value: -"team"
    • removedOutput schema / properties / data / items / properties / height / description
      Removed value: -"Height in pixels, as sent to media-upload-finish."
    • removedOutput schema / properties / data / items / properties / id / description
      Removed value: -"Id of the file (media_id)."
    • removedOutput schema / properties / data / items / properties / id / example
      Removed value: -"c9d6f121-1230-48fd-b3a7-8b5a1e8db052"
    • removedOutput schema / properties / data / items / properties / kind / description
      Removed value: -"image, video, audio or font."
    • removedOutput schema / properties / data / items / properties / merchant_id / description
      Removed value: -"Company whose library holds the file."
    • removedOutput schema / properties / data / items / properties / path / description
      Removed value: -"Object name in the public bucket: <merchant_id>/[<folder>/]<file>."
    • removedOutput schema / properties / data / items / properties / poster_url / description
      Removed value: -"Still image shown before a video plays."
    • removedOutput schema / properties / data / items / properties / read_only / description
      Removed value: -"True for a file of the parent company's library: it can be used on pages but not changed or deleted."
    • removedOutput schema / properties / data / items / properties / size_bytes / description
      Removed value: -"Size of the file in bytes, measured after the upload."
    • removedOutput schema / properties / data / items / properties / status / description
      Removed value: -"uploading until media-upload-finish accepts the file, then ready."
    • removedOutput schema / properties / data / items / properties / url / description
      Removed value: -"Public address of the file, served by the CDN. It changes when the file is replaced."
    • removedOutput schema / properties / data / items / properties / version / description
      Removed value: -"Goes up each time the file is replaced."
    • removedOutput schema / properties / data / items / properties / width / description
      Removed value: -"Width in pixels, as sent to media-upload-finish."
    • removedOutput schema / properties / folders / description
      Removed value: -"With include_folders=true: the folders A to Z, empty ones included; the top (\"\") is not a folder and is not listed."
    • removedOutput schema / properties / folders / items / properties / files / description
      Removed value: -"Files in the folder that finished uploading."
    • removedOutput schema / properties / folders / items / properties / files / example
      Removed value: -12
    • removedOutput schema / properties / folders / items / properties / name / description
      Removed value: -"Folder name, as files name it in `folder`."
    • removedOutput schema / properties / folders / items / properties / name / example
      Removed value: -"Crew life"
    • removedOutput schema / properties / pagination / properties / has_more / description
      Removed value: -"True when more records exist beyond this page (offset + returned < total)."
    • removedOutput schema / properties / pagination / properties / has_more / example
      Removed value: -true
    • removedOutput schema / properties / pagination / properties / limit / description
      Removed value: -"Page size used for this response."
    • removedOutput schema / properties / pagination / properties / limit / example
      Removed value: -50
    • removedOutput schema / properties / pagination / properties / offset / description
      Removed value: -"Offset used for this response."
    • removedOutput schema / properties / pagination / properties / offset / example
      Removed value: -0
    • removedOutput schema / properties / pagination / properties / total / description
      Removed value: -"Total matching records across all pages."
    • removedOutput schema / properties / pagination / properties / total / example
      Removed value: -137
  3. Added

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), so the bar is lower, and the description still adds real behavior: newest-first ordering, admin-only scoping, and that a sub-company sees parent files flagged read_only and thus usable but not changeable. That read-only inheritance detail is context an agent cannot get from the annotations alone.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core operation, then the key parameter behaviors, in a compact multi-clause form with no filler. The trailing pointer to get_tool_reference is mildly redundant given full schema coverage but does no harm.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a ten-parameter listing tool with an output schema and full annotation coverage, nothing essential is missing: scope, ordering, filtering semantics, folder behavior, and cross-company visibility are all addressed, and return-shape detail is correctly left to the output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, giving a baseline of 3, but the description goes beyond it by defining that an empty `folder` means the top level and by explaining what include_folders actually adds to the response (folder list with per-folder file counts). Those are behavioral semantics, not just restatements of the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource ('List the company's media library'), enumerates the file kinds covered (images, MP4 video, audio, WOFF2 fonts), and gives the ordering ('newest first'). An agent can distinguish this from manage_media_file and start_media_upload purely from this text.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explains when to set include_folders=true (to get every folder including empty ones with file counts) and clarifies that the `folder` value here is the same one used by start_media_upload and manage_media_file, which routes the agent correctly across siblings. It stops short of explicitly stating when to use a different listing tool, but the surrounding context is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.