Skip to main content
Glama

Wait for a console line to appear

wait_for_console
Read-onlyIdempotent

Block execution until a console line matching a regex appears on the FiveM server or client. Use after fire-and-forget commands to detect startup banners, errors, or RESULT: lines.

Instructions

Block until a line matching a regex appears. 'client' watches the live devcon stream; 'server' polls FIVEM_SERVER_LOG for newly written lines (only lines appended after the call count). Use after a fire-and-forget command, to watch for a resource's startup banner, an error, or a scripted RESULT: line.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
targetYes'server' = the FXServer console (UDP RCON; needs rcon_password). 'client' = the F8 console of a running FiveM Legacy client (devcon 29200/29300) — LOCAL console commands only (connect, quit, tooling); RegisterCommand chat commands are not console commands.
patternYesJS regex, e.g. 'Started resource breeze-chat'
afterSeqNoclient only: ignore lines up to this sequence number
timeoutMsNoDefault 10000

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
seqYes
channelYes
messageYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, so the safety profile is covered. The description adds genuinely useful behavior: the call blocks, 'client' watches a live stream while 'server' polls FIVEM_SERVER_LOG, and only lines appended after the call are considered. It does not describe what a timeout yields, which is the main remaining gap for a blocking tool.

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?

Three sentences, front-loaded with the core action, then the target mechanics, then the usage trigger. Every sentence carries distinct information with no 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?

With an output schema present, return values need not be explained, and the description covers the blocking model and target behavior. The only omission is timeout/partial-result behavior, which matters for a tool that blocks up to timeoutMs.

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, but the description adds meaning beyond it: the stream-vs-poll distinction for 'target' and the 'only lines appended after the call count' semantics that govern afterSeq and the freshness of matches.

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 precise verb+resource+mechanism: 'Block until a line matching a regex appears.' It also distinguishes itself from read-only siblings (read_console, wait) by describing the two observation targets and the streaming-vs-polling model, so an agent can tell what this tool does 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 Guidelines4/5

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

Explicitly says when to reach for it: 'Use after a fire-and-forget command, to watch for a resource's startup banner, an error, or a scripted RESULT: line.' That is concrete triggering context, though it never names a competing sibling (e.g., read_console) or says when not to use it.

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