Client
Last updated
Was this helpful?
Last updated
Was this helpful?
The main class to interact with API.
Attributes/Parameters
Methods
api_key
This your API authentication key.
Type:
As of version 3, The API key is required to use the API. Get one from .
version
The version of API to use. This defaults to "4"
Type:
suppress_warnings
Determines if version or other warnings will be shown in console or not. Set this to True
to stop warnings.
get_ai_response
Gets random AI response.
These are parameters for version 4.
message
The message to which the response is required.
plan
(Optional)The plan to use for AI response.
language
(Optional)The language of returned response. This defaults to en
.
server
(Optional)The server from which the response should be received. This defaults to primary
. Set it to backup
if the primary is down. Don't use unstable
as it is quiet unstable.
master
(Optional)The developer's name. Used in responses. Defaults to PGamerX
This is basically what bot will say on "Who is your creator?" or related questions.
bot
(Optional)The bot's name. This is used in responses. Defaults to RSA
. This is basically what bot will say on "Who are you?" or "What is your name?" or related questions.
uid
(Optional)get_image
Gets a random image.
get_joke
Gets a random joke.
get_waifu
Gets a random waifu/anime image URL.
get_weather
Gets the weather of provided city.
close
Closes a session.
are usually printed on outdated versions of API.
Type:
Type:
Type:
This must be one of from the .
Type:
Type:
Type:
Type:
The unique ID. This is used to create a separate session. Read page for more info.
Type:
Type:
Type:
This must be one of from the .
Type:
Type:
Type:
Type:
The unique ID. This is used to create a separate session. Read page for more info.
Type:
Type:
: The API key provided was invalid.
: The plan is not available on your account because you haven't bought it.
The type of image. This is one of the types from . Defaults to any
.
Type:
Type:
: The API key provided was invalid.: The image type was not valid.
The type of joke. This is one of the types from . Defaults to any
.
Type:
The random joke as object.
Type:
: The API key provided was invalid.
: The joke type was not valid.
The type of anime. Can be one from
Type:
The plan to use. Can be one from
Type:
The random anime as object.
Type:
: The API key provided was invalid.
: The waifu type was not valid.
: The plan is not available on your API key.
Type: