# Variable: NablaConnect

> `const` **NablaConnect**: `object`

The entry point of the SDK.

## Type Declaration[​](#type-declaration "Direct link to Type Declaration")

### create[​](#create "Direct link to create")

> **create**: (`options`) => [`NablaConnectClient`](/connect/sdk/reference/type-aliases/NablaConnectClient.md)

Creates a client for the Connect iframe and loads the encounter in it.

#### Parameters[​](#parameters "Direct link to Parameters")

##### options[​](#options "Direct link to options")

[`NablaConnectOptions`](/connect/sdk/reference/type-aliases/NablaConnectOptions.md)

The iframe and the encounter URL to load in it.

#### Returns[​](#returns "Direct link to Returns")

[`NablaConnectClient`](/connect/sdk/reference/type-aliases/NablaConnectClient.md)

A client for the loaded encounter.

#### Remarks[​](#remarks "Direct link to Remarks")

Synchronous: `ready` resolves with the first state. Render the `<iframe>` without a `src`: the SDK sets it. A new `create` on the same iframe ends the previous client with `CONTEXT_CHANGED`.

#### Throws[​](#throws "Direct link to Throws")

`TypeError` when the iframe does not belong to a window.

#### Example[​](#example "Direct link to Example")

```
const client = NablaConnect.create({ iframe, url: urlOfEncounter });

client.addEventListener("stateChanged", ({ detail: state }) => {

  recordButton.disabled = !state.availableActions.includes("START_RECORDING");

});

await client.ready;
```
