Schedule a post
1Find the account
GET /social/accountslists the connected accounts with their network and name.curl "https://cuil.si/api/v1/social/accounts" -H "Authorization: Bearer $CUILSI_API_KEY" # [ { "id": "...", "network": "instagram", "name": "Sunny Beans Coffee", ... } ]2Add a picture or video (optional)
Upload a file to your Library, or use one you made with
/generations. Uploads can be up to 500 MB.curl -X POST "https://cuil.si/api/v1/assets/upload" -H "Authorization: Bearer $CUILSI_API_KEY" \ -F "[email protected]" # 201 Created: { "id": "ASSET_ID", "kind": "image", ... }3Check it first (optional)
POST /social/validatetells you what a network would refuse (text too long, the wrong picture size, a missing video) before anything is sent.curl -X POST "https://cuil.si/api/v1/social/validate" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -d '{"text": "Our summer cold brew is back!", "media_asset_ids": ["ASSET_ID"], "account_ids": ["ACCOUNT_ID"]}' # Lists anything a network would refuse (too long, wrong size, missing video...) before you send it.4Schedule it
Give the time in UTC in
scheduled_at, or leave it out to publish right away. YouTube and TikTok can't be posted to with an API key: those posts come only from people in cuil.si (and, for YouTube, the automations they set up there). A key can still save a YouTube post as a draft for a person to post.curl -X POST "https://cuil.si/api/v1/social/posts" -H "Authorization: Bearer $CUILSI_API_KEY" \ -H "Content-Type: application/json" \ -H "Idempotency-Key: $(uuidgen)" \ -d '{ "text": "Our summer cold brew is back!", "media_asset_ids": ["ASSET_ID"], "targets": [{ "account_id": "ACCOUNT_ID" }], "scheduled_at": "2026-11-01T09:00:00Z" }'5Links on X use credits
Posting is free, except an X post whose text has a link (
https://…with a real domain, or a bare domain likecuil.siorshop.com): it uses 20 credits for each X account, because X charges for those posts. They are charged when the post goes out, and come back if it fails. If your credits don't cover it,POST /social/postsanswers402withinsufficient_credits(it also saysneededandavailable), and nothing is saved. Each X account'scapabilities.link_post_creditsinGET /social/accountssays the current number.6Follow it
Check the post, or add a webhook for
post.publishedandpost.failed. A failed publication can be tried again.curl "https://cuil.si/api/v1/social/posts/POST_ID" -H "Authorization: Bearer $CUILSI_API_KEY" # Each account has its own publication: "scheduled", "publishing", "published" (with a link) or "failed". # Retry a failed one with POST https://cuil.si/api/v1/social/publications/PUBLICATION_ID/retry