Skip to main content
Glama

generate_api_integration_test

Generate API integration tests (supertest, httpx or REST Assured) asserting status, response body (partial match) and auth; optional validation, security-header and rate-limit checks

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "method": "<method>",
      "path": "<path>"
    },
    "name": "generate_api_integration_test"
  }
}

Input Schema

NameRequiredDescriptionDefault
authNoEndpoint requires a bearer token (adds a 401-without-token test)
pathYes
checksNoExtra behaviour tests to include
methodYes
appPathNosupertest: module exporting the Express/Koa app (default ../src/app)
baseUrlNohttpx / REST Assured: base URL (default http://localhost:3000; BASE_URL env overrides)
frameworkNo
packageNameNoREST Assured: Java package (default com.example.integration)
requestBodyNo
expectedBodyNoSubset the response body must contain, e.g. {"status": "ok"}
expectedStatusNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changed
    • addedInput schema / properties / appPath
      Added value: +{
      +  "description": "supertest: module exporting the Express/Koa app (default ../src/app)",
      +  "type": "string"
      +}
    • addedInput schema / properties / auth / description
      Added value: +"Endpoint requires a bearer token (adds a 401-without-token test)"
    • addedInput schema / properties / baseUrl
      Added value: +{
      +  "description": "httpx / REST Assured: base URL (default http://localhost:3000; BASE_URL env overrides)",
      +  "type": "string"
      +}
    • addedInput schema / properties / checks
      Added value: +{
      +  "description": "Extra behaviour tests to include",
      +  "items": {
      +    "enum": [
      +      "validation",
      +      "securityHeaders",
      +      "rateLimit"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / expectedBody
      Added value: +{
      +  "description": "Subset the response body must contain, e.g. {\"status\": \"ok\"}",
      +  "type": "object"
      +}
    • addedInput schema / properties / packageName
      Added value: +{
      +  "description": "REST Assured: Java package (default com.example.integration)",
      +  "type": "string"
      +}
  2. First observed

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It usefully discloses what the generated tests cover (status, partial body match, auth, optional validation/security-header/rate-limit), but it never says whether files are written to disk or code is returned, where output lands, or that the tests are generated rather than executed — significant gaps for a generator with no annotations.

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?

A single dense sentence that front-loads the action, the framework options, and the assertion scope with no filler. Nothing in the wording is redundant.

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

Completeness3/5

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

For an 11-parameter tool with no output schema and no annotations, the description should clarify the return shape and framework defaults. It covers assertion scope well but leaves the agent guessing about output (file path vs. code string) and how the three framework families map to the appPath vs. baseUrl parameters.

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 55%, so the description should compensate for undocumented parameters (path, method, framework, requestBody, expectedStatus). It adds 'partial match' semantics for expectedBody and ties auth to a 401 test, but it leaves the uncovered half of the parameters (notably framework selection and requestBody shape) without added meaning.

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 specific verb+resource ('Generate API integration tests') and names the concrete frameworks (supertest, httpx, REST Assured) plus what the generated tests assert. Naming HTTP test frameworks implicitly separates it from generate_grpc_integration_test and generate_db_integration_test, but it never states that distinction explicitly, so it stops short of a 5.

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

Usage Guidelines3/5

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

It conveys what the tool produces and which optional checks exist, so usage is implied, but there is no explicit when-to-use vs. when-not, and no prerequisites such as requiring an existing app module at appPath or a running server for httpx/REST Assured. An agent must infer those conditions from the schema.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.