Skip to main content
Glama
ivossos

FCCS MCP Agentic Server

by ivossos

get_recent_executions

Retrieve recent tool executions from FCCS MCP Agentic Server for rating and review purposes. Filter by tool name or limit results to analyze performance.

Instructions

Get recent tool executions that can be rated / Obter execucoes recentes que podem ser avaliadas

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tool_nameNoOptional filter by specific tool name
limitNoMaximum number of executions to return (default: 10)

Implementation Reference

  • MCP tool handler: async function that calls feedback_service.get_recent_executions and formats the response.
    async def get_recent_executions(
        tool_name: Optional[str] = None,
        limit: int = 10
    ) -> dict[str, Any]:
        """Get recent tool executions that can be rated.
        
        Use this to find execution IDs for tools you want to provide feedback on.
        
        Args:
            tool_name: Optional filter by specific tool name
            limit: Maximum number of executions to return (default: 10)
        
        Returns:
            dict: List of recent executions with their IDs and status
        """
        feedback_service = get_feedback_service()
        if not feedback_service:
            return {
                "status": "error",
                "error": "Feedback service not available"
            }
        
        try:
            executions = feedback_service.get_recent_executions(
                tool_name=tool_name,
                limit=limit
            )
            
            return {
                "status": "success",
                "executions": executions,
                "count": len(executions)
            }
        except Exception as e:
            return {
                "status": "error",
                "error": f"Failed to get executions: {str(e)}"
            }
  • Input schema definition for the 'get_recent_executions' tool in TOOL_DEFINITIONS.
            "name": "get_recent_executions",
            "description": "Get recent tool executions that can be rated / Obter execucoes recentes que podem ser avaliadas",
            "inputSchema": {
                "type": "object",
                "properties": {
                    "tool_name": {
                        "type": "string",
                        "description": "Optional filter by specific tool name",
                    },
                    "limit": {
                        "type": "integer",
                        "description": "Maximum number of executions to return (default: 10)",
                        "default": 10,
                    },
                },
            },
        },
    ]
  • Tool registration in TOOL_HANDLERS dictionary mapping name to handler function.
    TOOL_HANDLERS = {
        # Application
        "get_application_info": application.get_application_info,
        "get_rest_api_version": application.get_rest_api_version,
        # Jobs
        "list_jobs": jobs.list_jobs,
        "get_job_status": jobs.get_job_status,
        "run_business_rule": jobs.run_business_rule,
        "run_data_rule": jobs.run_data_rule,
        # Dimensions
        "get_dimensions": dimensions.get_dimensions,
        "get_members": dimensions.get_members,
        "get_dimension_hierarchy": dimensions.get_dimension_hierarchy,
        # Journals
        "get_journals": journals.get_journals,
        "get_journal_details": journals.get_journal_details,
        "perform_journal_action": journals.perform_journal_action,
        "update_journal_period": journals.update_journal_period,
        "export_journals": journals.export_journals,
        "import_journals": journals.import_journals,
        # Data
        "export_data_slice": data.export_data_slice,
        "smart_retrieve": data.smart_retrieve,
        "smart_retrieve_consolidation_breakdown": data.smart_retrieve_consolidation_breakdown,
        "smart_retrieve_with_movement": data.smart_retrieve_with_movement,
        "copy_data": data.copy_data,
        "clear_data": data.clear_data,
        # Reports
        "generate_report": reports.generate_report,
        "get_report_job_status": reports.get_report_job_status,
        "generate_report_script": reports.generate_report_script,
        # Consolidation
        "export_consolidation_rulesets": consolidation.export_consolidation_rulesets,
        "import_consolidation_rulesets": consolidation.import_consolidation_rulesets,
        "validate_metadata": consolidation.validate_metadata,
        "generate_intercompany_matching_report": consolidation.generate_intercompany_matching_report,
        "import_supplementation_data": consolidation.import_supplementation_data,
        "deploy_form_template": consolidation.deploy_form_template,
        "generate_consolidation_process_report": consolidation.generate_consolidation_process_report,
        # Memo
        "generate_system_pitch": memo.generate_system_pitch,
        "generate_investment_memo": memo.generate_investment_memo,
        # Feedback
        "submit_feedback": feedback.submit_feedback,
        "get_recent_executions": feedback.get_recent_executions,
        # Local Data
        "query_local_metadata": local_data.query_local_metadata,
    }
  • Core service method that queries the database for recent tool executions using SQLAlchemy.
    def get_recent_executions(
        self,
        tool_name: Optional[str] = None,
        limit: int = 50
    ) -> list[dict]:
        """Get recent tool executions."""
        with self.Session() as session:
            query = session.query(ToolExecution).order_by(
                ToolExecution.created_at.desc()
            )
            if tool_name:
                query = query.filter(ToolExecution.tool_name == tool_name)
            query = query.limit(limit)
    
            return [
                {
                    "id": e.id,
                    "session_id": e.session_id,
                    "tool_name": e.tool_name,
                    "success": e.success,
                    "execution_time_ms": e.execution_time_ms,
                    "user_rating": e.user_rating,
                    "created_at": e.created_at.isoformat() if e.created_at else None
                }
                for e in query.all()
            ]
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden but lacks behavioral details. It doesn't disclose whether this is a read-only operation, what authentication is needed, rate limits, pagination behavior, or what 'recent' means temporally. The 'can be rated' hint is vague without explaining rating criteria or process.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is brief but inefficiently bilingual, repeating the same information in Portuguese without adding value. The single English sentence is front-loaded but could be more precise about scope. The Portuguese translation wastes space without enhancing understanding.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no annotations and no output schema, the description is inadequate. It doesn't explain what constitutes 'recent', what 'can be rated' means operationally, the return format, or error conditions. The bilingual approach doesn't compensate for these missing contextual elements.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema fully documents both parameters. The description adds no parameter-specific information beyond implying filtering for rateable executions, which doesn't directly map to the documented 'tool_name' and 'limit' parameters. Baseline 3 is appropriate when schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('Get') and resource ('recent tool executions') with a specific qualifier ('that can be rated'). It distinguishes from siblings like 'list_jobs' or 'get_journal_details' by focusing on rateable executions. However, it doesn't explicitly differentiate from all siblings like 'get_journals' or 'get_job_status' which might also retrieve recent items.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites, timing, or compare to siblings like 'list_jobs' or 'get_job_status' that might retrieve similar data. The bilingual text adds no usage context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/ivossos/fccs-mcp-ag-server'

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