Skip to content

Tags

The Tag class represents a tag returned by the Modrinth tag endpoints. Tags can be used to categorize projects and provide metadata for search filters.

Depending on the tag type, different fields may be available.

Tag Fields9 available fields
id

The unique identifier of the tag.

Type: String
name

The display name of the tag.

Type: String
description

A description of the tag.

Type: String
icon

The icon associated with the tag.

Type: String
header

The header associated with the tag.

Type: String
value

The API value used to identify the tag.

Type: String
featured

Whether the tag is featured by Modrinth.

Type: boolean
projectType

The project type associated with the tag.

Type: ProjectType
projectTypes

The project types supported by the tag.

Type: String[]

The TagsClient provides access to the tags and metadata available through the Modrinth API.

Access it through the main Modrinth client:

modrinth.tags()

Each method returns a different type of tag or metadata.

List<Tag> categories = modrinth.tags().categories();
List<Tag> loaders = modrinth.tags().loaders();
List<Tag> versions = modrinth.tags().versions();
TagsClient Methods11 available methods
categories()

Returns all available project categories.

Returns: List<Tag>
loaders()

Returns all available mod loaders and platforms.

Returns: List<Tag>
versions()

Returns all available Minecraft versions.

Returns: List<Tag>
users()

Returns the available user tags.

Returns: List<Tag>
teams()

Returns the available team tags.

Returns: List<Tag>
versionFiles()

Returns the available version file tags.

Returns: List<Tag>
tags()

Returns general Modrinth tags.

Returns: List<Tag>
licenses()

Returns all available project licenses.

Returns: List<License>
projectTypes()

Returns all available project types.

Returns: List<ProjectType>
sideTypes()

Returns all available client and server side support types.

Returns: List<SideSupport>
donationPlatforms()

Returns all available donation platforms.

Returns: List<Tag>

For example, you can retrieve all loaders and inspect their API values:

List<Tag> loaders = modrinth.tags().loaders();
for (Tag loader : loaders) {
System.out.println(loader.name + ": " + loader.value);
}