Skip to main content
Glama

nevent_quote_campaign

Read-only

Estimate the credit cost and eligible audience of a campaign BEFORE sending it. Read-only pre-flight check against nev-api POST /campaigns/quote — it never debits credits and never sends. Call this after nevent_create_campaign and before nevent_schedule_campaign: scheduling a campaign the tenant cannot afford fails at send time with a 402. Returns cost (credits required), available (credits in the pool), missing (shortfall), recipientCount, affordable (boolean — the gate to check), blocked, unlimited, and an audience block with uniqueAudience, estimatedEligible per channel, eligibleAnyChannel and emailExclusions (no_email / invalid_email / opt_out / unknown). The audience block is null when the estimate could not be computed: a channel mix that combines WhatsApp with another channel (for example EMAIL_AND_WHATSAPP or ALL_CHANNELS), more than 20 segments, a WhatsApp selection too large for the segmentation budget, or a data-api failure/timeout — cost and recipientCount are still valid in that case. A WHATSAPP_ONLY quote IS estimated (by nev-api, with the same eligibility the send applies: consent of the tenant or its descendants, opt-outs, Meta stops and cooldowns, one recipient per phone) and fills extra audience fields: estimatedEligible.whatsapp (recipients that will receive the message), whatsappExclusions (why audience users do NOT receive it, one count per reason) and whatsappConsentSources (list of {tenantId, tenantName, relation SELF|DESCENDANT, recipients}: whose WhatsApp consent authorises the recipients, sending tenant first). Those three are null/absent for every other channel. Use segment_ids from nevent_list_segments; omit them to quote the full addressable audience. Set transactional=true only for genuinely transactional sends (order confirmations, ticket delivery) — it estimates against the TRANSACTIONAL consent mode, which reaches recipients who opted out of marketing.

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": {
      "channel": "<channel>"
    },
    "name": "nevent_quote_campaign"
  }
}

Input Schema

NameRequiredDescriptionDefault
channelYesDelivery channel to quote (nev-api CommunicationChannel enum). Legacy values EMAIL/SMS/WHATSAPP are accepted and mapped to the _ONLY variants. WHATSAPP_ONLY returns a WhatsApp-specific audience estimate; mixes that combine WhatsApp with another channel return a null audience block.
segment_idsNoSegment IDs to quote (optional, max 20). Omit to quote the full addressable audience for the channel. More than 20 segments makes the backend skip the audience estimate.
transactionalNoWhether this is a transactional campaign (default false). Transactional uses the TRANSACTIONAL consent mode for the audience estimate, which reaches recipients who have opted out of marketing.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / channel / description
      Previous value: -"Delivery channel to quote (nev-api CommunicationChannel enum). Legacy values EMAIL/SMS/WHATSAPP are accepted and mapped to the _ONLY variants. Channel mixes involving WhatsApp return a null audience block."New value: +"Delivery channel to quote (nev-api CommunicationChannel enum). Legacy values EMAIL/SMS/WHATSAPP are accepted and mapped to the _ONLY variants. WHATSAPP_ONLY returns a WhatsApp-specific audience estimate; mixes that combine WhatsApp with another channel return a null audience block."
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only declare readOnlyHint/destructiveHint/openWorldHint; the description goes well beyond by asserting it 'never debits credits and never sends', enumerating the returned fields including the 'affordable (boolean — the gate to check)', and listing the precise conditions under which the audience block is null. That is exactly the failure-mode context an agent needs before calling.

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, safety, and call ordering, and every section earns its place given there is no output schema. However, it is a single dense block of ~330 words that would scan far better as a short bulleted list of return fields and null-audience conditions.

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?

With no output schema, the description takes full responsibility for describing the response contract (cost/available/missing/recipientCount/affordable/blocked/unlimited plus the audience block and the WhatsApp-only extra fields) and explains the one call-specific decision point, the transactional flag.

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 schema already carries enum and maxItems detail. The description still adds real meaning: segment_ids should come from nevent_list_segments, omission quotes the full addressable audience, and transactional=true is restricted to 'genuinely transactional sends' with the consent-mode consequence spelled out.

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 ('Estimate the credit cost and eligible audience of a campaign') and immediately scopes it as a 'Read-only pre-flight check against nev-api POST /campaigns/quote'. It explicitly distinguishes itself from the sibling write tools nevent_create_campaign and nevent_schedule_campaign, so an agent can route correctly without opening a 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?

Gives explicit ordering ('after nevent_create_campaign and before nevent_schedule_campaign') plus the concrete consequence of skipping it ('fails at send time with a 402'). It also names the sibling to source input from ('Use segment_ids from nevent_list_segments') and states the omission behavior.

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.