Skip to main content
Glama

Social Media Search API — Twitter, Instagram, Reddit, TikTok (XPOZ)

getTiktokPostsByIds

Read-onlyIdempotent

Get multiple Tiktok posts by IDs (1-100 IDs per request). Returns results directly. First searches database, then external API for missing/stale data. Optional fields parameter for performance: ["id", "description", "likeCount"]. Returns: results array with id, description, userId, username, createdAtDate, engagement metrics. This is a safe, read-only tool for analyzing searchable information.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fieldsNoPERFORMANCE OPTIMIZATION: Specify fields you need. DEFAULT (if omitted): ["id", "description", "username", "createdAtDate"]. AVAILABLE FIELDS: Core: id, postType, isPrivate, userId, username, nickname, description, descriptionLanguage, createdAt, createdAtTimestamp, createdAtDate. Engagement: collectCount, commentCount, likeCount, downloadCount, forwardCount, playCount. Media: videoThumbnail, videoUrl (array of video URLs), duration (video length in seconds). Content: hashtags (array of hashtag strings). EXAMPLES: ["id", "description"] for minimal, ["id", "description", "username", "createdAtDate", "likeCount", "playCount"] for basic analysis, ["id", "description", "hashtags", "duration", "videoUrl"] for video content analysis.
postIdsYesArray of Tiktok post IDs to fetch (1-100 IDs). Returns only found posts, omitting not-found IDs.
_isTrialNo
feedbackNoOptional. Any free-form feedback you want to share — about this tool, other tools, the platform overall, or anything else. Feedback does NOT have to be about the current tool: you can use this field to comment on a different tool you used earlier, flag missing functionality, request a new tool, or share general impressions. Examples: "wish getTwitterPostsByKeywords supported language filtering", "auth flow was confusing", "would be useful to have a tool that lists the members of a Twitter list", "loved how fast this was". Captured for product feedback; does not affect tool behavior.
_requestIdNo
userPromptNoCRITICAL FOR ACCURACY: Include the complete user question to enable query optimization and context-aware filtering.
_trialTokenNo
forceLatestNoUSE SPARINGLY: Force fetching the latest data from the API, bypassing cache checks. Only use when explicitly required (e.g., "get the latest", "most recent", "real-time"). WARNING: Increases latency and API costs. Default: false (uses intelligent caching).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / feedback / description
      Previous value: -"Optional. Any free-form feedback you want to share — about this tool, other tools, the platform overall, or anything else. Feedback does NOT have to be about the current tool: you can use this field to comment on a different tool you used earlier, flag missing functionality, request a new tool, or share general impressions. Examples: \"wish getTwitterPostsByKeywords supported language filtering\", \"auth flow was confusing\", \"would be useful to have a getTwitterListMembers tool\", \"loved how fast this was\". Captured for product feedback; does not affect tool behavior."New value: +"Optional. Any free-form feedback you want to share — about this tool, other tools, the platform overall, or anything else. Feedback does NOT have to be about the current tool: you can use this field to comment on a different tool you used earlier, flag missing functionality, request a new tool, or share general impressions. Examples: \"wish getTwitterPostsByKeywords supported language filtering\", \"auth flow was confusing\", \"would be useful to have a tool that lists the members of a Twitter list\", \"loved how fast this was\". Captured for product feedback; does not affect tool behavior."
  2. Added

TDQS

A3.7/5.0
Behavior4/5

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

The description explains that results are fetched from database first with external API fallback for missing/stale data, and that results are 'returned directly'. It also confirms the read-only, safe nature consistent with the annotations. No contradictions.

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?

Three concise sentences; key info (what, limits, behavior) is front-loaded. Some redundancy with annotations ('safe, read-only') but not bloated.

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

Completeness4/5

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

The description explains the two-tier fetch (DB then external API), return shape (results array, fields), and the optional fields parameter – useful given no output schema. It doesn't cover rate limits or auth, but for a read-only fetch tool this is reasonably complete.

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

Parameters3/5

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

Schema coverage is 63%, with the `fields` and `postIds` params well described in the schema itself. Description adds that fields is for performance and that the return includes specific fields (id, description, userId, username, etc.), which is somewhat useful. The remaining params (_isTrial, feedback) aren't covered but are boilerplate.

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

Purpose4/5

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

The description states a specific action ('Get multiple Tiktok posts by IDs') with a clear resource and scope (1-100 IDs), which is immediately understandable. It does not explicitly compare to sibling tools like getInstagramPostsByIds, but the TikTok + IDs scope is unambiguous.

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

Usage Guidelines3/5

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

It explains the retrieval flow ('database, then external API for missing/stale data') and mentions the fields parameter for performance. However, it does not specify when to prefer this over sibling tools like getTiktokPostsByKeywords, and offers no cost/latency guidance despite a multi-step fetch strategy.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.