---
url: >-
  https://game-engine-io.github.io/enginex-frontend-sdk/reference/api/@getenginex/sdk-vue/functions/useEnginex.md
---
[Reference](../../../index.md) / [@getenginex/sdk-vue](../index.md) / useEnginex

# useEnginex()

> **useEnginex**(): [`EnginexClient`](../../sdk/interfaces/EnginexClient.md)

Core client given to the app's [EnginexPlugin](../variables/EnginexPlugin.md).

## Returns

[`EnginexClient`](../../sdk/interfaces/EnginexClient.md)

The same `EnginexClient` passed to the plugin.

## Throws

If called in an app without the `EnginexPlugin`, outside `setup()` (or `app.runWithContext`),
or with the app's vue-query using another `QueryClient`.

## Example

```ts
const enginex = useEnginex()
const onLogout = () => enginex.auth.logout()
```
