get_contact
Retrieve contact details from Microsoft Outlook by providing a contact ID and account ID using the Microsoft MCP server for efficient management.
Instructions
Get contact details
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| account_id | Yes | ||
| contact_id | Yes |
Implementation Reference
- src/microsoft_mcp/tools.py:652-658 (handler)The handler function decorated with @mcp.tool that implements the logic to retrieve a specific contact by ID using the Microsoft Graph API.@mcp.tool def get_contact(contact_id: str, account_id: str) -> dict[str, Any]: """Get contact details""" result = graph.request("GET", f"/me/contacts/{contact_id}", account_id) if not result: raise ValueError(f"Contact with ID {contact_id} not found") return result
- src/microsoft_mcp/server.py:14-14 (registration)Entry point that runs the FastMCP server instance, thereby registering and serving all tools defined in tools.py including get_contact.mcp.run()
- src/microsoft_mcp/tools.py:8-8 (registration)Creates the FastMCP instance to which all tools, including get_contact, are registered via decorators.mcp = FastMCP("microsoft-mcp")