# Quickstart

> Install the SDK, initialize it with your license key, and run your first moderation check.

> For AI agents: the complete documentation index is at https://nosmai.com/llms/moderations.txt

Product: Nosmai Moderation
Group: get-started
Source: https://nosmai.com/docs/moderations/quickstart/

## Before you start

You need a Nosmai license key for your app. It looks like `NOSMAI-XXXX` and is tied to your app's package name or bundle identifier and to the platform. Get one from the Nosmai dashboard.

The first launch verifies the key online, so make sure the device has connectivity the first time you run your app.

## 1. Install

Pick your platform.

**Flutter**

```yaml
dependencies:
  nosmai_moderation_sdk: ^2.0.0
```

**iOS**

```ruby
pod 'NosmaiModerationSDK', '~> 2.0.1'
```

**React Native**

```sh
npm install @nosmai/moderation-react-native@2.0.1
```

**Android** (download `nosmai-detection.aar` from the releases page, put it in `app/libs/`, then reference it):

```kotlin
dependencies {
    implementation(files("libs/nosmai-detection.aar"))
}
```

## 2. Initialize

Initialize once at startup with your license key. Initialization does a network check and loads the models, so run it off the main thread.

**Flutter**

```dart
final res = await NosmaiModeration.initialize('NOSMAI-XXXX');
if (!res.success) debugPrint('init failed: ${res.error}');
```

**iOS**

```swift
DispatchQueue.global(qos: .userInitiated).async {
    let ok = NosmaiSDK.initialize(licenseKey: "NOSMAI-XXXX")
}
```

**Android**

```kotlin
Executors.newSingleThreadExecutor().execute {
    val ok = NosmaiSDK.init(context, "NOSMAI-XXXX")
}
```

**React Native**

```tsx
import { NosmaiModeration } from '@nosmai/moderation-react-native';

const res = await NosmaiModeration.initialize('NOSMAI-XXXX', ['nsfw']);
if (!res.success) console.warn('init failed:', res.error);
```

## 3. Run your first check

Moderate an image and read the verdict.

**Flutter**

```dart
final r = await NosmaiModeration.analyzeImage(file.path);
print(r.isUnsafe ? 'UNSAFE' : 'SAFE');
```

**iOS**

```swift
if let r = NosmaiSDK.analyzeImage(uiImage) {
    print(r.isUnsafe ? "UNSAFE" : "SAFE")
}
```

**Android**

```kotlin
val r = NosmaiSDK.analyzeImage(bitmap)
Log.d("Mod", if (r.isUnsafe) "UNSAFE" else "SAFE")
```

**React Native**

```tsx
const r = await NosmaiModeration.analyzeImage(filePath);
console.log(r.isUnsafe ? 'UNSAFE' : 'SAFE');
```

## Next steps

- [How moderation works](/docs/moderations/concepts/): surfaces, detection types, results and thresholds.
- Platform guides: [iOS](/docs/moderations/ios/), [Android](/docs/moderations/android/), [Flutter](/docs/moderations/flutter/), [React Native](/docs/moderations/react-native/).
- [Authentication](/docs/moderations/authentication/): how license keys and offline validation work.
