Skip to content

journifyio/clevertap-journify-ios

Repository files navigation

CleverTap iOS Journify SDK

SwiftPM Compatible

CleverTap integration for Journify-ios.

Installation

Clevertap-Journify-ios is available through SPM

Swift Package Manager (SPM)

To add Clevertap-Journify-ios via Swift Package Mangaer:

Xcode

Xcode Add SPM Package

Screenshot 2024-03-22 at 1 59 56 PM Screenshot 2024-03-22 at 2 00 16 PM

Note: Clevertap-Journify-ios recommends that you use Xcode to add your package.

Usage/Examples

//Enable debug mode
CleverTap.setDebugLevel(CleverTapLogLevel.debug.rawValue)
Journify.debugLogsEnabled = true
        
//Setup Journify
let configuration = Configuration(writeKey: "Your_Key")
    .trackApplicationLifecycleEvents(true)
    .flushInterval(10)
Journify.setup(with: configuration)
        
//Setup & Add cleverTapDestination
let cleverTapDestination = CleverTapDestination(accountID: "Your_Account_ID", token: "Your_Account_Token", region: "Your_Region")
Journify.shared().add(plugin: cleverTapDestination)

Development

Requirements

  • Xcode 14+
  • Swift 5.3+
  • iOS 13.0+

Setup

  1. Clone the repository:

    git clone https://github.com/journifyio/clevertap-journify-ios.git
    cd clevertap-journify-ios
  2. Resolve dependencies:

    swift package resolve
  3. Open the example app:

    open Example/SwiftExample/SwiftExample.xcodeproj
  4. In Xcode, go to File > Packages > Resolve Package Versions to sync the workspace dependencies.

Running the Example App

The example app (Example/SwiftExample) lets you test the integration end-to-end. On launch it prompts for:

  • Journify Write Key — your Journify source write key
  • CleverTap Account ID — from the CleverTap dashboard
  • CleverTap Token — from the CleverTap dashboard
  • CleverTap Region - from the CleverTap dashboard

Project Structure

.
├── Sources/CleverTapDestination/   # SDK source
├── Example/SwiftExample/           # Example Xcode project
├── Package.swift                   # SPM manifest
└── Package.resolved                # Pinned dependency versions

License

MIT

Credits

This SDK was based of Segment Swift SDK https://github.com/segmentio/analytics-swift (Thanks to the Segment team)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors