Skip to main content
Glama
Firenook

Firenook

Official

pubsub_publish

Destructive

Publish a message to a Pub/Sub emulator topic to trigger subscribed functions, passing string data, JSON payload text, and attributes.

Instructions

Publish one message to a Pub/Sub emulator topic: string data as given, other JSON as its text (base64-encoded on the wire), plus attributes; the functions subscribed to it run. To read a subscription's backlog without consuming it, use pubsub_peek; to run a scheduled function, schedules_run.

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": {
      "topic": "<topic>"
    },
    "name": "pubsub_publish"
  }
}

Input Schema

NameRequiredDescriptionDefault
dataNoMessage data
topicYesTopic name (or projects/<p>/topics/<name>)
attributesNoString attributes
orderingKeyNoOrdering key

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.1

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false and idempotentHint=false, so the safety profile is covered. The description adds real behavioral context beyond that: JSON values are sent as text and base64-encoded on the wire, and, crucially, subscribed functions run as a side effect. It still omits failure behavior for a missing topic and whether a message ID is returned.

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?

Two sentences, front-loaded with the action and followed by routing guidance; every clause carries information. The first sentence is dense with three separate clauses about data encoding, but none is filler.

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?

For a mutating publish tool with no output schema, the description covers the encoding rules and the downstream side effect, which are the pieces an agent most needs. It stops short of delivery semantics for orderingKey and error conditions, which keeps it just under fully complete.

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 baseline would be 3, but the description genuinely adds meaning: data is sent verbatim for strings and as JSON text otherwise, and attributes are attached to the message. Ordering key and the accepted topic name form are left to the schema.

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 gives a specific verb and resource ('Publish one message to a Pub/Sub emulator topic'), scopes it to the emulator, and explicitly distinguishes it from pubsub_peek and schedules_run. An agent can tell what this does and what it is not without opening the 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?

It names two concrete alternatives with the conditions that select them: pubsub_peek for reading a subscription backlog without consuming it, and schedules_run for running a scheduled function. That is explicit when-to-use routing rather than implied context.

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