# Getting started

## Usage

1. Follow [our Getting Started guide](https://docs-preview.optiview.dolby.com/pr-861/theoplayer/getting-started/sdks/web/getting-started.md) to set up THEOplayer in your web app or website.
2. Add an OptiView Live source to your player's source.

### Add an OptiView Live source

After setting up your THEOplayer on your web page, set its source to a `SourceDescription` containing a `THEOliveSource`. You'll need an OptiView Live channel ID:

```javascript
const player = new THEOplayer.Player(element, configuration);
player.source = {
  sources: {
    type: 'theolive',
    src: 'your-channel-id',
  },
};
```

### Add configuration

Optionally, you can provide additional configuration to the player, specific for OptiView Live streams. To configure these settings, add a `theolive` property to the player configuration. For an exhaustive list of these options, please visit the [documentation](https://docs-preview.optiview.dolby.com/pr-861/theoplayer/v11/api-reference/web/interfaces/TheoLiveConfiguration).

```javascript
var player = new THEOplayer.Player(element, {
  license: 'your-license',
  // This is needed for fallback to work properly
  retryConfiguration: {
    maxRetries: 6,
  },
  theoLive: {
    externalSessionId: 'my-external-session-id',
    fallbackEnabled: true,
  },
});
```

## More information

* [API references](https://docs-preview.optiview.dolby.com/pr-861/theoplayer/v11/api-reference/web/interfaces/TheoLiveSource)
