Skip to main content
Glama

strapi_upload_media

Upload media from a URL to Strapi's media library, with format conversion and quality control. Add metadata like name, caption, and alt text. Requires explicit user authorization.

Instructions

Upload media to Strapi's media library from a URL with format conversion, quality control, and metadata options. IMPORTANT: This is a write operation that REQUIRES explicit user authorization via the userAuthorized parameter.

Upload Steps

  1. Upload via strapi_upload_media with URL and metadata

  2. Get image ID from response

  3. Link to content using strapi_rest PUT request

Linking Images to Content (Strapi v5)

After upload, use PUT request to link: { "method": "PUT", "endpoint": "api/articles/{documentId}", "body": { "data": { "images": ["imageId"] } }, "userAuthorized": true }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serverYesThe name of the server to connect to
urlYesURL of the image to upload
formatNoTarget format for the image. Use 'original' to keep the source format.original
qualityNoImage quality (1-100). Only applies when converting formats.
metadataNo
userAuthorizedNoREQUIRED for media upload operations. Client MUST obtain explicit user authorization before setting this to true.
Behavior3/5

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

With no annotations provided, the description carries the full burden. It correctly identifies the tool as a write operation and highlights the authorization requirement. However, it does not disclose what happens if authorization is not provided, the response structure, or any side effects beyond the immediate upload.

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?

The description is relatively concise, front-loading the main purpose and important authorization note. The subsequent steps and linking example are helpful but add length. Overall, it is well-structured and readable.

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

Completeness4/5

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

Given the tool's complexity (6 parameters, nested objects, no output schema), the description provides essential context: the upload workflow, linking steps, and authorization requirement. It lacks a description of the return value but compensates with procedural guidance.

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

Parameters3/5

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

The input schema already covers 83% of parameters with descriptions. The description adds minimal new meaning beyond restating the schema's purpose and emphasizing the 'userAuthorized' requirement. Given high schema coverage, a baseline of 3 is appropriate.

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 clearly states the tool uploads media to Strapi's media library from a URL, with format conversion, quality control, and metadata options. It distinguishes itself from sibling tools (which are get/list/rest operations) as the dedicated upload/write tool.

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?

The description emphasizes that this is a write operation requiring user authorization via the 'userAuthorized' parameter. It also provides upload steps and linking instructions, guiding the agent on how to use the tool in a workflow. However, it does not explicitly state when to use versus alternatives or when not to use.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/misterboe/strapi-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server