> ## Documentation Index
> Fetch the complete documentation index at: https://docs.beyondwords.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Getting started

You will first need to have created a [project](/docs-and-guides/getting-started/concepts#projects) with some [articles](/docs-and-guides/getting-started/concepts#articles) generated.

## First steps

### Add the JitPack repository to your root build.gradle at the end of repositories

```javascript theme={null}
allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}
```

### Add the dependency to your app build.gradle

```javascript theme={null}
dependencies {
    implementation 'com.github.beyondwords-io:player-android:+'
}
```

### Add playerView to your view hierarchy

There are two options:

1. Add PlayerView to your layout xml file

```javascript theme={null}
<io.beyondwords.player.PlayerView
    android:id="@+id/player_view"
    android:layout_width="match_parent"
    android:layout_height="wrap_content" />
```

2. Add PlayerView programmatically

```javascript theme={null}
val playerView = PlayerView(context)
playerViewParent.addView(playerView)
```

### Load your content into the player

```javascript theme={null}
playerView.load(PlayerSettings(
    projectId = <ID>,
    contentId = <ID>
))
```

You will need to replace the `<ID>` placeholders with the real identifiers for your project and content.

playerView\.release() should be called after this PlayerView has been removed from the view system. No other methods may be called on this PlayerView after release.

After running the app, the player should load.

## How it works

The PlayerView uses a [Web Player](https://github.com/beyondwords-io/player?tab=readme-ov-file) under the hood to load the Web Player and provides a Kotlin interface which binds to the underlying JavaScript API.

You can check the API compatibility between the iOS and the Web player in the [compatibility settings](/docs-and-guides/distribution/player/sdk/javascript/player-settings#player-settings-compatibility-across-sdks).

To understand how the underlying Web Player works, please refer to its [documentation](/docs-and-guides/distribution/player/sdk/javascript/getting-started).

## How to configure it

The preferred way to configure the player is by logging into the BeyondWords dashboard, going to the Player tab, and changing its settings.

However, you can also override properties at the app level, for example:

```javascript theme={null}
playerView.load(PlayerSettings(
    projectId = <ID>,
    contentId = <ID>,
    playerStyle = "large",
    callToAction = "Listen to this recipe",
    backgroundColor = "yellow",
))
```

These settings will take precedence over those specified in the dashboard and allow more flexibility.

These settings can also be changed after loading the player, for example:

```javascript theme={null}
playerView.setPlayerStyle("large")
playerView.setBackgroundColor("yellow")
playerView.setPlaybackRate(1.5F)
```

You can also refer to [example app](https://github.com/beyondwords-io/player-android/tree/main/example) which showcases the core functionality of the player, including how to build a custom UI.

You can download a precompiled version of the example app from the assets of the [latest GitHub Release](https://github.com/beyondwords-io/player-android/releases).

## Android SDK Github repository

<Card title="Android SDK Documentation" icon="android" href="https://github.com/beyondwords-io/player-android" target="_blank">
  View the Android SDK documentation in our GitHub repository
</Card>
