Skip to main content
Glama

dhis2_get_composition_recommendations

Generate integration recommendations to combine the output of the last executed tool with other MCP servers, enhancing DHIS2 health system workflows and data management.

Instructions

Get recommendations for integrating the result of the last operation with other MCP servers

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lastToolNoName of the last tool that was executed

Implementation Reference

  • Primary handler implementation for the 'dhis2_get_composition_recommendations' tool. Extracts the lastTool parameter, calls the helper method from MultiServerComposition, logs the operation via audit, and formats a rich text response with recommendations, compatible servers, and integration patterns.
    case 'dhis2_get_composition_recommendations': const { lastTool } = args as { lastTool?: string }; const recommendations = multiServerComposition.getCompositionRecommendations( lastTool || 'dhis2_general', {} ); auditLogger.log({ toolName: name, parameters: { lastTool }, outcome: 'success', dhis2Instance: dhis2Client?.baseURL, userId: currentUser?.username, executionTime: Date.now() - startTime }); return { content: [{ type: 'text', text: `💡 Multi-Server Integration Recommendations ${lastTool ? `**Based on your last operation:** ${lastTool}` : '**General Recommendations:**'} **Suggested Next Steps:** ${recommendations.length > 0 ? recommendations.map(rec => ` • ${rec}`).join('\n') : ' • No specific recommendations for this operation' } **Available Compatible Servers:** ${multiServerComposition.getCompatibleServers().length} ${multiServerComposition.getCompatibleServers().map(server => ` • **${server.name}**: ${server.capabilities.map(c => c.domain).join(', ')}` ).join('\n') || ' • Register servers with dhis2_register_compatible_server'} **Common Integration Patterns:** • **Data Quality**: DHIS2 validation → GitHub issues → Slack notifications • **Development**: DHIS2 app generation → Git commits → Pull requests • **Analytics**: DHIS2 reports → Database storage → Email distribution • **Monitoring**: DHIS2 system info → Log aggregation → Alert systems 🔗 Use **dhis2_export_for_composition** to prepare data for other servers.` }] };
  • Core helper function getCompositionRecommendations that analyzes the currentTool string and returns an array of suggested next integration steps with other MCP servers, forming the logic behind the tool's recommendations.
    getCompositionRecommendations(currentTool: string, result: any): string[] { const recommendations: string[] = []; // Analysis of current tool and suggest next steps if (currentTool.includes('validation')) { recommendations.push('Create GitHub issue for validation failures'); recommendations.push('Send Slack notification to data team'); recommendations.push('Log validation results to database'); } if (currentTool.includes('init_webapp')) { recommendations.push('Commit generated code to Git repository'); recommendations.push('Create GitHub pull request'); recommendations.push('Notify development team via Slack'); } if (currentTool.includes('get_analytics')) { recommendations.push('Export analytics data to external database'); recommendations.push('Generate and email automated report'); recommendations.push('Create dashboard visualization'); } if (currentTool.includes('create_data_element')) { recommendations.push('Backup metadata to version control'); recommendations.push('Update documentation in Wiki/GitHub'); recommendations.push('Notify configuration team'); } return recommendations; }

Other Tools

Related 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/Dradebo/dhis2-mcp'

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