Skip to main content
Glama

chat

One conversational turn, for an agent relaying a person's words. It either asks ONE clarifying question (action "clarify"), answers about delivered hooks or the tool (action "answer", run null, no credits), or starts a research run (action "research", with the started run under "run"), exactly like POST /v1/chat. Every response has suggestions: 0 to 4 follow-ups, [] for research.

A deck size typed into the message ("..., 15 hooks") and a recency phrase ("this
month", "last week") set the run's count and posted_within_days; the count argument
sets the deck size when the message states none. Asked to make one of
the conversation's hooks yours for a niche ("make hook 2 mine for dentists"), the turn
writes lines from that hook's structure (1 credit, like remix_hook) and answers them
labelled, the full result under "remix".

language and country select the search locale: omitted or null keeps the current
conversation setting; a value sets it for this and later turns; an empty string
clears it to any language / any country. The picker wins over the message's locale;
replies stay in the language the person writes in. Invalid locale: 422 invalid_request.

message is 1 to 4000 characters. Pass conversation_id from an earlier turn to keep
the context; leave it out to start a conversation. Cost: a turn itself is free but is
a model call, so turns are limited per account per hour (429 rate_limited); a turn
that starts a run reserves credits like find_hooks. Next step: on "research", call
get_run with run.run_id and wait_seconds=50. Errors: 503 model_unavailable when the
model is down (nothing charged, try again), 402 insufficient_credits. For direct
research without the question step, call find_hooks instead. Needs the write
permission, and research for a turn that starts a run (403 insufficient_scope, nothing
reserved).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "message": "<message>"
    },
    "name": "chat"
  }
}

Input Schema

NameRequiredDescriptionDefault
countNohow many hooks a run this turn starts should deliver, 1 to 30; a size typed into the message ("15 hooks") wins over it, and it wins over the turn's own guess; null or omitted lets the turn decide. Fewer hooks is a faster, cheaper run
api_keyNo
countryNooptional: only clips from creators in this country, as an assigned ISO 3166-1 alpha-2 code: MA, EG, BR, US (UK is read as GB). For a region that is not a country, send its country's code and name the regional variety in language: Quebec is country CA with language "Quebec French", Flanders BE with "Flemish", Catalonia ES with "Catalan". The country places the TikTok search there; the language judge does the regional filtering, and Instagram reports no country. A country alone does not restrict the language. For chat, omitted or null keeps the conversation's current setting; a value sets it for this and later turns; the empty string clears it back to any language / any country.
messageYes
languageNooptional, up to 60 characters: only clips spoken or written in this language or dialect, in words or as a tag: "Moroccan Darija", "ar-MA", "Egyptian Arabic", "Brazilian Portuguese". Any language works, including a regional variety ("Quebec French", "Flemish", "Catalan") and a mixed, code-switched one ("Hinglish", "Taglish", "Moroccan Darija with French"), or two joined by "or" ("Tagalog or Taglish"). The value is handed to the judges exactly as written; how well they honour a mixed or either-of value is not measured yet. Saying it inside topic works too; this field wins when both are given. For chat, omitted or null keeps the conversation's current setting; a value sets it for this and later turns; the empty string clears it back to any language / any country.
platformsNosince 2026-10-10: optional, which platforms to search and deliver from, a non-empty list of "tiktok", "instagram" and "youtube" (YouTube Shorts); left out (or all three) searches the currently available platforms. GET /health/deep lists any skipped ones. ["instagram"] delivers Instagram reels only. Names are read without regard to case and a repeat counts once; an empty list or any other name is 422 naming platforms. The run echoes it as `platforms`.
seed_hook_idsNosince 2026-10-01: optional, up to 10 hook ids from your runs (a kept hook from GET /v1/keeps, or any hook you can read): "find more like these". The engine reads their lines, topics, creators and languages to steer the search phrases and the creators it expands; a seed is never delivered again. An id that is not one of your hooks is 422.
conversation_idNo
idempotency_keyNoretry safely: a turn that started a run with this key within 24 hours answers that run again, no model call, nothing reserved
posted_within_daysNosince 2026-10-01: optional, how recent the clips must be, as days: 7, 30, 90, 365. The search asks the platforms for that window and the floor for a clip under 7 days old uses views per day (10,000 a day passes); null or left out means any time. A clip's `posted_at` and `age_days` say what the run found. For chat (the recency chip): omitted keeps the conversation's current setting; 7, 30, 90 or 365 sets it for this and later turns and wins over a recency phrase in the message; an explicit null on REST, or 0 on either door, clears it back to any time.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / platforms / description
      Previous value: -"since 2026-10-10: optional, which platforms to search and deliver from, a non-empty list of \"tiktok\", \"instagram\" and \"youtube\" (YouTube Shorts); left out (or all three) searches all three. [\"instagram\"] delivers Instagram reels only. Names are read without regard to case and a repeat counts once; an empty list or any other name is 422 naming platforms. The run echoes it as `platforms`."New value: +"since 2026-10-10: optional, which platforms to search and deliver from, a non-empty list of \"tiktok\", \"instagram\" and \"youtube\" (YouTube Shorts); left out (or all three) searches the currently available platforms. GET /health/deep lists any skipped ones. [\"instagram\"] delivers Instagram reels only. Names are read without regard to case and a repeat counts once; an empty list or any other name is 422 naming platforms. The run echoes it as `platforms`."
  2. Changed1 schema field changed
    • addedInput schema / properties / platforms
      Added value: +{
      +  "default": null,
      +  "description": "since 2026-10-10: optional, which platforms to search and deliver from, a non-empty list of \"tiktok\", \"instagram\" and \"youtube\" (YouTube Shorts); left out (or all three) searches all three. [\"instagram\"] delivers Instagram reels only. Names are read without regard to case and a repeat counts once; an empty list or any other name is 422 naming platforms. The run echoes it as `platforms`.",
      +  "examples": [
      +    [
      +      "instagram"
      +    ]
      +  ],
      +  "items": {
      +    "enum": [
      +      "tiktok",
      +      "instagram",
      +      "youtube"
      +    ],
      +    "type": "string"
      +  },
      +  "maxItems": 3,
      +  "minItems": 1,
      +  "title": "Platforms",
      +  "type": [
      +    "array",
      +    "null"
      +  ],
      +  "uniqueItems": true
      +}
  3. Changed1 schema field changed
    • addedInput schema / properties / count
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maximum": 30,
      +      "minimum": 1,
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "how many hooks a run this turn starts should deliver, 1 to 30; a size typed into the message (\"15 hooks\") wins over it, and it wins over the turn's own guess; null or omitted lets the turn decide. Fewer hooks is a faster, cheaper run",
      +  "title": "Count"
      +}
  4. Changed2 schema fields changed
    • addedInput schema / properties / posted_within_days
      Added value: +{
      +  "default": null,
      +  "description": "since 2026-10-01: optional, how recent the clips must be, as days: 7, 30, 90, 365. The search asks the platforms for that window and the floor for a clip under 7 days old uses views per day (10,000 a day passes); null or left out means any time. A clip's `posted_at` and `age_days` say what the run found. For chat (the recency chip): omitted keeps the conversation's current setting; 7, 30, 90 or 365 sets it for this and later turns and wins over a recency phrase in the message; an explicit null on REST, or 0 on either door, clears it back to any time.",
      +  "enum": [
      +    7,
      +    30,
      +    90,
      +    365,
      +    0,
      +    null
      +  ],
      +  "title": "Posted Within Days",
      +  "type": [
      +    "integer",
      +    "null"
      +  ]
      +}
    • addedInput schema / properties / seed_hook_ids
      Added value: +{
      +  "default": null,
      +  "description": "since 2026-10-01: optional, up to 10 hook ids from your runs (a kept hook from GET /v1/keeps, or any hook you can read): \"find more like these\". The engine reads their lines, topics, creators and languages to steer the search phrases and the creators it expands; a seed is never delivered again. An id that is not one of your hooks is 422.",
      +  "items": {
      +    "format": "uuid",
      +    "type": "string"
      +  },
      +  "maxItems": 10,
      +  "title": "Seed Hook Ids",
      +  "type": [
      +    "array",
      +    "null"
      +  ],
      +  "uniqueItems": true
      +}
  5. Changed3 schema fields changed
    • addedInput schema / properties / country
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "optional: only clips from creators in this country, as an assigned ISO 3166-1 alpha-2 code: MA, EG, BR, US (UK is read as GB). For a region that is not a country, send its country's code and name the regional variety in language: Quebec is country CA with language \"Quebec French\", Flanders BE with \"Flemish\", Catalonia ES with \"Catalan\". The country places the TikTok search there; the language judge does the regional filtering, and Instagram reports no country. A country alone does not restrict the language. For chat, omitted or null keeps the conversation's current setting; a value sets it for this and later turns; the empty string clears it back to any language / any country.",
      +  "examples": [
      +    "MA"
      +  ],
      +  "pattern": "^[A-Za-z]{2}$",
      +  "title": "Country"
      +}
    • addedInput schema / properties / idempotency_key
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "retry safely: a turn that started a run with this key within 24 hours answers that run again, no model call, nothing reserved",
      +  "title": "Idempotency Key"
      +}
    • addedInput schema / properties / language
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "optional, up to 60 characters: only clips spoken or written in this language or dialect, in words or as a tag: \"Moroccan Darija\", \"ar-MA\", \"Egyptian Arabic\", \"Brazilian Portuguese\". Any language works, including a regional variety (\"Quebec French\", \"Flemish\", \"Catalan\") and a mixed, code-switched one (\"Hinglish\", \"Taglish\", \"Moroccan Darija with French\"), or two joined by \"or\" (\"Tagalog or Taglish\"). The value is handed to the judges exactly as written; how well they honour a mixed or either-of value is not measured yet. Saying it inside topic works too; this field wins when both are given. For chat, omitted or null keeps the conversation's current setting; a value sets it for this and later turns; the empty string clears it back to any language / any country.",
      +  "examples": [
      +    "Moroccan Darija"
      +  ],
      +  "maxLength": 60,
      +  "title": "Language"
      +}
  6. First observed

TDQS

A4.8/5.0
Behavior5/5

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

No annotations exist, and the description carries the full burden: a turn is free but is a model call limited per account per hour (429 rate_limited), a research turn reserves credits like find_hooks, and 503/402/403 are enumerated with what is charged or reserved in each case. It additionally discloses locale statefulness (a value persists to later turns; empty string clears it) and that the picker beats the message.

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 the three action modes, then ordered by cost, next step, errors, and alternatives. It is dense and runs long, and the locale-clearing rules are repeated almost verbatim from the language and country schema fields, which is the one place sentences do not fully earn their place.

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, stateful, credit-affecting tool with no annotations, the description covers everything an agent needs: mode selection, conversation continuity, locale and recency stickiness, cost and rate limits, permission requirements, and the follow-up call. The output schema covers return shape, so the description is not obligated to explain it.

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?

At 70% schema coverage, the description adds cross-parameter precedence the schema states only in fragments: a count typed in the message beats the count argument, which beats the turn's own guess, and a recency phrase sets posted_within_days. It also supplies semantics for the undocumented conversation_id ("pass from an earlier turn to keep the context; leave it out to start a conversation") and the message length bound.

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?

States a specific verb+resource ("One conversational turn, for an agent relaying a person's words") and enumerates the three outcomes it can produce: clarify, answer, research. It explicitly bounds itself against siblings, naming find_hooks for direct research and remix_hook for the cost model of the remix path.

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?

Gives concrete when-to-use routing ("For direct research without the question step, call find_hooks instead") and an explicit next step on the research path: "call get_run with run.run_id and wait_seconds=50". It also names the no-cost answer mode ("run null, no credits"), so the agent knows how to avoid spending credits.

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