Skip to content
MCP uploads

Upload screenshots to GitHub from any MCP client

One server for Claude Code, Codex, Cursor, and any other agent that speaks MCP.

Why an MCP server #

GitHub has no public API for attachments, so the GitHub MCP server has no tool that uploads an image. An agent that takes a screenshot needs another way to get it into the pull request. The uploads hosted MCP server is that tool. With it, an agent can:

  • Upload screenshots, video, PDFs, and logs to a pull request or an issue.
  • Stage files on a branch before the pull request exists.
  • Keep one attachments comment on the pull request, updated on each upload.
  • Get back a public URL and Markdown for anything it uploads.

The tools are the same in every MCP client. A team that uses Claude Code, Codex, and Cursor connects each one to the same server, and each agent uploads the same way. The agent needs an uploads sign-in. It does not need the uploads CLI, gh, or a GitHub token.

Connect your agent #

Add the server to your MCP client:

claude mcp add --transport http uploads https://agents.uploads.sh/mcp

The client opens a browser to sign in on first use.

Using claude.ai or Cowork? Add uploads from the Claude directory instead.

Agent can’t open a browser? Send a workspace or service token as a bearer token. See Authentication →

Install the GitHub App #

Install the uploads GitHub App on the repository. It posts the attachments comment for uploads made through the hosted server. Without it, the agent can still paste the Markdown it gets back into the pull request.

Upload a screenshot #

The agent calls sign_upload_url with the file name, the repo, and the branch it is working on:

sign_upload_url arguments
{
"files": [{ "filename": "settings-after.png" }],
"repo": "acme/web",
"branch": "feat/settings",
"state": "after"
}

The server returns a short-lived upload URL and a curl line for each file. The agent runs it, and the file goes straight from disk:

Run by the agent
curl -sS --fail-with-body -T 'settings-after.png' 'https://agents.uploads.sh/u/…'

The response has the file’s public URL and Markdown. If the branch has one open pull request, the file attaches to it. The agent then calls comment with the repo and the pull request number to update the attachments comment.

Video uploads the same way. The comment shows a poster image that links to a page where the video plays.

No shell? Pass the file to put as base64, or as a public HTTPS URL. See cloud agents →

Before the PR exists #

An agent usually takes screenshots before it opens the pull request. The same call with repo and branch stages each file for that branch. When the pull request opens, the GitHub App posts everything staged in one comment. Without the App, the agent calls promote with the branch and the new pull request number.

Full flow and arguments: Stage, then promote →

Public files and holds #

Uploaded files are public to anyone with the URL, including files attached to a private repository. Tell the agent not to capture screens that show credentials or customer data.

On workspaces with AI labels turned on, the hosted server also checks each upload. A file that appears to show a secret, an ID, or a card number is held for review. A held file stays out of the pull request comment, and its URL does not serve the image until a workspace member approves it. The agent can list held files with list_held. See Held uploads.

Compared with gh --attach #

GitHub CLI 2.99 added an --attach flag that uploads an image or video to an issue, pull request, or comment. If your agent has a shell, gh, and push access to the repository, it works with no other setup. It is not available through MCP, so an agent without that shell can’t use it.

Which one fits your agent: gh --attach or uploads →

FAQ #

Is there an MCP server that uploads screenshots to GitHub?
Yes. The uploads hosted MCP server at agents.uploads.sh/mcp gives an agent tools that upload a screenshot, video, or file and post it to a pull request or issue. It works in Claude Code, Codex, Cursor, OpenCode, and any other client that supports remote MCP servers.
Can the GitHub MCP server upload images to a pull request?
No. GitHub has no public API for attachments, so the GitHub MCP server has no upload tool. An agent needs a separate upload tool, such as the uploads MCP server, or a shell with gh 2.99 or newer for gh --attach.
How does an agent upload a file through MCP without sending base64?
It calls sign_upload_url with the file name. The server returns a short-lived URL and a curl command, and the agent sends the file straight from disk. An agent with no shell passes the file to put as base64, or as a public HTTPS URL that the server fetches.
Can an agent upload video through the MCP server?
Yes. MP4, WebM, and MOV upload the same way as screenshots. The pull request comment shows a poster image that links to a page where the video plays.
Does every agent need its own setup?
Each agent needs the server URL added once. After that the tools, arguments, and results are the same in every agent, so one set of instructions covers all of them.