Skip to main content
Glama
vfa-khuongdv

MCP Chatwork Server

by vfa-khuongdv

list_rooms

Retrieve a list of all Chatwork rooms you belong to, enabling quick overview and management of your conversations.

Instructions

Retrieves a list of Chatwork rooms the user belongs to.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The main tool definition for 'list_rooms'. Contains the executor function that calls client.listRooms() and returns the room list as JSON text content.
    export const listRoomsTool = {
      name: "list_rooms",
      description: "Retrieves a list of Chatwork rooms the user belongs to.",
      schema: ListRoomsSchema,
      executor: async (client: ChatworkClient) => {
        const rooms = await client.listRooms();
        return {
          content: [
            {
              type: "text" as const,
              text: JSON.stringify(rooms, null, 2),
            },
          ],
        };
      },
    };
  • Schema for list_rooms - an empty Zod object (no input parameters required).
    export const ListRoomsSchema = z.object({});
  • src/index.ts:24-32 (registration)
    Registration of the tool in the MCP server using server.tool() with name, description, schema, and handler callback.
    server.tool(
      listRoomsTool.name,
      listRoomsTool.description,
      listRoomsTool.schema.shape,
      async (_args) => {
        // @ts-ignore
        return listRoomsTool.executor(client);
      }
    );
  • Helper method in ChatworkClient that makes the actual HTTP GET request to /rooms and returns ChatworkRoom[] data.
    async listRooms(): Promise<ChatworkRoom[]> {
      try {
        const response = await this.client.get<ChatworkRoom[]>("/rooms");
        return response.data;
      } catch (error) {
        if (axios.isAxiosError(error)) {
          throw new Error(`Chatwork API Error: ${error.message} - ${JSON.stringify(error.response?.data)}`);
        }
        throw error;
      }
    }
  • src/tools/index.ts:1-9 (registration)
    Re-export of listRoomsTool from the tools barrel module.
    export * from "./listRooms.js";
    export * from "./listMessages.js";
    export * from "./sendMessage.js";
    export * from "./getRoomMembers.js";
    export * from "./createTask.js";
    export * from "./getMyTasks.js";
    export * from "./deleteMessage.js";
    export * from "./completeTask.js";
    export * from "./leaveRoom.js";
Behavior2/5

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

With no annotations provided, the description must disclose all behavioral traits. It only states the action without mentioning read-only nature, pagination, ordering, or any side effects. This is insufficient for safe invocation.

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?

The description is a single sentence of 11 words, front-loaded with the verb, and contains no redundant information. It is maximally concise for the information it conveys.

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

Completeness2/5

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

Given the lack of output schema and annotations, the description does not explain what fields are in the returned list (e.g., room IDs, names) or any limitations. This leaves the agent with incomplete information to use the tool effectively.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has no parameters, so the description does not need to explain any. The description adds meaning by clarifying that the list is of rooms the user belongs to, which is useful context beyond the empty schema.

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

Purpose5/5

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

The description clearly specifies the action ('Retrieves'), the resource ('list of Chatwork rooms'), and the scope ('the user belongs to'). It effectively distinguishes this tool from siblings like get_room_members (which retrieves members of a specific room) and list_messages (messages in a room).

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, no prerequisites, and no context about when not to use it. This leaves the agent without decision support.

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/vfa-khuongdv/mcp-chatwork'

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