Skip to main content
Glama

get_room_details

Retrieve detailed information about a specific room using its unique ID, enabling integration with Cisco Webex messaging capabilities for enhanced collaboration and data access.

Instructions

Get details of a room by ID.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
roomIdYesThe unique identifier for the room.

Implementation Reference

  • The main handler function that executes the tool logic: fetches room details from Webex API endpoint `/rooms/{roomId}` using GET request with authentication headers, handles errors, and returns the data or error object.
    const executeFunction = async ({ roomId }) => {
    
      try {
        // Construct the URL with the roomId
        const url = getWebexUrl(`/rooms/${encodeURIComponent(roomId)}`);
    
        // Set up headers for the request
        const headers = getWebexHeaders();
    
        // Perform the fetch request
        const response = await fetch(url, {
          method: 'GET',
          headers
        });
    
        // Check if the response was successful
        if (!response.ok) {
          const errorText = await response.text();
          let errorMessage = `HTTP ${response.status}: ${response.statusText}`;
          try {
            const errorData = JSON.parse(errorText);
            errorMessage = errorData.message || errorData.error || JSON.stringify(errorData);
          } catch (e) {
            errorMessage = errorText || errorMessage;
          }
          throw new Error(errorMessage);
        }
    
        // Parse and return the response data
        const data = await response.json();
        return data;
      } catch (error) {
        console.error('Error getting room details:', error);
        return { error: 'An error occurred while getting room details.' };
      }
    };
  • The apiTool object defining the tool's schema: name 'get_room_details', description, input parameters schema (roomId: string, required), and references the handler function.
    const apiTool = {
      function: executeFunction,
      definition: {
        type: 'function',
        function: {
          name: 'get_room_details',
          description: 'Get details of a room by ID.',
          parameters: {
            type: 'object',
            properties: {
              roomId: {
                type: 'string',
                description: 'The unique identifier for the room.'
              }
            },
            required: ['roomId']
          }
        }
      }
    };
  • lib/tools.js:7-16 (registration)
    The discoverTools function that registers all tools by dynamically importing modules from toolPaths (including get-room-details.js) and collecting their apiTool definitions.
    export async function discoverTools() {
      const toolPromises = toolPaths.map(async (file) => {
        const module = await import(`../tools/${file}`);
        return {
          ...module.apiTool,
          path: file,
        };
      });
      return Promise.all(toolPromises);
    }
  • tools/paths.js:6-6 (registration)
    The toolPaths array entry that includes the path to the get_room_details tool file, used by discoverTools for registration.
    'webex-public-workspace/webex-messaging/get-room-details.js',
  • Import of helper functions getWebexUrl and getWebexHeaders from webex-config.js, used to construct API URL and authentication headers.
    import { getWebexUrl, getWebexHeaders } from '../../../lib/webex-config.js';
    /**
     * Function to get room details from Webex.
     *
     * @param {Object} args - Arguments for the room details request.
     * @param {string} args.roomId - The unique identifier for the room.
     * @returns {Promise<Object>} - The details of the room.
     */
    const executeFunction = async ({ roomId }) => {
    
      try {
        // Construct the URL with the roomId
        const url = getWebexUrl(`/rooms/${encodeURIComponent(roomId)}`);
    
        // Set up headers for the request
        const headers = getWebexHeaders();
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states a read operation ('Get details'), which implies safety, but doesn't cover aspects like authentication needs, rate limits, error handling, or what details are returned, leaving significant gaps for a tool with no annotation support.

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, efficient sentence that directly states the tool's purpose without any wasted words. It's appropriately sized and front-loaded, making it easy to parse quickly.

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 annotations and output schema, the description is incomplete. It doesn't explain what details are returned, potential errors, or behavioral traits like idempotency. For a read operation with no structured support, more context is needed to adequately guide the agent.

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?

The schema description coverage is 100%, with the parameter 'roomId' documented as 'The unique identifier for the room.' The description adds no additional meaning beyond this, such as format examples or constraints, so it meets the baseline of 3 where the schema does the heavy lifting.

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 clearly states the action ('Get details') and resource ('room by ID'), making the purpose understandable. However, it doesn't differentiate from sibling tools like 'get_room_meeting_details' or 'list_rooms', which would require more specificity to earn a 5.

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?

No guidance is provided on when to use this tool versus alternatives like 'list_rooms' or 'get_room_meeting_details'. The description lacks context about prerequisites, such as needing a specific room ID, or exclusions, leaving the agent without usage direction.

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

Related 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/Kashyap-AI-ML-Solutions/webex-messaging-mcp-server'

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