Skip to content

Weekly multi-platform queue

Once a week you have a folder of finished videos and a list of slots - Monday, Wednesday and Friday at 18:00, say - and every file should go to every network. This recipe turns the folder into a week of queued posts with one script against the REST API. Each file is uploaded once and referenced by its mediaId in as many posts as it needs.

  • A paid plan (the API starts on Creator) and an API key with write - Settings → API keys.
  • Connected accounts, or a group that holds them - Groups & cross-posting.
  • curl and jq, or any HTTP client. The bodies below are what any language sends.
  1. List the targets once: GET /groups for the group id, or GET /accounts for the ids.
  2. For each file: POST /media/uploads → PUT the bytes → GET /media/{id} until ready.
  3. For each file and its slot: POST /posts/plan, check every row is ok, then POST /posts with confirm: true.
  4. Verify: GET /posts?status=queued&from=…&to=… lists the week.
Terminal window
export KEY="ds_live_xxxxxxxxxxxxxxxxxxxx"
export API="https://api.dropslate.top/v1"
AUTH="Authorization: Bearer $KEY"
# 1) The group every post goes to (created once on Accounts -> Groups)
GROUP_ID=$(curl -s "$API/groups" -H "$AUTH" | jq -r '.groups[] | select(.name=="Weekly") | .id')
# 2) Upload one file and wait until it is ready
upload() {
local file="$1"
local size; size=$(stat -c%s "$file")
local ticket; ticket=$(curl -s -X POST "$API/media/uploads" -H "$AUTH" -H "Content-Type: application/json" \
-d "{\"filename\":\"$(basename "$file")\",\"mime\":\"video/mp4\",\"size\":$size}")
local id; id=$(echo "$ticket" | jq -r .mediaId)
curl -s -X PUT "$(echo "$ticket" | jq -r .uploadUrl)" -H "Content-Type: video/mp4" --data-binary @"$file" > /dev/null
until [ "$(curl -s "$API/media/$id" -H "$AUTH" | jq -r .status)" = "ready" ]; do sleep 5; done
echo "$id"
}
# 3) Plan, then create, one post per slot
schedule() {
local media="$1" when="$2" text="$3"
local body; body=$(jq -n --arg g "$GROUP_ID" --arg m "$media" --arg w "$when" --arg t "$text" \
'{targets:{groupId:$g}, mediaIds:[$m], text:$t, title:($t|.[0:100]), when:{publishAt:$w, timezone:"Europe/Kiev"}}')
local plan; plan=$(curl -s -X POST "$API/posts/plan" -H "$AUTH" -H "Content-Type: application/json" -d "$body")
if [ "$(echo "$plan" | jq -r .ok)" != "true" ]; then echo "$plan" | jq -r .table; return 1; fi
curl -s -X POST "$API/posts" -H "$AUTH" -H "Content-Type: application/json" \
-d "$(echo "$body" | jq '. + {confirm:true}')" | jq -r '.posts[].statusLine'
}
M1=$(upload ./week/monday.mp4)
M2=$(upload ./week/wednesday.mp4)
M3=$(upload ./week/friday.mp4)
schedule "$M1" "2026-09-28T18:00" "Monday: what we shipped this week."
schedule "$M2" "2026-09-30T18:00" "Wednesday: one question, answered."
schedule "$M3" "2026-10-02T18:00" "Friday: behind the scenes."

when is a local time plus the IANA time zone it is written in - {"publishAt":"2026-09-28T18:00","timezone":"Europe/Kiev"} - or the string "now" or "draft"; a scheduled time must be at least 2 minutes ahead. title is used by YouTube (required there) and Facebook videos; other networks ignore it. A YouTube description over 5,000 bytes or a Threads text over 500 characters shows up as an ok: false row in the plan, and the function prints the plan’s table instead of creating anything.

Terminal window
curl -s "$API/posts?status=queued&from=2026-09-28T00:00:00%2B03:00&to=2026-10-05T00:00:00%2B03:00" -H "$AUTH" | jq -r '.posts[].statusLine'

Each line reads Queued. YouTube · What We Made · 28 Sep, 18:00 (Kyiv). The same posts are on the Calendar; each can be cancelled or rescheduled there on its own. After the slots pass, GET /posts?status=failed is the check that needs a look.

  • Different text per network. Add overrides: {"overrides":{"threads":{"text":"Short version with one idea."},"youtube":{"title":"Full title for YouTube"}}}. The base text still goes to the rest.
  • Instagram as a Reel with a cover frame. "perPlatform":{"instagram":{"contentType":"reel","coverMs":4500}}.
  • Drafts instead of a schedule. "when":"draft" creates drafts you place from the Calendar later.
  • n8n. The same three calls as HTTP Request nodes; the recipe Content table queue shows the node layout.