Media Saver

The Media Saver API

One request uploads your image and creates the post in your Buffer account. Media Saver keeps the file online until Buffer publishes it, then deletes it.

  1. Connect your Buffer account.
  2. Create an API key on your dashboard.
  3. Copy a channel ID from your dashboard, or list them with GET /channels.
  4. Send your first post with the request below.
Base URLhttps://mediasaver.si/api/v1

Authentication

Send your API key in the Authorization header of every request. Keep it secret. If a key leaks, revoke it on your dashboard and create a new one: the old key stops working immediately.

Authorization: Bearer ms_live_your_key_here

Keeping keys safe

  • Create one key per automation, named after it, such as “n8n weekly posts”. If one is exposed, you revoke only that key, and everything else keeps working.
  • Store keys in your tool’s credential manager, such as n8n credentials, Zapier connections or your hosting provider’s environment variables. Never paste them into code, shared documents or screenshots.
  • To rotate a key, create the new one, update your automation to use it, check it works, then revoke the old one. Nothing stops in between.
  • Rotate straight away if a key may have been exposed, or when someone with access leaves your team. Otherwise, rotating every few months is good practice.
  • Check the “last used” date on your dashboard now and then. A key that hasn’t been used for weeks is probably not needed, so revoke it.
POST

/posts

Uploads an image and creates the post in Buffer. Send it as multipart form data.

FieldRequiredDescription
fileYesJPEG, PNG or GIF, up to 4 MB. For files up to 20 MB, use the two-step upload below.
channelIdYesA channel ID from your dashboard or GET /channels.
textYesThe post text, within the network’s character limit.
dueAtNoISO 8601 time to publish, such as 2026-11-05T10:00:00Z. Leave it out to use the next free slot in your Buffer queue.
draftNoSet to true to save the post as a draft in Buffer instead of scheduling it. Useful for testing.
curl -X POST https://mediasaver.si/api/v1/posts \
  -H "Authorization: Bearer ms_live_your_key_here" \
  -F "file=@launch.jpg" \
  -F "channelId=YOUR_CHANNEL_ID" \
  -F "text=We just shipped it." \
  -F "dueAt=2026-11-05T10:00:00Z"

Response: 201 Created

{
  "uploadId": "97737c17-90b2-4aa5-8896-3cdc071614aa",
  "postId": "6ae578a0b84259308bbbe3d6",
  "status": "scheduled",
  "dueAt": "2026-11-05T10:00:00.000Z"
}

The image stays online until Buffer reports the post as published, then a daily cleanup deletes it. You never need to delete files yourself.

GET

/channels

Lists the channels in your Buffer account with their IDs, so your automation knows where to post. Results are cached for up to 10 minutes, so a newly connected channel may take a few minutes to appear.

curl https://mediasaver.si/api/v1/channels \
  -H "Authorization: Bearer ms_live_your_key_here"

Response: 200 OK

{
  "channels": [
    {
      "id": "6ad9a464778b240e2f87c827",
      "name": "my-company",
      "service": "linkedin",
      "organizationName": "My Organization"
    }
  ]
}

Errors

Every error returns JSON with an error message you can show or log.

{
  "error": "text is required"
}
400A required field is missing or invalid. The message names the field.
401The API key is missing or revoked, or your Buffer connection needs renewing.
404Something you referenced, such as a channel, was not found.
409The file has not been uploaded yet, or that upload already has a post.
413The file is too large: 4 MB in one request, or 20 MB with the two-step upload.
415The file type is not supported.
422Buffer rejected the post, for example because the queue is full. The message says why, and uploadId lets you retry without uploading again.
429Rate limit reached. Wait for the number of seconds in the Retry-After header.

Rate limits

Requests to Buffer count against a shared quota. If you receive a 429, wait for the number of seconds in the Retry-After header before trying again, and avoid automatic retry loops in your workflows.

Using n8n

  1. Add an HTTP Request node, set the method to POST and the URL to https://mediasaver.si/api/v1/posts.
  2. Under Authentication, choose Header Auth, with the name Authorization and the value Bearer followed by your key.
  3. Set the body to Form-Data. Add file as an n8n binary field, then channelId, text and, if you want a set time, dueAt as text fields.

Large files

For images up to 20 MB, upload the file directly to storage in three steps. The file never passes through Media Saver’s servers, so the 4 MB limit does not apply.

1. Ask for an upload address, giving the file’s name, type and exact size in bytes.

curl -X POST https://mediasaver.si/api/v1/uploads \
  -H "Authorization: Bearer ms_live_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"fileName":"photo.jpg","contentType":"image/jpeg","size":8123456}'
{
  "uploadId": "7b90b90b-9c9d-4689-8571-a0de326552e8",
  "uploadUrl": "https://…",
  "publicUrl": "https://media.mediasaver.si/…",
  "expiresIn": 600,
  "headers": { "Content-Type": "image/jpeg" }
}

2. Upload the file to uploadUrl within 10 minutes, with the headers from step 1. Do not send your API key: the address carries its own permission.

curl -X PUT "UPLOAD_URL_FROM_STEP_1" \
  -H "Content-Type: image/jpeg" \
  --data-binary @photo.jpg

3. Create the post with the uploadId. Media Saver checks the file arrived before sending it to Buffer.

curl -X POST https://mediasaver.si/api/v1/posts \
  -H "Authorization: Bearer ms_live_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"uploadId":"UPLOAD_ID_FROM_STEP_1","channelId":"YOUR_CHANNEL_ID","text":"We just shipped it."}'