Skip to main content
Glama
Upload-Post

Upload-Post

Official

Get post analytics

get_post_analytics

Fetch live per-platform metrics for a single post by requestId or platform post ID. Get views, reach, watch time, retention, audience breakdown and follower gains for TikTok, Instagram, YouTube and more.

Instructions

Per-platform metrics for one post. Identify it EITHER by requestId (a post published through Upload-Post, including TikTok drafts once they are published publicly from the TikTok app; add platform to read only that platform) OR by platformPostId + platform + user together (any post on the connected account, e.g. one returned by get_media, even if it was not published through Upload-Post). post_metrics carries whatever each platform reports, so its shape is not the same everywhere: on TikTok it adds retention (the curve, second by second), impression_sources (For You, following, search, profile…), audience_types (followers vs non-followers), new_followers won by the post, reach and the watch times (average_time_watched, total_time_watched, full_video_watched_rate) on top of the usual counters. TikTok drafts: until the draft is published from the TikTok app, post_metrics_error says it is still in the inbox; a draft published as private has no per-post analytics; once published publicly the entry carries the real platform_post_id, post_url, draft_published_at and original_publish_id (the TikTok publish id the upload started with). A TikTok upload more than 30 days old that never got a post id is no longer looked up: read it by platformPostId. It fetches the metrics live from the platform and changes nothing on the post or the account; Upload-Post keeps a copy of the result, which later reads of the same post can get from get_cached_post_analytics. Repeated calls for the same post within 5 minutes return the same result; live reads are limited to 100 per 5 minutes. When one platform cannot answer (for example, X's daily limit on live post reads), its entry carries post_metrics_error instead of post_metrics and the other platforms still answer.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_post_analytics"
  }
}

Input Schema

NameRequiredDescriptionDefault
userNoUpload-Post profile name that owns the account. Required with platformPostId.
platformNoPlatform of the post. Required with platformPostId; with requestId it limits the answer to that platform.
requestIdNo`request_id` of an upload made through Upload-Post. Use this OR platformPostId + platform + user.
platformPostIdNoThe post's own id on the platform (e.g. Instagram media id, TikTok video id). Needs `platform` and `user` too.

Output Schema

NameRequiredDescriptionDefault
resultNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.23.0
    • addedInput schema / properties / platform
      Added value: +{
      +  "description": "Platform of the post. Required with platformPostId; with requestId it limits the answer to that platform.",
      +  "enum": [
      +    "instagram",
      +    "tiktok",
      +    "youtube",
      +    "facebook",
      +    "linkedin",
      +    "x",
      +    "threads",
      +    "pinterest",
      +    "reddit",
      +    "bluesky"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / platformPostId
      Added value: +{
      +  "description": "The post's own id on the platform (e.g. Instagram media id, TikTok video id). Needs `platform` and `user` too.",
      +  "type": "string"
      +}
    • addedInput schema / properties / requestId / description
      Added value: +"`request_id` of an upload made through Upload-Post. Use this OR platformPostId + platform + user."
    • addedInput schema / properties / user
      Added value: +{
      +  "description": "Upload-Post profile name that owns the account. Required with platformPostId.",
      +  "type": "string"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "requestId"
      -]
  2. Changed2 schema fields changedv0.11.1
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • removedOutput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
  3. First observedv0.4.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations it discloses rate limits (100 live reads per 5 minutes), 5-minute result deduplication, cache copying, and partial-failure semantics where one platform returns `post_metrics_error` while others still answer. The TikTok draft lifecycle (inbox, private, published publicly) and the resulting field changes are spelled out, which annotations never cover.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose and identification modes, and essentially every sentence carries information an agent could act on. It is one dense block though, and the TikTok draft passage is long enough that it would benefit from being split into a separate edge-case note.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given an output schema exists, the description needn't explain return values, yet its notes on `post_metrics` being platform-specific and `post_metrics_error` fill the gaps that matter. Nothing an agent needs in order to choose the right lookup path or interpret a partial failure is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3; the description adds real meaning on top by establishing the OR-relationship between `requestId` and the `platformPostId`+`platform`+`user` triple and by clarifying that `platform` acts as a filter when `requestId` is used. It stops short of adding format or example values for the ids themselves.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource ("Per-platform metrics for one post") and immediately defines the two mutually exclusive ways to identify the post. It names the sibling get_cached_post_analytics as the cache path, so an agent can distinguish live reads from cached ones without opening another schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit when-to-use for both lookup paths: `requestId` for posts published through Upload-Post vs `platformPostId`+`platform`+`user` for any post on the connected account, including one returned by get_media. It also states when a lookup is no longer possible (TikTok upload >30 days with no post id) and points to get_cached_post_analytics for repeat reads.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools