Skip to main content
Glama

set_source_visibility

Control source visibility in OBS Studio scenes to show or hide elements during live production or streaming sessions.

Instructions

Show or hide a source in a scene.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scene_nameNoScene name. Omit to use the current program scene.
scene_item_idYesThe sceneItemId from list_sources.
visibleYestrue to show, false to hide.

Implementation Reference

  • The handler implementation for the set_source_visibility tool.
    case "set_source_visibility": {
      let sceneName = args.scene_name;
      if (!sceneName) {
        const { currentProgramSceneName } = await obs.call("GetSceneList");
        sceneName = currentProgramSceneName;
      }
      await obs.call("SetSceneItemEnabled", {
        sceneName,
        sceneItemId: args.scene_item_id,
        sceneItemEnabled: args.visible,
      });
      return ok({
        scene: sceneName,
        scene_item_id: args.scene_item_id,
        visible: args.visible,
      });
  • Tool registration and input schema definition for set_source_visibility.
    name: "set_source_visibility",
    description: "Show or hide a source in a scene.",
    inputSchema: {
      type: "object",
      properties: {
        scene_name: {
          type: "string",
          description: "Scene name. Omit to use the current program scene.",
        },
        scene_item_id: {
          type: "number",
          description: "The sceneItemId from list_sources.",
        },
        visible: {
          type: "boolean",
          description: "true to show, false to hide.",
        },
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It fails to indicate that this is an immediate state mutation (not buffered), whether the change affects active recordings/streams, idempotency characteristics, or error conditions (e.g., invalid scene_item_id). The user must infer this is a write operation from the verb 'set' in the tool name.

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?

At seven words, the description is appropriately terse with zero redundancy. It front-loads the action ('Show or hide') immediately followed by the target ('a source'), achieving maximum information density without extraneous phrases.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a three-parameter mutation tool with 100% input schema coverage but no output schema and no annotations, the description provides minimum viable context. However, given the lack of annotations, it should disclose immediate side effects or persistence guarantees to reach completeness.

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?

Given 100% schema description coverage where scene_item_id references list_sources and visible explains the boolean mapping (true=show, false=hide), the schema adequately documents parameters. The description adds no semantic clarifications beyond the schema, warranting the baseline score of 3 for high-coverage schemas.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Show or hide a source in a scene' provides a specific verb+resource combination that clarifies the boolean nature of the operation (show vs hide) and scopes it to scene contexts. While it clearly distinguishes from sibling scene-switching tools (set_scene), it could be elevated to a 5 by explicitly differentiating from other source-manipulation operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives, nor does it mention prerequisites such as obtaining scene_item_id from list_sources (though the schema documents this). There are no warnings about omitting scene_name or behavior when targeting the current program scene.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LarsCanGit/OBS-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server