Skip to main content
Glama

note_notesInfo

Retrieve detailed information for specific note IDs from Anki flashcards using a structured query, enabling efficient management and organization of learning content.

Instructions

Returns a list of objects containing information for each note ID provided.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
notesYesA list of note IDs.

Implementation Reference

  • Handler function for the 'note_notesInfo' tool (internally 'notesInfo' with 'note_' prefix). It accepts a list of note IDs and retrieves detailed information about those notes by calling the AnkiConnect 'notesInfo' API.
    @note_mcp.tool( name="notesInfo", description="Returns a list of objects containing information for each note ID provided.", ) async def get_notes_info_tool( notes: Annotated[List[int], Field(description="A list of note IDs.")], ) -> List[Dict[str, Any]]: return await anki_call("notesInfo", notes=notes)
  • Registers all tools from the note service (note_mcp) with the 'note_' prefix on the main AnkiMCP server, making 'notesInfo' available as 'note_notesInfo'.
    await anki_mcp.import_server("note", note_mcp)
  • Shared helper utility that performs the actual HTTP request to the AnkiConnect server. Used by the notesInfo handler to fetch note data.
    async def anki_call(action: str, **params: Any) -> Any: async with httpx.AsyncClient() as client: payload = {"action": action, "version": 6, "params": params} result = await client.post(ANKICONNECT_URL, json=payload) result.raise_for_status() result_json = result.json() error = result_json.get("error") if error: raise Exception(f"AnkiConnect error for action '{action}': {error}") response = result_json.get("result") if "result" in result_json: return response return result_json

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/ujisati/anki-mcp'

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