modrinth-api
v1.0.0
Published
Modrinth API Library
Downloads
6
Readme
modrinth-api
Installation
npm install modrinth-api
Examples
Get info about a mod or modpack
const modrinth = require("modrinth-api");
modrinth.getMod("Mod or modpack id/slug").then((result) => {
console.log(result);
});
Search for mods or modpacks
const modrinth = require("modrinth-api");
modrinth.getSearch({ limit: "2", offset: "2" }).then((result) => {
console.log(result);
});
More info on search (Version is not available here.)
Get all versions from mods or modpacks
const modrinth = require("modrinth-api");
modrinth.getModVersions("Mod or modpack id/slug").then((result) => {
console.log(result);
});
Get all versions from mods or modpacks
const modrinth = require("modrinth-api");
modrinth.getModVersion("Version id").then((result) => {
console.log(result);
});