authProfile
Manage and authenticate user identities within the Routine system to interact with calendars, tasks, and notes efficiently.
Instructions
Main user identity.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "authProfile"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools.ts:6-24 (handler)The handler function for the 'authProfile' tool. It calls sendRpcRequest('auth.profile', []) to fetch the main user identity and returns it as a formatted JSON text response, or an error if the request fails.
server.tool("authProfile", "Main user identity.", {}, async ({}) => { try { const data = await sendRpcRequest("auth.profile", []); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching auth.profile: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } }); - src/tools.ts:6-24 (registration)The server.tool call registers the 'authProfile' tool with an empty input schema ({}), description 'Main user identity.', and the handler function.
server.tool("authProfile", "Main user identity.", {}, async ({}) => { try { const data = await sendRpcRequest("auth.profile", []); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching auth.profile: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } }); - src/index.ts:234-235 (registration)Calls registerServerTools which includes the registration of the authProfile tool among others.
registerServerTools(server, sendRpcRequest, logger);