Compose the apply_operations payload to wire a locked-door mechanic between an existing key item and an existing door item in the room. Returns an operations array — does NOT mutate the room. Pass the array to apply_operations to actually apply the wiring. Use this AFTER place_marketplace_items +...
AI agents use wire_locked_door to create or update resources in Portals — usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Portals environment.
| Parameter | Type | Required | Description |
|---|---|---|---|
keyItemId | string | Yes | The roomItem id of the key (must be type=GlbCollectable to be collectible). Get from apply_operations.ids_created after placing it. |
doorItemId | string | Yes | The roomItem id of the door (typically type=GLB). Get from apply_operations.ids_created. |
ensureKeyIsCollectable | boolean | — | If true (default), include a modify_item op that re-types the key item as GlbCollectable. Set false if the key was already placed as GlbCollectable. |
Parameters from the server's own tool schema.
The tool itself only composes/prepares a payload and does not directly mutate state. However, its output is intended to be passed to apply_operations which will write/modify room item configurations (wiring a locked-door mechanic, re-typing items, adding event listeners). This is fundamentally a Write operation that configures game logic between existing room items.
From the tool's definition Returns an operations array — does NOT mutate the room. Pass the array to apply_operations to actually apply the wiring.
Attacks that exploit this kind of access
Compose the apply_operations payload to wire a locked-door mechanic between an existing key item and an existing door item in the room. Returns an operations array — does NOT mutate the room. Pass the array to apply_operations to actually apply the wiring. Use this AFTER place_marketplace_items + apply_operations have placed the key and door, and you have their roomItemIds (from apply_operations.ids_created). Variable-free implementation: the door listens for OnItemCollectedEvent (any GlbCollectable pickup) and hides itself, removing its collider. Re-typing the key as GlbCollectable is required for it to be collectible — emit a separate modify_item op or place the key as GlbCollectable from the start. It is categorised as a Write tool in the Portals MCP Server, which means it can create or modify data. Consider rate limits to prevent runaway writes.
wire_locked_door accepts 3 parameters: keyItemId, doorItemId, ensureKeyIsCollectable. Required: keyItemId, doorItemId. The full parameter table on this page comes from the server's own tool schema.
Register the Portals MCP server in PolicyLayer and add a rule for wire_locked_door: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Portals. Nothing to install.
wire_locked_door is a Write tool with medium risk. Write tools should be rate-limited to prevent accidental bulk modifications.
Yes. Add a rate_limit block to the wire_locked_door rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for wire_locked_door. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
wire_locked_door is provided by the Portals MCP server (portals-mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
Every MCP server has a record like this.
Type a name, get the same breakdown: verified identity, auth posture, risk grade, capabilities, recommended policy.
Teams ship this data inside their own products. See what a licence covers →