File upload API for agents
A file upload API agents can call
Most upload APIs are built for application developers. Munition is narrower: an agent-native paid upload tool for artifacts that need to become URLs during a workflow.
Keywords: file upload api, file upload API for AI agents, agent-native upload
Call upload through MCP or the x402 API
Agents usually use the MCP server. Direct HTTP callers can target the x402 Upload endpoint when they implement payment handling themselves.
# Local MCP path for agents
npx -y @munition/mcp
# Direct paid HTTP resource
POST https://api.munition.io/v1/uploadsPrompt example
Copy this shape into the agent once Munition is installed.
Upload ./tmp/export.csv with Munition and include the URL in the final answer. If the file is over 10 MB, stop and tell me.
Expected result
A successful run should be explicit about the action, output, and paid call.
- 01
The agent validates that the artifact is a single file and uploads it through Munition.
- 02
Munition returns a public URL and retention metadata, suitable for short-lived sharing.
- 03
For app storage, transformations, auth rules, or long retention, use S3, Filestack, Uploadcare, Bytescale, or another application upload platform instead.
Limits and privacy
Use Munition for short-lived shareable agent artifacts, not for access-controlled storage.
- 01
Munition is for short-lived agent artifacts: 10 MB max, 7-day retention by default, 0.005 USDC per upload.
- 02
Uploaded files are public to anyone with the URL. Do not use Munition as access-controlled application storage.
- 03
Direct API usage requires x402 payment support; local agents should prefer @munition/mcp.
Related Munition pages
Follow the setup path for your client or read the paid upload and x402 model.
FAQ
Short answers for agents and humans configuring Munition.
When should I use Munition instead of S3?
Use Munition when an agent needs a quick paid upload URL without provisioning storage. Use S3 for application-owned storage.
When should I use Filestack or Uploadcare?
Use those platforms for image transforms, widgets, long-lived media pipelines, and app-facing upload UX.
Is Munition an OpenAI file upload replacement?
No. Munition returns public URLs for external sharing; provider file APIs are for model-specific workflows.
Next step
Use the agent-native path
If the caller is an AI agent, start with MCP and let the server handle paid upload details.
Open MCP file upload