Class ModrinthV2Client
🏭 Constructors
constructor
new ModrinthV2Client(options: ModrinthClientOptions): ModrinthV2Client
Parameters
- options:
ModrinthClientOptions
Return Type
ModrinthV2Client
Defined in: packages/modrinth/index.ts:185
🏷️ Properties
baseUrl private
baseUrl: string
Defined in: packages/modrinth/index.ts:181
dispatcher private optional
dispatcher: Dispatcher
Defined in: packages/modrinth/index.ts:182
headers
headers: Record<string, string>
Defined in: packages/modrinth/index.ts:183
🔧 Methods
getCategoryTags
getCategoryTags(signal: AbortSignal): Promise<Category[]>
Parameters
- signal:
AbortSignal
Return Type
Promise<Category[]>
Defined in: packages/modrinth/index.ts:397
getGameVersionTags
getGameVersionTags(signal: AbortSignal): Promise<GameVersion[]>
Parameters
- signal:
AbortSignal
Return Type
Promise<GameVersion[]>
Defined in: packages/modrinth/index.ts:414
getLatestProjectVersion
getLatestProjectVersion(sha1: string, __namedParameters: Object= {}, signal: AbortSignal): Promise<ProjectVersion>
Parameters
- sha1:
string
- __namedParameters:
Object
- signal:
AbortSignal
Return Type
Promise<ProjectVersion>
Defined in: packages/modrinth/index.ts:357
getLatestVersionsFromHashes
getLatestVersionsFromHashes(hashes: string[], __namedParameters: Object= {}, signal: AbortSignal): Promise<Record<string, ProjectVersion>>
Parameters
- hashes:
string[]
- __namedParameters:
Object
- signal:
AbortSignal
Return Type
Promise<Record<string, ProjectVersion>>
Defined in: packages/modrinth/index.ts:333
getLicenseTags
getLicenseTags(signal: AbortSignal): Promise<License[]>
Parameters
- signal:
AbortSignal
Return Type
Promise<License[]>
Defined in: packages/modrinth/index.ts:380
getLoaderTags
getLoaderTags(signal: AbortSignal): Promise<Loader[]>
Parameters
- signal:
AbortSignal
Return Type
Promise<Loader[]>
Defined in: packages/modrinth/index.ts:431
getProject
getProject(projectId: string, signal: AbortSignal): Promise<Project>
Parameters
- projectId:
string
- signal:
AbortSignal
Return Type
Promise<Project>
Defined in: packages/modrinth/index.ts:217
getProjectTeamMembers
getProjectTeamMembers(projectId: string, signal: AbortSignal): Promise<TeamMember[]>
Parameters
- projectId:
string
- signal:
AbortSignal
Return Type
Promise<TeamMember[]>
Defined in: packages/modrinth/index.ts:448
getProjectVersion
getProjectVersion(versionId: string, signal: AbortSignal): Promise<ProjectVersion>
Parameters
- versionId:
string
- signal:
AbortSignal
Return Type
Promise<ProjectVersion>
Defined in: packages/modrinth/index.ts:273
getProjectVersions
getProjectVersions(projectId: string, __namedParameters: Object= {}, signal: AbortSignal): Promise<ProjectVersion[]>
Parameters
- projectId:
string
- __namedParameters:
Object
- signal:
AbortSignal
Return Type
Promise<ProjectVersion[]>
Defined in: packages/modrinth/index.ts:253
getProjectVersionsByHash
getProjectVersionsByHash(hashes: string[], algorithm: string= 'sha1', signal: AbortSignal): Promise<Record<string, ProjectVersion>>
Parameters
- hashes:
string[]
- algorithm:
string
- signal:
AbortSignal
Return Type
Promise<Record<string, ProjectVersion>>
Defined in: packages/modrinth/index.ts:308
getProjectVersionsById
getProjectVersionsById(ids: string[], signal: AbortSignal): Promise<ProjectVersion[]>
Parameters
- ids:
string[]
- signal:
AbortSignal
Return Type
Promise<ProjectVersion[]>
Defined in: packages/modrinth/index.ts:290
getProjects
getProjects(projectIds: string[], signal: AbortSignal): Promise<Project[]>
Parameters
- projectIds:
string[]
- signal:
AbortSignal
Return Type
Promise<Project[]>
Defined in: packages/modrinth/index.ts:235
getUser
getUser(id: string, signal: AbortSignal): Promise<User>
Parameters
- id:
string
- signal:
AbortSignal
Return Type
Promise<User>
Defined in: packages/modrinth/index.ts:465
getUserProjects
getUserProjects(id: string, signal: AbortSignal): Promise<Project[]>
Parameters
- id:
string
- signal:
AbortSignal
Return Type
Promise<Project[]>
Defined in: packages/modrinth/index.ts:482
searchProjects
searchProjects(options: SearchProjectOptions, signal: AbortSignal): Promise<SearchResult>
Parameters
- options:
SearchProjectOptions
- signal:
AbortSignal
Return Type
Promise<SearchResult>
Defined in: packages/modrinth/index.ts:194