UNPKG

@zikeji/hypixel

Version:

With IntelliSense support & test coverage, this is an unopinionated async/await API wrapper for Hypixel's Public API. It is developed in TypeScript complete with documentation, typed interfaces for all API responses, built-in rate-limit handling, flexible

33 lines (31 loc) 1.05 kB
import { Paths } from "../../types/api"; import { Method } from "../../util/Method"; import { getResultObject, ResultObject } from "../../util/ResultObject"; import type { SkyblockMuseumResponse } from "../../types/AugmentedTypes"; /** * @example * ```typescript * const museum = await client.skyblock.museum.profile("20934ef9488c465180a78f861586b4cf"); * ``` * @category Client */ export class SkyBlockMuseum extends Method { /** * SkyBlock museum data for all members of the provided profile. The data returned can differ depending on the players in-game API settings. * @example * ```typescript * const museum = await client.skyblock.museum.profile("20934ef9488c465180a78f861586b4cf"); * ``` * @category API */ public async profile( uuid: Paths.V2SkyblockMuseum.Get.Parameters.Profile ): Promise<ResultObject<SkyblockMuseumResponse, ["profile"]>> { return getResultObject( await this.client.call<SkyblockMuseumResponse>("skyblock/museum", { uuid, }), ["profile"] ); } }