@blizzard-api/classic-wow 1.1.4 → 1.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -63,7 +63,7 @@ Because there are multiple classic flavours of the game, each endpoint will take
63
63
 
64
64
  ## Notes on Types
65
65
 
66
- The types are manually created from using the Blizzard API documentation, and are as accurate as possible with smoke testing each endpoint. However, no-one is perfect so there is likely be some discrepancies. If you encounter any issues with the types from this package, please open an issue or a pull request.
66
+ The types are manually created from using the Blizzard API documentation, and are as accurate as possible with smoke testing each endpoint. However, no-one is perfect so there is likely to be some discrepancies. If you encounter any issues with the types from this package, please open an issue or a pull request.
67
67
 
68
68
  ## Client
69
69
 
@@ -1 +1 @@
1
- {"version":3,"sources":["../../wow/src/base.ts","../src/auction-house/auction-house.ts","../src/connected-realm/connected-realm.ts","../src/creature/creature.ts","../src/guild-crest/guild-crest.ts","../src/item/item.ts","../src/media-search/media-search.ts","../src/playable-class/playable-class.ts","../src/playable-race/playable-race.ts","../src/power-type/power-type.ts","../src/pvp-season/pvp-season.ts","../src/realm/realm.ts","../src/region/region.ts","../src/index.ts"],"names":[],"mappings":";;;;;AASO,IAAM,IAAO,GAAA,WAAA,CAAA;AAKb,IAAM,SAAA,GAAY,GAAG,IAAI,CAAA,MAAA,CAAA,CAAA;AAKzB,IAAM,UAAA,GAAa,GAAG,IAAI,CAAA,OAAA,CAAA,CAAA;;;ACT1B,SAAS,iBAAA,CACd,WACA,gBACqC,EAAA;AACrC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAM,EAAA,CAAA,EAAG,IAAI,CAAA,iBAAA,EAAoB,gBAAgB,CAAA,eAAA,CAAA;AAAA,GACnD,CAAA;AACF,CAAA;AAYO,SAAS,QAAA,CACd,SACA,EAAA,gBAAA,EACA,cAC4B,EAAA;AAC5B,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,MAAM,CAAG,EAAA,IAAI,CAAo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B,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAA,EAAM,GAAG,IAAI,CAAA,aAAA,CAAA;AAAA,GACf,CAAA;AACF,CAAA;;;ACAO,IAAM,UAAa,GAAA;AAAA;AAAA,EAExB,iBAAA;AAAA,EACA,QAAA;AAAA;AAAA,EAEA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,oBAAA;AAAA;AAAA,EAEA,QAAA;AAAA,EACA,oBAAA;AAAA,EACA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,mBAAA;AAAA,EACA,cAAA;AAAA,EACA,YAAA;AAAA,EACA,iBAAA;AAAA;AAAA,EAEA,gBAAA;AAAA,EACA,yBAAA;AAAA,EACA,gBAAA;AAAA;AAAA,EAEA,IAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA,EACA,SAAA;AAAA,EACA,UAAA;AAAA,EACA,YAAA;AAAA;AAAA,EAEA,WAAA;AAAA;AAAA,EAEA,aAAA;AAAA,EACA,kBAAA;AAAA,EACA,kBAAA;AAAA;AAAA,EAEA,YAAA;AAAA,EACA,iBAAA;AAAA;AAAA,EAEA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,iBAAA;AAAA,EACA,sBAAA;AAAA,EACA,cAAA;AAAA,EACA,eAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,KAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA;AAAA,EAEA,MAAA;AAAA,EACA,WAAA;AACF,EAAA;AACA,IAAO,WAAQ,GAAA","file":"index.cjs","sourcesContent":["/**\r\n * @file base.ts\r\n * @module base\r\n * @description Contains base constants and interfaces for the Blizzard API.\r\n */\r\n\r\n/**\r\n * The base request path for the Blizzard API for world of warcraft.\r\n */\r\nexport const base = '/data/wow';\r\n\r\n/**\r\n * The base request path for media in the Blizzard API for world of warcraft.\r\n */\r\nexport const mediaBase = `${base}/media` as const;\r\n\r\n/**\r\n * The base request path for search in the Blizzard API for world of warcraft.\r\n */\r\nexport const searchBase = `${base}/search` as const;\r\n\r\n/**\r\n * Base interface for Blizzard API responses.\r\n */\r\nexport interface ResponseBase {\r\n _links: {\r\n self: {\r\n href: string;\r\n };\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing key.href property that often appear in Blizzard API responses.\r\n */\r\nexport interface KeyBase {\r\n key: {\r\n href: string;\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing name and id properties that often appear together in Blizzard API responses.\r\n */\r\nexport interface NameId {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n/**\r\n * Base record containing both {@link KeyBase} and {@link NameId} interfaces.\r\n */\r\nexport interface NameIdKey extends KeyBase, NameId {}\r\n\r\n/**\r\n * A record containing the RGBA values of a color.\r\n */\r\nexport interface Color {\r\n a: number;\r\n b: number;\r\n g: number;\r\n r: number;\r\n}\r\n\r\n/**\r\n * The media asset associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface MediaAsset {\r\n file_data_id: number;\r\n key: string;\r\n value: string;\r\n}\r\n\r\n/**\r\n * The playable genders in World of Warcraft.\r\n */\r\nexport interface Gender {\r\n female: string;\r\n male: string;\r\n}\r\n\r\n/**\r\n * The playable factions in World of Warcraft.\r\n */\r\nexport const Factions = {\r\n ALLIANCE: 'ALLIANCE',\r\n HORDE: 'HORDE',\r\n} as const;\r\n\r\n/**\r\n * The faction associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Faction {\r\n name: Capitalize<Lowercase<keyof typeof Factions>>;\r\n type: keyof typeof Factions;\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { AuctionHouseIndexResponse, AuctionsResponse } from './types';\r\n\r\n/**\r\n * Returns an index of auction houses for a connected realm.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @returns The auction house index. See {@link AuctionHouseIndexResponse}.\r\n */\r\nexport function auctionHouseIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<AuctionHouseIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/index`,\r\n };\r\n}\r\n/**\r\n * Returns all active auctions for a specific auction house on a connected realm.\r\n *\r\n * Auction house data updates at a set interval. The value was initially set at 1 hour; however, it might change over time without notice.\r\n *\r\n * Depending on the number of active auctions on the specified connected realm, the response from this endpoint may be rather large, sometimes exceeding 10 MB.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @param auctionHouseId The ID of the auction house.\r\n * @returns The auction house data. See {@link AuctionsResponse}.\r\n */\r\nexport function auctions(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n auctionHouseId: number,\r\n): Resource<AuctionsResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/${auctionHouseId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type {\r\n ConnectedRealmIndexResponse,\r\n ConnectedRealmResponse,\r\n ConnectedRealmSearchParameters,\r\n ConnectedRealmSearchResponseItem,\r\n} from './types';\r\n\r\n/**\r\n * Returns an index of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The connected realm index. See {@link ConnectedRealmIndexResponse}.\r\n */\r\nexport function connectedRealmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<ConnectedRealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/index`,\r\n };\r\n}\r\n/**\r\n * Returns a connected realm by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The connected realm ID.\r\n * @returns The connected realm. See {@link ConnectedRealmResponse}.\r\n */\r\nexport function connectedRealm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<ConnectedRealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}`,\r\n };\r\n}\r\n/**\r\n * Performs a search of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ConnectedRealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse} & {@link ConnectedRealmSearchResponseItem}.\r\n */\r\nexport function connectedRealmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: ConnectedRealmSearchParameters,\r\n): Resource<SearchResponse<ConnectedRealmSearchResponseItem>, ConnectedRealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n 'realms.timezone': options['realms.timezone'],\r\n 'status.type': options['status.type'],\r\n },\r\n path: `${base}/search/connected-realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n CreatureDisplayMediaResponse,\r\n CreatureFamilyIndexResponse,\r\n CreatureFamilyMediaResponse,\r\n CreatureFamilyResponse,\r\n CreatureResponse,\r\n CreatureSearchParameters,\r\n CreatureSearchResponseItem,\r\n CreatureTypeIndexResponse,\r\n CreatureTypeResponse,\r\n} from './types';\r\n\r\n/**\r\n * Returns a creature by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureId The creature ID.\r\n * @returns The creature. See {@link CreatureResponse}.\r\n */\r\nexport function creature(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureId: number,\r\n): Resource<CreatureResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature/${creatureId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature display by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureDisplayId The creature display ID.\r\n * @returns The creature display media. See {@link CreatureDisplayMediaResponse}.\r\n */\r\nexport function creatureDisplayMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureDisplayId: number,\r\n): Resource<CreatureDisplayMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-display/${creatureDisplayId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family. See {@link CreatureFamilyResponse}.\r\n */\r\nexport function creatureFamily(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature families.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature family index. See {@link CreatureFamilyIndexResponse}.\r\n */\r\nexport function creatureFamilyIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureFamilyIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family media. See {@link CreatureFamilyMediaResponse}.\r\n */\r\nexport function creatureFamilyMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureTypeId The creature type ID.\r\n * @returns The creature type. See {@link CreatureTypeResponse}.\r\n */\r\nexport function creatureType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureTypeId: number,\r\n): Resource<CreatureTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/${creatureTypeId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature types.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature type index. See {@link CreatureTypeIndexResponse}.\r\n */\r\nexport function creatureTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/index`,\r\n };\r\n}\r\n/**\r\n * Performs a search of creatures.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The creature search parameters. See {@link CreatureSearchParameters}.\r\n * @returns The creature search results. See {@link SearchResponse} & {@link CreatureSearchResponseItem}.\r\n */\r\nexport function creatureSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: CreatureSearchParameters,\r\n): Resource<SearchResponse<CreatureSearchResponseItem>, Omit<CreatureSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/creature`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { GuildCrestBorderEmblemResponse, GuildCrestComponentsIndexResponse } from './types';\r\n\r\n/**\r\n * Returns an index of guild crest media.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The guild crest components index. See {@link GuildCrestComponentsIndexResponse}.\r\n */\r\nexport function guildCrestComponentsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<GuildCrestComponentsIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/guild-crest/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest border by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param borderId The guild crest border ID.\r\n * @returns The guild crest border. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestBorder(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n borderId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/border/${borderId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest emblem by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param emblemId The guild crest emblem ID.\r\n * @returns The guild crest emblem. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestEmblem(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n emblemId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/emblem/${emblemId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n ItemClassIndexResponse,\r\n ItemClassResponse,\r\n ItemMediaResponse,\r\n ItemResponse,\r\n ItemSearchParameters,\r\n ItemSearchResponseItem,\r\n ItemSubClassResponse,\r\n} from './types';\r\n\r\n/**\r\n * Get an item class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The item class index. See {@link ItemClassIndexResponse}.\r\n */\r\nexport function itemClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<ItemClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/index`,\r\n };\r\n}\r\n/**\r\n * Get an item class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @returns The item class. See {@link ItemClassResponse}.\r\n */\r\nexport function itemClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n): Resource<ItemClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item subclass by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @param itemSubclassId The item subclass ID.\r\n * @returns The item subclass. See {@link ItemSubClassResponse}.\r\n */\r\nexport function itemSubClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n itemSubclassId: number,\r\n): Resource<ItemSubClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}/item-subclass/${itemSubclassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item. See {@link ItemResponse}.\r\n */\r\nexport function item(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Get item media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item media. See {@link ItemMediaResponse}.\r\n */\r\nexport function itemMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Search for items.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ItemSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function itemSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: ItemSearchParameters,\r\n): Resource<SearchResponse<ItemSearchResponseItem>, Omit<ItemSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/item`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { searchBase } from '../../../wow/src/base';\r\nimport type { MediaSearchParameters, MediaSearchResponseItem } from './types';\r\n\r\n/**\r\n * Search for media.\r\n * @param options The search parameters. See {@link MediaSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function mediaSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: MediaSearchParameters,\r\n): Resource<SearchResponse<MediaSearchResponseItem>, MediaSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n tags: options.tags,\r\n },\r\n path: `${searchBase}/media`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { PlayableClassIndexResponse, PlayableClassMediaResponse, PlayableClassResponse } from './types';\r\n\r\n/**\r\n * Get a playable class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class. See {@link PlayableClassResponse}.\r\n */\r\nexport function playableClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable class index. See {@link PlayableClassIndexResponse}.\r\n */\r\nexport function playableClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/index`,\r\n };\r\n}\r\n/**\r\n * Get playable class media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class media. See {@link PlayableClassMediaResponse}.\r\n */\r\nexport function playableClassMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PlayableRaceIndexResponse, PlayableRaceResponse } from './types';\r\n\r\n/**\r\n * Get a playable race by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableRaceId The playable race ID.\r\n * @returns The playable race. See {@link PlayableRaceResponse}.\r\n */\r\nexport function playableRace(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableRaceId: number,\r\n): Resource<PlayableRaceResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/${playableRaceId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable race index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable race index. See {@link PlayableRaceIndexResponse}.\r\n */\r\nexport function playableRaceIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableRaceIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PowerTypeIndexResponse, PowerTypeResponse } from './types';\r\n\r\n/**\r\n * Get a power type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param powerTypeId The power type ID.\r\n * @returns The power type. See {@link PowerTypeResponse}.\r\n */\r\nexport function powerType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n powerTypeId: number,\r\n): Resource<PowerTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/${powerTypeId}`,\r\n };\r\n}\r\n/**\r\n * Get a power type index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The power type index. See {@link PowerTypeIndexResponse}.\r\n */\r\nexport function powerTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PowerTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PvpSeasonIndexResponse, PvpSeasonResponse } from './types';\r\n\r\n/**\r\n * Get a PvP season index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP season by ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @returns The PvP season. See {@link PvpSeasonResponse}.\r\n */\r\nexport function pvpSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpSeasonId: number,\r\n): Resource<PvpSeasonResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Regions.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n */\r\nexport function pvpRegionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/index`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Seasons in a PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpRegionalSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Returns a PvP season by region ID and season ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRegionalSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP leaderboards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpLeaderboardIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP leaderboard by PvP season ID and bracket.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @param pvpBracket The PvP bracket.\r\n */\r\nexport function pvpLeaderboard(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n pvpBracket: string,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/${pvpBracket}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP rewards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRewardsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-reward/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, searchBase } from '../../../wow/src/base';\r\nimport type { RealmIndexResponse, RealmResponse, RealmSearchParameters, RealmSearchResponseItem } from './types';\r\n\r\n/**\r\n * Get a realm by slug.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param realmSlug The realm slug.\r\n * @returns The realm. See {@link RealmResponse}.\r\n */\r\nexport function realm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n realmSlug: string,\r\n): Resource<RealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/${realmSlug}`,\r\n };\r\n}\r\n/**\r\n * Get a realm index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The realm index. See {@link RealmIndexResponse}.\r\n */\r\nexport function realmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/index`,\r\n };\r\n}\r\n/**\r\n * Search for realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link RealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function realmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: RealmSearchParameters,\r\n): Resource<SearchResponse<RealmSearchResponseItem>, RealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n timezone: options.timezone,\r\n },\r\n path: `${searchBase}/realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { RegionIndexResponse, RegionResponse } from './types';\r\n\r\n/**\r\n * Get a region by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param regionId The region ID.\r\n * @returns The region. See {@link RegionResponse}.\r\n */\r\nexport function region(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n regionId: number,\r\n): Resource<RegionResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/${regionId}`,\r\n };\r\n}\r\n/**\r\n * Get a region index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The region index. See {@link RegionIndexResponse}.\r\n */\r\nexport function regionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RegionIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/index`,\r\n };\r\n}\r\n","import { auctionHouseIndex, auctions } from './auction-house/auction-house';\r\nimport { connectedRealm, connectedRealmIndex, connectedRealmSearch } from './connected-realm/connected-realm';\r\nimport {\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n} from './creature/creature';\r\nimport { guildCrestBorder, guildCrestComponentsIndex, guildCrestEmblem } from './guild-crest/guild-crest';\r\nimport { item, itemClass, itemClassIndex, itemMedia, itemSearch, itemSubClass } from './item/item';\r\nimport { mediaSearch } from './media-search/media-search';\r\nimport { playableClass, playableClassIndex, playableClassMedia } from './playable-class/playable-class';\r\nimport { playableRace, playableRaceIndex } from './playable-race/playable-race';\r\nimport { powerType, powerTypeIndex } from './power-type/power-type';\r\nimport {\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n} from './pvp-season/pvp-season';\r\nimport { realm, realmIndex, realmSearch } from './realm/realm';\r\nimport { region, regionIndex } from './region/region';\r\n\r\nexport const classicWow = {\r\n //Auction House\r\n auctionHouseIndex,\r\n auctions,\r\n //Connected Realm\r\n connectedRealm,\r\n connectedRealmIndex,\r\n connectedRealmSearch,\r\n //Creature\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n //Guild Crest\r\n guildCrestBorder,\r\n guildCrestComponentsIndex,\r\n guildCrestEmblem,\r\n //Item\r\n item,\r\n itemClass,\r\n itemClassIndex,\r\n itemMedia,\r\n itemSearch,\r\n itemSubClass,\r\n //Media Search\r\n mediaSearch,\r\n //Playable Class\r\n playableClass,\r\n playableClassIndex,\r\n playableClassMedia,\r\n //Playable Race\r\n playableRace,\r\n playableRaceIndex,\r\n //Power Type\r\n powerType,\r\n powerTypeIndex,\r\n //Pvp Season\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n //Realm\r\n realm,\r\n realmIndex,\r\n realmSearch,\r\n //Region\r\n region,\r\n regionIndex,\r\n};\r\nexport default classicWow;\r\n\r\n//Auction House\r\nexport * from './auction-house/auction-house';\r\nexport type * from './auction-house/types';\r\n//Connected Realm\r\nexport * from './connected-realm/connected-realm';\r\nexport type * from './connected-realm/types';\r\n//Creature\r\nexport * from './creature/creature';\r\nexport type * from './creature/types';\r\n//Guild Crest\r\nexport * from './guild-crest/guild-crest';\r\nexport type * from './guild-crest/types';\r\n//Item\r\nexport * from './item/item';\r\nexport type * from './item/types';\r\n//Media Search\r\nexport * from './media-search/media-search';\r\nexport type * from './media-search/types';\r\n//Playable Class\r\nexport * from './playable-class/playable-class';\r\nexport type * from './playable-class/types';\r\n//Playable Race\r\nexport * from './playable-race/playable-race';\r\nexport type * from './playable-race/types';\r\n//Power Type\r\nexport * from './power-type/power-type';\r\nexport type * from './power-type/types';\r\n//Pvp Season\r\nexport * from './pvp-season/pvp-season';\r\nexport type * from './pvp-season/types';\r\n//Realm\r\nexport * from './realm/realm';\r\nexport type * from './realm/types';\r\n//Region\r\nexport * from './region/region';\r\nexport type * from './region/types';\r\n"]}
1
+ {"version":3,"sources":["../../wow/src/base.ts","../src/auction-house/auction-house.ts","../src/connected-realm/connected-realm.ts","../src/creature/creature.ts","../src/guild-crest/guild-crest.ts","../src/item/item.ts","../src/media-search/media-search.ts","../src/playable-class/playable-class.ts","../src/playable-race/playable-race.ts","../src/power-type/power-type.ts","../src/pvp-season/pvp-season.ts","../src/realm/realm.ts","../src/region/region.ts","../src/index.ts"],"names":[],"mappings":";;;;;AASO,IAAM,IAAO,GAAA,WAAA,CAAA;AAKb,IAAM,SAAA,GAAY,GAAG,IAAI,CAAA,MAAA,CAAA,CAAA;AAKzB,IAAM,UAAA,GAAa,GAAG,IAAI,CAAA,OAAA,CAAA,CAAA;;;ACT1B,SAAS,iBAAA,CACd,WACA,gBACqC,EAAA;AACrC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAM,EAAA,CAAA,EAAG,IAAI,CAAA,iBAAA,EAAoB,gBAAgB,CAAA,eAAA,CAAA;AAAA,GACnD,CAAA;AACF,CAAA;AAYO,SAAS,QAAA,CACd,SACA,EAAA,gBAAA,EACA,cAC4B,EAAA;AAC5B,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,MAAM,CAAG,EAAA,IAAI,CAAoB,iBAAA,EAAA,gBAAgB,aAAa,cAAc,CAAA,CAAA;AAAA,GAC9E,CAAA;AACF,CAAA;;;ACzBO,SAAS,oBACd,SACuC,EAAA;AACvC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAA,EAAM,GAAG,IAAI,CAAA,sBAAA,CAAA;AAAA,GACf,CAAA;AACF,CAAA;AAOO,SAAS,cAAA,C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AAA,EAEA,QAAA;AAAA,EACA,oBAAA;AAAA,EACA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,mBAAA;AAAA,EACA,cAAA;AAAA,EACA,YAAA;AAAA,EACA,iBAAA;AAAA;AAAA,EAEA,gBAAA;AAAA,EACA,yBAAA;AAAA,EACA,gBAAA;AAAA;AAAA,EAEA,IAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA,EACA,SAAA;AAAA,EACA,UAAA;AAAA,EACA,YAAA;AAAA;AAAA,EAEA,WAAA;AAAA;AAAA,EAEA,aAAA;AAAA,EACA,kBAAA;AAAA,EACA,kBAAA;AAAA;AAAA,EAEA,YAAA;AAAA,EACA,iBAAA;AAAA;AAAA,EAEA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,iBAAA;AAAA,EACA,sBAAA;AAAA,EACA,cAAA;AAAA,EACA,eAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,KAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA;AAAA,EAEA,MAAA;AAAA,EACA,WAAA;AACF,EAAA;AACA,IAAO,WAAQ,GAAA","file":"index.cjs","sourcesContent":["/**\r\n * @file base.ts\r\n * @module base\r\n * @description Contains base constants and interfaces for the Blizzard API.\r\n */\r\n\r\n/**\r\n * The base request path for the Blizzard API for world of warcraft.\r\n */\r\nexport const base = '/data/wow';\r\n\r\n/**\r\n * The base request path for media in the Blizzard API for world of warcraft.\r\n */\r\nexport const mediaBase = `${base}/media` as const;\r\n\r\n/**\r\n * The base request path for search in the Blizzard API for world of warcraft.\r\n */\r\nexport const searchBase = `${base}/search` as const;\r\n\r\n/**\r\n *\r\n */\r\n\r\nexport interface Href {\r\n href: string;\r\n}\r\n/**\r\n * Base interface for Blizzard API responses.\r\n */\r\nexport interface ResponseBase {\r\n _links: {\r\n self: Href;\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing key.href property that often appear in Blizzard API responses.\r\n */\r\nexport interface KeyBase {\r\n key: Href;\r\n}\r\n\r\n/**\r\n * Base record interface containing name and id properties that often appear together in Blizzard API responses.\r\n */\r\nexport interface NameId {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n/**\r\n * Base record containing both {@link KeyBase} and {@link NameId} interfaces.\r\n */\r\nexport interface NameIdKey extends KeyBase, NameId {}\r\n\r\n/**\r\n * A record containing the RGBA values of a color.\r\n */\r\nexport interface Color {\r\n a: number;\r\n b: number;\r\n g: number;\r\n r: number;\r\n}\r\n\r\n/**\r\n * The media asset associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface MediaAsset {\r\n file_data_id: number;\r\n key: string;\r\n value: string;\r\n}\r\n\r\n/**\r\n * The playable gender names/descriptions in World of Warcraft.\r\n */\r\nexport interface GenderName {\r\n female: string;\r\n male: string;\r\n}\r\n\r\n/**\r\n * The playable genders in World of Warcraft.\r\n */\r\nexport const Genders = {\r\n FEMALE: 'FEMALE',\r\n MALE: 'MALE',\r\n} as const;\r\n\r\n/**\r\n * The gender associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Gender {\r\n name: Capitalize<Lowercase<keyof typeof Genders>>;\r\n type: keyof typeof Genders;\r\n}\r\n\r\n/**\r\n * The playable factions in World of Warcraft.\r\n */\r\nexport const Factions = {\r\n ALLIANCE: 'ALLIANCE',\r\n HORDE: 'HORDE',\r\n} as const;\r\n\r\n/**\r\n * The faction associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Faction {\r\n name: Capitalize<Lowercase<keyof typeof Factions>>;\r\n type: keyof typeof Factions;\r\n}\r\n\r\n/**\r\n * The standard structure to represent a World of Warcraft Realm.\r\n */\r\nexport interface Realm extends NameIdKey {\r\n slug: string;\r\n}\r\n\r\n/**\r\n * The standard structure to represent a World of Warcraft Character.\r\n */\r\nexport interface Character extends NameIdKey {\r\n realm: Realm;\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { AuctionHouseIndexResponse, AuctionsResponse } from './types';\r\n\r\n/**\r\n * Returns an index of auction houses for a connected realm.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @returns The auction house index. See {@link AuctionHouseIndexResponse}.\r\n */\r\nexport function auctionHouseIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<AuctionHouseIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/index`,\r\n };\r\n}\r\n/**\r\n * Returns all active auctions for a specific auction house on a connected realm.\r\n *\r\n * Auction house data updates at a set interval. The value was initially set at 1 hour; however, it might change over time without notice.\r\n *\r\n * Depending on the number of active auctions on the specified connected realm, the response from this endpoint may be rather large, sometimes exceeding 10 MB.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @param auctionHouseId The ID of the auction house.\r\n * @returns The auction house data. See {@link AuctionsResponse}.\r\n */\r\nexport function auctions(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n auctionHouseId: number,\r\n): Resource<AuctionsResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/${auctionHouseId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type {\r\n ConnectedRealmIndexResponse,\r\n ConnectedRealmResponse,\r\n ConnectedRealmSearchParameters,\r\n ConnectedRealmSearchResponseItem,\r\n} from './types';\r\n\r\n/**\r\n * Returns an index of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The connected realm index. See {@link ConnectedRealmIndexResponse}.\r\n */\r\nexport function connectedRealmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<ConnectedRealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/index`,\r\n };\r\n}\r\n/**\r\n * Returns a connected realm by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The connected realm ID.\r\n * @returns The connected realm. See {@link ConnectedRealmResponse}.\r\n */\r\nexport function connectedRealm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<ConnectedRealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}`,\r\n };\r\n}\r\n/**\r\n * Performs a search of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ConnectedRealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse} & {@link ConnectedRealmSearchResponseItem}.\r\n */\r\nexport function connectedRealmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: ConnectedRealmSearchParameters,\r\n): Resource<SearchResponse<ConnectedRealmSearchResponseItem>, ConnectedRealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n 'realms.timezone': options['realms.timezone'],\r\n 'status.type': options['status.type'],\r\n },\r\n path: `${base}/search/connected-realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n CreatureDisplayMediaResponse,\r\n CreatureFamilyIndexResponse,\r\n CreatureFamilyMediaResponse,\r\n CreatureFamilyResponse,\r\n CreatureResponse,\r\n CreatureSearchParameters,\r\n CreatureSearchResponseItem,\r\n CreatureTypeIndexResponse,\r\n CreatureTypeResponse,\r\n} from './types';\r\n\r\n/**\r\n * Returns a creature by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureId The creature ID.\r\n * @returns The creature. See {@link CreatureResponse}.\r\n */\r\nexport function creature(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureId: number,\r\n): Resource<CreatureResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature/${creatureId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature display by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureDisplayId The creature display ID.\r\n * @returns The creature display media. See {@link CreatureDisplayMediaResponse}.\r\n */\r\nexport function creatureDisplayMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureDisplayId: number,\r\n): Resource<CreatureDisplayMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-display/${creatureDisplayId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family. See {@link CreatureFamilyResponse}.\r\n */\r\nexport function creatureFamily(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature families.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature family index. See {@link CreatureFamilyIndexResponse}.\r\n */\r\nexport function creatureFamilyIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureFamilyIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family media. See {@link CreatureFamilyMediaResponse}.\r\n */\r\nexport function creatureFamilyMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureTypeId The creature type ID.\r\n * @returns The creature type. See {@link CreatureTypeResponse}.\r\n */\r\nexport function creatureType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureTypeId: number,\r\n): Resource<CreatureTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/${creatureTypeId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature types.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature type index. See {@link CreatureTypeIndexResponse}.\r\n */\r\nexport function creatureTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/index`,\r\n };\r\n}\r\n/**\r\n * Performs a search of creatures.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The creature search parameters. See {@link CreatureSearchParameters}.\r\n * @returns The creature search results. See {@link SearchResponse} & {@link CreatureSearchResponseItem}.\r\n */\r\nexport function creatureSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: CreatureSearchParameters,\r\n): Resource<SearchResponse<CreatureSearchResponseItem>, Omit<CreatureSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/creature`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { GuildCrestBorderEmblemResponse, GuildCrestComponentsIndexResponse } from './types';\r\n\r\n/**\r\n * Returns an index of guild crest media.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The guild crest components index. See {@link GuildCrestComponentsIndexResponse}.\r\n */\r\nexport function guildCrestComponentsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<GuildCrestComponentsIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/guild-crest/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest border by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param borderId The guild crest border ID.\r\n * @returns The guild crest border. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestBorder(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n borderId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/border/${borderId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest emblem by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param emblemId The guild crest emblem ID.\r\n * @returns The guild crest emblem. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestEmblem(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n emblemId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/emblem/${emblemId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n ItemClassIndexResponse,\r\n ItemClassResponse,\r\n ItemMediaResponse,\r\n ItemResponse,\r\n ItemSearchParameters,\r\n ItemSearchResponseItem,\r\n ItemSubClassResponse,\r\n} from './types';\r\n\r\n/**\r\n * Get an item class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The item class index. See {@link ItemClassIndexResponse}.\r\n */\r\nexport function itemClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<ItemClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/index`,\r\n };\r\n}\r\n/**\r\n * Get an item class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @returns The item class. See {@link ItemClassResponse}.\r\n */\r\nexport function itemClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n): Resource<ItemClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item subclass by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @param itemSubclassId The item subclass ID.\r\n * @returns The item subclass. See {@link ItemSubClassResponse}.\r\n */\r\nexport function itemSubClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n itemSubclassId: number,\r\n): Resource<ItemSubClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}/item-subclass/${itemSubclassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item. See {@link ItemResponse}.\r\n */\r\nexport function item(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Get item media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item media. See {@link ItemMediaResponse}.\r\n */\r\nexport function itemMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Search for items.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ItemSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function itemSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: ItemSearchParameters,\r\n): Resource<SearchResponse<ItemSearchResponseItem>, Omit<ItemSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/item`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { searchBase } from '../../../wow/src/base';\r\nimport type { MediaSearchParameters, MediaSearchResponseItem } from './types';\r\n\r\n/**\r\n * Search for media.\r\n * @param options The search parameters. See {@link MediaSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function mediaSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: MediaSearchParameters,\r\n): Resource<SearchResponse<MediaSearchResponseItem>, MediaSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n tags: options.tags,\r\n },\r\n path: `${searchBase}/media`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { PlayableClassIndexResponse, PlayableClassMediaResponse, PlayableClassResponse } from './types';\r\n\r\n/**\r\n * Get a playable class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class. See {@link PlayableClassResponse}.\r\n */\r\nexport function playableClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable class index. See {@link PlayableClassIndexResponse}.\r\n */\r\nexport function playableClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/index`,\r\n };\r\n}\r\n/**\r\n * Get playable class media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class media. See {@link PlayableClassMediaResponse}.\r\n */\r\nexport function playableClassMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PlayableRaceIndexResponse, PlayableRaceResponse } from './types';\r\n\r\n/**\r\n * Get a playable race by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableRaceId The playable race ID.\r\n * @returns The playable race. See {@link PlayableRaceResponse}.\r\n */\r\nexport function playableRace(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableRaceId: number,\r\n): Resource<PlayableRaceResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/${playableRaceId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable race index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable race index. See {@link PlayableRaceIndexResponse}.\r\n */\r\nexport function playableRaceIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableRaceIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PowerTypeIndexResponse, PowerTypeResponse } from './types';\r\n\r\n/**\r\n * Get a power type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param powerTypeId The power type ID.\r\n * @returns The power type. See {@link PowerTypeResponse}.\r\n */\r\nexport function powerType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n powerTypeId: number,\r\n): Resource<PowerTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/${powerTypeId}`,\r\n };\r\n}\r\n/**\r\n * Get a power type index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The power type index. See {@link PowerTypeIndexResponse}.\r\n */\r\nexport function powerTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PowerTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PvpSeasonIndexResponse, PvpSeasonResponse } from './types';\r\n\r\n/**\r\n * Get a PvP season index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP season by ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @returns The PvP season. See {@link PvpSeasonResponse}.\r\n */\r\nexport function pvpSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpSeasonId: number,\r\n): Resource<PvpSeasonResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Regions.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n */\r\nexport function pvpRegionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/index`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Seasons in a PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpRegionalSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Returns a PvP season by region ID and season ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRegionalSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP leaderboards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpLeaderboardIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP leaderboard by PvP season ID and bracket.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @param pvpBracket The PvP bracket.\r\n */\r\nexport function pvpLeaderboard(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n pvpBracket: string,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/${pvpBracket}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP rewards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRewardsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-reward/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, searchBase } from '../../../wow/src/base';\r\nimport type { RealmIndexResponse, RealmResponse, RealmSearchParameters, RealmSearchResponseItem } from './types';\r\n\r\n/**\r\n * Get a realm by slug.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param realmSlug The realm slug.\r\n * @returns The realm. See {@link RealmResponse}.\r\n */\r\nexport function realm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n realmSlug: string,\r\n): Resource<RealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/${realmSlug}`,\r\n };\r\n}\r\n/**\r\n * Get a realm index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The realm index. See {@link RealmIndexResponse}.\r\n */\r\nexport function realmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/index`,\r\n };\r\n}\r\n/**\r\n * Search for realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link RealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function realmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: RealmSearchParameters,\r\n): Resource<SearchResponse<RealmSearchResponseItem>, RealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n timezone: options.timezone,\r\n },\r\n path: `${searchBase}/realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { RegionIndexResponse, RegionResponse } from './types';\r\n\r\n/**\r\n * Get a region by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param regionId The region ID.\r\n * @returns The region. See {@link RegionResponse}.\r\n */\r\nexport function region(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n regionId: number,\r\n): Resource<RegionResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/${regionId}`,\r\n };\r\n}\r\n/**\r\n * Get a region index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The region index. See {@link RegionIndexResponse}.\r\n */\r\nexport function regionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RegionIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/index`,\r\n };\r\n}\r\n","import { auctionHouseIndex, auctions } from './auction-house/auction-house';\r\nimport { connectedRealm, connectedRealmIndex, connectedRealmSearch } from './connected-realm/connected-realm';\r\nimport {\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n} from './creature/creature';\r\nimport { guildCrestBorder, guildCrestComponentsIndex, guildCrestEmblem } from './guild-crest/guild-crest';\r\nimport { item, itemClass, itemClassIndex, itemMedia, itemSearch, itemSubClass } from './item/item';\r\nimport { mediaSearch } from './media-search/media-search';\r\nimport { playableClass, playableClassIndex, playableClassMedia } from './playable-class/playable-class';\r\nimport { playableRace, playableRaceIndex } from './playable-race/playable-race';\r\nimport { powerType, powerTypeIndex } from './power-type/power-type';\r\nimport {\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n} from './pvp-season/pvp-season';\r\nimport { realm, realmIndex, realmSearch } from './realm/realm';\r\nimport { region, regionIndex } from './region/region';\r\n\r\nexport const classicWow = {\r\n //Auction House\r\n auctionHouseIndex,\r\n auctions,\r\n //Connected Realm\r\n connectedRealm,\r\n connectedRealmIndex,\r\n connectedRealmSearch,\r\n //Creature\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n //Guild Crest\r\n guildCrestBorder,\r\n guildCrestComponentsIndex,\r\n guildCrestEmblem,\r\n //Item\r\n item,\r\n itemClass,\r\n itemClassIndex,\r\n itemMedia,\r\n itemSearch,\r\n itemSubClass,\r\n //Media Search\r\n mediaSearch,\r\n //Playable Class\r\n playableClass,\r\n playableClassIndex,\r\n playableClassMedia,\r\n //Playable Race\r\n playableRace,\r\n playableRaceIndex,\r\n //Power Type\r\n powerType,\r\n powerTypeIndex,\r\n //Pvp Season\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n //Realm\r\n realm,\r\n realmIndex,\r\n realmSearch,\r\n //Region\r\n region,\r\n regionIndex,\r\n};\r\nexport default classicWow;\r\n\r\n//Auction House\r\nexport * from './auction-house/auction-house';\r\nexport type * from './auction-house/types';\r\n//Connected Realm\r\nexport * from './connected-realm/connected-realm';\r\nexport type * from './connected-realm/types';\r\n//Creature\r\nexport * from './creature/creature';\r\nexport type * from './creature/types';\r\n//Guild Crest\r\nexport * from './guild-crest/guild-crest';\r\nexport type * from './guild-crest/types';\r\n//Item\r\nexport * from './item/item';\r\nexport type * from './item/types';\r\n//Media Search\r\nexport * from './media-search/media-search';\r\nexport type * from './media-search/types';\r\n//Playable Class\r\nexport * from './playable-class/playable-class';\r\nexport type * from './playable-class/types';\r\n//Playable Race\r\nexport * from './playable-race/playable-race';\r\nexport type * from './playable-race/types';\r\n//Power Type\r\nexport * from './power-type/power-type';\r\nexport type * from './power-type/types';\r\n//Pvp Season\r\nexport * from './pvp-season/pvp-season';\r\nexport type * from './pvp-season/types';\r\n//Realm\r\nexport * from './realm/realm';\r\nexport type * from './realm/types';\r\n//Region\r\nexport * from './region/region';\r\nexport type * from './region/types';\r\n"]}
package/dist/index.d.cts CHANGED
@@ -1,22 +1,24 @@
1
1
  import { BlizzardNamespaces, Resource, Locales, BaseSearchParameters, SearchResponse } from '@blizzard-api/core';
2
2
 
3
+ /**
4
+ *
5
+ */
6
+ interface Href {
7
+ href: string;
8
+ }
3
9
  /**
4
10
  * Base interface for Blizzard API responses.
5
11
  */
6
12
  interface ResponseBase {
7
13
  _links: {
8
- self: {
9
- href: string;
10
- };
14
+ self: Href;
11
15
  };
12
16
  }
13
17
  /**
14
18
  * Base record interface containing key.href property that often appear in Blizzard API responses.
15
19
  */
16
20
  interface KeyBase {
17
- key: {
18
- href: string;
19
- };
21
+ key: Href;
20
22
  }
21
23
  /**
22
24
  * Base record interface containing name and id properties that often appear together in Blizzard API responses.
@@ -48,9 +50,9 @@ interface MediaAsset$1 {
48
50
  value: string;
49
51
  }
50
52
  /**
51
- * The playable genders in World of Warcraft.
53
+ * The playable gender names/descriptions in World of Warcraft.
52
54
  */
53
- interface Gender {
55
+ interface GenderName {
54
56
  female: string;
55
57
  male: string;
56
58
  }
@@ -68,6 +70,12 @@ interface Faction {
68
70
  name: Capitalize<Lowercase<keyof typeof Factions>>;
69
71
  type: keyof typeof Factions;
70
72
  }
73
+ /**
74
+ * The standard structure to represent a World of Warcraft Realm.
75
+ */
76
+ interface Realm$1 extends NameIdKey {
77
+ slug: string;
78
+ }
71
79
 
72
80
  interface AuctionHouseIndexResponse extends ResponseBase {
73
81
  auctions: Array<NameIdKey>;
@@ -136,9 +144,6 @@ type RealmType = 'Normal' | 'Roleplaying';
136
144
  interface RealmIndexResponse extends ResponseBase {
137
145
  realms: Array<Realm$1>;
138
146
  }
139
- interface Realm$1 extends NameIdKey {
140
- slug: string;
141
- }
142
147
  /**
143
148
  * The response for a realm.
144
149
  * @see {@link https://develop.battle.net/documentation/world-of-warcraft/game-data-apis}
@@ -856,7 +861,7 @@ interface PlayableClassMediaResponse extends ResponseBase {
856
861
  * @see {@link https://develop.battle.net/documentation/world-of-warcraft-classic/game-data-apis}
857
862
  */
858
863
  interface PlayableClassResponse extends ResponseBase, NameId {
859
- gender_name: Gender;
864
+ gender_name: GenderName;
860
865
  media: Media;
861
866
  playable_races: Array<NameIdKey>;
862
867
  power_type: NameIdKey;
@@ -902,7 +907,7 @@ interface PlayableRaceIndexResponse extends ResponseBase {
902
907
  */
903
908
  interface PlayableRaceResponse extends ResponseBase, NameId {
904
909
  faction: Faction;
905
- gender_name: Gender;
910
+ gender_name: GenderName;
906
911
  is_allied_race: boolean;
907
912
  is_selectable: boolean;
908
913
  playable_classes: Array<NameIdKey>;
package/dist/index.d.ts CHANGED
@@ -1,22 +1,24 @@
1
1
  import { BlizzardNamespaces, Resource, Locales, BaseSearchParameters, SearchResponse } from '@blizzard-api/core';
2
2
 
3
+ /**
4
+ *
5
+ */
6
+ interface Href {
7
+ href: string;
8
+ }
3
9
  /**
4
10
  * Base interface for Blizzard API responses.
5
11
  */
6
12
  interface ResponseBase {
7
13
  _links: {
8
- self: {
9
- href: string;
10
- };
14
+ self: Href;
11
15
  };
12
16
  }
13
17
  /**
14
18
  * Base record interface containing key.href property that often appear in Blizzard API responses.
15
19
  */
16
20
  interface KeyBase {
17
- key: {
18
- href: string;
19
- };
21
+ key: Href;
20
22
  }
21
23
  /**
22
24
  * Base record interface containing name and id properties that often appear together in Blizzard API responses.
@@ -48,9 +50,9 @@ interface MediaAsset$1 {
48
50
  value: string;
49
51
  }
50
52
  /**
51
- * The playable genders in World of Warcraft.
53
+ * The playable gender names/descriptions in World of Warcraft.
52
54
  */
53
- interface Gender {
55
+ interface GenderName {
54
56
  female: string;
55
57
  male: string;
56
58
  }
@@ -68,6 +70,12 @@ interface Faction {
68
70
  name: Capitalize<Lowercase<keyof typeof Factions>>;
69
71
  type: keyof typeof Factions;
70
72
  }
73
+ /**
74
+ * The standard structure to represent a World of Warcraft Realm.
75
+ */
76
+ interface Realm$1 extends NameIdKey {
77
+ slug: string;
78
+ }
71
79
 
72
80
  interface AuctionHouseIndexResponse extends ResponseBase {
73
81
  auctions: Array<NameIdKey>;
@@ -136,9 +144,6 @@ type RealmType = 'Normal' | 'Roleplaying';
136
144
  interface RealmIndexResponse extends ResponseBase {
137
145
  realms: Array<Realm$1>;
138
146
  }
139
- interface Realm$1 extends NameIdKey {
140
- slug: string;
141
- }
142
147
  /**
143
148
  * The response for a realm.
144
149
  * @see {@link https://develop.battle.net/documentation/world-of-warcraft/game-data-apis}
@@ -856,7 +861,7 @@ interface PlayableClassMediaResponse extends ResponseBase {
856
861
  * @see {@link https://develop.battle.net/documentation/world-of-warcraft-classic/game-data-apis}
857
862
  */
858
863
  interface PlayableClassResponse extends ResponseBase, NameId {
859
- gender_name: Gender;
864
+ gender_name: GenderName;
860
865
  media: Media;
861
866
  playable_races: Array<NameIdKey>;
862
867
  power_type: NameIdKey;
@@ -902,7 +907,7 @@ interface PlayableRaceIndexResponse extends ResponseBase {
902
907
  */
903
908
  interface PlayableRaceResponse extends ResponseBase, NameId {
904
909
  faction: Faction;
905
- gender_name: Gender;
910
+ gender_name: GenderName;
906
911
  is_allied_race: boolean;
907
912
  is_selectable: boolean;
908
913
  playable_classes: Array<NameIdKey>;
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../../wow/src/base.ts","../src/auction-house/auction-house.ts","../src/connected-realm/connected-realm.ts","../src/creature/creature.ts","../src/guild-crest/guild-crest.ts","../src/item/item.ts","../src/media-search/media-search.ts","../src/playable-class/playable-class.ts","../src/playable-race/playable-race.ts","../src/power-type/power-type.ts","../src/pvp-season/pvp-season.ts","../src/realm/realm.ts","../src/region/region.ts","../src/index.ts"],"names":[],"mappings":";AASO,IAAM,IAAO,GAAA,WAAA,CAAA;AAKb,IAAM,SAAA,GAAY,GAAG,IAAI,CAAA,MAAA,CAAA,CAAA;AAKzB,IAAM,UAAA,GAAa,GAAG,IAAI,CAAA,OAAA,CAAA,CAAA;;;ACT1B,SAAS,iBAAA,CACd,WACA,gBACqC,EAAA;AACrC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAM,EAAA,CAAA,EAAG,IAAI,CAAA,iBAAA,EAAoB,gBAAgB,CAAA,eAAA,CAAA;AAAA,GACnD,CAAA;AACF,CAAA;AAYO,SAAS,QAAA,CACd,SACA,EAAA,gBAAA,EACA,cAC4B,EAAA;AAC5B,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,MAAM,CAAG,EAAA,IAAI,CAAoB,iBAAA,EAAA,gBAAgB,aAAa,cAAc,CAAA,CAAA;AAAA,GAC9E,CAAA;AACF,CAAA;;;ACzBO,SAAS,oBACd,SACuC,EAAA;AACvC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAA,EAAM,GAAG,IAAI,CAAA,sBAAA,CAAA;AAAA,GACf,CAAA;AACF,CAAA;AAOO,SAAS,cAAA,CACd,WACA,gBACkC,EAAA;AAClC,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,IAAM,EAAA,CAAA,EAAG,IAAI,CAAA,iBAAA,EAAoB,gBAAgB,CAAA,CAAA;AAAA,GACnD,CAAA;AACF,CAAA;AAOO,SAAS,oBAAA,CACd,WACA,OAC4F,EAAA;AAC5F,EAAO,OAAA;AAAA,IACL,SAAA;AAAA,IACA,UAAY,EAAA;AAAA,MACV,OAAO,OAAQ,CAAA,KAA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,YAAA;AAAA;AAAA,EAEA,WAAA;AAAA;AAAA,EAEA,aAAA;AAAA,EACA,kBAAA;AAAA,EACA,kBAAA;AAAA;AAAA,EAEA,YAAA;AAAA,EACA,iBAAA;AAAA;AAAA,EAEA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,cAAA;AAAA,EACA,mBAAA;AAAA,EACA,iBAAA;AAAA,EACA,sBAAA;AAAA,EACA,cAAA;AAAA,EACA,eAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,KAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA;AAAA,EAEA,MAAA;AAAA,EACA,WAAA;AACF,EAAA;AACA,IAAO,WAAQ,GAAA","file":"index.js","sourcesContent":["/**\r\n * @file base.ts\r\n * @module base\r\n * @description Contains base constants and interfaces for the Blizzard API.\r\n */\r\n\r\n/**\r\n * The base request path for the Blizzard API for world of warcraft.\r\n */\r\nexport const base = '/data/wow';\r\n\r\n/**\r\n * The base request path for media in the Blizzard API for world of warcraft.\r\n */\r\nexport const mediaBase = `${base}/media` as const;\r\n\r\n/**\r\n * The base request path for search in the Blizzard API for world of warcraft.\r\n */\r\nexport const searchBase = `${base}/search` as const;\r\n\r\n/**\r\n * Base interface for Blizzard API responses.\r\n */\r\nexport interface ResponseBase {\r\n _links: {\r\n self: {\r\n href: string;\r\n };\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing key.href property that often appear in Blizzard API responses.\r\n */\r\nexport interface KeyBase {\r\n key: {\r\n href: string;\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing name and id properties that often appear together in Blizzard API responses.\r\n */\r\nexport interface NameId {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n/**\r\n * Base record containing both {@link KeyBase} and {@link NameId} interfaces.\r\n */\r\nexport interface NameIdKey extends KeyBase, NameId {}\r\n\r\n/**\r\n * A record containing the RGBA values of a color.\r\n */\r\nexport interface Color {\r\n a: number;\r\n b: number;\r\n g: number;\r\n r: number;\r\n}\r\n\r\n/**\r\n * The media asset associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface MediaAsset {\r\n file_data_id: number;\r\n key: string;\r\n value: string;\r\n}\r\n\r\n/**\r\n * The playable genders in World of Warcraft.\r\n */\r\nexport interface Gender {\r\n female: string;\r\n male: string;\r\n}\r\n\r\n/**\r\n * The playable factions in World of Warcraft.\r\n */\r\nexport const Factions = {\r\n ALLIANCE: 'ALLIANCE',\r\n HORDE: 'HORDE',\r\n} as const;\r\n\r\n/**\r\n * The faction associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Faction {\r\n name: Capitalize<Lowercase<keyof typeof Factions>>;\r\n type: keyof typeof Factions;\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { AuctionHouseIndexResponse, AuctionsResponse } from './types';\r\n\r\n/**\r\n * Returns an index of auction houses for a connected realm.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @returns The auction house index. See {@link AuctionHouseIndexResponse}.\r\n */\r\nexport function auctionHouseIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<AuctionHouseIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/index`,\r\n };\r\n}\r\n/**\r\n * Returns all active auctions for a specific auction house on a connected realm.\r\n *\r\n * Auction house data updates at a set interval. The value was initially set at 1 hour; however, it might change over time without notice.\r\n *\r\n * Depending on the number of active auctions on the specified connected realm, the response from this endpoint may be rather large, sometimes exceeding 10 MB.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @param auctionHouseId The ID of the auction house.\r\n * @returns The auction house data. See {@link AuctionsResponse}.\r\n */\r\nexport function auctions(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n auctionHouseId: number,\r\n): Resource<AuctionsResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/${auctionHouseId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type {\r\n ConnectedRealmIndexResponse,\r\n ConnectedRealmResponse,\r\n ConnectedRealmSearchParameters,\r\n ConnectedRealmSearchResponseItem,\r\n} from './types';\r\n\r\n/**\r\n * Returns an index of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The connected realm index. See {@link ConnectedRealmIndexResponse}.\r\n */\r\nexport function connectedRealmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<ConnectedRealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/index`,\r\n };\r\n}\r\n/**\r\n * Returns a connected realm by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The connected realm ID.\r\n * @returns The connected realm. See {@link ConnectedRealmResponse}.\r\n */\r\nexport function connectedRealm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<ConnectedRealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}`,\r\n };\r\n}\r\n/**\r\n * Performs a search of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ConnectedRealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse} & {@link ConnectedRealmSearchResponseItem}.\r\n */\r\nexport function connectedRealmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: ConnectedRealmSearchParameters,\r\n): Resource<SearchResponse<ConnectedRealmSearchResponseItem>, ConnectedRealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n 'realms.timezone': options['realms.timezone'],\r\n 'status.type': options['status.type'],\r\n },\r\n path: `${base}/search/connected-realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n CreatureDisplayMediaResponse,\r\n CreatureFamilyIndexResponse,\r\n CreatureFamilyMediaResponse,\r\n CreatureFamilyResponse,\r\n CreatureResponse,\r\n CreatureSearchParameters,\r\n CreatureSearchResponseItem,\r\n CreatureTypeIndexResponse,\r\n CreatureTypeResponse,\r\n} from './types';\r\n\r\n/**\r\n * Returns a creature by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureId The creature ID.\r\n * @returns The creature. See {@link CreatureResponse}.\r\n */\r\nexport function creature(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureId: number,\r\n): Resource<CreatureResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature/${creatureId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature display by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureDisplayId The creature display ID.\r\n * @returns The creature display media. See {@link CreatureDisplayMediaResponse}.\r\n */\r\nexport function creatureDisplayMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureDisplayId: number,\r\n): Resource<CreatureDisplayMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-display/${creatureDisplayId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family. See {@link CreatureFamilyResponse}.\r\n */\r\nexport function creatureFamily(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature families.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature family index. See {@link CreatureFamilyIndexResponse}.\r\n */\r\nexport function creatureFamilyIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureFamilyIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family media. See {@link CreatureFamilyMediaResponse}.\r\n */\r\nexport function creatureFamilyMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureTypeId The creature type ID.\r\n * @returns The creature type. See {@link CreatureTypeResponse}.\r\n */\r\nexport function creatureType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureTypeId: number,\r\n): Resource<CreatureTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/${creatureTypeId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature types.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature type index. See {@link CreatureTypeIndexResponse}.\r\n */\r\nexport function creatureTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/index`,\r\n };\r\n}\r\n/**\r\n * Performs a search of creatures.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The creature search parameters. See {@link CreatureSearchParameters}.\r\n * @returns The creature search results. See {@link SearchResponse} & {@link CreatureSearchResponseItem}.\r\n */\r\nexport function creatureSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: CreatureSearchParameters,\r\n): Resource<SearchResponse<CreatureSearchResponseItem>, Omit<CreatureSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/creature`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { GuildCrestBorderEmblemResponse, GuildCrestComponentsIndexResponse } from './types';\r\n\r\n/**\r\n * Returns an index of guild crest media.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The guild crest components index. See {@link GuildCrestComponentsIndexResponse}.\r\n */\r\nexport function guildCrestComponentsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<GuildCrestComponentsIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/guild-crest/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest border by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param borderId The guild crest border ID.\r\n * @returns The guild crest border. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestBorder(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n borderId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/border/${borderId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest emblem by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param emblemId The guild crest emblem ID.\r\n * @returns The guild crest emblem. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestEmblem(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n emblemId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/emblem/${emblemId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n ItemClassIndexResponse,\r\n ItemClassResponse,\r\n ItemMediaResponse,\r\n ItemResponse,\r\n ItemSearchParameters,\r\n ItemSearchResponseItem,\r\n ItemSubClassResponse,\r\n} from './types';\r\n\r\n/**\r\n * Get an item class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The item class index. See {@link ItemClassIndexResponse}.\r\n */\r\nexport function itemClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<ItemClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/index`,\r\n };\r\n}\r\n/**\r\n * Get an item class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @returns The item class. See {@link ItemClassResponse}.\r\n */\r\nexport function itemClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n): Resource<ItemClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item subclass by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @param itemSubclassId The item subclass ID.\r\n * @returns The item subclass. See {@link ItemSubClassResponse}.\r\n */\r\nexport function itemSubClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n itemSubclassId: number,\r\n): Resource<ItemSubClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}/item-subclass/${itemSubclassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item. See {@link ItemResponse}.\r\n */\r\nexport function item(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Get item media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item media. See {@link ItemMediaResponse}.\r\n */\r\nexport function itemMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Search for items.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ItemSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function itemSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: ItemSearchParameters,\r\n): Resource<SearchResponse<ItemSearchResponseItem>, Omit<ItemSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/item`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { searchBase } from '../../../wow/src/base';\r\nimport type { MediaSearchParameters, MediaSearchResponseItem } from './types';\r\n\r\n/**\r\n * Search for media.\r\n * @param options The search parameters. See {@link MediaSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function mediaSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: MediaSearchParameters,\r\n): Resource<SearchResponse<MediaSearchResponseItem>, MediaSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n tags: options.tags,\r\n },\r\n path: `${searchBase}/media`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { PlayableClassIndexResponse, PlayableClassMediaResponse, PlayableClassResponse } from './types';\r\n\r\n/**\r\n * Get a playable class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class. See {@link PlayableClassResponse}.\r\n */\r\nexport function playableClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable class index. See {@link PlayableClassIndexResponse}.\r\n */\r\nexport function playableClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/index`,\r\n };\r\n}\r\n/**\r\n * Get playable class media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class media. See {@link PlayableClassMediaResponse}.\r\n */\r\nexport function playableClassMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PlayableRaceIndexResponse, PlayableRaceResponse } from './types';\r\n\r\n/**\r\n * Get a playable race by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableRaceId The playable race ID.\r\n * @returns The playable race. See {@link PlayableRaceResponse}.\r\n */\r\nexport function playableRace(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableRaceId: number,\r\n): Resource<PlayableRaceResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/${playableRaceId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable race index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable race index. See {@link PlayableRaceIndexResponse}.\r\n */\r\nexport function playableRaceIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableRaceIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PowerTypeIndexResponse, PowerTypeResponse } from './types';\r\n\r\n/**\r\n * Get a power type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param powerTypeId The power type ID.\r\n * @returns The power type. See {@link PowerTypeResponse}.\r\n */\r\nexport function powerType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n powerTypeId: number,\r\n): Resource<PowerTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/${powerTypeId}`,\r\n };\r\n}\r\n/**\r\n * Get a power type index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The power type index. See {@link PowerTypeIndexResponse}.\r\n */\r\nexport function powerTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PowerTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PvpSeasonIndexResponse, PvpSeasonResponse } from './types';\r\n\r\n/**\r\n * Get a PvP season index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP season by ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @returns The PvP season. See {@link PvpSeasonResponse}.\r\n */\r\nexport function pvpSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpSeasonId: number,\r\n): Resource<PvpSeasonResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Regions.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n */\r\nexport function pvpRegionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/index`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Seasons in a PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpRegionalSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Returns a PvP season by region ID and season ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRegionalSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP leaderboards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpLeaderboardIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP leaderboard by PvP season ID and bracket.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @param pvpBracket The PvP bracket.\r\n */\r\nexport function pvpLeaderboard(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n pvpBracket: string,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/${pvpBracket}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP rewards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRewardsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-reward/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, searchBase } from '../../../wow/src/base';\r\nimport type { RealmIndexResponse, RealmResponse, RealmSearchParameters, RealmSearchResponseItem } from './types';\r\n\r\n/**\r\n * Get a realm by slug.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param realmSlug The realm slug.\r\n * @returns The realm. See {@link RealmResponse}.\r\n */\r\nexport function realm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n realmSlug: string,\r\n): Resource<RealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/${realmSlug}`,\r\n };\r\n}\r\n/**\r\n * Get a realm index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The realm index. See {@link RealmIndexResponse}.\r\n */\r\nexport function realmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/index`,\r\n };\r\n}\r\n/**\r\n * Search for realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link RealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function realmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: RealmSearchParameters,\r\n): Resource<SearchResponse<RealmSearchResponseItem>, RealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n timezone: options.timezone,\r\n },\r\n path: `${searchBase}/realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { RegionIndexResponse, RegionResponse } from './types';\r\n\r\n/**\r\n * Get a region by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param regionId The region ID.\r\n * @returns The region. See {@link RegionResponse}.\r\n */\r\nexport function region(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n regionId: number,\r\n): Resource<RegionResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/${regionId}`,\r\n };\r\n}\r\n/**\r\n * Get a region index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The region index. See {@link RegionIndexResponse}.\r\n */\r\nexport function regionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RegionIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/index`,\r\n };\r\n}\r\n","import { auctionHouseIndex, auctions } from './auction-house/auction-house';\r\nimport { connectedRealm, connectedRealmIndex, connectedRealmSearch } from './connected-realm/connected-realm';\r\nimport {\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n} from './creature/creature';\r\nimport { guildCrestBorder, guildCrestComponentsIndex, guildCrestEmblem } from './guild-crest/guild-crest';\r\nimport { item, itemClass, itemClassIndex, itemMedia, itemSearch, itemSubClass } from './item/item';\r\nimport { mediaSearch } from './media-search/media-search';\r\nimport { playableClass, playableClassIndex, playableClassMedia } from './playable-class/playable-class';\r\nimport { playableRace, playableRaceIndex } from './playable-race/playable-race';\r\nimport { powerType, powerTypeIndex } from './power-type/power-type';\r\nimport {\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n} from './pvp-season/pvp-season';\r\nimport { realm, realmIndex, realmSearch } from './realm/realm';\r\nimport { region, regionIndex } from './region/region';\r\n\r\nexport const classicWow = {\r\n //Auction House\r\n auctionHouseIndex,\r\n auctions,\r\n //Connected Realm\r\n connectedRealm,\r\n connectedRealmIndex,\r\n connectedRealmSearch,\r\n //Creature\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n //Guild Crest\r\n guildCrestBorder,\r\n guildCrestComponentsIndex,\r\n guildCrestEmblem,\r\n //Item\r\n item,\r\n itemClass,\r\n itemClassIndex,\r\n itemMedia,\r\n itemSearch,\r\n itemSubClass,\r\n //Media Search\r\n mediaSearch,\r\n //Playable Class\r\n playableClass,\r\n playableClassIndex,\r\n playableClassMedia,\r\n //Playable Race\r\n playableRace,\r\n playableRaceIndex,\r\n //Power Type\r\n powerType,\r\n powerTypeIndex,\r\n //Pvp Season\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n //Realm\r\n realm,\r\n realmIndex,\r\n realmSearch,\r\n //Region\r\n region,\r\n regionIndex,\r\n};\r\nexport default classicWow;\r\n\r\n//Auction House\r\nexport * from './auction-house/auction-house';\r\nexport type * from './auction-house/types';\r\n//Connected Realm\r\nexport * from './connected-realm/connected-realm';\r\nexport type * from './connected-realm/types';\r\n//Creature\r\nexport * from './creature/creature';\r\nexport type * from './creature/types';\r\n//Guild Crest\r\nexport * from './guild-crest/guild-crest';\r\nexport type * from './guild-crest/types';\r\n//Item\r\nexport * from './item/item';\r\nexport type * from './item/types';\r\n//Media Search\r\nexport * from './media-search/media-search';\r\nexport type * from './media-search/types';\r\n//Playable Class\r\nexport * from './playable-class/playable-class';\r\nexport type * from './playable-class/types';\r\n//Playable Race\r\nexport * from './playable-race/playable-race';\r\nexport type * from './playable-race/types';\r\n//Power Type\r\nexport * from './power-type/power-type';\r\nexport type * from './power-type/types';\r\n//Pvp Season\r\nexport * from './pvp-season/pvp-season';\r\nexport type * from './pvp-season/types';\r\n//Realm\r\nexport * from './realm/realm';\r\nexport type * from './realm/types';\r\n//Region\r\nexport * from './region/region';\r\nexport type * from './region/types';\r\n"]}
1
+ {"version":3,"sources":["../../wow/src/base.ts","../src/auction-house/auction-house.ts","../src/connected-realm/connected-realm.ts","../src/creature/creature.ts","../src/guild-crest/guild-crest.ts","../src/item/item.ts","../src/media-search/media-search.ts","../src/playable-class/playable-class.ts","../src/playable-race/playable-race.ts","../src/power-type/power-type.ts","../src/pvp-season/pvp-season.ts","../src/realm/realm.ts","../src/region/region.ts","../src/index.ts"],"names":[],"mappings":";AASO,IAAM,IAAO,GAAA,WAAA,CAAA;AAKb,IAAM,SAAA,GAAY,GA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AA,EACA,cAAA;AAAA,EACA,eAAA;AAAA,EACA,SAAA;AAAA,EACA,cAAA;AAAA;AAAA,EAEA,KAAA;AAAA,EACA,UAAA;AAAA,EACA,WAAA;AAAA;AAAA,EAEA,MAAA;AAAA,EACA,WAAA;AACF,EAAA;AACA,IAAO,WAAQ,GAAA","file":"index.js","sourcesContent":["/**\r\n * @file base.ts\r\n * @module base\r\n * @description Contains base constants and interfaces for the Blizzard API.\r\n */\r\n\r\n/**\r\n * The base request path for the Blizzard API for world of warcraft.\r\n */\r\nexport const base = '/data/wow';\r\n\r\n/**\r\n * The base request path for media in the Blizzard API for world of warcraft.\r\n */\r\nexport const mediaBase = `${base}/media` as const;\r\n\r\n/**\r\n * The base request path for search in the Blizzard API for world of warcraft.\r\n */\r\nexport const searchBase = `${base}/search` as const;\r\n\r\n/**\r\n *\r\n */\r\n\r\nexport interface Href {\r\n href: string;\r\n}\r\n/**\r\n * Base interface for Blizzard API responses.\r\n */\r\nexport interface ResponseBase {\r\n _links: {\r\n self: Href;\r\n };\r\n}\r\n\r\n/**\r\n * Base record interface containing key.href property that often appear in Blizzard API responses.\r\n */\r\nexport interface KeyBase {\r\n key: Href;\r\n}\r\n\r\n/**\r\n * Base record interface containing name and id properties that often appear together in Blizzard API responses.\r\n */\r\nexport interface NameId {\r\n id: number;\r\n name: string;\r\n}\r\n\r\n/**\r\n * Base record containing both {@link KeyBase} and {@link NameId} interfaces.\r\n */\r\nexport interface NameIdKey extends KeyBase, NameId {}\r\n\r\n/**\r\n * A record containing the RGBA values of a color.\r\n */\r\nexport interface Color {\r\n a: number;\r\n b: number;\r\n g: number;\r\n r: number;\r\n}\r\n\r\n/**\r\n * The media asset associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface MediaAsset {\r\n file_data_id: number;\r\n key: string;\r\n value: string;\r\n}\r\n\r\n/**\r\n * The playable gender names/descriptions in World of Warcraft.\r\n */\r\nexport interface GenderName {\r\n female: string;\r\n male: string;\r\n}\r\n\r\n/**\r\n * The playable genders in World of Warcraft.\r\n */\r\nexport const Genders = {\r\n FEMALE: 'FEMALE',\r\n MALE: 'MALE',\r\n} as const;\r\n\r\n/**\r\n * The gender associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Gender {\r\n name: Capitalize<Lowercase<keyof typeof Genders>>;\r\n type: keyof typeof Genders;\r\n}\r\n\r\n/**\r\n * The playable factions in World of Warcraft.\r\n */\r\nexport const Factions = {\r\n ALLIANCE: 'ALLIANCE',\r\n HORDE: 'HORDE',\r\n} as const;\r\n\r\n/**\r\n * The faction associated with a character or entity in World of Warcraft.\r\n */\r\nexport interface Faction {\r\n name: Capitalize<Lowercase<keyof typeof Factions>>;\r\n type: keyof typeof Factions;\r\n}\r\n\r\n/**\r\n * The standard structure to represent a World of Warcraft Realm.\r\n */\r\nexport interface Realm extends NameIdKey {\r\n slug: string;\r\n}\r\n\r\n/**\r\n * The standard structure to represent a World of Warcraft Character.\r\n */\r\nexport interface Character extends NameIdKey {\r\n realm: Realm;\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { AuctionHouseIndexResponse, AuctionsResponse } from './types';\r\n\r\n/**\r\n * Returns an index of auction houses for a connected realm.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @returns The auction house index. See {@link AuctionHouseIndexResponse}.\r\n */\r\nexport function auctionHouseIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<AuctionHouseIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/index`,\r\n };\r\n}\r\n/**\r\n * Returns all active auctions for a specific auction house on a connected realm.\r\n *\r\n * Auction house data updates at a set interval. The value was initially set at 1 hour; however, it might change over time without notice.\r\n *\r\n * Depending on the number of active auctions on the specified connected realm, the response from this endpoint may be rather large, sometimes exceeding 10 MB.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The ID of the connected realm.\r\n * @param auctionHouseId The ID of the auction house.\r\n * @returns The auction house data. See {@link AuctionsResponse}.\r\n */\r\nexport function auctions(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n auctionHouseId: number,\r\n): Resource<AuctionsResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}/auctions/${auctionHouseId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type {\r\n ConnectedRealmIndexResponse,\r\n ConnectedRealmResponse,\r\n ConnectedRealmSearchParameters,\r\n ConnectedRealmSearchResponseItem,\r\n} from './types';\r\n\r\n/**\r\n * Returns an index of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The connected realm index. See {@link ConnectedRealmIndexResponse}.\r\n */\r\nexport function connectedRealmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<ConnectedRealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/index`,\r\n };\r\n}\r\n/**\r\n * Returns a connected realm by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param connectedRealmId The connected realm ID.\r\n * @returns The connected realm. See {@link ConnectedRealmResponse}.\r\n */\r\nexport function connectedRealm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n connectedRealmId: number,\r\n): Resource<ConnectedRealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/connected-realm/${connectedRealmId}`,\r\n };\r\n}\r\n/**\r\n * Performs a search of connected realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ConnectedRealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse} & {@link ConnectedRealmSearchResponseItem}.\r\n */\r\nexport function connectedRealmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: ConnectedRealmSearchParameters,\r\n): Resource<SearchResponse<ConnectedRealmSearchResponseItem>, ConnectedRealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n 'realms.timezone': options['realms.timezone'],\r\n 'status.type': options['status.type'],\r\n },\r\n path: `${base}/search/connected-realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n CreatureDisplayMediaResponse,\r\n CreatureFamilyIndexResponse,\r\n CreatureFamilyMediaResponse,\r\n CreatureFamilyResponse,\r\n CreatureResponse,\r\n CreatureSearchParameters,\r\n CreatureSearchResponseItem,\r\n CreatureTypeIndexResponse,\r\n CreatureTypeResponse,\r\n} from './types';\r\n\r\n/**\r\n * Returns a creature by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureId The creature ID.\r\n * @returns The creature. See {@link CreatureResponse}.\r\n */\r\nexport function creature(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureId: number,\r\n): Resource<CreatureResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature/${creatureId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature display by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureDisplayId The creature display ID.\r\n * @returns The creature display media. See {@link CreatureDisplayMediaResponse}.\r\n */\r\nexport function creatureDisplayMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureDisplayId: number,\r\n): Resource<CreatureDisplayMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-display/${creatureDisplayId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family. See {@link CreatureFamilyResponse}.\r\n */\r\nexport function creatureFamily(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature families.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature family index. See {@link CreatureFamilyIndexResponse}.\r\n */\r\nexport function creatureFamilyIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureFamilyIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-family/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a creature family by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureFamilyId The creature family ID.\r\n * @returns The creature family media. See {@link CreatureFamilyMediaResponse}.\r\n */\r\nexport function creatureFamilyMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureFamilyId: number,\r\n): Resource<CreatureFamilyMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/creature-family/${creatureFamilyId}`,\r\n };\r\n}\r\n/**\r\n * Returns a creature type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param creatureTypeId The creature type ID.\r\n * @returns The creature type. See {@link CreatureTypeResponse}.\r\n */\r\nexport function creatureType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n creatureTypeId: number,\r\n): Resource<CreatureTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/${creatureTypeId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of creature types.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The creature type index. See {@link CreatureTypeIndexResponse}.\r\n */\r\nexport function creatureTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<CreatureTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/creature-type/index`,\r\n };\r\n}\r\n/**\r\n * Performs a search of creatures.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The creature search parameters. See {@link CreatureSearchParameters}.\r\n * @returns The creature search results. See {@link SearchResponse} & {@link CreatureSearchResponseItem}.\r\n */\r\nexport function creatureSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: CreatureSearchParameters,\r\n): Resource<SearchResponse<CreatureSearchResponseItem>, Omit<CreatureSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/creature`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { GuildCrestBorderEmblemResponse, GuildCrestComponentsIndexResponse } from './types';\r\n\r\n/**\r\n * Returns an index of guild crest media.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The guild crest components index. See {@link GuildCrestComponentsIndexResponse}.\r\n */\r\nexport function guildCrestComponentsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<GuildCrestComponentsIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/guild-crest/index`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest border by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param borderId The guild crest border ID.\r\n * @returns The guild crest border. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestBorder(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n borderId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/border/${borderId}`,\r\n };\r\n}\r\n/**\r\n * Returns media for a guild crest emblem by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param emblemId The guild crest emblem ID.\r\n * @returns The guild crest emblem. See {@link GuildCrestBorderEmblemResponse}.\r\n */\r\nexport function guildCrestEmblem(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n emblemId: number,\r\n): Resource<GuildCrestBorderEmblemResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/guild-crest/emblem/${emblemId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, mediaBase, searchBase } from '../../../wow/src/base';\r\nimport type {\r\n ItemClassIndexResponse,\r\n ItemClassResponse,\r\n ItemMediaResponse,\r\n ItemResponse,\r\n ItemSearchParameters,\r\n ItemSearchResponseItem,\r\n ItemSubClassResponse,\r\n} from './types';\r\n\r\n/**\r\n * Get an item class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The item class index. See {@link ItemClassIndexResponse}.\r\n */\r\nexport function itemClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<ItemClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/index`,\r\n };\r\n}\r\n/**\r\n * Get an item class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @returns The item class. See {@link ItemClassResponse}.\r\n */\r\nexport function itemClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n): Resource<ItemClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item subclass by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemClassId The item class ID.\r\n * @param itemSubclassId The item subclass ID.\r\n * @returns The item subclass. See {@link ItemSubClassResponse}.\r\n */\r\nexport function itemSubClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemClassId: number,\r\n itemSubclassId: number,\r\n): Resource<ItemSubClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item-class/${itemClassId}/item-subclass/${itemSubclassId}`,\r\n };\r\n}\r\n/**\r\n * Get an item by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item. See {@link ItemResponse}.\r\n */\r\nexport function item(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Get item media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param itemId The item ID.\r\n * @returns The item media. See {@link ItemMediaResponse}.\r\n */\r\nexport function itemMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n itemId: number,\r\n): Resource<ItemMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/item/${itemId}`,\r\n };\r\n}\r\n/**\r\n * Search for items.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link ItemSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function itemSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: ItemSearchParameters,\r\n): Resource<SearchResponse<ItemSearchResponseItem>, Omit<ItemSearchParameters, 'locale' | 'name'>> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n [`name.${options.locale}`]: options.name,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n },\r\n path: `${searchBase}/item`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { searchBase } from '../../../wow/src/base';\r\nimport type { MediaSearchParameters, MediaSearchResponseItem } from './types';\r\n\r\n/**\r\n * Search for media.\r\n * @param options The search parameters. See {@link MediaSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function mediaSearch(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n options: MediaSearchParameters,\r\n): Resource<SearchResponse<MediaSearchResponseItem>, MediaSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n tags: options.tags,\r\n },\r\n path: `${searchBase}/media`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base, mediaBase } from '../../../wow/src/base';\r\nimport type { PlayableClassIndexResponse, PlayableClassMediaResponse, PlayableClassResponse } from './types';\r\n\r\n/**\r\n * Get a playable class by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class. See {@link PlayableClassResponse}.\r\n */\r\nexport function playableClass(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable class index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable class index. See {@link PlayableClassIndexResponse}.\r\n */\r\nexport function playableClassIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableClassIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-class/index`,\r\n };\r\n}\r\n/**\r\n * Get playable class media by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableClassId The playable class ID.\r\n * @returns The playable class media. See {@link PlayableClassMediaResponse}.\r\n */\r\nexport function playableClassMedia(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableClassId: number,\r\n): Resource<PlayableClassMediaResponse> {\r\n return {\r\n namespace,\r\n path: `${mediaBase}/playable-class/${playableClassId}`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PlayableRaceIndexResponse, PlayableRaceResponse } from './types';\r\n\r\n/**\r\n * Get a playable race by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param playableRaceId The playable race ID.\r\n * @returns The playable race. See {@link PlayableRaceResponse}.\r\n */\r\nexport function playableRace(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n playableRaceId: number,\r\n): Resource<PlayableRaceResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/${playableRaceId}`,\r\n };\r\n}\r\n/**\r\n * Get a playable race index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The playable race index. See {@link PlayableRaceIndexResponse}.\r\n */\r\nexport function playableRaceIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PlayableRaceIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/playable-race/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PowerTypeIndexResponse, PowerTypeResponse } from './types';\r\n\r\n/**\r\n * Get a power type by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param powerTypeId The power type ID.\r\n * @returns The power type. See {@link PowerTypeResponse}.\r\n */\r\nexport function powerType(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n powerTypeId: number,\r\n): Resource<PowerTypeResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/${powerTypeId}`,\r\n };\r\n}\r\n/**\r\n * Get a power type index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The power type index. See {@link PowerTypeIndexResponse}.\r\n */\r\nexport function powerTypeIndex(\r\n namespace: Extract<BlizzardNamespaces, 'static-classic' | 'static-classic1x'>,\r\n): Resource<PowerTypeIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/power-type/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { PvpSeasonIndexResponse, PvpSeasonResponse } from './types';\r\n\r\n/**\r\n * Get a PvP season index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP season by ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @returns The PvP season. See {@link PvpSeasonResponse}.\r\n */\r\nexport function pvpSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpSeasonId: number,\r\n): Resource<PvpSeasonResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Regions.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n */\r\nexport function pvpRegionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/index`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP Seasons in a PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @returns The PvP season index. See {@link PvpSeasonIndexResponse}.\r\n */\r\nexport function pvpRegionalSeasonIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n): Resource<PvpSeasonIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/index`,\r\n };\r\n}\r\n/**\r\n * Returns a PvP season by region ID and season ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRegionalSeason(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP leaderboards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpLeaderboardIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/index`,\r\n };\r\n}\r\n/**\r\n * Get a PvP leaderboard by PvP season ID and bracket.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n * @param pvpBracket The PvP bracket.\r\n */\r\nexport function pvpLeaderboard(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n pvpBracket: string,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-leaderboard/${pvpBracket}`,\r\n };\r\n}\r\n/**\r\n * Returns an index of PvP rewards for a PvP season in a given PvP region.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param pvpRegionId The PvP region ID.\r\n * @param pvpSeasonId The PvP season ID.\r\n */\r\nexport function pvpRewardsIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n pvpRegionId: number,\r\n pvpSeasonId: number,\r\n): Resource<unknown> {\r\n return {\r\n namespace,\r\n path: `${base}/pvp-region/${pvpRegionId}/pvp-season/${pvpSeasonId}/pvp-reward/index`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource, SearchResponse } from '@blizzard-api/core';\r\nimport { base, searchBase } from '../../../wow/src/base';\r\nimport type { RealmIndexResponse, RealmResponse, RealmSearchParameters, RealmSearchResponseItem } from './types';\r\n\r\n/**\r\n * Get a realm by slug.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param realmSlug The realm slug.\r\n * @returns The realm. See {@link RealmResponse}.\r\n */\r\nexport function realm(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n realmSlug: string,\r\n): Resource<RealmResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/${realmSlug}`,\r\n };\r\n}\r\n/**\r\n * Get a realm index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The realm index. See {@link RealmIndexResponse}.\r\n */\r\nexport function realmIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RealmIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/realm/index`,\r\n };\r\n}\r\n/**\r\n * Search for realms.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param options The search parameters. See {@link RealmSearchParameters}.\r\n * @returns The search results. See {@link SearchResponse}.\r\n */\r\nexport function realmSearch(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n options: RealmSearchParameters,\r\n): Resource<SearchResponse<RealmSearchResponseItem>, RealmSearchParameters> {\r\n return {\r\n namespace,\r\n parameters: {\r\n _page: options._page,\r\n orderby: Array.isArray(options.orderby) ? options.orderby.join(',') : options.orderby,\r\n timezone: options.timezone,\r\n },\r\n path: `${searchBase}/realm`,\r\n };\r\n}\r\n","import type { BlizzardNamespaces, Resource } from '@blizzard-api/core';\r\nimport { base } from '../../../wow/src/base';\r\nimport type { RegionIndexResponse, RegionResponse } from './types';\r\n\r\n/**\r\n * Get a region by ID.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @param regionId The region ID.\r\n * @returns The region. See {@link RegionResponse}.\r\n */\r\nexport function region(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n regionId: number,\r\n): Resource<RegionResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/${regionId}`,\r\n };\r\n}\r\n/**\r\n * Get a region index.\r\n * @param namespace The namespace to use. See {@link BlizzardNamespaces}.\r\n * @returns The region index. See {@link RegionIndexResponse}.\r\n */\r\nexport function regionIndex(\r\n namespace: Extract<BlizzardNamespaces, 'dynamic-classic' | 'dynamic-classic1x'>,\r\n): Resource<RegionIndexResponse> {\r\n return {\r\n namespace,\r\n path: `${base}/region/index`,\r\n };\r\n}\r\n","import { auctionHouseIndex, auctions } from './auction-house/auction-house';\r\nimport { connectedRealm, connectedRealmIndex, connectedRealmSearch } from './connected-realm/connected-realm';\r\nimport {\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n} from './creature/creature';\r\nimport { guildCrestBorder, guildCrestComponentsIndex, guildCrestEmblem } from './guild-crest/guild-crest';\r\nimport { item, itemClass, itemClassIndex, itemMedia, itemSearch, itemSubClass } from './item/item';\r\nimport { mediaSearch } from './media-search/media-search';\r\nimport { playableClass, playableClassIndex, playableClassMedia } from './playable-class/playable-class';\r\nimport { playableRace, playableRaceIndex } from './playable-race/playable-race';\r\nimport { powerType, powerTypeIndex } from './power-type/power-type';\r\nimport {\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n} from './pvp-season/pvp-season';\r\nimport { realm, realmIndex, realmSearch } from './realm/realm';\r\nimport { region, regionIndex } from './region/region';\r\n\r\nexport const classicWow = {\r\n //Auction House\r\n auctionHouseIndex,\r\n auctions,\r\n //Connected Realm\r\n connectedRealm,\r\n connectedRealmIndex,\r\n connectedRealmSearch,\r\n //Creature\r\n creature,\r\n creatureDisplayMedia,\r\n creatureFamily,\r\n creatureFamilyIndex,\r\n creatureFamilyMedia,\r\n creatureSearch,\r\n creatureType,\r\n creatureTypeIndex,\r\n //Guild Crest\r\n guildCrestBorder,\r\n guildCrestComponentsIndex,\r\n guildCrestEmblem,\r\n //Item\r\n item,\r\n itemClass,\r\n itemClassIndex,\r\n itemMedia,\r\n itemSearch,\r\n itemSubClass,\r\n //Media Search\r\n mediaSearch,\r\n //Playable Class\r\n playableClass,\r\n playableClassIndex,\r\n playableClassMedia,\r\n //Playable Race\r\n playableRace,\r\n playableRaceIndex,\r\n //Power Type\r\n powerType,\r\n powerTypeIndex,\r\n //Pvp Season\r\n pvpLeaderboard,\r\n pvpLeaderboardIndex,\r\n pvpRegionalSeason,\r\n pvpRegionalSeasonIndex,\r\n pvpRegionIndex,\r\n pvpRewardsIndex,\r\n pvpSeason,\r\n pvpSeasonIndex,\r\n //Realm\r\n realm,\r\n realmIndex,\r\n realmSearch,\r\n //Region\r\n region,\r\n regionIndex,\r\n};\r\nexport default classicWow;\r\n\r\n//Auction House\r\nexport * from './auction-house/auction-house';\r\nexport type * from './auction-house/types';\r\n//Connected Realm\r\nexport * from './connected-realm/connected-realm';\r\nexport type * from './connected-realm/types';\r\n//Creature\r\nexport * from './creature/creature';\r\nexport type * from './creature/types';\r\n//Guild Crest\r\nexport * from './guild-crest/guild-crest';\r\nexport type * from './guild-crest/types';\r\n//Item\r\nexport * from './item/item';\r\nexport type * from './item/types';\r\n//Media Search\r\nexport * from './media-search/media-search';\r\nexport type * from './media-search/types';\r\n//Playable Class\r\nexport * from './playable-class/playable-class';\r\nexport type * from './playable-class/types';\r\n//Playable Race\r\nexport * from './playable-race/playable-race';\r\nexport type * from './playable-race/types';\r\n//Power Type\r\nexport * from './power-type/power-type';\r\nexport type * from './power-type/types';\r\n//Pvp Season\r\nexport * from './pvp-season/pvp-season';\r\nexport type * from './pvp-season/types';\r\n//Realm\r\nexport * from './realm/realm';\r\nexport type * from './realm/types';\r\n//Region\r\nexport * from './region/region';\r\nexport type * from './region/types';\r\n"]}
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@blizzard-api/classic-wow",
3
- "version": "1.1.4",
3
+ "version": "1.1.6",
4
4
  "license": "MIT",
5
5
  "author": "Putro",
6
6
  "description": "A series of helpers to interact with the World of Warcraft Classic Blizzard API",
7
- "repository": "https://github.com/Pewtro/blizzard/tree/main/packages/classic-wow",
7
+ "repository": "https://github.com/Pewtro/blizzard-api/tree/main/packages/classic-wow",
8
8
  "type": "module",
9
9
  "engines": {
10
10
  "node": "^18.18 || ^20.9 || ^21.1 || ^22"
@@ -38,10 +38,10 @@
38
38
  ],
39
39
  "dependencies": {},
40
40
  "peerDependencies": {
41
- "@blizzard-api/core": "1.1.2"
41
+ "@blizzard-api/core": "1.2.1"
42
42
  },
43
43
  "devDependencies": {
44
- "@blizzard-api/core": "1.1.2"
44
+ "@blizzard-api/core": "1.2.1"
45
45
  },
46
46
  "scripts": {
47
47
  "build": "tsup",