# Examples

The following GitHub repositories are available to demonstrate the integration of Appfigurate Library into iOS, Android and Mobile Flutter apps and app extensions.

## Prerequisites

You must have the following installed:

* [Appfigurate Simulator](https://docs.electricbolt.co.nz/appfigurate-se-user-guide/setup-ios-simulator-app) app installed into one or more iOS Simulators (use the AppfigurateSE macOS app for easy 1 click installation).
* The [example app's metadata records](https://docs.electricbolt.co.nz/appfigurate-user-guide/install-example-apps).

## iOS

{% hint style="warning" %}
**Note:** You *cannot* have both the Objective-C and Swift examples installed in the same Simulator, as they share the same URL Scheme and app identifiers.

To swap between language examples you must delete the existing app from the Simulator and clear Xcode's DerivedData directory.
{% endhint %}

### Swift example

{% embed url="<https://github.com/electricbolt/appfiguratesdk-swiftexample>" %}

Contains the following integrations:

* iOS native app
* iOS native app extension
* iOS native app UI automation testing support
* watchOS app extension
* watchOS intent extension

#### Installation instructions

```bash
git clone https://github.com/electricbolt/appfiguratesdk-swiftexample.git
```

In Xcode, open `SwiftExample.xcodeproj`

Ensure Appfigurate package dependency has been downloaded. (File ‣ Packages ‣ Reset Package Caches).

Select `AppfigurateExample (Swift iOS)` target, and choose the iOS Simulator that you previously installed Appfigurate Simulator into. e.g.

![](https://1008176080-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fw1fcw3dvtSrfUh3YtO9Z%2Fuploads%2FXdW8YIHiXx06mSEzAmRn%2Fimage.png?alt=media\&token=49fb3f58-aefe-47ba-a9d7-e7f6a480753a)

Tap Run.

### Objective-C example

{% embed url="<https://github.com/electricbolt/appfiguratesdk-objcexample>" %}

Contains the following integrations:

* iOS native app
* iOS native app extension
* iOS native app UI automation testing support
* watchOS app extension
* watchOS intent extension

#### Installation instructions

```bash
git clone https://github.com/electricbolt/appfiguratesdk-objcexample.git
```

In Xcode, open `ObjCExample.xcodeproj`

Ensure Appfigurate package dependency has been downloaded. (File ‣ Packages ‣ Reset Package Caches).

Select `AppfigurateExample (ObjC iOS)` target, and choose the iOS Simulator that you previously installed Appfigurate Simulator into. e.g.

![](https://1008176080-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fw1fcw3dvtSrfUh3YtO9Z%2Fuploads%2FgR9HxBFwmMTihdnGPTjD%2Fimage.png?alt=media\&token=c7a76407-c077-4f2e-97f7-2a3c3c2345d3)

Tap Run.

## Flutter

{% embed url="<https://github.com/electricbolt/appfiguratesdk-flutter>" %}

Contains the following integrations:

* iOS app

#### Installation instructions

```bash
git clone https://github.com/electricbolt/appfiguratesdk-flutter.git
```

In Android Studio, open the directory containing the projects `pubspec.yaml`

Select `main.dart` Run/Debug Configuration, and choose the iOS Simulator that you previously installed Appfigurate Simulator into. e.g.

![](https://1008176080-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fw1fcw3dvtSrfUh3YtO9Z%2Fuploads%2FeThC97J48vdLxAEoERzP%2Fimage.png?alt=media\&token=54ecaeb5-ca38-476c-a70b-20f72765e71c)

Tap Run.
