> For the complete documentation index, see [llms.txt](https://docs.mpush.cloud/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mpush.cloud/ios-sdk/integrate-mpush.md).

# Integrate MPush

To integrate MPush to your implementation you need to add this in your AppDelegate

```bash
import MPushSwift

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
    ...
    MPush.token = "YOUR_PUSH_TOKEN"
    ...
}

...

func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
    MPush.registerDevice(deviceToken: deviceToken, success: {
        MPush.register(toTopic: "YOUR_TOPIC")
        // OR if you have more than one topic
        // MPush.register(toTopics: ["TOPIC1", "TOPIC2"])
    })
}
```

{% hint style="success" %}
You're set 🎉, the device will receive notifications for the topic is registered to.
{% endhint %}
