Skip to main content
Glama
199-mcp

Limitless MCP Server

by 199-mcp

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
NameRequiredDescriptionDefault
lifelog_idYesThe unique identifier of the lifelog to retrieve.
includeMarkdownNoInclude markdown content in the response.
includeHeadingsNoInclude 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 }))
    );
  • 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;
    }
  • 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."),
    };
  • 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
    }

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/199-mcp/mcp-limitless'

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