Skip to main content
Glama
anoopt

Outlook Meetings Scheduler MCP Server

get-event

Retrieve detailed calendar event information using a specific event ID, enabling efficient management and tracking of Outlook meetings.

Instructions

Get details of a calendar event by its ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
eventIdYesID of the event to retrieve

Implementation Reference

  • Executes the 'get-event' tool: authenticates, fetches event from Microsoft Graph API by ID, formats details (subject, times, location, attendees, URL) into markdown text response, handles auth and not-found errors.
        async ({ eventId }) => {
          const { graph, userEmail, authError } = await getGraphConfig();
    
          if (authError) {
            return {
              content: [{ type: "text", text: `🔐 Authentication Required\n\n${authError}\n\nPlease complete the authentication and try again.` }]
            };
          }
      
          // Retrieve the event
          const event = await graph.getEvent(eventId, userEmail);
          
          if (!event) {
            return {
              content: [
                {
                  type: "text",
                  text: "Failed to retrieve the event. The event might not exist or there was an error. Check the logs for details.",
                },
              ],
            };
          }
      
          // Format the result for response
          const eventUrl = event.webLink || "No event URL available";
          const startTime = event.start?.dateTime || "No start time available";
          const endTime = event.end?.dateTime || "No end time available";
          const timeZone = event.start?.timeZone || "No time zone information";
          const location = event.location?.displayName || "No location specified";
          
          // Format attendees if they exist
          let attendeesList = "None";
          if (event.attendees && event.attendees.length > 0) {
            attendeesList = event.attendees.map((a: any) => {
              const name = a.emailAddress?.name || 'No name';
              const email = a.emailAddress?.address || 'No email';
              const type = a.type || 'required';
              return `${name} (${email}) - ${type}`;
            }).join("\n                ");
          }
          
          const successMessage = `
    Calendar event details:
    
    Event ID: ${eventId}
    Subject: ${event.subject || "No subject"}
    Start: ${startTime}
    End: ${endTime}
    Time Zone: ${timeZone}
    Location: ${location}
    User: ${userEmail}
    Attendees: 
    ${attendeesList}
    Event URL: ${eventUrl}
                        `;
      
          return {
            content: [
              {
                type: "text",
                text: successMessage,
              },
            ],
          };
        }
  • Input schema using Zod: requires 'eventId' as string.
    {
      eventId: z.string().describe("ID of the event to retrieve"),
    },
  • Registers the 'get-event' tool on the MCP server via registerTool, providing name, description, input schema, and handler function.
      registerTool(
        server,
        "get-event",
        "Get details of a calendar event by its ID",
        {
          eventId: z.string().describe("ID of the event to retrieve"),
        },
        async ({ eventId }) => {
          const { graph, userEmail, authError } = await getGraphConfig();
    
          if (authError) {
            return {
              content: [{ type: "text", text: `🔐 Authentication Required\n\n${authError}\n\nPlease complete the authentication and try again.` }]
            };
          }
      
          // Retrieve the event
          const event = await graph.getEvent(eventId, userEmail);
          
          if (!event) {
            return {
              content: [
                {
                  type: "text",
                  text: "Failed to retrieve the event. The event might not exist or there was an error. Check the logs for details.",
                },
              ],
            };
          }
      
          // Format the result for response
          const eventUrl = event.webLink || "No event URL available";
          const startTime = event.start?.dateTime || "No start time available";
          const endTime = event.end?.dateTime || "No end time available";
          const timeZone = event.start?.timeZone || "No time zone information";
          const location = event.location?.displayName || "No location specified";
          
          // Format attendees if they exist
          let attendeesList = "None";
          if (event.attendees && event.attendees.length > 0) {
            attendeesList = event.attendees.map((a: any) => {
              const name = a.emailAddress?.name || 'No name';
              const email = a.emailAddress?.address || 'No email';
              const type = a.type || 'required';
              return `${name} (${email}) - ${type}`;
            }).join("\n                ");
          }
          
          const successMessage = `
    Calendar event details:
    
    Event ID: ${eventId}
    Subject: ${event.subject || "No subject"}
    Start: ${startTime}
    End: ${endTime}
    Time Zone: ${timeZone}
    Location: ${location}
    User: ${userEmail}
    Attendees: 
    ${attendeesList}
    Event URL: ${eventUrl}
                        `;
      
          return {
            content: [
              {
                type: "text",
                text: successMessage,
              },
            ],
          };
        }
      );
  • src/index.ts:34-34 (registration)
    Top-level registration call in main server file, invoking registerEventReadTools which includes 'get-event' tool.
    registerEventReadTools(server);
  • Shared helper function providing Microsoft Graph client, user email, and auth error status, used by the handler for API access.
    export async function getGraphConfig() {
Behavior2/5

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

With no annotations, the description carries full burden but only states the basic action. It doesn't disclose behavioral traits like authentication needs, rate limits, error handling, or what details are returned (e.g., title, time, attendees), which is inadequate for a read operation with no output schema.

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 front-loads the purpose without waste. It's appropriately sized for a simple tool, making it easy for an agent 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 no annotations and no output schema, the description is incomplete. It doesn't explain what details are returned (e.g., event properties), potential errors, or usage context, leaving gaps for the agent to infer behavior in a server with multiple event-related tools.

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 schema already documents the 'eventId' parameter. The description adds no additional meaning beyond implying retrieval by ID, which aligns with the schema. Baseline 3 is appropriate as the schema handles parameter documentation.

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 ('calendar event'), specifying it retrieves by ID. However, it doesn't differentiate from sibling tools like 'list-events' or 'find-person' that might also retrieve event information, so it lacks sibling differentiation.

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. For example, it doesn't mention using 'list-events' for multiple events or 'find-person' for person-related queries, leaving the agent without context for selection among siblings.

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/anoopt/outlook-meetings-scheduler-mcp-server'

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