Modrinth API
Base: https://api.modrinth.com/v2
Modrinth is an open mod platform whose public API needs no key, which makes it the easiest provider to start with. The plugin searches projects with facets, lists the versions of a project and reads the primary file of a version for the download. This page shows the Modrinth calls behind the mod browser at api.modrinth.com/v2, including the filters the plugin builds from your server settings.
/search
Search projects
Searches Modrinth projects with facets and returns hits with title, author, description, downloads, icon and supported versions.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
query
|
string | No | Search keyword. Leave empty to list the most downloaded mods. |
facets
|
string | No | Filter as a JSON array of arrays, for example [["project_type:mod"],["categories:fabric"]]. |
limit
|
integer | No | Results per page. The plugin uses the mods-per-page setting (default 20), Modrinth itself defaults to 10. |
offset
|
integer | No | Number of results to skip, calculated from the page number. |
Response Example
{"hits":[{"slug":"fabric-api","title":"Fabric API","description":"Essential hooks for modding with Fabric","project_type":"mod","downloads":250000000,"icon_url":"https://cdn.modrinth.com/...","versions":["1.20.1","1.21"]}],"offset":0,"limit":10,"total_hits":1}
cURL
curl "https://api.modrinth.com/v2/search?query=fabric-api&facets=[[\"project_type:mod\"]]&limit=5"
Internal Behavior
Results come back as hits with total_hits. The plugin maps project_id (or the slug), title, description, author, downloads, icon_url, date_modified and categories into its own list format. A non-200 answer is logged as a Modrinth warning and the browser shows an empty list.
/project/{id|slug}
Get project
Returns a single Modrinth project by ID or slug with description, download count, side support and loaders.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
id|slug
|
string | Yes | Project ID (for example AANobbMI) or slug (for example sodium). |
Response Example
{"slug":"fabric-api","title":"Fabric API","description":"Essential hooks...","downloads":250000000,"project_type":"mod","server_side":"required","loaders":["fabric","quilt"]}
cURL
curl "https://api.modrinth.com/v2/project/fabric-api"
Internal Behavior
/project/{id|slug}/version
List versions
Lists all versions of a Modrinth project with version number, release date, supported game versions, loaders and files.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
id|slug
|
string | Yes | Project ID or slug. |
loaders
|
string | No | JSON array of loaders, for example ["fabric"]. Valid at Modrinth, not sent by the plugin. |
game_versions
|
string | No | JSON array of game versions, for example ["1.20.1"]. Valid at Modrinth, not sent by the plugin. |
Response Example
[{"id":"abcd1234","version_number":"0.91.0","game_versions":["1.20.1"],"loaders":["fabric"],"files":[{"url":"https://cdn.modrinth.com/...","filename":"fabric-api-0.91.0.jar","hashes":{"sha1":"..."}}],"dependencies":[]}]
cURL
curl "https://api.modrinth.com/v2/project/fabric-api/version?loaders=[\"fabric\"]&game_versions=[\"1.20.1\"]"