---
title: "@supertokens-plugins/tenants-react"
description: "Public root exports for @supertokens-plugins/tenants-react 0.2.0."
---

**Package version:** `0.2.0`

Generated from the packed release's root declaration, `./dist/index.d.ts`. Only exports reachable from that root are
listed. See the [immutable release source](https://github.com/supertokens/supertokens-plugins/blob/%40supertokens-plugins%2Ftenants-react%400.2.0/packages/tenants-react/src/index.ts).

:::caution
This release's declaration graph imports unpublished workspace modules (`@shared/react`, `@shared/tenants`). The generator detected these imports from the packed declaration graph and strict compiler diagnostics. This upstream packaging defect cannot be fixed by the reference generator; do not enable `skipLibCheck` to hide it.
:::

## Public root exports

| Export | Kind |
| --- | --- |
| `default` | Constant |
| `init` | Constant |
| `PLUGIN_ID` | Constant |

## `default`

Published from the emitted `_default` declaration.

Root export:

```ts check=false reason="Generated API signature"
export default _default;
```

Resolved declaration:

```ts check=false reason="Generated API signature"
declare const _default: {
    init: (config?: (import('./types').SuperTokensPluginTenantsPluginConfig & {
        override?: ((oI: undefined) => undefined) | undefined;
    }) | undefined) => import('supertokens-auth-react').SuperTokensPlugin;
    PLUGIN_ID: string;
};
```

## `init`

Root export:

```ts check=false reason="Generated API signature"
import { init } from './plugin';
import { PLUGIN_ID } from './constants';
export { init, PLUGIN_ID };
```

Resolved declaration:

```ts check=false reason="Generated API signature"
import { SuperTokensPluginTenantsPluginConfig, SuperTokensPluginTenantsPluginNormalisedConfig, TranslationKeys } from './types';
import { SuperTokensPlugin, SuperTokensPublicConfig, SuperTokensPublicPlugin } from 'supertokens-auth-react';
export declare const init: (config?: (SuperTokensPluginTenantsPluginConfig & {
    override?: ((oI: undefined) => undefined) | undefined;
}) | undefined) => SuperTokensPlugin;
```

## `PLUGIN_ID`

Root export:

```ts check=false reason="Generated API signature"
import { init } from './plugin';
import { PLUGIN_ID } from './constants';
export { init, PLUGIN_ID };
```

Resolved declaration:

```ts check=false reason="Generated API signature"
export declare const PLUGIN_ID = "supertokens-plugin-tenants";
```

## Required signature types

These declarations are not additional package-root exports. They are included because the public signatures above depend on them.

### `SuperTokensPluginTenantsPluginConfig`

```ts check=false reason="Generated API signature"
export type SuperTokensPluginTenantsPluginConfig = {
    requireTenantCreation?: boolean;
    redirectToUrlOnJoiningTenant?: string | (() => void);
};
```
