limitless_get_lifelog_by_id
Retrieve a specific lifelog or Pendant recording by its unique ID to access detailed conversation content and analytics.
Instructions
Retrieves a single lifelog or Pendant recording by its specific ID.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lifelog_id | Yes | The unique identifier of the lifelog to retrieve. | |
| includeMarkdown | No | Include markdown content in the response. | |
| includeHeadings | No | Include headings content in the response. |
Implementation Reference
- src/server.ts:438-442 (registration)MCP tool registration for 'limitless_get_lifelog_by_id', which wraps the getLifelogById function call.server.tool( "limitless_get_lifelog_by_id", "Retrieves a single lifelog or Pendant recording by its specific ID.", GetByIdArgsSchema, async (args, _extra) => handleToolApiCall(() => getLifelogById(limitlessApiKey, args.lifelog_id, { includeMarkdown: args.includeMarkdown, includeHeadings: args.includeHeadings })) );
- src/limitless-client.ts:304-316 (handler)The core handler function that makes the API request to retrieve a single lifelog by its ID from the Limitless API.export async function getLifelogById(apiKey: string, lifelogId: string, options: Pick<LifelogParams, 'includeMarkdown' | 'includeHeadings'> = {}): Promise<Lifelog> { // Cannot log here reliably for stdio // console.error(`[Limitless Client] Requesting lifelog by ID: ${lifelogId}`); const params: Record<string, string | number | boolean | undefined> = { includeMarkdown: options.includeMarkdown ?? true, includeHeadings: options.includeHeadings ?? true, }; const response = await makeApiRequest<SingleLifelogResponse>(apiKey, `v1/lifelogs/${lifelogId}`, params); if (!response.data?.lifelog) { throw new LimitlessApiError(`Lifelog with ID ${lifelogId} not found`, 404); } return response.data.lifelog; }
- src/server.ts:188-192 (schema)Zod schema defining the input arguments for the tool, including the required lifelog_id.const GetByIdArgsSchema = { lifelog_id: z.string().describe("The unique identifier of the lifelog to retrieve."), includeMarkdown: z.boolean().optional().default(true).describe("Include markdown content in the response."), includeHeadings: z.boolean().optional().default(true).describe("Include headings content in the response."), };
- src/limitless-client.ts:35-45 (schema)TypeScript interface defining the structure of a Lifelog object returned by the API.export interface Lifelog { id: string; title?: string; markdown?: string; startTime: string; endTime: string; contents?: LifelogContentNode[]; // Use specific type isStarred?: boolean; // Whether this lifelog is starred updatedAt?: string; // When this lifelog was last updated // Add other fields from the API response as needed }