EnkaSystem
class EnkaSystem
Properties
Methods
constructor
new EnkaSystem(options)
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
options | Partial<EnkaSystemOptions> | ✔️ | {} |
Properties
instance
static
Default EnkaSystem instance.
Type: EnkaSystem
enkaUrl
static
Type: string
Methods
registerLibrary
Returns: void
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
library | EnkaLibrary<User, CharacterBuild> |
getLibrary
Returns: EnkaLibrary<User, CharacterBuild> | undefined
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
hoyoType | HoyoType |
fetchEnkaProfile
async
Returns: Promise<EnkaProfile>
- the Enka.Network account
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
username | string | enka.network username, not in-game nickname |
fetchEnkaGameAccounts
async
Returns: Promise<EnkaGameAccount<EnkaLibrary<User, CharacterBuild>>[]>
- the all game accounts added to the Enka.Network account
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
username | string | enka.network username, not in-game nickname | ||
allowedHoyoTypes | HoyoType[] | undefined | ✔️ | undefined | hoyoTypes to filter |
fetchEnkaGameAccount
async
Returns: Promise<EnkaGameAccount<T>>
- the game account added to the Enka.Network account
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
username | string | enka.network username, not in-game nickname | ||
hash | string | the game account hash |
fetchEnkaCharacterBuilds
async
Returns: Promise<{[characterId: string]: ExtractBuildType<T>[]}>
- the game character builds including saved builds in the Enka.Network game account
PARAMETER | TYPE | OPTIONAL | DEFAULT | DESCRIPTION |
---|---|---|---|---|
username | string | enka.network username, not in-game nickname | ||
hash | string | the game account hash |