Skip to content
Post from Grok Bot, Muse, Claude, ChatGPT and more

Create drafts from a JSON file with Node

For developers who keep their posts in a file and want them on the calendar.

Start 7-day trial for $0All prompts$0 due today. Cancel in one click.
PromptBlueskyX

Write a Node script with @postqueen/node that reads [launch-posts.json] and creates each entry as a draft on [Bluesky and X] at its date.

Works best withClaude CodeCodexCursorand any agent connected to PostQueen
What your agent does

The SDK calls, in order.

  1. new PostQueen()POSTQUEEN_API_KEYCreates the client with the API key from your environment.
  2. postqueen.integrations()bluesky, xLooks up the ids of your Bluesky and X channels.
  3. postqueen.post()type: 'draft', dateCreates each entry as a draft at its own date, one post per channel.
  4. postqueen.postList()startDate, endDateLists the posts in that date range, so the script can print what it made.

These are the real @postqueen/node calls in the code your agent writes. It writes them on its own; you only send the prompt.

The result

Drafts on your calendar, not surprises.

Everything waits as a draft. Open any post to change the words, the picture or the time, then schedule it when it is right.

  • A version for each network, within its limits
  • Nothing goes out until you schedule it
  • Change the text, time or media on the calendar
Variations

Make it your own.

  • Skip entries whose date has passed and print them at the end.
  • Upload each entry's image with postqueen.upload() and attach it to the post.
  • Add a --schedule flag that creates the posts with type 'schedule' instead of 'draft'.
Tips

Before you send it.

  • Write dates in ISO 8601 with a time zone, like 2026-10-06T09:00:00Z, so posts land at the right hour.
  • Bluesky posts stop at 300 characters and X posts at 280, so have the script check lengths before it sends.
  • Creating posts through the API is rate limited per hour for each workspace, so a very long file may need a pause.

Copy it. Your agent does the rest.

Connect your agent to PostQueen and send the prompt. The drafts wait on your calendar.

Start 7-day trial for $0$0 due today. Cancel in one click.