Reference / @getenginex/sdk / EnginexClient
EnginexClient
EngineX SDK client: one object per app (browser) or per request (server).
Properties
auth
readonlyauth:AuthApi
Sign-up, login, verification, password and 2FA.
config
readonlyconfig:ConfigApi
The operator's public configuration.
deposits
readonlydeposits:DepositsApi
Deposits via PIX.
kyc
readonlykyc:KycApi
Identity verification (KYC): status and document upload.
notifications
readonlynotifications:NotificationsApi
The player's notifications and channel preferences.
pixKeys
readonlypixKeys:PixKeysApi
The player's PIX keys, the destination of withdrawals.
profile
readonlyprofile:ProfileApi
The player's profile and their login sessions.
responsibleGambling
readonlyresponsibleGambling:ResponsibleGamblingApi
Responsible gambling: limits, self-exclusion and reality check.
session
readonlysession:SessionApi
Current session.
wallet
readonlywallet:WalletApi
Wallet balance and statement.
withdrawals
readonlywithdrawals:WithdrawalsApi
Withdrawals via PIX, with OTP confirmation when the operator requires it.
Methods
dispose()
dispose():
void
Disposes the client: releases the session subscription on the tokenStore (removes the storage listener of localStorageTokenStore when this was the last one) and cancels nothing in flight. Once called, every method of this client rejects with an EnginexError CONFIGURATION_ERROR and session.subscribe becomes a no-op (it does not add the listener; the returned unsubscribe does not throw). Idempotent. Use it when unmounting a client created per request (e.g. tests, short-lived scripts) so as not to leave the storage listener hanging.
Returns
void
Example
client.dispose()setLocale()
setLocale(
locale):void
Switches the language sent in Accept-Language. The next requests already go out with the new locale — including the retry of a call already in flight (after a renewed 401): only the attempt that was already sent to fetch keeps the old locale.
Parameters
locale
string
Returns
void
Example
client.setLocale('en-US')