> ## Documentation Index
> Fetch the complete documentation index at: https://jdev-e8db0569.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Enums

> Enum types for verification statuses and error codes.

## SeonVerificationStatus

Enum representing the possible verification outcomes returned by [`startVerification()`](/api-reference/start-verification).

```dart theme={null}
enum SeonVerificationStatus {
  completed,
  completedSuccess,
  completedPending,
  completedFailed,
  interruptedByUser,
  error,
  missingLocationPermission,
}
```

### Values

| Value                       | Description                                                                                                    |
| --------------------------- | -------------------------------------------------------------------------------------------------------------- |
| `completed`                 | Verification process completed (generic completion status)                                                     |
| `completedSuccess`          | Verification completed successfully — user is verified                                                         |
| `completedPending`          | Verification completed but requires manual review                                                              |
| `completedFailed`           | Verification completed but user failed verification                                                            |
| `interruptedByUser`         | User cancelled or interrupted the verification flow                                                            |
| `error`                     | An error occurred during verification (check `errorMessage` for [native error codes](#native-sdk-error-codes)) |
| `missingLocationPermission` | Verification cannot proceed due to missing location permission (Android only)                                  |

### Usage

```dart theme={null}
import 'package:seon_orchestration_flutter/seon_orchestration_flutter.dart';

final result = await SeonOrchestration.startVerification();

switch (result.status) {
  case SeonVerificationStatus.completedSuccess:
    // Handle success
    break;
  case SeonVerificationStatus.completedPending:
    // Handle pending review
    break;
  case SeonVerificationStatus.completedFailed:
    // Handle failure
    break;
  case SeonVerificationStatus.interruptedByUser:
    // Handle user cancellation
    break;
  case SeonVerificationStatus.error:
    print(result.errorMessage);
    break;
  case SeonVerificationStatus.missingLocationPermission:
    // Prompt user to enable location (Android)
    break;
  default:
    break;
}
```

***

## Native SDK Error Messages

When `status` is `error`, the `errorMessage` field contains a message from the native SEON SDK describing what went wrong. Common causes include expired sessions, network failures, and invalid configuration. Refer to the [SEON documentation](https://docs.seon.io) for the full list of native error messages.

```dart theme={null}
final result = await SeonOrchestration.startVerification();

if (result.status == SeonVerificationStatus.error) {
  print('Native SDK error: ${result.errorMessage}');
}
```

***

## SeonErrorCode

Enum representing the error codes used on the `code` property of `SeonException`. The `rawCode` string property on `SeonException` preserves the original platform string for logging.

```dart theme={null}
enum SeonErrorCode {
  eNotInitialized,
  eInitializationFailed,
  eNoActivity,
  eVerificationFailed,
  eVerificationInProgress,
  eInvalidArgs,
  unknown;

  static SeonErrorCode fromString(String raw) { ... }
}
```

### Values

| Code                      | String Equivalent            | Description                                                  | Thrown By             |
| ------------------------- | ---------------------------- | ------------------------------------------------------------ | --------------------- |
| `eNotInitialized`         | `E_NOT_INITIALIZED`          | `initialize()` must be called before `startVerification()`   | `startVerification()` |
| `eInitializationFailed`   | `E_INITIALIZATION_FAILED`    | SDK initialization failed — check configuration              | `initialize()`        |
| `eNoActivity`             | `E_NO_ACTIVITY`              | No activity available to launch verification (Android only)  | `startVerification()` |
| `eVerificationFailed`     | `E_VERIFICATION_FAILED`      | Verification process failed unexpectedly                     | `startVerification()` |
| `eVerificationInProgress` | `E_VERIFICATION_IN_PROGRESS` | Cannot start a new verification while one is already running | `startVerification()` |
| `eInvalidArgs`            | `E_INVALID_ARGS`             | Invalid arguments passed to a method                         | `initialize()`        |
| `unknown`                 | *(any other string)*         | Unrecognized error code from the platform                    | Any method            |

### Usage

```dart theme={null}
import 'package:seon_orchestration_flutter/seon_orchestration_flutter.dart';

try {
  await SeonOrchestration.startVerification();
} on SeonException catch (e) {
  if (e.code == SeonErrorCode.eNotInitialized) {
    print('Call initialize() first');
  } else if (e.code == SeonErrorCode.eVerificationInProgress) {
    print('A verification is already running');
  } else {
    print('Unexpected error (${e.rawCode}): ${e.message}');
  }
}
```
