Skip to main content
Glama

Check API compatibility

check_api_compatibility
Read-only

Checks whether a Java or Kotlin library build breaks its last published public API, returns the required semantic version bump and incompatible changes with compatible alternatives.

Instructions

Checks whether the current build of a Java or Kotlin library breaks the public API of its last published version (Maven Central or the repository the server was started with). Returns the verdict, the required semantic version bump (MAJOR/MINOR/PATCH), the next version, every binary or source incompatible change with a compatible alternative (e.g. keep the old method as deprecated), and optionally a changelog draft. It reads the compiled classes, so build the project first (the way it is usually built) and again after each change. Call it after changing the public API of a library, before committing.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "check_api_compatibility"
  }
}

Input Schema

NameRequiredDescriptionDefault
againstNoCompare with this published version instead. Optional.
currentNoBuild output to check: jar files or classes folders. Optional: found in target/ or build/.
excludeNoPackages or types that are not public API, e.g. com.acme.internal (its subpackages too; * and ** are globs). Their changes are left out of the result. Optional: by default every public package is checked.
projectNoFolder of the library module (with its pom.xml or build.gradle). Optional: defaults to the folder the server was started in. Relative paths are resolved against it.
versionNoThe version the build declares, e.g. 1.4.0-SNAPSHOT. Optional: read from the build. It picks the release to compare with and is checked against the changes.
artifactNoMaven coordinates GROUP:ARTIFACT of the published library, e.g. com.acme:acme-core. Optional: read from pom.xml or gradle.properties.
classpathNoJars the build depends on, when Bumpwise cannot read them from the build's POM (pom.xml, a Gradle build/publications POM or ~/.m2). Optional; needed only to tell classes that moved into a dependency from removed ones.
includeChangelogNoAlso return a Markdown changelog draft. Default: false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.4

TDQS

A4.1/5.0
Behavior4/5

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

Annotations declare readOnlyHint=true and openWorldHint=true, and the description is consistent with both while adding real context: it reads compiled classes rather than source, needs a prior build, may reach Maven Central for the published baseline, and enumerates exactly what comes back (verdict, semver bump, next version, incompatible changes with alternatives, optional changelog). It stops short of describing failure modes, such as what happens with no published version or an unreadable artifact.

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?

Purpose is front-loaded, followed by return contents, prerequisites, and the call trigger. The return-value enumeration is long but justified because no output schema exists; the only redundancy is restating 'build the project first' alongside the timing advice.

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

Completeness4/5

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

For an eight-parameter, zero-required tool with no output schema, the description covers what it computes, what it returns, and the build prerequisite, which is what an agent needs to invoke it correctly. It could still say more about first-release cases, network/auth needs for Maven Central, and error behavior.

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 all eight optional parameters are already documented, which sets the baseline at 3. The description adds only marginal meaning beyond the schema, mainly clarifying that the comparison target comes from Maven Central or the server's startup repository and that the changelog return is opt-in.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource with precise scope: it decides whether a build of a Java or Kotlin library breaks the public API of the last published version, and it names the baseline sources (Maven Central or the server's startup repository). An agent can tell this apart from a dependency-upgrade check without opening the schema.

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

Usage Guidelines4/5

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

It gives an explicit trigger and ordering: 'Call it after changing the public API of a library, before committing', plus the prerequisite that the project must be built (the usual way) and rebuilt after each change. What is missing is any mention of the sibling check_dependency_upgrade or of when this tool is the wrong choice.

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