Latest 1.0.1
Homepage https://github.com/PerformanteSDK/PerformanteSDK-iOS
License Apache License, Version 2.0
Platforms ios 8.0, requires ARC
Authors

Performante SDK for iOS

platform
tool
language
version

PerformanteSDK is a tool for tracking different events in your application.

Compatibility:

  • iOS 8.0 or later
  • Swift and Objective-C

Installation via Cocoapods

  • Add this line to your Podfile:
pod 'PerformanteSDK', '~> 1.0.1'
  • And then execute:
$ pod install
In Swift project you need to add Objective-C bridging header. If you don’t how to do it, explanation is here.

Import

Add import to your class where you want to use SDK

Swift

import PerformanteSDK

Objective-C

#import <PerformanteSDK/PerformanteSDK.h> or @import PerformanteSDK;

Example usage – configure and sending events

Swift

let sdk = PFSDK.newWithProductId("Example-Swift", apiKey:"example-api-key")
sdk.sendAppStarted()
sdk.sendAppEvent("Custom_event")

Objective-C

PFSDK *sdk = [PFSDK newWithProductId:@"Example-Objective-C" apiKey:@"example-api-key"];
[sdk sendAppStarted];
[sdk sendAppEvent:@"Custom_event"];

Method sendAppStarted should be called when app was started.

Method sendAppEvent: is for sending different event.

Mark existing user

When you don’t want track existing user you can use method:

Swift

sdk.setExistingUser(true)

Objective-C

[sdk setExistingUser:YES];

Default value for this parameter is set to false/NO. When you set to true/YES user will not be tracked. Remember to configure this value before calling method sendAppStarted.

Debug mode

If you want to make sure that you have correctly configured SDK you can enable debug mode. Add to your main plist file below code:

 <key>PerformanteSDK</key>
 <dict>
    <key>EnableDebugMode</key>
    <true/>
 </dict>

You can setup true or false value for key EnableDebugMode.

Example applications

If you still have difficulty setting up the SDK, look at the Example applications in Swift and Objective-C.

License

The Apache License (Apache) – check included LICENSE file

Latest podspec

{
    "name": "PerformanteSDK",
    "version": "1.0.1",
    "summary": "iOS SDK for tracking.",
    "description": "PerformanteSDK is a tool for tracking different events in your application.",
    "homepage": "https://github.com/PerformanteSDK/PerformanteSDK-iOS",
    "license": {
        "type": "Apache License, Version 2.0",
        "file": "LICENSE"
    },
    "authors": {
        "Performante, Sp. z o.o.": "[email protected]"
    },
    "source": {
        "git": "https://github.com/PerformanteSDK/PerformanteSDK-iOS.git",
        "tag": "1.0.1"
    },
    "platforms": {
        "ios": "8.0"
    },
    "libraries": "z",
    "requires_arc": true,
    "preserve_paths": "PerformanteSDK.framework",
    "vendored_frameworks": "PerformanteSDK.framework",
    "xcconfig": {
        "OTHER_LDFLAGS": "-ObjC, -lz"
    }
}

Pin It on Pinterest

Share This