Skip to main content
Glama

update_membership

Modify Webex membership settings by updating roles and visibility. Adjust moderator status and room visibility using the membership ID for precise control.

Instructions

Update a membership in Webex.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
isModeratorYesIndicates if the user is a moderator.
isRoomHiddenYesIndicates if the room is hidden.
membershipIdYesThe unique identifier for the membership.

Implementation Reference

  • The main handler function `executeFunction` that performs the Webex API PUT request to update a membership's isModerator and isRoomHidden properties.
    const executeFunction = async ({ membershipId, isModerator, isRoomHidden }) => {
    
      try {
        // Construct the URL for the membership update
        const url = getWebexUrl(`/memberships/${encodeURIComponent(membershipId)}`);
    
        // Prepare the request body
        const body = JSON.stringify({
          isModerator,
          isRoomHidden
        });
    
        // Set up headers for the request
        const headers = getWebexJsonHeaders();
    
        // Perform the fetch request
        const response = await fetch(url, {
          method: 'PUT',
          headers,
          body
        });
    
        // Check if the response was successful
        if (!response.ok) {
          const errorData = await response.json();
          throw new Error(errorData);
        }
    
        // Parse and return the response data
        const data = await response.json();
        return data;
      } catch (error) {
        console.error('Error updating membership:', error);
        return { error: 'An error occurred while updating the membership.' };
      }
    };
  • Input schema defining the parameters for the update_membership tool, including required membershipId and optional isRoomHidden.
      parameters: {
        type: 'object',
        properties: {
          membershipId: {
            type: 'string',
            description: 'The unique identifier for the membership.'
          },
          isModerator: {
            type: 'boolean',
            description: 'Indicates if the user is a moderator.'
          },
          isRoomHidden: {
            type: 'boolean',
            description: 'Indicates if the room is hidden.'
          }
        },
        required: ['membershipId', 'isModerator']
      }
    }
  • tools/paths.js:39-39 (registration)
    The file path for the update_membership tool is listed in the toolPaths array, which is used to dynamically discover and load tools.
    'webex-public-workspace/webex-messaging/update-a-membership.js',
  • lib/tools.js:7-16 (registration)
    The `discoverTools` function dynamically imports the apiTool from each path in toolPaths, effectively registering all tools including update_membership.
    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);
    }
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 this is an update operation, implying mutation, but doesn't mention permission requirements, whether changes are reversible, error conditions, or what the response looks like. For a mutation tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

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 unnecessary words. It's appropriately sized for a simple update operation and front-loads the essential information.

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?

For a mutation tool with no annotations and no output schema, the description is insufficient. It doesn't cover behavioral aspects like permissions, side effects, or response format, nor does it provide usage guidance. Given the complexity of updating memberships and the lack of structured data, more contextual information would be needed for an agent to use this tool effectively.

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?

Schema description coverage is 100%, so the input schema fully documents all three parameters. The description doesn't add any meaning beyond what the schema provides about parameters, nor does it explain relationships between them. The baseline score of 3 reflects adequate parameter documentation through the schema alone.

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 ('Update') and resource ('a membership in Webex'), making the purpose immediately understandable. However, it doesn't differentiate this tool from its sibling 'update_team_membership' or specify what aspects of a membership can be updated beyond what's implied by the parameters.

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 about when to use this tool versus alternatives like 'create_membership' or 'delete_membership', nor about prerequisites such as needing an existing membership ID. The description offers only the basic function without context for appropriate application.

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