Prompt
Using tips/042-multi-cursor.md, write a TikTok caption for the matching clip tips/042-multi-cursor.mp4: a hook, the shortcut, and 4 hashtags. Upload the video and create the TikTok draft. How to do it
- Connect TikTok and mint a key In https://app.socialhandoff.com, open Connections, connect TikTok, then open TikTok settings on the account and choose visibility, comment/duet/stitch, and commercial disclosure. Then create an agent key named VS Code scoped to TikTok with draft and schedule permission.
- Declare the server for Copilot Add .vscode/mcp.json with a servers entry of type http, the URL https://app.socialhandoff.com/mcp, and a password input for the key. Start the server, then switch Copilot Chat to agent mode.
- Attach media from the workspace VS Code calls attach_media for the video or up to 35 photos: a public url, or the file as base64 data (up to 8 MB) with its mime type and alt text. Larger files go to POST https://app.socialhandoff.com/v1/media as multipart. The ids go into draft_post as mediaIds.
- Ask for the draft In Copilot Chat, choose Agent and give it the prompt. Confirm the terminal command and the tool call when asked.
- Approve with the consent text The approval screen shows the visibility and interaction settings chosen in Connections and TikTok's consent text. Approve, and it publishes; a video is sent to TikTok in chunks.
Example draft
Stop editing lines one by one. Alt+Click to add a cursor anywhere, or Ctrl+Alt+Down to add one on the next line. Type once, change all of them. #vscode #codingtips #programming #developer [Video: tips/042-multi-cursor.mp4, 28-second vertical screen recording]
Gotchas
- TikTok refuses text-only posts. The agent can draft the caption first, but approval and scheduling are refused until a video or photos are attached.
- Copilot only calls MCP tools in agent mode. In ask or edit mode it will describe the post but never call draft_post.
- Until TikTok audits your developer app, every post is private (visible only to the account), the posting account must be private, and only 5 accounts can post per day.
- Media: Every post needs one video or up to 35 photos. Text-only posts are not possible.
- Video upload: Videos upload in chunks of 5 to 64 MB; smaller files go in one piece. Maximum duration depends on the creator account.
- Photo posts: Up to 35 JPEG or WebP images, a title up to 90 characters, and a description up to 4,000 characters.
- Required choices: TikTok requires a visibility setting with no default, comment/duet/stitch toggles, and a commercial content disclosure.
Frequently asked questions
Why are my TikTok posts private?
TikTok limits unaudited developer apps to private posts. Submit your app for TikTok's audit to lift the restriction; until then, posts are visible only to the account.
Why does VS Code use servers instead of mcpServers?
That is the VS Code format. Its mcp.json uses a servers key and supports inputs, so the key is prompted once and stored securely.
Can I post photos instead of a video?
Yes. A TikTok photo post takes up to 35 images. The domain serving them must be verified in the TikTok developer portal.