npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

portals-mcp

v1.3.7

Published

MCP server that turns AI assistants into game developers — prompt to playable 3D multiplayer browser game on Portals

Readme

portals-mcp

Prompt → playable 3D multiplayer game in the browser.

npm version npm downloads license

portals-mcp is an MCP server that turns Claude, Cursor, and any MCP-capable AI assistant into a game developer on Portals. Describe the game you want; the assistant builds the scene, wires the game logic, generates 3D models, textures, music, and sound effects, and hands you a link anyone can play instantly — multiplayer, in the browser, no engine or build step.

Quick Start

Add portals MCP server to Cursor

Run it directly:

npx -y portals-mcp@latest

Claude Code

claude mcp add portals -- npx -y portals-mcp@latest

Claude Desktop

Add to claude_desktop_config.json (Settings → Developer → Edit Config):

{
  "mcpServers": {
    "portals": {
      "command": "npx",
      "args": ["-y", "portals-mcp@latest"]
    }
  }
}

Cursor

Use the button above, or add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global):

{
  "mcpServers": {
    "portals": {
      "command": "npx",
      "args": ["-y", "portals-mcp@latest"]
    }
  }
}

Environment variables

All optional — with no configuration the server opens a browser sign-in on first use.

| Variable | Required | Description | |----------|----------|-------------| | PORTALS_ACCESS_KEY | No | Portals access key. Set it (e.g. in a .env file next to your project) to skip the browser sign-in prompt. | | PORTALS_ROOM_ID | No | Default room ID used when a tool call doesn't specify one. | | PORTALS_DISABLE_TELEMETRY | No | Set to 1 to disable anonymous usage telemetry. |

First session

  1. Ask your assistant to build something: "Create a mini golf course with a scoreboard." It will call authenticate (browser sign-in) the first time.
  2. Behind the scenes the assistant calls get_context for targeted specs, gotchas, and recipes, and resolve_gameplay_capability / plan_gameplay_mechanic before making platform claims.
  3. Edits land via apply_operations (scoped) or set_room_data (full snapshot); render_scene screenshots let it check its own work.

Tools

51 tools across authentication, marketplace assets, room building, scene design, live-game control, and AI asset generation.

Authentication & Discovery

| Tool | Description | |------|-------------| | authenticate | Authenticate with Portals access key or browser flow | | get_help | Setup/workflow guidance with matching docs resources | | get_context | Returns targeted specs, syntax references, gotchas, recipes, and suggested tools | | lookup | Fast knowledge lookup for items, triggers, effects, systems, recipes | | resolve_gameplay_capability | Classify gameplay requests as supported directly, workaround, unsupported, or unknown | | plan_gameplay_mechanic | Return a compact implementation contract with required capabilities, objects, variables, triggers, validation, risks, and sources | | search_recipes | Search recipe manifest by keywords, tags, and patterns |

Marketplace & Inventory

| Tool | Description | |------|-------------| | search_marketplace | Search the Portals creator marketplace for assets (3D models, sounds, packs) | | get_pack_items | List the items contained in a marketplace pack | | list_marketplace_facets | List marketplace catalogue facets (categories, themes, visual styles, biomes, types) | | get_user_inventory | List assets the signed-in user has claimed or purchased | | claim_marketplace_item | Claim a free marketplace item into the user's inventory | | place_marketplace_items | Claim a batch of marketplace items and compose the ops to place them in the room | | get_room_build_items | List every item available in the room's in-game build palette | | add_to_room_inventory | Add marketplace items or packs to a room's build inventory | | wire_locked_door | Compose the ops to wire a locked-door mechanic between a key item and a door item |

Room Management

| Tool | Description | |------|-------------| | create_room | Create from 18 templates (art-gallery, blank, spaceship, etc.) | | duplicate_room | Clone a room with all data | | get_room_data | Download room snapshot to temp JSON | | inspect_room_data | Summarize room-data counts, item types, variables, triggers/actions, and warnings without dumping full JSON | | simulate_key_input | Audit and simulate OnKeyPressedEvent / OnKeyReleasedEvent mappings against a snapshot | | simulate_trigger_zone_input | Audit and simulate Trigger pressBtn / keyCode press-inside-zone behavior | | query_room | Query room data for specific items, logic, or structure | | update_room_settings | Modify name, description, image, privacy, loading screens | | set_room_settings | Update only scene settings (lighting, skybox, fog, movement, avatars, voice chat) |

Building

| Tool | Description | |------|-------------| | set_room_data | Replace entire room data (full snapshot) | | apply_operations | Targeted ops: add_item, modify_item, remove_item, add_logic_task, clear_logic_tasks, add_quest, remove_quest, add_component |

Assets

| Tool | Description | |------|-------------| | upload_glb | Upload one .glb file or all .glb files in a folder | | upload_image | Upload one image file or all supported image files in a folder |

Scene Design

| Tool | Description | |------|-------------| | analyze_scene | Spatial composition analysis — zones, relationships, design checks | | render_scene | Screenshot of the live 3D scene via the game's MCP camera | | compare_scene | Before/after snapshot diff | | position_camera | Compute optimal camera placement to frame one or more items | | record_video | Record a video fly-through from a CameraObject |

Live Game Connection

| Tool | Description | |------|-------------| | connect_to_game | Connect to a live game client via WebSocket bridge | | poll_game_events | Poll for events from the live game (Ctrl+Click items, Shift+Click locations) | | change_task_state | Activate, complete, or reset tasks in a live game | | get_runtime_data | Fetch live runtime variables and JS effector results |

AI-Generated Assets

| Tool | Description | |------|-------------| | text_to_3d_model | Generate a 3D model from text | | image_to_3d_model | Generate a 3D model from an image | | check_3d_model_task | Poll 3D model generation status | | list_generated_3d_models | List generated 3D models for the current user | | generate_ai_image | Generate an image from a text prompt | | list_generated_images | List generated images for the current user | | generate_ai_texture | Generate a seamless PBR texture from a text prompt | | list_generated_textures | List generated textures for the current user | | text_to_speech | Generate speech audio | | list_voices | List available text-to-speech voices | | generate_sound_effect | Generate sound effect audio | | generate_music | Generate an instrumental or vocal music track from a text prompt | | list_generated_sounds | List generated sounds for the current user |

Resources

The server bundles ~148 docs:// resources covering item specs, workflow guides, recipes, harness grounding data, and more. Resources are served from the package — no external docs repo required.

| Category | URI Pattern | Count | Examples | |----------|-------------|-------|----------| | Reference specs | docs://ref/* | 40 | 26 item specs, systems, interactions, components | | Extended reference | docs://reference/* | 17 | Full API docs, cameras, movement, quests | | Python tools & libs | docs://python/* | 27 | apply_ops, query_room, portals_core, portals_effects | | Recipes | docs://recipes/* | 18 | Dice roll, board game, keypad, side-scroller, leaderboard, cutscene camera | | Workflows | docs://workflows/* | 13 | Scene design, validation, quality review, asset pipeline | | Indexes | docs://index/* | 5 | Items, triggers, effects, knowledge map | | Logic & scripting | docs://logic/* | 5 | JS reference, expressions, multiplayer, string variables | | Guides | docs://guide/* | 3 | Rules & conventions, workflow steps | | AI bootstrap | docs://ai/* | 3 | Execution policy, tool output contracts | | Harness grounding | docs://harness/* | — | Capabilities, limitations, patterns, response contract, eval fixtures | | Architecture | docs://architecture/* | — | Harness architecture assessment and migration plan | | Usage rules | docs://usage-rules | 1 | Tool roles & error handling | | Catalog | docs://catalog | — | JSON index of all resource URIs |

Testing

npm test
npm run build
npm run test:mcp-client

Harness-specific checks:

npm run check:harness
npm run check:harness-package
npm run eval:harness

Shared Harness Core

The harness grounding layer is available as an independently buildable package under packages/harness-core:

import { resolveGameDevRequest } from "@portals/harness-core";

The MCP package also exposes a compatibility subpath:

import { resolveGameDevRequest } from "portals-mcp/harness-core";

Use @portals/harness-core as the target dependency for product-native harness services once it is published or wired internally.

License

ISC