GET
/
v1
/
teams
/
{teamId}
/
posts
/
{postId}
/
performance
TypeScript client
import { OctosparkClient } from '@octospark/sdk'

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

const response = await client.social.getPostPerformance({
  teamId: process.env.OCTOSPARK_TEAM_ID ?? "teamId",
  postId: process.env.OCTOSPARK_POST_ID ?? "postId",
})
{
  "scheduledPostId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "current": {
    "likeCount": 123,
    "commentCount": 123,
    "shareCount": 123,
    "saveCount": 123,
    "impressionCount": 123,
    "reachCount": 123,
    "linkClickCount": 123
  },
  "derivedMetrics": {
    "engagementRate": 123,
    "performanceScore": 50,
    "viralityScore": 123,
    "qualityScore": 123,
    "banditReward": 123
  },
  "content": {
    "isThread": true,
    "caption": "<string>",
    "title": "<string>",
    "assetCount": 123,
    "assetTypes": [
      "<string>"
    ],
    "assetCategories": [
      "<string>"
    ],
    "aiTags": [
      "<string>"
    ],
    "categories": [
      "<string>"
    ],
    "emotions": [
      "<string>"
    ],
    "purposes": [
      "<string>"
    ],
    "titles": [
      "<string>"
    ],
    "descriptions": [
      "<string>"
    ],
    "durationSecondsMax": 123,
    "durationSecondsTotal": 123,
    "widthMax": 123,
    "heightMax": 123,
    "fps": 123,
    "assets": [
      {
        "assetId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "assetType": "<string>",
        "aiTitle": "<string>",
        "aiDescription": "<string>",
        "aiTags": [
          "<string>"
        ],
        "contentCategory": "<string>",
        "emotion": {},
        "purpose": [
          "<string>"
        ],
        "durationSeconds": 123,
        "width": 123,
        "height": 123,
        "fps": 123,
        "analysis": {}
      }
    ]
  },
  "snapshots": [
    {
      "hoursSincePost": 123,
      "snapshotTakenAt": "<string>",
      "likeCount": 123,
      "commentCount": 123,
      "shareCount": 123,
      "saveCount": 123,
      "impressionCount": 123,
      "reachCount": 123,
      "linkClickCount": 123,
      "collectionError": "<string>"
    }
  ],
  "lastCollectedAt": "<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

scheduledPostId
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}$
platform
enum<string>
required

Social platform identifier: x, tiktok, instagram, facebook, youtube, linkedin, or threads.

Available options:
x,
tiktok,
instagram,
facebook,
youtube,
linkedin,
threads
Example:

"x"

collectionStatus
enum<string>
required
Available options:
pending,
collecting,
completed,
failed,
stale
current
object
required
derivedMetrics
object
required
content
object
required
snapshots
object[]
required
lastCollectedAt
string | null