Skip to main content
Glama

enable_toolset

Activate a tool group in the cesium-mcp server to make its 3D globe control tools available for use. First check available groups with list_toolsets.

Instructions

Enable a tool group to make its tools available. Call list_toolsets first to see available groups.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toolsetYesName of the toolset to enable (e.g. "camera", "animation", "entity-ext")

Implementation Reference

  • The tool handler logic for 'enable_toolset' which validates the toolset name, checks if already enabled, and calls the _enableToolset helper.
    async ({ toolset }) => {
      if (!(toolset in TOOLSETS)) {
        return {
          content: [{ type: 'text' as const, text: `Unknown toolset "${toolset}". Available: ${Object.keys(TOOLSETS).join(', ')}` }],
          isError: true,
        }
      }
      if (_enabledSets.has(toolset)) {
        return { content: [{ type: 'text' as const, text: `Toolset "${toolset}" is already enabled.` }] }
      }
      const added = _enableToolset(toolset)
      server.sendToolListChanged?.()
      return {
        content: [{
          type: 'text' as const,
          text: `Enabled toolset "${toolset}" — ${added.length} new tools available: ${added.join(', ')}`,
        }],
      }
    },
  • The helper function _enableToolset that actually adds the tools to the server and tracks enabled sets.
    function _enableToolset(setName: string): string[] {
      const tools = TOOLSETS[setName]
      if (!tools) return []
      const added: string[] = []
      for (const toolName of tools) {
        if (!_enabledTools.has(toolName)) {
          _enabledTools.add(toolName)
          const def = _toolDefs.get(toolName)
          if (def) {
            ;(server.tool as Function).apply(server, def)
            added.push(toolName)
          }
        }
      }
      _enabledSets.add(setName)
      return added
    }
  • Registration of the 'enable_toolset' tool on the MCP server instance.
    server.tool(
      'enable_toolset',
      'Enable a tool group to make its tools available. Call list_toolsets first to see available groups.',
      {
        toolset: z.string().describe('Name of the toolset to enable (e.g. "camera", "animation", "entity-ext")'),
      },
      async ({ toolset }) => {
        if (!(toolset in TOOLSETS)) {
          return {
            content: [{ type: 'text' as const, text: `Unknown toolset "${toolset}". Available: ${Object.keys(TOOLSETS).join(', ')}` }],
            isError: true,
          }
        }
        if (_enabledSets.has(toolset)) {
          return { content: [{ type: 'text' as const, text: `Toolset "${toolset}" is already enabled.` }] }
        }
        const added = _enableToolset(toolset)
        server.sendToolListChanged?.()
        return {
          content: [{
            type: 'text' as const,
            text: `Enabled toolset "${toolset}" — ${added.length} new tools available: ${added.join(', ')}`,
          }],
        }
      },
    )

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/gaopengbin/cesium-mcp'

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