An MCP server implementation using Express.js with HTTP transport that provides tools for generating random numbers
This server has a single tool (generateRandomNumber) with critical definition gaps. The tool lacks parameter descriptions entirely, has a minimal input schema with no documented properties, and provides only a basic description in Portuguese. The server does register the tool explicitly with schema and description in server.js, but the definition quality is far below production standards. No parameter validation, no error handling guidance, and no output schema documentation. This is representative of a beginner-level implementation.
Gera um número aleatório entre 1 e 100
Tool parameters lack descriptions. The inputSchema declares an empty object with no properties, but produces no parameter documentation for the LLM. Even though there are no parameters, the schema should be explicit about this intent.
Output schema is not documented. The tool returns a text response containing JSON, but there is no documented output schema showing what fields the LLM should expect. The response is hardcoded as a text string: 'Número aleatório gerado: {number}', making it unstructured.
Tool description is minimal and in Portuguese. The description 'Gera um número aleatório entre 1 e 100' (Generate a random number between 1 and 100) is only 47 characters and does not answer when or why to use the tool, what it returns, or any LLM-actionable context. Additionally, using a non-English description limits usability in many LLM contexts.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | F | 36 | 2026-07-28+ | v2 |
| 2026-03-09 | F | 6 | 2024-11-05+ | v1 |
No error handling or recovery guidance. The tool has no documented error cases, no validation (e.g., what if randomness fails?), and no guidance for the LLM on what to do if the call fails. A raw error or exception would leave the LLM without actionable next steps.
Tool name does not follow verb_noun convention strongly. 'generateRandomNumber' is camelCase and action-oriented, which is acceptable, but 'generate' is somewhat vague in this context, 'generate_random_number' would be clearer and follow standard MCP naming. Minor issue, but naming consistency matters for multi-tool servers.