Skip to main content
Glama
paramount-engineering

Roku Dev Studio MCP Server

Debugger: Attach

debugger_attach
Idempotent

Attach a BrightScript debugger session to a Roku device via port 8081, enabling subsequent debugger operations. Safe to call even if already attached.

Instructions

Open a BrightScript debug session to the Roku on control port 8081. REQUIRED FIRST — every other debugger_* tool needs an attached session. Prefer calling the read-only debugger_status before this one: if it already reports attached/running/stopped, skip this call entirely and go straight to the debugger_* operation you need. The port is only open when the channel was launched with debugging (sideload "with Debugging", or a STOP in the source auto-enables it); a plain sideload/relaunch does NOT open it, and attach returns an actionable error explaining that. Safe to call anyway even when already attached: if a healthy session for this device already exists (e.g. the user attached via the app's own debugger UI), this is a no-op that returns success without touching it — it only tears down and reconnects when there is no session, or the existing one is stale/errored (the control port is single-client, so a doomed reconnect would otherwise kill a working session for nothing). On success returns { ip, state }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
deviceNoOptional. Roku IP or serial; must match a connected Dev Studio tab. Omit to use the focused tab.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.0.2

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint=false, idempotentHint=true), the description reveals important behavioral details: it is a safe no-op when a healthy session exists, it tears down and reconnects only when stale/errored, and it returns an actionable error when the port is closed. The single-client caveat also explains why the tool avoids breaking working sessions. No contradiction with annotations.

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?

The description is longer than average, but every sentence carries operational value: prerequisite status, port conditions, no-op behavior, reconnect semantics, and return shape. It is front-loaded with the core purpose and required-first warning. Slightly dense, but not padded.

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 tool with no output schema and one optional parameter, the description is remarkably complete. It explains preconditions, error conditions, idempotent behavior, side effects, and the success return shape ({ ip, state }). An agent has enough context to invoke it correctly and to decide whether to call it at all.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the single optional 'device' parameter is already fully documented in the schema. The description does not add new parameter-specific semantics beyond the schema, which fits the baseline of 3.

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 uses a specific verb and resource: 'Open a BrightScript debug session to the Roku on control port 8081.' It also clearly distinguishes itself as the required prerequisite for all other debugger_* tools, so an agent can immediately tell it apart from siblings like debugger_status or debugger_continue.

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?

Provides explicit when-to-use guidance: call debugger_status first, and skip attach entirely if already attached/running/stopped. It also explains prerequisites (channel must be launched with debugging) and states that a plain sideload does not open the port, so the agent knows when the tool will fail and how to react.

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