Docs

Custom Upload Script

Press Upload on any screenshot and get a link copied to your clipboard. You choose where it goes: ImgBB, S3, R2, or your own server.

Requires Synapse Pro.

Quick start with ImgBB

The fastest way to get going. It is free, and needs no server of your own.

  1. 1Open Settings → Screenshot → Upload.
  2. 2Turn on Custom Upload Script.
  3. 3Click "Use ImgBB Template" and paste your ImgBB API key into the apiKey line.
  4. 4Click Test Script, then Save.

That's it. An Upload button now appears on every screenshot.

Writing your own

Define one function. Return a URL string, or a Promise that resolves to one:

function uploadImage(imageBase64, fileName) {
  // your upload logic, with your own API keys inline
  return "https://example.com/your-uploaded-image.png";
}

imageBase64 is the screenshot as a base64 PNG. fileName is a timestamped name like screenshot-20260817-143022.png. Throwing an error, or returning anything that isn't a URL, counts as a failed upload.

Making HTTP requests

Use nativeHTTPRequest. It supports GET, POST, and PUT:

function uploadImage(imageBase64, fileName) {
  return new Promise(function(resolve, reject) {
    nativeHTTPRequest(
      "https://your-server.com/upload",
      "POST",
      { "Content-Type": "application/json" },
      JSON.stringify({ name: fileName, image: imageBase64 }),
      function(error, statusCode, responseBody) {
        if (error) return reject(error);
        if (statusCode !== 200) return reject("HTTP " + statusCode);
        resolve(JSON.parse(responseBody).url);
      }
    );
  });
}

Tip: console.log() works, and its output shows up in the Test Script panel.

Good to know

Where it runs
In an isolated sandbox with no file, Keychain, or app access. The only thing it can do is make HTTP requests.
Timeout
30 seconds. Anything slower is cancelled and reported as an error.
Manual only
Uploads happen when you press Upload, never automatically on capture.
On failure
You get an error message. Nothing is copied, and nothing is retried.
Your API keys
Stored encrypted in your Mac's Keychain. They stay on your device, and Synapse never sends them anywhere.

Only run scripts you trust. A script can send your screenshots anywhere its code specifies. Synapse runs exactly what's in the editor, nothing more and nothing less.