fix: paper/purpur vers mismatch (#5687)

* fix: paper/purpur

* fix: use fill api

* fix: lint
This commit is contained in:
Calum H.
2026-03-27 17:24:16 +00:00
committed by GitHub
parent 87122cf9bd
commit e6b061f38c
8 changed files with 96 additions and 25 deletions

View File

@@ -1,6 +1,11 @@
export namespace Paper {
export namespace Versions {
export namespace v3 {
export type Project = {
project: { id: string; name: string }
versions: Record<string, string[]>
}
export type VersionBuilds = {
builds: number[]
}

View File

@@ -12,6 +12,13 @@ export class PaperVersionsV3Module extends AbstractModule {
return 'paper_versions_v3'
}
/**
* Get the Paper project info including all supported Minecraft versions.
*/
public async getProject(): Promise<Paper.Versions.v3.Project> {
return $fetch<Paper.Versions.v3.Project>(`${BASE_URL}/projects/paper`)
}
/**
* Get available Paper builds for a Minecraft version.
*