Skip to main content
Glama

list_recent

Retrieve recent episodes from the MCP Standards server to access current content and updates.

Instructions

List recent episodes

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMax results

Implementation Reference

  • Registration of the 'list_recent' tool in the list_tools handler, including its description and input schema (optional limit parameter).
    Tool(
        name="list_recent",
        description="List recent episodes",
        inputSchema={
            "type": "object",
            "properties": {
                "limit": {"type": "integer", "description": "Max results", "default": 10},
            },
        },
    ),
  • Core handler implementation for 'list_recent' tool. Queries SQLite episodes table for most recent entries ordered by timestamp DESC, limited by input limit (default 10), returns success, results list, and count.
    async def _list_recent(self, limit: int = 10) -> Dict[str, Any]:
        """List recent episodes"""
        try:
            with sqlite3.connect(self.db_path) as conn:
                conn.row_factory = sqlite3.Row
                cursor = conn.execute("""
                    SELECT id, name, content, source, timestamp
                    FROM episodes 
                    ORDER BY timestamp DESC
                    LIMIT ?
                """, (limit,))
                
                episodes = [dict(row) for row in cursor.fetchall()]
                
                return {
                    "success": True,
                    "results": episodes,
                    "count": len(episodes)
                }
        except Exception as e:
            return {"success": False, "error": str(e)}
  • Registration of the 'list_recent' tool in enhanced_server list_tools, with note about cost-efficient model routing.
    Tool(
        name="list_recent",
        description="List recent episodes (uses cost-efficient model)",
        inputSchema={
            "type": "object",
            "properties": {
                "limit": {"type": "integer", "description": "Max results", "default": 10},
            },
        },
    ),
  • Identical core handler implementation in enhanced_server.
    async def _list_recent(self, limit: int = 10) -> Dict[str, Any]:
        """List recent episodes"""
        try:
            with sqlite3.connect(self.db_path) as conn:
                conn.row_factory = sqlite3.Row
                cursor = conn.execute("""
                    SELECT id, name, content, source, timestamp
                    FROM episodes
                    ORDER BY timestamp DESC
                    LIMIT ?
                """, (limit,))
    
                episodes = [dict(row) for row in cursor.fetchall()]
    
                return {
                    "success": True,
                    "results": episodes,
                    "count": len(episodes)
                }
        except Exception as e:
            return {"success": False, "error": str(e)}
  • Classification of 'list_recent' as SIMPLE task complexity for model routing to cost-efficient models.
    "list_recent": TaskComplexity.SIMPLE,

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/airmcp-com/mcp-standards'

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