# Maven Central API

> Maven Central returns library versions, release dates, and dependency snippets as a workflow and API.

Maven Central finds a library by name or group:artifact coordinates and returns its latest release, date, version count, and dependency snippets. Get latest version needs a library name or coordinates; use coordinates to select an exact artifact.

- Page: https://fous.com/tools/maven-central
- Handle: `@maven-central`
- Category: [Developer tools](https://fous.com/tools/category/developer-tools)
- Source website: https://central.sonatype.com
- Last verified: Sep 29, 2026

## Methods

### Get latest version

Operation `get_latest_version`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

Find the best matching Maven Central library from its name or group:artifact coordinates. Returns its current release, release date, version count, dependency snippets, and matched artifact. Broad names may match a different project than intended; use coordinates to select an exact artifact.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `library` | string | yes | `"jackson databind"` | Library name or Maven group:artifact coordinates, for example jackson databind or com.google.guava:guava. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "library"
  ],
  "properties": {
    "library": {
      "type": "string",
      "description": "Library name or Maven group:artifact coordinates, for example jackson databind or com.google.guava:guava.",
      "examples": [
        "jackson databind",
        "com.google.guava:guava",
        "guava"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "library": "jackson databind"
    },
    {
      "library": "com.google.guava:guava"
    },
    {
      "library": "guava"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `group` | string | `"com.fasterxml.jackson.core"` | Matched Maven group. |
| `artifact` | string | `"jackson-databind"` | Matched Maven artifact. |
| `release_date` | string or null | `"2026-09-21"` | UTC publication date of the release POM, when available. |
| `latest_version` | string | `"2.22.3"` | Latest release version in the repository. |
| `maven_dependency` | string | `"<dependency>\n    <groupId>com.fasterxml.jackson.core</groupId>\n    <artifactId>jackson-databind</artifactId>\n    <ve` | Maven dependency XML. |
| `gradle_dependency` | string | `"implementation 'com.fasterxml.jackson.core:jackson-databind:2.22.3'"` | Gradle Groovy dependency declaration. |
| `maven_central_link` | string | `"https://central.sonatype.com/artifact/com.fasterxml.jackson.core/jackson-databind/2.22.3"` | Page for the matched version on Maven Central. |
| `number_of_versions` | integer | `235` | Number of published versions listed by the repository. |

**Example input**

```json
{
  "library": "jackson databind"
}
```

**Example output**

```json
{
  "group": "com.fasterxml.jackson.core",
  "artifact": "jackson-databind",
  "release_date": "2026-09-21",
  "latest_version": "2.22.3",
  "maven_dependency": "<dependency>\n    <groupId>com.fasterxml.jackson.core</groupId>\n    <artifactId>jackson-databind</artifactId>\n    <version>2.22.3</version>\n</dependency>",
  "gradle_dependency": "implementation 'com.fasterxml.jackson.core:jackson-databind:2.22.3'",
  "maven_central_link": "https://central.sonatype.com/artifact/com.fasterxml.jackson.core/jackson-databind/2.22.3",
  "number_of_versions": 235
}
```

## Quick start

Replace `YOUR_API_KEY` with a Fous API key. To create one, open Developers at the bottom of Fous Studio, turn on Developer mode, then go to API keys (https://app.fous.com/keys). Change the values in `input` to run the same tool on new data.

```bash
curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 180 \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@maven-central",
  "visibility": "public",
  "operation": "get_latest_version",
  "version": 1,
  "input": {
    "library": "jackson databind"
  },
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
import json
import urllib.error
import urllib.request

api_key = "YOUR_API_KEY"

body = json.loads("{\n  \"api\": \"@maven-central\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_latest_version\",\n  \"version\": 1,\n  \"input\": {\n    \"library\": \"jackson databind\"\n  },\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=180) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
const apiKey = "YOUR_API_KEY";

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(180_000),
  body: JSON.stringify({
  "api": "@maven-central",
  "visibility": "public",
  "operation": "get_latest_version",
  "version": 1,
  "input": {
    "library": "jackson databind"
  },
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

## Use from an AI assistant

Connect this tool to Claude Code, Claude Desktop, Cursor, VS Code, Codex and any MCP client as its own MCP server. Each method is a typed tool whose arguments are the method’s input.

- Server URL: `https://api.fous.com/mcp/tools/maven-central`
- Authorization: `Authorization: Bearer <Fous API key>`

**Tools**

- `get_latest_version`: Get latest version. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `fous_get_run`: the result of a run that was still going, by its `request_id`. Free.

Claude Code:

```bash
claude mcp add --scope user --transport http fous-maven-central https://api.fous.com/mcp/tools/maven-central --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"
```

To give the assistant every tool, connect `https://api.fous.com/mcp`: it finds one with `fous_search_tools` and runs it with `fous_run_tool`. Setup for other clients: https://fous.com/llms-full.txt.

## Use cases

- Check a library’s latest release
- Review a library’s release date and version count
- Copy Maven or Gradle dependency declarations
- Find an artifact using its group and artifact coordinates

## FAQ

### Can I run it with my own inputs?

Yes. Change the inputs in Studio and press Run, or send new inputs from your code, or ask a connected AI assistant.

### Can I call this Maven Central tool as an API?

Yes. Send a POST request to /v1/query with your Fous API key and the inputs, and get JSON back.

### How much does it cost?

Each completed run costs 1 credit. Failed runs without a completed receipt are free; completed work can remain charged if delivery is interrupted. With pay as you go, a credit costs 1¢. Monthly plans cost less per credit.

### Do I need a Maven Central account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from central.sonatype.com when you run it. Some results are reused for up to 24 hours, and results that use your account or key are never reused. It was last verified on Sep 29, 2026.

### What is the latest version of a library?

Get latest version returns the latest release version for a matching library.

### When was the latest release published?

Get latest version returns the release POM’s UTC publication date when available.

### What dependency declaration should I use?

Get latest version returns Maven XML and Gradle Groovy dependency snippets.

## Related

- [npm API](https://fous.com/tools/npm.md): npm provides package details, search results and latest versions, plus weekly download and publish data; daily and historical download counts may lag by a day or more.
- [RubyGems API](https://fous.com/tools/rubygems.md): Discover and share Ruby gems.
- [NuGet API](https://fous.com/tools/nuget.md): The .NET package gallery for discovering and sharing packages.
- [GitHub API](https://fous.com/tools/github.md): GitHub returns public repository matches and details, up to 25 trending projects, issues, pull requests, and newest-first published releases; release or commit dates may be unavailable.
- [crates.io API](https://fous.com/tools/crates-io.md): crates.io is the Rust community package registry, returning current crate details and recent releases or up to 100 keyword-matched crates with version, download, and update information.
- [OverDrive API](https://fous.com/tools/overdrive.md): Find ebooks and audiobooks at public libraries.
- [PyPI API](https://fous.com/tools/pypi.md): PyPI provides package metadata, links, and current/latest plus 10 recent versions; release dates reflect first file uploads, and keyword searches return up to 100 packages.
- [Go Packages API](https://fous.com/tools/go-packages.md): Find Go module versions, licenses, usage and source repositories.
- [All Developer tools tools](https://fous.com/tools/category/developer-tools)
