Skip to main content
Glama
in2out

Mattermost S MCP

by in2out

mattermost_set_default

Set a specified channel as the default webhook for sending messages to Mattermost through MCP integration.

Instructions

지정한 채널을 기본 웹훅으로 설정합니다.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
channelYes기본으로 설정할 채널명

Implementation Reference

  • The handler function that validates the channel, checks if it exists in config, sets it as default_channel, saves the config, and returns a success message.
    async setDefault(channel) {
      if (!channel || typeof channel !== "string") {
        throw new Error("channel 인자가 필요합니다.");
      }
    
      const config = this.loadConfig();
      const channelExists = config.webhooks.some((w) => w.channel === channel);
    
      if (!channelExists) {
        throw new Error(`등록되지 않은 채널입니다: ${channel}`);
      }
    
      config.default_channel = channel;
      this.saveConfig(config);
    
      return {
        content: [
          {
            type: "text",
            text: `기본 채널이 '${channel}' 으로 설정되었습니다.`,
          },
        ],
      };
    }
  • Input schema defining the required 'channel' string parameter for the tool.
    inputSchema: {
      type: "object",
      properties: {
        channel: {
          type: "string",
          description: "기본으로 설정할 채널명",
        },
      },
      required: ["channel"],
    },
  • index.js:85-98 (registration)
    Tool definition registered in the ListToolsRequest handler, including name, description, and input schema.
    {
      name: "mattermost_set_default",
      description: "지정한 채널을 기본 웹훅으로 설정합니다.",
      inputSchema: {
        type: "object",
        properties: {
          channel: {
            type: "string",
            description: "기본으로 설정할 채널명",
          },
        },
        required: ["channel"],
      },
    },
  • index.js:128-130 (registration)
    Dispatch to the setDefault handler in the CallToolRequest switch statement.
    case "mattermost_set_default":
      return await this.setDefault(args.channel);

Tool Definition Quality

Score is being calculated. Check back soon.

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/in2out/mattermost-s-mcp'

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