---
title: "Maven Central API: Java, JVM artifact search as JSON"
description: "Maven Central API for Java and JVM artifact search by keyword, group ID or artifact ID, and every version of an artifact with publish dates as JSON."
url: https://perceptlayer.com/apis/maven-central
---

[APIs](https://perceptlayer.com/apis) / [Apps and media](https://perceptlayer.com/verticals/apps) / Maven Central

1 credit per call 2 endpoints 4 datapoints 

# Maven Central API

Maven Central API for Java and JVM artifact search by keyword, group ID or artifact ID, and every version of an artifact with publish dates as JSON.

[Get a free API key](https://perceptlayer.com/signup) Run it below

Maven Central

GET /v1/maven-central/versions?group\_id=com.google.guava&artifact\_id=guava 

```
{
  "success": true,
  "data": {
    "group_id": "com.google.guava",
    "artifact_id": "guava",
    "latest_version": "33.8.0-jre",
    "release_version": "33.8.0-jre",
    "last_updated": "2026-11-02T18:07:48Z",
    "total": 162,
    "page": 1,
    "has_more": true,
    "count": 20,
    "items": [
      {
        "version": "33.8.0-jre",
        "published_at": "2026-11-02T18:06:39.000Z",
        "packaging": "bundle",
        "url": "https://central.sonatype.com/artifact/com.google.guava/guava/33.8.0-jre"
      },
      {
        "version": "33.8.0-android",
        "published_at": "2026-11-02T18:06:38.000Z",
        "packaging": "bundle",
        "url": "https://central.sonatype.com/artifact/com.google.guava/guava/33.8.0-android"
      },
      {
        "version": "33.7.2-jre",
        "published_at": "2026-09-29T14:47:28.000Z",
        "packaging": "bundle",
        "url": "https://central.sonatype.com/artifact/com.google.guava/guava/33.7.2-jre"
      }
    ]
  },
  "meta": {
    "request_id": "req_2c4b014515b74e28b9c385639470f325",
    "credits_charged": 1,
    "credits_remaining": 490
  }
}
```

200 OK JSON X-Credits-Used: 1

Recorded from our API and shortened.

Sample data

## What one call returns

A recorded run of `versions`: the fields and shapes you will get, shortened to 3 items.

| # | version string | published\_at string | packaging string | url url |
| --- | --- | --- | --- | --- |
| 1 | 33.8.0-jre | 2026-11-02T18:06:39.000Z | bundle | https://central.sonatype.com/artifact/com.google.guava/guava/33.8.0-jre |
| 2 | 33.8.0-android | 2026-11-02T18:06:38.000Z | bundle | https://central.sonatype.com/artifact/com.google.guava/guava/33.8.0-android |
| 3 | 33.7.2-jre | 2026-09-29T14:47:28.000Z | bundle | https://central.sonatype.com/artifact/com.google.guava/guava/33.7.2-jre |

Recorded from our API · 3 items shown · 4 datapoints per item GET /v1/maven-central/versions?group\_id=com.google.guava&artifact\_id=guava

4 datapoints

### Contact

-   url url

### Other

-   version string
-   published\_at string
-   packaging string

Playground

## Run this API

cURL shell 

```
curl "https://api.perceptlayer.com/v1/maven-central/versions?group_id=com.google.guava&artifact_id=guava" \
  -H "X-API-Key: $API_KEY"
```

Maven Central · 2 endpoints

## Endpoints

Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.

| Endpoint | Required parameters | Returns | Cost |
| --- | --- | --- | --- |
| [GET `/v1/maven-central/search`](https://perceptlayer.com/apis/maven-central/search) | none +5 optional | `group_id` `artifact_id` `coordinates` `latest_version` `packaging` `updated_at` +1 more | 1 credit |
| [GET `/v1/maven-central/versions`](https://perceptlayer.com/apis/maven-central/versions) | `group_id` `artifact_id` +2 optional | `group_id` `artifact_id` `latest_version` `release_version` `last_updated` `items` | 1 credit |

Overview

## About the Maven Central API

## What you can get

The Maven Central API returns Java and JVM artifact data from Maven Central as JSON through 2 endpoints.

-   **Search:** `search` takes a `query` (words in the group or artifact ID), a `group_id` or an `artifact_id`, with `page` and `per_page` (1 to 100, default 20). Search reaches the first 1,000 results.
-   **Versions:** `versions` takes a `group_id` and an `artifact_id`, with `page` and `per_page` (1 to 50, default 20). Versions come newest first.

The recorded `search` for group `com.google.guava` found 21 artifacts ( `total`), each with `group_id`, `artifact_id`, `coordinates` (group:artifact), `latest_version`, `packaging`, `updated_at` and `url`. The recorded `versions` call for `com.google.guava:guava` found 162 versions, with `latest_version` and `release_version` both 33.8.0-jre and `last_updated`, and each version with `version`, `published_at`, `packaging` and `url`.

## How a call works

Find the coordinates, then list versions: `GET /v1/maven-central/search?group_id=com.google.guava&per_page=10` with your key in the `X-API-Key` header returns each artifact's `group_id` and `artifact_id`, which `versions` takes, for example `GET /v1/maven-central/versions?group_id=com.google.guava&artifact_id=guava&per_page=10`. Check `has_more` before asking for the next `page`. An artifact with no versions on Maven Central answers 404. Answers come from a cache for up to an hour. Every successful call costs 1 credit; failed calls cost nothing.

Apps and media JSON REST MCP

### More apps and media APIs

[Apple App Store](https://perceptlayer.com/apis/apple-app-store) [Apple Podcasts](https://perceptlayer.com/apis/apple-podcasts) [arXiv](https://perceptlayer.com/apis/arxiv) [Audible](https://perceptlayer.com/apis/audible) [Bandcamp](https://perceptlayer.com/apis/bandcamp) [Chrome Web Store](https://perceptlayer.com/apis/chrome-web-store) [CISA KEV](https://perceptlayer.com/apis/cisa-kev) [ClinicalTrials.gov](https://perceptlayer.com/apis/clinicaltrials) [Coursera](https://perceptlayer.com/apis/coursera) [crates.io](https://perceptlayer.com/apis/crates-io) [Crossref](https://perceptlayer.com/apis/crossref) [Discogs](https://perceptlayer.com/apis/discogs)

Use cases

### Let a coding agent look up the current release of a library before writing a \`pom.xml\` or \`build.gradle\`

`` Use the Maven Central API to let a coding agent look up the current release of a library before writing a `pom.xml` or `build.gradle` `` 

### Flag outdated dependencies by comparing a build file against \`release\_version\`

`` Use the Maven Central API to flag outdated dependencies by comparing a build file against `release_version` `` 

### List every artifact a group publishes, such as all \`com.google.guava\` modules

`` Use the Maven Central API to list every artifact a group publishes, such as all `com.google.guava` modules `` 

### Track release cadence from each version's \`published\_at\`

`` Use the Maven Central API to track release cadence from each version's `published_at` `` 

FAQ

## Questions

**Is this the official Maven Central API?**

No. Perceptlayer is an independent service and is not affiliated with Sonatype or Maven Central. Maven Central's search and repository are free to call directly, under Sonatype's terms, which forbid excessive requests. This API calls them on your behalf and adds one key for every source on Perceptlayer, one response shape for search and version lists, a cache of up to an hour, and no charge for failed calls.

**Where do the version lists come from?**

From the artifact's \`maven-metadata.xml\` in the Maven Central repository, so \`versions\` lists the versions the repository itself records for the artifact.

**Can I search with several words?**

Yes. Words are matched together against group and artifact IDs, up to 10 words. Use \`group\_id\` or \`artifact\_id\` for an exact match.

**Does it return dependencies or POM details?**

No. These endpoints return coordinates, versions, packaging and dates, not the dependency tree from a POM.

**Should I build a Maven Central scraper instead?**

You can, but a Maven Central scraper is code you maintain: page changes break it, requests get blocked, and Maven Central's terms govern how you collect data. The Maven Central API gives you 2 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.

## Try the Maven Central API with 100 free credits

No credit card. Failed calls are never billed.

[Get a free API key](https://perceptlayer.com/signup) [Read the docs](https://docs.perceptlayer.com)
