Building in-app UI for iOS and macOS

Learn more about the in-app notifications experiences you can build for iOS and macOS applications with Knock.
🌠
Note in the current version of the Swift SDK there are no pre-built UI elements.

The Knock Swift SDK is a low-level set of methods for interacting with the Knock APIs from iOS and macOS applications. The SDK is designed to help you easily integrate Knock into your application and build in-app notification experiences powered by Knock.

Features

  • API methods for interacting with the Knock in-app API.
  • Managed websocket connections to the Knock real-time service.

Getting started

You can install the Swift SDK in a few different ways:

  • Swift Package Manager (SPM)
  • Cartage
  • Cocoapods

Installing via Swift Package Manager

You can add the package by pointing to the Github repo: https://github.com/knocklabs/knock-swift.git.

Installing via Carthage

Add github "knocklabs/knock-swift" ~> 0.1.0 to your Cartfile.

Follow the steps listed in the README here.

Installing via Cocoapods

Add the dependency to your Podfile:

Read more in the quick start guide ->