# First Time Setup

Follow this step-by-step guide to set up the Sinch Voice and Video SDK for the first time.

## Register an Application

1. Register a Sinch Developer account [here](https://dashboard.sinch.com/signup).
2. Set up a new application in the Dashboard to obtain an *Application Key* and an *Application Secret*.


## Download

Download the Sinch SDK from the [SDK Downloads](/docs/in-app-calling/sdk-downloads) page. It includes the AAR library, this user guide, reference documentation, and sample apps for calling.

### Add the Sinch library

The Sinch SDK library is distributed in [AAR](https://developer.android.com/studio/projects/android-library) format. To use it in your project either:

> - Copy the `.aar` file to the `libs` folder and edit the `build.gradle` file to include:



```gradle
repositories {
    flatDir {
        dirs 'libs'
    }
}

dependencies {
    implementation(name:'sinch-android-rtc', version:'+', ext:'aar')
}
```

> - Or, in Android Studio, choose `File → New → New Module → Import .JAR/.AAR Package`.



### Consume from Maven Central

Alternatively, you can consume the SDK from Maven Central.
See the Android SDK artifact and Gradle instructions in
the [SDK Downloads](/docs/in-app-calling/sdk-downloads#android-sdk-on-maven-central)
page.

## Running ProGuard

If you use ProGuard/R8, we bundle an example `proguard-project.txt` that ensures the Sinch SDK works as expected.

## Permissions

A minimum set of permissions is needed for the app to use the Sinch SDK. Specify these in the `AndroidManifest.xml` file.

```xml
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.CAMERA"/>
```

Native calls and phone state
By default, the Sinch SDK hangs up any Sinch call if the regular phone app has an active call. This functionality requires the permission `android.permission.READ_PHONE_STATE`.

If you do not want this behavior, disable it by calling [`SinchClient.callController.setRespectNativeCalls(false)`](https://download.sinch.com/android/latest/reference/sinch-rtc/com.sinch.android.rtc.calling/-call-controller/set-respect-native-calls.html) and you can remove the `READ_PHONE_STATE` permission.

Automatic audio routing & Bluetooth
If you intend to use Automatic Audio Routing (see the [Voice Calling](/docs/in-app-calling/android/calling) section), you must add `android.permission.BLUETOOTH` in the manifest and ensure the user has granted this permission.

## Verify Manifest at Runtime

To verify that the manifest has the necessary permissions, use [`SinchClient.checkManifest()`](https://download.sinch.com/android/latest/reference/sinch-rtc/com.sinch.android.rtc/-sinch-client/check-manifest.html). It checks whether required permissions are granted by the user at runtime. Examples of dynamically requesting missing permissions are included in the sample apps that come with the SDK.

*Note:* This method considers the features enabled for the app (for example, calling, respecting native calls). Call `SinchClient.checkManifest()` after setup but before starting the `SinchClient`.