Skip to main content
Glama

campaigns_list

Returns campaigns ordered by priority desc, then creation time desc.

Archived campaigns are hidden by default. Pass ?state=archived to see only those, ?state=__all__ for everything, or a comma-separated list (?state=active,paused). state is the lifecycle: 0 ACTIVE, 10 PAUSED, 20 COMPLETED, 30 CANCELLED, 40 ARCHIVED; is_active is the derived "currently sending" flag.

Key response fields to inspect:

  • add_limit — UTC-daily cap on NEW leads auto-enroled from the segment. 0 disables automatic enrolment (a common gotcha: a campaign can be is_active=true yet pull no new leads). Manual campaigns_add_leads bypasses the cap.

  • current_add_count / last_add_reset_at — today's counter toward add_limit, resets at UTC midnight.

  • list_stats — {available, added_today, completed, total} for the bound segment. available=0 on an active campaign often means the segment is drained OR add_limit=0.

  • is_autopilot_enabled — if true, messages skip REVIEW_REQUIRED and send straight through.

Method: GET /api/v1/workspaces/{workspace_sqid}/campaigns/

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

Input Schema

NameRequiredDescriptionDefault
qfNoAd-hoc column filters as a JSON array, ANDed on top of the other query parameters. Each entry is `{"field": <key>, "op": <operator>, ...}` where `op` is `in` (with `values`, a `null` element meaning blanks) or one of `=`, `!=`, `>`, `>=`, `<`, `<=`, `contains`, `is empty`, `is not empty` (with `value`, except for the last two). Entries are ANDed; values within one `in` entry are ORed. Example: `[{"field":"is_active","op":"=","value":true}]`.
limitNoNumber of results to return per page.
stateNoLifecycle filter. Omitted: everything except archived. Accepts names or numbers, comma-separated (`active`, `paused`, `completed`, `cancelled`, `archived`), or `__all__` for no filtering.
offsetNoThe initial index from which to return the results.
pinnedNo
searchNoA search term.
orderingNoWhich field to use when ordering the results.
is_activeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full disclosure burden and does it well: default archived suppression, ordering, the state-vs-is_active distinction, and the `add_limit=0` gotcha that keeps a campaign `is_active` but pulling no leads. It stops short of covering pagination behavior, permissions/auth needs, or error cases.

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

Conciseness5/5

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

Front-loaded with the return contract and default filter, then a clearly delimited field-inspection block. The bolded gotchas are dense but each earns its place by preventing a plausible misuse (e.g., assuming an active campaign is enrolling leads).

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?

There is no output schema, so the response-field walkthrough is essential and largely delivered. The remaining gap is the undocumented half of the parameter set (qf, pinned, search, ordering) for an 8-parameter tool, though the schema covers them at 75%.

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 75%, so baseline is 3, but the description adds real meaning: the numeric lifecycle codes (0 ACTIVE through 40 ARCHIVED) that the schema does not enumerate, plus the warning that `is_active` is a derived sending flag rather than the lifecycle state. The other parameters (qf, pinned, search, ordering) get no mention in the description.

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 opening sentence names a specific resource (campaigns) and a specific default ordering (priority desc, then creation time desc), so the agent knows exactly what this tool returns. It is clearly distinguishable from campaigns_get or campaigns_typeahead, which return single/abbreviated results.

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

Usage Guidelines4/5

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

It gives concrete guidance on when to widen the query: archived campaigns are hidden by default and `?state=archived` or `?state=__all__` is the escape hatch. However, it never states when to use this tool versus siblings like `campaigns_facets` or `campaigns_typeahead`, so routing among alternatives is left to inference.

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.