# 1. Including the SDK

## Flutter

Install the Sentiance Core plugin, by running the following command in your terminal, inside the project directory:

```bash
flutter pub add sentiance_core
```

The module should now be added to your project's **pubspec.yaml** file.

{% code title="pubspec.yaml" %}

```yaml
dependencies:
  flutter:
    sdk: flutter
  sentiance_core: ^6.9.0
  ...
```

{% endcode %}

## Native

Before moving forward, please ensure you follow the instructions tailored to your platform.

### iOS Setup

Execute the `pod install` command to check for any issues. If you encounter an error resembling:

```
-> Installing sentiance_plugin (0.0.1)
  - Running pre install hooks
[!] The 'Pods-Runner' target has transitive dependencies that include 
statically linked binaries: (/path/to/flutter-app/ios/Pods/SENTSDK/SENTSDK.xcframework)
```

Instruct CocoaPods to statically link these frameworks rather than dynamically by updating the Podfile with:

```ruby
target 'Runner' do
  use_frameworks! :linkage => :static
  ...
```

### Android setup

Add the Sentiance maven repository to the **build.gradle** file in your project's **android** directory:

{% code title="android/build.gradle" %}

```groovy
allprojects {
    repositories {
        ...
        maven { url "https://repository.sentiance.com" }
    }
}
```

{% endcode %}

This will allow Gradle to find and download the necessary native Sentiance SDK libraries.

### Feature Packages

Similar to the [Android's Artifacts](https://docs.sentiance.com/important-topics/sdk/appendix/android/artifacts-and-dependencies) you can install the Flutter plugins based on the features you would want to use your application. Following are the packages available:

```dart
sentiance_core
sentiance_user_context
sentiance_event_timeline
sentiance_driving_insights
sentiance_crash_detection
sentiance_smart_geofences
```

Contact [support](mailto:support@sentiance.com) to learn more about which features (and packages) best suit your use-case.
