> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mutalabs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Swift SDK

> Create dynamic, remotely configurable onboarding experiences in your iOS app

A Swift SDK for creating dynamic, remotely configurable onboarding experiences in your iOS app. Muta allows you to create, update, and A/B test your onboarding flows without deploying app updates or writing a single line of code.

## Features

* 🎨 **No-code editor** - Design and update flows with a drag-and-drop interface
* 🚀 **Remote updates** - Modify onboarding flows instantly without app releases
* ✨ **Rich components** - Buttons, text, images, shapes, and icons
* 🔄 **Smooth transitions** - Fade and slide animations
* 🔧 **Code Screens** - Inject native SwiftUI components into remotely configured flows
* 📊 **Analytics integration** - Track user behavior with any analytics provider
* 📝 **User input collection** - Gather text and multiple choice responses
* 💪 **Full Swift support**
* 🪶 **Extremely lightweight**

## Installation

### Swift Package Manager

Add the following dependency to your Package.swift:

```swift theme={null}
dependencies: [
    .package(url: "https://github.com/muta-labs/MutaSDK-iOS", from: "1.0.0")
]
```

Or in Xcode:

1. File > Add Package Dependencies
2. Enter package URL: `https://github.com/muta-labs/MutaSDK-iOS`
3. Click "Add Package"

## Quick Start

1. Initialize the SDK:

```swift theme={null}
import MutaSDK

// In your app initialization
Muta.configure(apiKey: "your-api-key")
```

2. Display a placement:

```swift theme={null}
// Basic usage
Muta.shared.displayPlacement(
    placementId: "your-placement-id",
    backgroundColor: .white
)

// With custom loading view and presentation type
Muta.shared.displayPlacement(
    placementId: "your-placement-id",
    backgroundColor: .white,
    presentationType: .fade,
    loadingView: AnyView(
        VStack {
            Image("your-logo")
                .resizable()
                .frame(width: 100, height: 100)
            ProgressView()
            Text("Loading...")
        }
    )
)
```

## Next Steps

* Learn about [Code Screens](/sdk/swift/code-screens) for native component injection
* Learn about [User Input Collection](/sdk/swift/user-input)
* Explore [Analytics Integration](/sdk/swift/analytics)
* Understand [Error Handling](/sdk/swift/error-handling)
* View the [API Reference](/sdk/swift/api-reference)
