Free File Storage API for Developers

March 3, 2026 7 min read REST API

Need to upload and share files programmatically? Whether you're building a file-sharing feature, storing AI-generated outputs, handling user uploads in a SaaS app, or sharing temporary build artifacts — you need a file storage API that's simple, fast, and doesn't require configuring S3 buckets.

Setting up AWS S3, managing IAM policies, configuring CORS, and handling presigned URLs adds complexity that slows down development. We built a free file storage API with 3 upload methods, auto-expiring links, download limits, and direct shareable URLs. No signup, no bucket configuration, no cloud console.

Try it right now

Upload your first file in under 30 seconds. No signup, no cloud setup.

Get Free API Key

Quick Start: Upload a File in One Command

1. Upload via curl (no API key needed for free tier)

# Upload any file with a PUT request
curl -X PUT https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload/report.pdf \
  --upload-file report.pdf
{
  "id": "f_17b7f20d0dd4",
  "token": "9f22922553107298",
  "originalName": "report.pdf",
  "contentType": "application/pdf",
  "size": 45230,
  "uploadedAt": "2026-03-03T20:07:59.187Z",
  "expiresAt": "2026-03-04T20:07:59.187Z",
  "ttlHours": 24,
  "downloads": 0,
  "downloadUrl": "/api/files/f_17b7f20d0dd4/download",
  "directUrl": "/d/9f22922553107298/report.pdf"
}

2. Share the direct URL

The directUrl is a public link — anyone with it can download the file, no authentication needed. Perfect for sharing with teammates, clients, or embedding in docs.

3. Download or manage

# Download by file ID (authenticated)
curl https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/f_17b7f20d0dd4/download -o report.pdf

# Delete when done
curl -X DELETE https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/f_17b7f20d0dd4 \
  -H "Authorization: Bearer YOUR_KEY"

3 Upload Methods

Raw Binary (PUT)

Upload any file directly with curl --upload-file. Simplest method — just PUT the file content to /api/files/upload/:filename.

Multipart Form (POST)

Standard multipart/form-data upload. Works with HTML forms, React file inputs, and any HTTP client. Send to /api/files/upload.

Base64 JSON (POST)

Send file content as base64 in a JSON body. Great for programmatic uploads when you already have the data in memory. Send to /api/files/upload/base64.

Features

Auto-Expiring Files

Files expire after 24 hours by default (configurable up to 7 days). No cleanup scripts needed — storage manages itself.

Download Limits

Set a maximum download count per file. After the limit is reached, the file becomes inaccessible. Perfect for one-time download links.

Tags & Metadata

Organize files with tags and custom metadata. Filter and search your uploads programmatically.

Direct Share URLs

Every file gets a public direct URL that requires no authentication. Share it anywhere — Slack, email, docs, CI/CD logs.

Deletion Tokens

Each upload returns a deletion token. Share it with the recipient so they can delete the file themselves without your API key.

50 MB File Limit

Upload files up to 50 MB. Supports any content type — documents, images, archives, data files, binaries.

API Reference

EndpointMethodDescription
/api/files/uploadPOSTUpload via multipart/form-data
/api/files/upload/:filenamePUTUpload via raw binary body
/api/files/upload/base64POSTUpload via base64-encoded JSON
/api/filesGETList your uploaded files
/api/files/:idGETGet file metadata
/api/files/:id/downloadGETDownload file by ID
/d/:token/:filenameGETDirect download (no auth, shareable)
/api/files/:idPATCHUpdate tags or download limits
/api/files/:idDELETEDelete a file (requires auth)
/api/files/:id/:deletionTokenDELETEDelete with deletion token (no auth)

Code Examples

curl
Python
Node.js
# Upload a file (raw binary — simplest method)
curl -X PUT https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload/screenshot.png \
  --upload-file screenshot.png

# Upload with tags and custom TTL (base64 method)
curl -X POST https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload/base64 \
  -H "Content-Type: application/json" \
  -d '{"filename": "config.json", "content": "eyJrZXkiOiJ2YWx1ZSJ9", "contentType": "application/json", "tags": ["config", "v2"], "ttlHours": 48}'

# Upload via multipart form (like an HTML form)
curl -X POST https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload \
  -F "file=@document.pdf"

# List your files
curl https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files \
  -H "Authorization: Bearer YOUR_KEY"

# Set download limit (one-time download link)
curl -X PATCH https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/f_abc123 \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"maxDownloads": 1}'
import requests
import base64

API = "https://agent-gateway-kappa.vercel.app/v1/agent-filestorage"

# Step 1: Get free API key
key_resp = requests.post(f"{API}/api/keys/create")
api_key = key_resp.json()["key"]
print(f"API Key: {api_key}")

headers = {"Authorization": f"Bearer {api_key}"}

# Step 2: Upload a file (multipart)
with open("report.pdf", "rb") as f:
    resp = requests.post(
        f"{API}/api/files/upload",
        headers=headers,
        files={"file": ("report.pdf", f, "application/pdf")}
    )
result = resp.json()
print(f"Uploaded: {result['id']}")
print(f"Share URL: {result['directUrl']}")
print(f"Expires: {result['expiresAt']}")

# Upload from memory (base64)
data = {"hello": "world"}
content = base64.b64encode(json.dumps(data).encode()).decode()
resp = requests.post(
    f"{API}/api/files/upload/base64",
    headers=headers,
    json={
        "filename": "data.json",
        "content": content,
        "contentType": "application/json",
        "tags": ["output", "json"]
    }
)
print(f"JSON uploaded: {resp.json()['directUrl']}")

# List all files
files = requests.get(f"{API}/api/files", headers=headers).json()
for f in files.get("files", []):
    print(f"  {f['originalName']} ({f['size']} bytes, expires {f['expiresAt']})")
const fs = require('fs');

const API = 'https://agent-gateway-kappa.vercel.app/v1/agent-filestorage';

async function uploadFiles() {
  // Step 1: Get free API key
  const keyResp = await fetch(`${API}/api/keys/create`, { method: 'POST' });
  const { key } = await keyResp.json();
  console.log(`API Key: ${key}`);

  // Step 2: Upload via raw binary
  const fileBuffer = fs.readFileSync('report.pdf');
  const resp = await fetch(`${API}/api/files/upload/report.pdf`, {
    method: 'PUT',
    headers: {
      'Authorization': `Bearer ${key}`,
      'Content-Type': 'application/pdf'
    },
    body: fileBuffer
  });
  const result = await resp.json();
  console.log(`Uploaded: ${result.id}`);
  console.log(`Share: ${result.directUrl}`);

  // Step 3: Upload JSON from memory (base64)
  const data = { metrics: [1, 2, 3], timestamp: Date.now() };
  const b64 = Buffer.from(JSON.stringify(data)).toString('base64');
  const jsonResp = await fetch(`${API}/api/files/upload/base64`, {
    method: 'POST',
    headers: {
      'Authorization': `Bearer ${key}`,
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      filename: 'metrics.json',
      content: b64,
      contentType: 'application/json',
      tags: ['metrics']
    })
  });
  console.log(`JSON uploaded: ${(await jsonResp.json()).directUrl}`);
}

uploadFiles();

Use Cases

CI/CD Build Artifacts

Upload build outputs, test reports, and coverage files from your CI pipeline. Share direct download links in pull request comments or Slack channels. Files auto-expire after 24 hours so you don't accumulate stale artifacts.

# In your CI pipeline — upload test results
RESULT=$(curl -s -X PUT https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload/test-report.html \
  --upload-file coverage/report.html)
URL=$(echo $RESULT | python3 -c "import sys,json; print(json.load(sys.stdin)['directUrl'])")
echo "Test report: $URL"

AI Agent Output Storage

When your AI agent generates a report, creates an image, or produces a data file — store it via the API and return the shareable link. The agent doesn't need to manage cloud storage credentials.

Temporary File Sharing

Share files that automatically disappear. Set expiration from 1 hour to 7 days. Optionally set a download limit of 1 for true one-time download links — the file becomes inaccessible after a single download.

# One-time download link (file deleted after first download)
curl -X POST https://agent-gateway-kappa.vercel.app/v1/agent-filestorage/api/files/upload/base64 \
  -H "Content-Type: application/json" \
  -d '{"filename": "secret.txt", "content": "VG9wIHNlY3JldCBkYXRh", "tags": ["sensitive"], "maxDownloads": 1}'

User Upload Backend

Add file upload to your web or mobile app without configuring S3, managing IAM, or writing presigned URL logic. Use the multipart endpoint — it works like a standard HTML form upload.

Comparison: File Storage APIs in 2026

FeatureAgent File StorageAWS S3Uploadcarefile.iotransfer.sh
Setup requiredNoneAWS account, IAM, bucketsAccount + projectNoneNone
Signup requiredNoYesYesNoNo
Free tier50 uploads5 GB (12 months)3,000 uploads/moUnlimited*10 GB
Max file size50 MB5 TB500 MB2 GB10 GB
Auto-expiring linksYes (1h-7d)Presigned URLsNoYes (14d)Yes (14d)
Download limitsYesNoNo1 download onlyMax downloads
Tags & metadataYesYesYesNoNo
Direct share URLYes (no auth)Presigned onlyCDN URLYesYes
Upload methods3 (multipart, binary, base64)Multipart, presignedMultipart, URLMultipartBinary
API styleRESTREST/SDKRESTRESTcurl

* file.io is free but files are deleted after a single download. Agent File Storage gives you configurable download limits, longer TTLs, and full CRUD operations.

Start uploading files now

50 free uploads. No signup, no cloud setup, no bucket configuration.

Get Free API Key

Frequently Asked Questions

How many free uploads do I get?

50 uploads with each API key. No signup or credit card required. Basic uploads (without an API key) work for the first few files on the free tier. Paid credits cost $0.002 per upload (500 credits per USDC).

How long are files stored?

Files expire after 24 hours by default. You can set custom TTL from 1 hour to 168 hours (7 days) using the ttlHours parameter. Expired files are automatically deleted.

What's the maximum file size?

50 MB per file. Any content type is accepted — documents, images, archives, data files, binaries, and more.

Can I create one-time download links?

Yes. Set maxDownloads: 1 when uploading or via PATCH. After the file is downloaded once, it becomes inaccessible. Great for sharing sensitive documents.

Are direct URLs public?

Yes. The directUrl (/d/:token/:filename) is a public link that anyone can access without authentication. The token is random and unguessable. If you need to restrict access, use the authenticated download endpoint instead.

Can I delete files before they expire?

Yes. Use DELETE /api/files/:id with your API key, or DELETE /api/files/:id/:deletionToken with the deletion token from the upload response (no auth needed).

Is there a rate limit?

Free tier: 30 requests per minute. With an API key and credits: 120 requests per minute.

More Developer Tools