CloudInAppMessaging is CloudKit-powered SDK which allows you to engage active app users with contextual messages.
It was created as an open-source alternative to the Firebase In-App Messaging.
CloudInAppMessaging uses a public CloudKit database so it can be accessed by any user of your app even without an iCloud account. This comes with an important limitation of not having push notifications feature. Because currently, CloudKit supports push notifications for shared and private databases only they can't be used for purposes of sending In-App Messaging.
com.example.myapp
.
Also, this can be done via Apple Developer Portal.application:didFinishLaunchingWithOptions:
method:Swift
CLMCloudInAppMessaging.setup(with: "iCloud.com.example.myapp")
Objective-C
[CLMCloudInAppMessaging setupWithCloudKitContainerIdentifier:@"iCloud.com.example.myapp"];
In order to create and modify Alert Campaigns, you need to use either CloudKit Dashboard or the so-called Admin App. The latter allows to do it more convenient instead of dealing with database data.
pod install
from the Example directory first.CloudMessagingAdminConfiguration.swift
CloudMessagingAdminConfiguration.swift
CloudInAppMessaging is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'CloudInAppMessaging'
Carthage is a decentralized dependency manager that automates the process of adding frameworks to your Cocoa application. To integrate CloudInAppMessaging into your Xcode project using Carthage, specify it in your Cartfile
:
github "podkovyrin/CloudInAppMessaging"
The Swift Package Manager is a tool for automating the distribution of Swift code and is integrated into the swift
compiler.
Once you have your Swift package set up, adding CloudInAppMessaging as a dependency is as easy as adding it to the dependencies
value of your Package.swift
.
dependencies: [
.package(url: "https://github.com/podkovyrin/CloudInAppMessaging.git", from: "0.1.0")
]
Package.swift
:.package(url: "https://github.com/podkovyrin/CloudInAppMessaging.git", .upToNextMajor(from: "0.1.0")),
CloudInAppMessaging
to your App targets dependencies like so:.target(name: "App", dependencies: ["CloudInAppMessaging"]),
accio update
.CloudInAppMessaging requires iOS 10 or later.
CloudInAppMessaging Admin App requires iOS 11 or later.
$ pod install
Installing Firebase (6.11.0)
Installing FirebaseAnalytics (6.1.3) # 📦 closed-source
Installing FirebaseAnalyticsInterop (1.4.0) # 📦 closed-source
Installing FirebaseCore (6.3.2)
Installing FirebaseCoreDiagnostics (1.1.1)
Installing FirebaseCoreDiagnosticsInterop (1.0.0)
Installing FirebaseInAppMessaging (0.15.5)
Installing FirebaseInAppMessagingDisplay (0.15.5)
Installing FirebaseInstanceID (4.2.6)
Installing GoogleAppMeasurement (6.1.3) # 📦 closed-source
Installing GoogleDataTransport (3.0.1)
Installing GoogleDataTransportCCTSupport (1.2.1)
Installing GoogleUtilities (6.3.1)
Installing nanopb (0.3.9011)
As for the rest, they have deep integration with Firebase Analytics which is great if you already using it.
Andrew Podkovyrin, [email protected]
CloudInAppMessaging is available under the MIT license. See the LICENSE file for more info.
link |
Stars: 6 |
Last commit: 4 years ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics