Table of contents
The Socialize SDK provides a simple set of classes and methods built upon the Socialize REST API
App developers can elect to use either the pre-defined user interface controls provided in the Socialize UI framework, or “roll their own” using direct SDK calls.
All calls to the Socialize SDK are asynchronous, meaning that your application will not “block” while waiting for a response from the Socialize server.
You are notified of the outcome of calls to the Socialize service via a SocializeServiceDelegate passed into each call to the Socialize SDK.
The main class through which you will be interacting would be Socialize.
As of release 3.0.1, Socialize iOS SDK can be installed with CocoaPods.
CocoaPods is an easy, elegant way to manage library dependencies in iOS. No need to manually import frameworks or deal with compiler flags. After a one-time installation of RubyGems (CocoaPods is Ruby-based), a single command-line operation is all that’s needed to install or upgrade Socialize. For more information on CocoaPods, check out the CocoaPods homepage.
$ ruby -v ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0] $ gem -v 2.1.5
$ sudo gem install cocoapods $ pod setup
Installing RubyGems and/or CocoaPods can take up to a minute, and may appear unresponsive for brief periods during install.
If you prefer not to use CocoaPods, the SDK can still be installed as before:
Some circumstances require Socialize source files to be altered before they are compiled. For those scenarios, you msut build the SDK from source instead of downloading it as specified in Step 1.
$ git submodule init $ git submodule update $ pod install $ pod update
Even though you are not using CocoaPods for your project, the Socialize SDK still uses it for some of its own dependencies. If you need to install CocoaPods, see the information above.
$ make package
The SDK will compile into build/package_dir
Run the app in your simulator or device, have fun with the action bar, add comments, likes and shares. Then you can visit the app dashboard on the Socialize website to see new user actions show up in the analytics charts. You can also enable additional features like Push Notifications.