# Quickstart

Schedule your first post through the API in about five minutes.


You need a CreatorHyve account on the Scale plan with at least one connected social account.

## 1. Create an API key

Open **Settings, then Developer**, name the key, keep the default permissions (read accounts, read posts, create and edit posts, upload media) and choose **Create Key**. Copy the key now: it starts with `ch_live_` and is shown only once.

```bash
export CH_KEY="ch_live_your_key_here"
export CH_API="https://creatorhyve.com/api/v1/developer"
```

## 2. See which accounts are connected

```bash
curl -s "$CH_API/accounts" -H "Authorization: Bearer $CH_KEY"
```

```json
{
  "accounts": [
    { "id": "0b5f...", "platform": "bluesky", "username": "you.bsky.social", "needs_reconnect": false }
  ]
}
```

The `platform` values are what you pass when creating a post. If `needs_reconnect` is true, reconnect the account in the dashboard first.

## 3. Schedule a post

```bash
curl -s -X POST "$CH_API/posts" \
  -H "Authorization: Bearer $CH_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: first-post-001" \
  -d '{
    "caption": "Hello from the API!",
    "platforms": ["bluesky"],
    "scheduledDatetime": "2030-01-15T09:00:00Z"
  }'
```

The answer contains the post with `status: "scheduled"`. Leave out `scheduledDatetime` to save a draft instead. The `Idempotency-Key` makes it safe to retry: sending the same request again returns the same post instead of creating a second one.

## 4. Check the result

After the scheduled time, ask what happened on each platform:

```bash
curl -s "$CH_API/posts/POST_ID/results" -H "Authorization: Bearer $CH_KEY"
```

```json
{
  "results": [
    { "platform": "bluesky", "status": "published", "url": "https://bsky.app/profile/...", "error": null }
  ]
}
```

A failed platform has an `error` with a plain-language `message` and an `action` (`reconnect`, `add_media`, `edit`, `retry`, `upgrade`).

## Next steps

- Get notified without polling: [webhooks](/docs/webhooks).
- Attach an image or video: [upload media](/docs/guides/upload-media).
- Let an assistant do this for you: [MCP](/docs/mcp).

