Skip to main content
Glama

Module Service Create

module_service_create

Create a Drupal service definition with PHP class stub. Specify machine name and service name to generate the code with optional path, tags, arguments, and class name.

Instructions

Create a service definition with PHP class stub.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNo
tagsNo
argumentsNo
class_nameNo
machine_nameYes
service_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.6/5.0
Behavior2/5

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

With no annotations, the description carries the full burden. It only states what is created (service definition and class stub), but omits critical behavioral traits such as file locations, overwrite behavior, module prerequisites, or side effects.

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

Conciseness4/5

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

The single sentence is front-loaded and contains no filler or redundancy. However, its extreme brevity borders on under-specification rather than optimal conciseness.

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?

Given 6 parameters, no annotations, and a creation operation, the description is far too sparse. While an output schema exists (so return values need not be explained), the lack of usage and parameter context leaves the agent poorly equipped to invoke the tool correctly.

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

Parameters1/5

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

The schema has 0% description coverage across 6 parameters, and the description adds no parameter meaning at all. An agent cannot know what machine_name, service_name, path, tags, arguments, or class_name represent.

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 states a clear verb (Create) and resource (service definition) and adds the PHP class stub output. It is distinguishable from siblings by resource, but does not explicitly differentiate or mention alternatives.

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 when-to-use guidance, prerequisites, or alternatives are provided. The agent must infer usage entirely from the name and sibling context.

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

Deploy Server

Other Tools