Latest 3.2.0
License Copyright Cloud Wings.
Platforms ios 9.0, requires ARC
Frameworks Foundation, UIKit

Date: 18-Oct-2017

Revision: 3.2.0

Change log:

  • 3.2.0

Shake delegate timeout callback combined to failure callback.
Added more comments.

  • 3.1.1

Fixed Xcode 9 block warning

  • 3.0.1

Combined Tag and Fp

  • 2.3.2

Tag algorithm recognize bug fixed

  • 2.3.1

Tag algorithm memory leak fixed

  • 2.3.0

Old algo removed

  • 2.2.0

Retry bug fixed

  • 2.1.0

Name changed

  • 2.0.3

fix fp crash bug

  • 2.0.2

fixed archieve error bitcode bundle could not be generated because was built without full bitcode

  • 2.0.0

Breaking API change.

  • 1.0.21

Minor updates.

  • 1.0.20

Mixed compatible and incompatible.

  • 1.0.19-c

Compatible with old audio tag algorithm.

  • 1.0.19

Minor optimization.

  • 1.0.18

Remove support to the old audio tag algorithm.

  • 1.0.6

Supporting new audio tag algorithm.

  • 1.0.4

Supporting IPV6 in production environment.

  • 1.0.3

Add IPV6 support(for experimental use only, please do not use it in product env)

  • 1.0.2

Add IPV6 support(for experimental use only, please do not use it in product env)

  • 1.0.1

CWSSDK interface updated.


This document demonstrates how to integrate CWSShakeSDK into your iOS project.


Version: 3.2.0
Description: The SDK provides ACR(Automatic Content Recognition) functionality which allows 3rd party apps to retrieve user-defined contents by listening to audio sources.


Language: Objective-C
IDE: XCode
Credentials: appId & appSecret



pod 'CWSSDK'


  1. Download and unzip it. You will get the following files:

    • CWSShakeSDK.framework: Framework file to be linked to your iOS project.
    • ShakeSDKDemo: Demo iOS app project which has already integrated the SDK.
    • iOS_CWSShakeSDK_Integration_Manual.pdf: Integration manual.
  2. Copy CWSShakeSDK.framework to your project folder and add it to your project.

  3. Create a new copy file phase and copy the framework file as framework.

    In the project view, click Build Phases > Plus symbol in the top left > New Copy File Phase:
    Switch destination to Frameworks and add the CWSShakeSDK.framework file:


  1. Import SDK header file.

    #import <CWSShakeSDK/CWSShakeSDK.h>
  2. Make your view controller extend CWSShakeViewController.

    @interface ViewController : CWSShakeViewController
  3. Make your view controller or any other object confirm to CWSShakeDelegate and implements all the required methods defined in the delegate.

    The CWSShakeDelegate is a protocol defined in the SDK. The declaration is as follows:

    @protocol CWSShakeDelegate <NSObject>
    - (void)shakeControllerPermissionDenied:(CWSShakeViewController *)controller;
    - (BOOL)shakeControllerCanShake:(CWSShakeViewController *)controller;
    - (void)shakeControllerDidShake:(CWSShakeViewController *)controller;
    - (void)shakeController:(CWSShakeViewController *)controller didSucceedWithUserContent:(CWSUserContent *)userContent;
    - (void)shakeControllerDidCancel:(CWSShakeViewController *)controller;
    - (void)shakeController:(CWSShakeViewController *)controller didFailWithError:(CWSError *)error;

    Confirm to this protocol:

    @interface ViewController () <CWSShakeDelegate>

    Set the delegate to the view controller:

    self.shakeDelegate = self;
  4. Call the requestPermission method of the SDK to ask for needed permissions from the user.

    [CWSShakeManager requestPermission];
  5. Call the register method with your appId and appSecret before using any other functions of the SDK.

    [CWSShakeManager registerWithAppId:APP_ID appSecret:APP_SECRET success:^{
    } failure:^(CWSError *error) {
  6. Add NSMicrophoneUsageDescription to the Info.plist of your project. Note that our SDK uses microphone when the user triggers the shake event. And it is compulsory to add the abovementioned key value pair to the Info.plist. Otherwise, the app will not be able to run.

  7. Compile and run the application in a real iOS device or simulator. You may need a demo video to test the ACR functionality. Please refer to this site for demo videos:

Latest podspec

    "name": "CWSSDK",
    "version": "3.2.0",
    "summary": "Cloud Wings iOS Shake SDK.",
    "homepage": "",
    "license": {
        "type": "Copyright",
        "text": "Cloud Wings."
    "authors": {
        "cloudwings": "[email protected]"
    "source": {
        "git": "",
        "tag": "3.2.0",
        "submodules": true
    "platforms": {
        "ios": "9.0"
    "requires_arc": true,
    "vendored_frameworks": "frameworks/cocoapods/CWSShakeSDK.framework",
    "frameworks": [

Pin It on Pinterest

Share This