Social Relay API
Publish, schedule and analyze TikTok and Instagram content. Authenticate with `Authorization: Bearer <api key>` (create keys in Settings). Errors are `{ "error": { "code", "message" } }`. Limit: 120 requests per minute per key. TikTok posts created with an API key get status `awaiting_approval`: the account owner reviews and confirms them in the dashboard, as TikTok requires. Instagram posts are published at `scheduled_at` (or right away).
Base URL: https://social.sagiware.com/api/v1 · Machine-readable spec: openapi.json
# 1. Upload a video (raw body) or pass {"url": "..."} as JSON
curl -X POST https://social.sagiware.com/api/v1/media \
-H "Authorization: Bearer $KEY" -H "Content-Type: video/mp4" \
--data-binary @clip.mp4
# 2. Post it to Instagram as a Reel tomorrow, and queue it for TikTok approval
curl -X POST https://social.sagiware.com/api/v1/posts \
-H "Authorization: Bearer $KEY" -H "Content-Type: application/json" \
-H "Idempotency-Key: launch-video-1" \
-d '{"account_ids":["<instagram id>","<tiktok id>"],"media_ids":["<media id>"],
"caption":"New drop #launch","scheduled_at":"2026-10-16T09:00:00Z"}'
# 3. Check engagement
curl https://social.sagiware.com/api/v1/posts?status=published -H "Authorization: Bearer $KEY"Scope: read.
Scope: read.
Scope: write. Revokes access and deletes its posts and metrics.
Scope: read. Current privacy options, disabled interactions, max video duration and whether the account can post now.
Scope: read. Includes posts made outside this app. TikTok: views, likes, comments, shares. Instagram: likes, comments.
Scope: read. Follower history from daily snapshots plus, for Instagram, reach, views, interactions, profile views and follower demographics.
Scope: comments. Instagram only.
Scope: comments. Instagram only.
Scope: comments. Instagram only.
Scope: write. Send the file as the raw body with its Content-Type (image/jpeg, image/png, image/webp, video/mp4, video/quicktime), or JSON `{"url": "https://..."}` to have the server download it. Returns `id` for `media_ids`. Unused media is deleted after 7 days.
Scope: read. Newest first, with latest metrics.
Scope: write. Creates one post per account. Optional `Idempotency-Key` header makes retries safe. Instagram `type`: FEED (1 JPEG), REELS (1 video), STORIES (1 image or video), CAROUSEL (2-10 items); inferred when omitted.
Scope: read. Status: awaiting_approval, scheduled, publishing, processing, published, failed, cancelled.
Scope: write. caption, title, scheduled_at, instagram.type. Editing a TikTok post sends it back for approval.
Scope: write. Only awaiting_approval or scheduled posts.
Scope: read. Snapshots every 6 hours for 60 days after publishing.