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

# Install the iOS SDK

> Add the Swift package, initialize it, and open a Glean Feed view.

## Before you install

You need iOS 14 or later, Swift 5.9 or later, and Swift Package Manager. In Glean Feed, open **Settings → Connections → iOS SDK** as an Owner or Admin and copy the **workspace ID** and **workspace slug**. Both are safe to ship in your app; neither is a secret.

## Add the package

In Xcode: **File → Add Package Dependencies…**, then paste:

```text theme={null}
https://github.com/MSW-Digital/glean-feed-ios-sdk
```

Choose **Exact Version** and enter `0.1.2`. The corresponding Git tag is `v0.1.2`.

If you manage dependencies in `Package.swift`, add:

```swift theme={null}
.package(url: "https://github.com/MSW-Digital/glean-feed-ios-sdk", exact: "0.1.2")
```

## Initialize once

Call `setup` once, early — in your SwiftUI `App` initializer or `application(_:didFinishLaunchingWithOptions:)`:

```swift theme={null}
import GleanFeed

GleanFeed.setup(
  workspaceId: "your-workspace-uuid",
  workspaceSlug: "your-workspace-slug"
)
```

<Note>
  For a local dev stack, pass `environment: .custom(baseURL: URL(string:
      "http://localhost:3000")!)`. It defaults to `.production`.
</Note>

## Present a view

### SwiftUI

```swift theme={null}
struct SupportView: View {
  @State private var showFeedback = false

  var body: some View {
    Button("Give feedback") { showFeedback = true }
      .gleanFeedFeedback(isPresented: $showFeedback)
    // also: .gleanFeedRoadmap(isPresented:) / .gleanFeedChangelog(isPresented:)
  }
}
```

### UIKit

```swift theme={null}
GleanFeed.showFeedback()      // presents a sheet from the top-most controller
GleanFeed.showRoadmap()
GleanFeed.showChangelog()

// Or push onto an existing navigation stack:
GleanFeed.pushFeedback(onto: navigationController)
```

<Check>
  Run the app and open feedback. You should see the expected workspace's portal in a native sheet
  with a **Done** button. This first check works anonymously; identity is the next step.
</Check>

## Next steps

* [Identify signed-in customers](/ios-sdk/identity) so their feedback ties to their account.
* [Show an unread badge](/ios-sdk/notifications).
* [Collect SDK diagnostics](/ios-sdk/diagnostics).
