Skip to main content
Glama
itrimble

Moom MCP Server

by itrimble

create_custom_grid_layout

Define custom window grid layouts for high-resolution displays by specifying columns and rows, enabling precise window arrangement on macOS.

Instructions

Create a custom grid layout (e.g., 3x2, 4x3) for high-res displays

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
layoutNameYesName for the grid layout
columnsYesNumber of columns in the grid
rowsYesNumber of rows in the grid

Implementation Reference

  • The main handler function for the 'create_custom_grid_layout' tool. It executes an AppleScript to display a notification as a placeholder implementation, noting that the full grid layout feature is coming soon.
    async createCustomGridLayout(layoutName, columns, rows) {
      const script = `
        tell application "Moom"
          -- This would require Moom's grid API or custom positioning
          -- For now, we'll create a notification
          display notification "Grid layout ${columns}x${rows} would be created here" with title "${layoutName}"
        end tell
      `;
    
      try {
        await this.runAppleScript(script);
        return {
          content: [{
            type: 'text',
            text: `Grid layout feature coming soon. For now, use Moom's built-in grid with ${columns}x${rows} dimensions.`
          }]
        };
      } catch (error) {
        return {
          content: [{
            type: 'text',
            text: `Error: ${error.message}`
          }]
        };
      }
    }
  • Input schema defining the parameters for the 'create_custom_grid_layout' tool: layoutName (string), columns (integer), rows (integer).
    inputSchema: {
      type: 'object',
      properties: {
        layoutName: {
          type: 'string',
          description: 'Name for the grid layout',
        },
        columns: {
          type: 'integer',
          description: 'Number of columns in the grid',
        },
        rows: {
          type: 'integer',
          description: 'Number of rows in the grid',
        },
      },
      required: ['layoutName', 'columns', 'rows'],
    },
  • src/index.js:106-127 (registration)
    Tool registration in the ListTools response, including name, description, and input schema.
    {
      name: 'create_custom_grid_layout',
      description: 'Create a custom grid layout (e.g., 3x2, 4x3) for high-res displays',
      inputSchema: {
        type: 'object',
        properties: {
          layoutName: {
            type: 'string',
            description: 'Name for the grid layout',
          },
          columns: {
            type: 'integer',
            description: 'Number of columns in the grid',
          },
          rows: {
            type: 'integer',
            description: 'Number of rows in the grid',
          },
        },
        required: ['layoutName', 'columns', 'rows'],
      },
    },
  • src/index.js:221-222 (registration)
    Dispatch case in the CallToolRequest handler that routes to the createCustomGridLayout method.
    case 'create_custom_grid_layout':
      return await this.createCustomGridLayout(args.layoutName, args.columns, args.rows);

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/itrimble/moom-mcp'

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