XreplyAIDevelopers
API ReferencePosts

Create a post

Requires scope: `posts:write`. Supply `post_contents` (one entry per platform) and `social_account_ids`. Omit `scheduled_at` to create a draft. Recurrence fields require a paid plan.

POST
/posts
AuthorizationBearer <token>

A personal API key created in the dashboard (Starter, Pro, and Team plans).

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/posts" \  -H "Content-Type: application/json" \  -d '{    "post_contents": [      {        "platform": "twitter",        "body": "Shipping something small today.",        "content_type": "text"      }    ],    "social_account_ids": [      301    ],    "scheduled_at": "2026-07-14T15:00:00Z"  }'
{  "post": {    "id": 0,    "status": "draft",    "flexible": true,    "scheduled_at": "2019-08-24T14:15:22Z",    "posted_at": "2019-08-24T14:15:22Z",    "failed_at": "2019-08-24T14:15:22Z",    "post_error": "string",    "disconnected": true,    "source": "string",    "recurrence_jitter_enabled": true,    "evergreen": true,    "evergreen_variations": [      "string"    ],    "recycled_from_id": 0,    "reviewed_at": "2019-08-24T14:15:22Z",    "review_action": "string",    "rejection_reason": "string",    "created_at": "2019-08-24T14:15:22Z",    "body": "string",    "post_contents": [      {        "id": 0,        "platform": "twitter",        "body": "string",        "content_type": "text",        "position": 0,        "first_comment": "string",        "metadata": {}      }    ],    "post_accounts": [      {        "id": 0,        "social_account_id": 0,        "platform": "string",        "username": "string",        "platform_status": "string",        "platform_post_id": "string",        "permalink": "string",        "platform_error": "string",        "dub_short_url": "string",        "dub_original_url": "string",        "post_metric": {          "impressions": 0,          "likes": 0,          "replies": 0,          "reposts": 0,          "clicks": 0,          "engagement_rate": 0,          "fetched_at": "2019-08-24T14:15:22Z"        }      }    ],    "dry_run": true  }}