# Client
The main hub to interact with FakeYouAPI
IMPORTANT
You need to forcely use start() method to get important data from API and login if needed
# Constructor
new Client(options);
PARAMETER | TYPE | DESCRIPTION | OPTIONAL |
---|---|---|---|
options | ClientOptions | Options for the client | Yes |
# Properties
# categories
All of categories the client is currently handling
- Type: VoiceManager
# models
All of models the client is currently handling
- Type: ModelManager
# isReady
Checks if the client is ready to work
- Type: Boolean
# results
All of results the client is currently handling
- Type: VoiceManager
# token
The authorization token for data request
- Type: String
# user
The user logged in
- Type: ClientUser or null
# Methods
# fetchUser(query)
Fetch all data about an user
PARAMETER | TYPE | DESCRIPTION | OPTIONAL |
---|---|---|---|
query | String | Profile username | No |
# leaderboard()
Obtains the TTS/W2L leaderboard
- Return: Promise <LeaderBoard>
# makeTTS(model, text)
Generate a TTS request
PARAMETER | TYPE | DESCRIPTION | OPTIONAL |
---|---|---|---|
model | ModelResolvable | Name, object or token of model | No |
text | String | The text to speech | No |
# queue()
Get info about TTS queued
# searchModel(query)
Search an model
PARAMETER | TYPE | DESCRIPTION | OPTIONAL |
---|---|---|---|
query | String | The model name | No |
- Return: Group <ModelToken, Model>
# start()
Fetch all data and login if needed