Screen Tools

Upload servers

Screen Tools can upload recordings and screenshots to your own server, as long as the server can hand out an upload URL and a public link for each file. This guide is for whoever runs that server: it’s everything the server has to do.

People add a server in Settings → Uploads → Add upload server, with a name, an icon, the server’s upload URL and, if the server wants one, an access token. Edit changes any of these later; Remove deletes the server from the extension (files already uploaded stay on the server). After that it shows up as a destination in the save dialog and the screenshot upload dialog.

How an upload works

Each upload is two requests:

  1. Screen Tools asks your upload URL where to put the file.
  2. It sends the file to the address your server answered with, then shows the public link.

Your server never has to receive the file itself. The address in step 2 can be your server, a storage bucket’s pre-signed URL, or anywhere else that takes a PUT.

Step 1: ask for an upload

POST <upload URL>
Content-Type: application/json
Authorization: Bearer <access token>

{
  "filename": "Screen recording 2026-11-02 at 10.15.00.mp4",
  "contentType": "video/mp4",
  "size": 48213504
}

Answer with 200 and JSON:

{
  "uploadUrl": "https://storage.example.com/a1b2c3/recording.mp4?signature=…",
  "publicUrl": "https://files.example.com/a1b2c3/recording.mp4",
  "headers": { "x-example-header": "value" }
}
Field Required What it is
uploadUrl Yes Where Screen Tools sends the file in step 2. http or https.
publicUrl Yes The link people share. Anyone with it should be able to open the file once the upload finishes.
headers No Extra request headers for step 2, as string values. Content-Type is always sent, so leave it out.

Any other fields are ignored.

Errors

Send a JSON body with an error field to have your message shown to the user, for example { "error": "Uploads are limited to 2 GB." }.

Status What Screen Tools does
401, 403 Stops and asks the user to check the access token.
413 Stops and says the file is too big.
429, 5xx Tries again up to three times, waiting longer each time.
Any other 4xx Stops and shows the error.

Step 2: send the file

PUT <uploadUrl>
Content-Type: <contentType from step 1>
<any headers from step 1>

<the file's bytes>

The file goes in one request, without the access token. Any 2xx answer means the upload is done.

If the PUT fails with 403, 408, 429 or a 5xx, or the connection drops, Screen Tools starts again from step 1 and asks for a new upload URL. Uploads aren’t resumed partway through, so a retry sends the whole file again.

Requirements

Try it with curl

These two requests are what Screen Tools sends, so a server that passes them will work:

curl -sS -X POST "$UPLOAD_URL" \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $TOKEN" \
  -d '{"filename":"test.png","contentType":"image/png","size":1234}'

curl -sS -X PUT "<uploadUrl from the answer>" \
  -H 'Content-Type: image/png' \
  --data-binary @test.png

Then open the publicUrl from the first answer in a private window.