Skip to main content

iOS Integration

1. Obtain API Credentials

Before integrating AudioShake into your iOS app, you need to obtain API credentials from the AudioShake support team. These credentials consist of a client ID and a client secret, which are required for initializing the SDK.

2. Add AudioShake.xcframework to Your Xcode Project

  1. Drag and drop the AudioShake.xcframework file into your Xcode project's "Frameworks, Libraries, and Embedded Content" section.
  2. Make sure to select "Copy items if needed" and add the framework to your app's target.

3. Initialize AudioShake SDK

In your app delegate or any suitable location, initialize the AudioShake SDK with your client ID and client secret.

For Swift:

import AudioShake

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
AudioShakeSDK.initialize(withClientID: "<Insert client ID>", clientSecret: "<Insert client secret>")
return true
}

For Objective C:


#import <AudioShake/AudioShake.h>

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[ASAudioShakeSDK initializeWithClientID:@"<Insert client ID>"
clientSecret:@"<Insert client secret>"];
return YES;
}

Replace "Insert client ID" and "Insert client secret" with your actual credentials obtained from the AudioShake earlier.

Now you can start using AudioShake’s SDK.