Skip to content

Projects

Daniel edited this page Jul 16, 2023 · 1 revision

Overview

On Modrinth projects can be mods, plugins, data packs, shaders, resource packs, or modpacks.

Getting a project's information: ModrinthProject

To get a project's information you'll need to create a ModrinthProject instance, which can be done like this:

# Where `zzz` is the project's slug or ID
project = modrinth.Projects.ModrinthProject('zzz')

# Prints the (display) name of the project
print(project.name)

Searching for a project: Search

If you don't know the project ID or slug you can also search for it:

# Search for a project with the query `Lambd` 
results = modrinth.Projects.Search('Lambd')

# Prints the display name of the first project on the hits list
print(projects.hits[0].name)
Clone this wiki locally