Skip to main content
Glama

Roku MCP

A standalone Model Context Protocol (MCP) server for Roku development. Create projects, look up BrightScript APIs, validate and package channels, run script tests, and capture headless SceneGraph or Draw2D previews.

Uses stdio transport. Requires Node.js 22 or newer and a working native canvas installation. No build step is needed to start the server.

Install

git clone https://github.com/vynxc/roku-mcp.git
cd roku-mcp
npm ci

canvas may need native build prerequisites if a prebuilt binary is unavailable for your platform. Run roku_doctor after connecting to check the runtime and PNG encoder.

Related MCP server: roku-mcp

Connect an MCP client

Add this entry to your client's MCP configuration, replacing both absolute paths:

{
  "mcpServers": {
    "roku": {
      "command": "node",
      "args": [
        "/absolute/path/to/roku-mcp/scripts/mcp.mjs",
        "--workspace",
        "/absolute/path/to/your/roku-projects"
      ]
    }
  }
}

The workspace directory must already exist. The server also accepts ROKU_WORKSPACE; otherwise it uses its working directory. Relative tool paths resolve inside that workspace. Absolute paths must also stay inside it. Diagnostics go to stderr; stdout is reserved for MCP messages.

Tools

Tool

Purpose

roku_doctor

Check dependencies, native PNG support, and simulator capabilities.

roku_project

Create a scenegraph, draw2d, or basic project, or inspect an existing one.

roku_reference

Search the bundled BrightScript type snapshot and guidance topics.

roku_check

Validate BrightScript, BrighterScript, and SceneGraph XML.

roku_build

Validate, transpile, and produce a development ZIP.

roku_test

Run finite .brs scripts with optional literal log assertions.

roku_preview

Run a project, ZIP, or .brs with remote steps and initial/final PNGs.

Start with roku_doctor, create or inspect a project, edit its sources with your client's file tools, then check, build, test, and preview. Each result includes ok; failed calls also set MCP isError. Preview reports include local artifact paths for PNGs and JSON logs.

Example tool arguments:

{"action":"create","project":"my-channel","template":"scenegraph","title":"My Channel"}
{"project":"my-channel","steps":[{"key":"up","wait_ms":100},{"key":"select","wait_ms":100}],"duration_ms":500,"output":"preview-001"}
{"files":["tests/main.brs"],"expect_logs":["TEST_PASS"],"timeout_ms":10000}

Project creation and explicit output paths must be new. Default outputs use unique directories under .roku-artifacts. Preview steps, execution time, logs, archive sizes, and file counts are bounded. Cancellation and connection closure terminate active tool subprocesses.

Limits

This is a simulator, not Roku OS. Hardware validation is still required for playback, DRM, performance, signing, and certification. No physical device discovery, deployment, or control is exposed. Reference data is bundled with BrighterScript and may differ from the current Roku SDK.

Run trusted apps only. Subprocesses inherit the server's OS permissions and environment; simulator apps may make network requests. Workspace path checks and symlink rejection are not an OS sandbox. Configure isolation in your MCP host or operating system when needed. Custom build hooks and file mappings are not executed.

Development

npm ci
npm test
npm run check:roku

Tests build sample ZIPs under dist/, exercise the MCP stdio connection, and cover project validation, packaging, runtime failures, remote input, and PNG output. Runtime implementation lives in src/headless; scripts/roku.mjs is the internal subprocess worker.

MIT licensed. Derived from dsh-roku-dev; original copyright is retained in LICENSE. Uses BrighterScript and the BrightScript simulator; dependencies retain their respective licenses. Not affiliated with Roku.

Available Tools

7 tools
roku_buildA

Build a Roku project into a NEW ZIP; existing output must not be overwritten.

Inputs: project (required), output.

roku_checkB

Check a Roku project; diagnostics and nonzero exit codes indicate failures.

Inputs: project (required).

roku_doctorB

Report installed Roku development capabilities and limitations.

Inputs: no named parameters.

roku_previewA

Preview a project directory, ZIP, or BRS file in the simulator with bounded remote-key steps; output must be a NEW directory.

Inputs: project (required), steps, output, timeout_ms, +3 more.

roku_projectC

Create a NEW Roku project or inspect an existing project; never overwrite an existing project.

Inputs: action (required), project (required), title, template.

roku_referenceB

Search bundled Roku/BrightScript reference material.

Inputs: query (required).

roku_testC

Run BrightScript test files in the headless simulator, not on a physical Roku device.

Inputs: files (required), timeout_ms, expect_logs.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 7 tools

    Disambiguation5/5

    Each tool maps to a distinct phase or resource: environment diagnostics, project create/inspect, static checks, build, tests, reference search, and simulator preview. The closest pair is check vs test, but their descriptions (diagnostics vs running BrightScript tests) clearly separate them.

    Naming Consistency4/5

    All tools share the roku_ prefix and lowercase snake_case, making the set predictable. Minor deviation: roku_project and roku_reference use nouns rather than the imperative verb style of check/build/test/preview, but this is easy to learn.

    Tool Count5/5

    Seven tools is well within the ideal range and each covers a necessary step in the Roku development workflow. The set is neither bloated nor too thin.

    Completeness4/5

    The tools cover the full local Roku project lifecycle: create/inspect, check, build, test, and preview, plus reference and capability reporting. There is no update/delete or device deployment tool, but those may be intentionally out of scope for a simulator-focused MCP.

    Maintenance

    ActivityStale
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      B
      maintenance
      MCP server for Roku BrightScript documentation and device control, enabling doc search, device introspection, keypress/keysequence input, app launch, and sideloading.
      -
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables AI agents to inspect and control Roku devices—query UI elements, send remote input, launch channels, and run tests—using the Model Context Protocol or a CLI.
      17 npm
      6
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Provides AI agents with Roku BrightScript debugging tools, including log reading, scene graph inspection, breakpoint management, variable inspection, and execution control.
      21
      1
      Apache 2.0