POST
/
v1
/
teams
/
{teamId}
/
posts
/
{postId}
/
move-to-draft
TypeScript client
import { OctosparkClient } from '@octospark/sdk'

const client = new OctosparkClient({
  token: process.env.OCTOSPARK_TOKEN
})

const response = await client.social.movePostToDraft({
  teamId: process.env.OCTOSPARK_TEAM_ID ?? "teamId",
  postId: process.env.OCTOSPARK_POST_ID ?? "postId",
})
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "teamId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "title": "<string>",
  "text": "<string>",
  "assetIds": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "assetTags": [
    "<string>"
  ],
  "userTags": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "name": "<string>",
      "colour": "<string>"
    }
  ],
  "contentPayloadId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "latestScheduledPost": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "teamId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "contentItemId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "socialAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "scheduledAt": "<string>",
    "timezone": "Europe/London",
    "platformPostId": "<string>",
    "platformSettings": {},
    "publishResults": {},
    "providerPublishState": {
      "requiresPolling": true,
      "publishId": "<string>",
      "platformPostId": "<string>",
      "providerStatus": "<string>",
      "pollingReason": "<string>",
      "uploadProgress": {
        "nextByteStart": 123,
        "uploadSize": 123
      },
      "failureCode": "<string>"
    },
    "errorCode": "<string>",
    "errorMessage": "<string>",
    "workflowId": "<string>",
    "workflowRunId": "<string>",
    "createdAt": "<string>",
    "updatedAt": "<string>"
  },
  "scheduledDestinationAccountIds": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "createdAt": "<string>",
  "updatedAt": "<string>",
  "postInput": {
    "kind": "atomic",
    "text": "<string>",
    "attachments": [
      {
        "kind": "media",
        "asset": {
          "assetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "mimeType": "<string>",
          "byteSize": 123,
          "width": 123,
          "height": 123,
          "durationSeconds": 123,
          "thumbnailUrl": "<string>",
          "altText": "<string>"
        },
        "altText": "<string>"
      }
    ]
  },
  "postPublishActions": {
    "firstComment": {
      "text": "<string>",
      "mediaIds": [
        "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      ]
    },
    "engagementCommentTrigger": {
      "likeThreshold": 2,
      "windowHours": 360,
      "comment": {
        "text": "<string>",
        "mediaIds": [
          "3c90c3cc-0d44-4b50-8888-8dd25736052a"
        ]
      }
    },
    "repostAfter": {
      "offsetDays": 15,
      "text": "<string>"
    },
    "recurrenceIntervalDays": 183,
    "recurrenceEndsAt": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

teamId
string
required

Team (workspace) id (UUID). Discover ids via the list teams endpoint or the agent context.

postId
string
required

Post id (UUID), as returned by the create post and list posts endpoints.

Response

Success

id
string<uuid>
required

UUID of the post.

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
Example:

"3c9d8e7f-6a5b-4c3d-9e2f-1a0b9c8d7e6f"

teamId
string<uuid>
required

a Universally Unique Identifier

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
postType
enum<string>
required

Content format of a post: text_post (text only), text_image, text_video, or carousel (2+ photos).

Available options:
text_post,
text_image,
text_video,
carousel
Examples:

"text_post"

"text_image"

title
string | null
required
status
enum<string>
required

Editorial status of a post: idea, proposed_render, draft, approved, rejected, archived, or deleted.

Available options:
idea,
proposed_render,
draft,
approved,
rejected,
archived,
deleted
Examples:

"draft"

"approved"

text
string
required
assetIds
string<uuid>[]
required

a Universally Unique Identifier

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
assetTags
string[]
required

Deduped, sorted union of the post's non-deleted assets' AI tags; empty for text-only posts.

Example:
["launch", "product"]
userTags
object[]
required

User/agent-assigned registry tags (id, name, colour) on the post; distinct from AI-derived assetTags. Empty when no tags are assigned.

contentPayloadId
string<uuid>
required

a Universally Unique Identifier

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
latestScheduledPost
object
required
scheduledDestinationAccountIds
string<uuid>[]
required

a Universally Unique Identifier

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$
saveDestination
enum<string>
required
Available options:
queue,
drafts
saveMessage
enum<string>
required
Available options:
Saved to Queue,
Saved to Drafts
createdAt
string
required
updatedAt
string
required
postInput
object
postPublishActions
object