Skip to content

Quickstart

Three ways to upload: the CLI demo (zero signup), the SDK, or a single REST call.

Zero-signup demo

Terminal window
npx @dropkit/cli@latest upload ./photo.png

Prints the CDN URL. Files expire in 1 hour, 10 MB cap. Great for a quick share before you commit to anything. Run dropkit login to attach a permanent project.

The SDK

Install:

Terminal window
bun add @dropkit/sdk

Upload:

import { dropkit } from '@dropkit/sdk';
const client = dropkit({ key: 'pk_live_...' });
const { data, error } = await client.upload(file);
if (error) throw new Error(error.message);
console.log(data.url);

That’s it. The URL is a live CDN link.

One REST call

For shell scripts, servers, or anywhere without the SDK:

Terminal window
curl -X POST https://api.dropkit.app/v1/upload \
-H "authorization: Bearer sk_live_..." \
-F "file=@photo.jpg"

Response:

{
"id": "abc123...",
"url": "https://cdn.dropkit.app/abc123.../photo.jpg",
"name": "photo.jpg",
"size": 12345,
"type": "image/jpeg"
}

Use a server key here, not a browser key. Server keys don’t need an origin and can also delete and sign per-user uploads.

Mirror a remote URL

When you already have a URL (image-gen output, a screenshot link, anything ephemeral), hand it to dropkit and skip the download/re-upload dance:

const { data } = await client.uploadFromUrl('https://example.com/photo.jpg');
console.log(data.url);

Or from the CLI:

Terminal window
dropkit upload https://example.com/photo.jpg

Real key only (the demo key is path-only). Full reference: URL ingest.

Or have your agent do it

Plug dropkit into Claude Code, Claude Desktop, Cursor, Windsurf, or ChatGPT via the MCP server. The agent uploads files mid-session and replies with a CDN URL the user can open.

For Claude Code, paste this in your terminal:

Terminal window
claude mcp add dropkit -- npx -y @dropkit/mcp

For Claude Desktop, Cursor, Windsurf, or ChatGPT, drop this into the client’s MCP config:

{
"mcpServers": {
"dropkit": { "command": "npx", "args": ["-y", "@dropkit/mcp"] }
}
}

Full setup: /docs/mcp.

Get your key

  1. Sign up at dash.dropkit.app.
  2. Create a project.
  3. Open the Keys page. Click New key.

dropkit creates two kinds of keys:

  • Browser key (pk_live_...): safe to ship in frontend code. Uploads only. Lock it to your app’s origin.
  • Server key (sk_live_...): backend only. Can delete files, sign per-user uploads, run REST one-shots.

Most apps only need a browser key.

Next

  • Recipes: copy-paste snippets for React, Svelte, Vue, Next, Remix, Expo, vanilla, Python, Go.
  • CLI: npx @dropkit/cli init or npx @dropkit/cli upload ./photo.jpg.
  • WordPress plugin: drop-in replacement for Media Library uploads.
  • Private files: mark uploads as private and mint short-lived signed URLs.
  • SDK reference: every option the SDK accepts.
  • REST upload: the one-shot endpoint.
  • Sign + complete flow: the resumable path.