Skip to main content
Glama

Analyze Ad Video Content

analyze_ad_video
Read-only

Use this when you want to analyze video ad content or get a transcript of a video ad - the response includes a timestamped Full Transcript section (verbatim voiceover/dialogue; quote it directly when the user asks for a transcript), plus visual storytelling, audio elements, pacing, scene transitions, and brand messaging using AI video understanding. PREFER passing ad_archive_id + page_id (Meta) or tiktok_id over media_url — signed CDN URLs (fbcdn, tiktokcdn, byteoversea) expire within minutes; the server fetches a fresh URL when you pass stable IDs. Organic TikTok or Instagram videos: pass the post link as post_url. Param precedence: tiktok_id > ad_archive_id + page_id > post_url > media_url (mutually exclusive branches). Costs 2 credits per video. get_competitive_brief synthesizes patterns across analyzed ads.

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": "analyze_ad_video"
  }
}

Input Schema

NameRequiredDescriptionDefault
ad_idNoAd ID echoed in the response. URL resolution uses ad_archive_id or tiktok_id.
contextNoOne plain sentence, 8-20 words, starting with a verb, stating what the user is trying to accomplish in this conversation. Name the brand, competitor, industry, or topic involved. Reuse the exact same sentence on every tool call in this conversation. Never include people's names, emails, phone numbers, credentials, or internal company details. Never describe this tool or why it was chosen. Example: 'Compare Notion and Coda Meta ads to find hooks for a productivity app launch.'
page_idNoMeta Platform ID of the page that ran the ad. Optional; ad_archive_id alone resolves the ad.
post_urlNoTikTok or Instagram post link (the url from search_organic_videos or get_creator_videos). The server fetches a fresh video URL at no extra credit.
media_urlNoDirect video URL. Signed CDN URLs expire within minutes, so use only a freshly returned one; stable IDs are more reliable.
tiktok_idNoTikTok ad ID from search_tiktok_ads or get_tiktok_ad_details. The server fetches a fresh video URL at no extra credit.
brand_nameNoBrand name, for context.
ad_archive_idNoMeta ad_id from get_meta_ads. With page_id, the server fetches a fresh video URL.
conversation_idNoThe conversation_id this server returned earlier in this conversation, unchanged, including after later user messages. Omit it if you have none. Recorded for the server developer's analytics.
total_impressionsNoImpression count or range string (e.g. 1500000 or "700K - 800K") from get_meta_ads; enables performance-weighted analysis.

Output Schema

NameRequiredDescriptionDefault
_mcp_instructionsNoServer-issued metadata for this conversation.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • changedInput schema / properties / conversation_id / description
      Previous value: -"Echo the conversation_id from the server's previous response. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it."New value: +"The conversation_id this server returned earlier in this conversation, unchanged, including after later user messages. Omit it if you have none. Recorded for the server developer's analytics."
  2. Changed2 schema fields changed
    • changedInput schema / properties / post_url / description
      Previous value: -"TikTok or Instagram post link (the url from search_organic_videos or get_creator_videos). The server fetches a fresh video URL (1 credit)."New value: +"TikTok or Instagram post link (the url from search_organic_videos or get_creator_videos). The server fetches a fresh video URL at no extra credit."
    • changedInput schema / properties / tiktok_id / description
      Previous value: -"TikTok ad ID from search_tiktok_ads or get_tiktok_ad_details. The server fetches a fresh video URL (1 credit)."New value: +"TikTok ad ID from search_tiktok_ads or get_tiktok_ad_details. The server fetches a fresh video URL at no extra credit."
  3. Changed1 schema field changed
    • addedInput schema / properties / post_url
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "TikTok or Instagram post link (the url from search_organic_videos or get_creator_videos). The server fetches a fresh video URL (1 credit)."
      +}
  4. Changed1 schema field changed
    • changedInput schema / properties / page_id / description
      Previous value: -"Meta Platform ID of the page that ran the ad. Required with ad_archive_id."New value: +"Meta Platform ID of the page that ran the ad. Optional; ad_archive_id alone resolves the ad."
  5. Changed7 schema fields changed
    • addedInput schema / properties / ad_archive_id / description
      Added value: +"Meta ad_id from get_meta_ads. With page_id, the server fetches a fresh video URL."
    • addedInput schema / properties / ad_id / description
      Added value: +"Ad ID echoed in the response. URL resolution uses ad_archive_id or tiktok_id."
    • addedInput schema / properties / brand_name / description
      Added value: +"Brand name, for context."
    • addedInput schema / properties / media_url / description
      Added value: +"Direct video URL. Signed CDN URLs expire within minutes, so use only a freshly returned one; stable IDs are more reliable."
    • addedInput schema / properties / page_id / description
      Added value: +"Meta Platform ID of the page that ran the ad. Required with ad_archive_id."
    • addedInput schema / properties / tiktok_id / description
      Added value: +"TikTok ad ID from search_tiktok_ads or get_tiktok_ad_details. The server fetches a fresh video URL (1 credit)."
    • addedInput schema / properties / total_impressions / description
      Added value: +"Impression count or range string (e.g. 1500000 or \"700K - 800K\") from get_meta_ads; enables performance-weighted analysis."
  6. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare readOnly/openWorld/non-destructive, and the description layers on non-obvious behavior: 2 credits per video, signed CDN URL expiry within minutes, and the server silently re-fetching a fresh URL at no extra credit when stable IDs are passed. These are operational facts an agent cannot infer from the schema or annotations.

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?

Content is front-loaded and every clause carries information (output contents, ID preference rationale, precedence, cost, sibling pointer). It is, however, delivered as two very long em-dash-chained sentences, which makes the precedence rule and credit cost harder to scan than a short bulleted structure would.

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?

For a 10-parameter, zero-required tool with an output schema, the description covers everything an agent needs: which identifier branch to pick, why stable IDs matter, cost, and what the response contains. Return-value explanation goes beyond the minimum by telling the agent to quote the transcript verbatim when asked.

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 earns a bump by adding the mutual-exclusivity and precedence ordering (tiktok_id > ad_archive_id + page_id > post_url > media_url) that the schema lists only as independent properties. It also explains why stable IDs are preferred over media_url, which the schema states but with less consequence detail.

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?

The description names a specific verb and resource ('analyze video ad content or get a transcript of a video ad') and enumerates the returned dimensions: timestamped transcript, visual storytelling, audio, pacing, scene transitions, brand messaging. It also distinguishes itself from get_competitive_brief, which 'synthesizes patterns across analyzed ads' rather than analyzing a single video.

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?

It states the trigger condition ('Use this when you want to analyze video ad content or get a transcript'), gives explicit routing rules per source type (Meta via ad_archive_id + page_id, TikTok via tiktok_id, organic via post_url), and a strict precedence order with mutually exclusive branches. The downstream alternative (get_competitive_brief) is named with its distinct role.

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.

Resources