Skip to main content
Glama
ghiloufibg

Maven Project Generator MCP

by ghiloufibg

add_resource_file

Adds a resource file to Maven projects for storing configuration, properties, or data files in main or test directories.

Instructions

Ajouter un fichier de ressources au projet

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fileNameYesNom du fichier de ressource
contentYesContenu du fichier
typeNoType de ressourcemain

Implementation Reference

  • The handler function that adds a resource file to the project structure.
    async function addResourceFile(args: any) {
      const { fileName, content, type = "main" } = args;
      const filePath = `src/${type}/resources/${fileName}`;
    
      currentProject.files[filePath] = content;
    
      return {
        content: [
          {
            type: "text",
            text: `Fichier de ressource ajoute!\n\n` +
                  `Fichier: ${filePath}\n` +
                  `Type: ${type}\n\n` +
                  `Repertoires crees automatiquement si necessaire.`,
          },
        ],
      };
    }
  • The input schema definition for the add_resource_file tool.
    inputSchema: {
      type: "object",
      properties: {
        fileName: {
          type: "string",
          description: "Nom du fichier de ressource",
        },
        content: {
          type: "string",
          description: "Contenu du fichier",
        },
        type: {
          type: "string",
          description: "Type de ressource",
          enum: ["main", "test"],
          default: "main",
  • src/index.ts:115-116 (registration)
    The registration of the add_resource_file tool.
    name: "add_resource_file",
    description: "Ajouter un fichier de ressources au projet",
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It states this is an addition operation but doesn't mention whether this requires specific project state, what happens if the file already exists, permission requirements, or response format. For a mutation tool with zero annotation coverage, this leaves significant behavioral questions unanswered.

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

Conciseness5/5

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

Single sentence with zero waste - every word contributes to the core purpose. The description is appropriately sized for a straightforward tool and is front-loaded with the essential action and target.

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 file creation/mutation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what happens after file addition, error conditions, or how this integrates with the project structure. Given the complexity of file system operations and lack of structured safety hints, more behavioral context is needed.

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 already documents all three parameters thoroughly. The description doesn't add any parameter-specific information beyond what's in the schema. The baseline of 3 is appropriate when the schema does the heavy lifting for parameter documentation.

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 action ('Ajouter' = Add) and resource ('fichier de ressources' = resource file) with target context ('au projet' = to the project). It distinguishes from generic file addition tools like 'add_any_file' by specifying resource files, but doesn't explicitly differentiate from 'add_java_file' which might be a specialized case.

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?

No guidance on when to use this tool versus alternatives like 'add_any_file' or 'add_java_file'. The description provides basic context (adding to a project) but doesn't specify prerequisites, constraints, or when other tools might be more appropriate.

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/ghiloufibg/maven-mcp-server'

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