Datastore API SDKs
Warning: The Datastore API has been deprecated. Learn more.
The Datastore API lets you effortlessly sync all of your app's structured data such as contacts, to-do items, and game state. It enables your app to sync data quickly, manage conflicting changes, and even work offline.
Before building an app using the Datastore API, you'll need to create an app on the App Console.
Xcode with the iOS development kit is required to build an iOS app using the Datastore API. The Datastore API requires iOS 5.0 or later.
Adding Dropbox.framework to your project
Once you've downloaded the Datastore API iOS SDK, you'll need to add all the necessary frameworks to your project.
- Open your project in Xcode.
- Navigate to where you downloaded the SDK and drag the Dropbox.framework folder into your project in Xcode.
- Make sure Copy items ... is selected.
- Press the Finish button.
- Ensure that you have CFNetwork.framework, Security.framework, SystemConfiguration.framework, QuartzCore.framework, libc++.dylib, and libz.dylib added to your project. To do this, select your project file in the file explorer, select your target, and select the Build Phases sub-tab. Under Link Binary with Libraries, press the + button, select CFNetwork.framework, and press Add. Repeat for Security.framework, SystemConfiguration.framework, QuartzCore.framework, libc++.dylib, and libz.dylib.
Creating a URL scheme
The SDK coordinates with the Dropbox app (if it's installed) to simplify the auth process. But in order to smoothly hand the user back to your app, you need to add a unique URL scheme that Dropbox can call. You'll need to configure your project to add one:
- Click on your project in the Project Navigator, choose the Info tab, expand the URL Types section at the bottom, and finally, press the + button.
- In the URL Schemes enter db-APP_KEY (replacing APP_KEY with the key generated when you created your app).
- Lists - A sample app that demonstrates many features of the Datastore API.
- Click the Box - A simple app for storing game state using the Datastore API.