EraslanAhmet / countly-sample-ios

Sample iOS projects to demonstrate how to use Countly SDKs. For Android sample, check Android repository and documentation.

Home Page:http://count.ly

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Countly sample test application

This repository includes sample iOS, iOS-Swift, watchOS, tvOS and macOS projects to demonstrate how to use Countly iOS SDK. It can be used to:

  • Send a sample push notification
  • Generate events with values and segmentations with count, sum, duration
  • Send a sample user profile
  • Send a custom user property
  • Send a view (automatic or manual)
  • Generate a crash (e.g out of bounds, null pointer, kill, etc or a custom crash log)

iOS-sample-app

Countly iOS SDK is added as a git submodule. Hence, you should do:

	git submodule update --init

after you cloned this repository to get the latest Countly iOS SDK.

Steps to deploy and send a sample push notification

  1. Download demo here.
  • This repository includes samples for each platform. For iOS, use ios
  • SDK is added to project as a git submodule. You just need to fetch it.
  1. Change application configuration as follows:
  • Change Bundle ID CodeSigning configurations according to your developer account configurations.
  • Change Countly server URL and AppID: config.appKey = @"YOUR_APP_KEY"; config.host = @"https://YOUR_COUNTLY_SERVER";
  • Enable push notifications: config.features = @[CLYPushNotifications];
  1. Create your push notification certificate and upload your Countly server.

  2. Run your application. From the list on the screen, choose "Ask for Notification Permission", and confirm.

  3. Push token will automatically be sent to Countly server. From this point forward, you will be able to send a push notification to that device.

  4. You can also send events, sample crashes, sample user profiles, and many more.

About

Sample iOS projects to demonstrate how to use Countly SDKs. For Android sample, check Android repository and documentation.

http://count.ly

License:MIT License


Languages

Language:Objective-C 78.6%Language:Swift 20.1%Language:Shell 1.2%