peopleGet
Retrieve contact details by ID from Routine. Simplify access to specific contact information for calendars, tasks, and notes.
Instructions
The contact with the given id.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
Implementation Reference
- src/tools.ts:264-282 (handler)Executes the tool logic: fetches contact data by ID via RPC call to 'people.get' and formats response as JSON text, with error handling.async ({ id }) => { try { const data = await sendRpcRequest("people.get", [id]); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching people.get: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } }
- src/tools.ts:259-263 (schema)Zod input schema requiring a string 'id' parameter for the people ID.{ /* {"$id":"#people-id","$schema":"https://json-schema.org/draft/2019-09/schema","type":"string"} */ id: z.string(), },
- src/tools.ts:256-283 (registration)Registers the 'peopleGet' tool on the MCP server with name, description, input schema, and handler function.server.tool( "peopleGet", "The contact with the given id.", { /* {"$id":"#people-id","$schema":"https://json-schema.org/draft/2019-09/schema","type":"string"} */ id: z.string(), }, async ({ id }) => { try { const data = await sendRpcRequest("people.get", [id]); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching people.get: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } } );