Latest 0.9.3
Homepage https://github.com/iqnect-org/iqkit-ios
License Commercial http://iqnect.org/business/terms-and-conditions/
Platforms ios 8.0, requires ARC
Dependencies NFAllocInit, SVProgressHUD, SDWebImage, SBJson, Masonry, OpenCV
Frameworks AVFoundation, CoreLocation, CoreText, CoreData, QuartzCore

iQKit iOS SDK

The iQKit iOS SDK gives you access to the powerful iQNECT Vision Search platform
to integrate into your iOS app.

Installation

With CocoaPods

Using CocoaPods, add to your podfile:

pod 'iQKit'

Run pod install to download the SDK and install it into your project, along with the SDK’s dependencies.

Initialization

Required

In your App Delegate, initialise the SDK with the App ID and secret you obtained from the iQNECT Developer Portal:

#import "iQKit.h"
[iQKit setAppID:@"APP-ID"
   andAppSecret:@"APP-SECRET"];

Optional

For best results, report some further information about the user:

[iQKit setUserAge:@(42)];
[iQKit setUserGender:@"f"]; 

The age and gender can be updated at anytime with these functions.

Usage

Vision Search

To initiate a vision search, add the following code to an appropriate view controller:

iQScannerViewController *scannerViewController = [[iQScannerViewController alloc] init];
scannerViewController.delegate = self;
[self presentViewController:scannerViewController animated:NO completion:nil];

When the search is complete, you will get a callback via the iQScannerViewControllerDelegate protocol:

- (void)scannerViewController:(iQScannerViewController *)scannerViewController didLoadSearchResponse:(iQAPISearchResponse *)searchResponse
{    
    [self dismissViewControllerAnimated:YES completion:^{
        NSLog(@"Payload URL: %@", searchResponse.payload);
    }];
}

In the callback, the iQAPISearchResponse object has a payload property which is the URL returned by the search. Use this URL, typically to load in a web view or to open the iQNECT app.

Image Search

This is the same as the Keyword search, except the parameter is of type UIImage.

[[iQAPISearchRequest requestWithImage:image] runWithCompletionHandler:^(iQAPISearchResponse *response) {
    NSLog(@"Payload: %@", response.payload); 
}];

Latest podspec

{
    "name": "iQKit",
    "version": "0.9.3",
    "summary": "Search by iQNECT.",
    "description": "Search by iQNECTnn* text/keyword searchn* image search",
    "homepage": "https://github.com/iqnect-org/iqkit-ios",
    "license": {
        "type": "Commercial",
        "text": "http://iqnect.org/business/terms-and-conditions/"
    },
    "authors": "iQNECT",
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/iqnect-org/iqkit-ios.git",
        "tag": "0.9.3"
    },
    "source_files": "iQKit/include/iQKit/*.h",
    "public_header_files": "iQKit/include/iQKit/*.h",
    "resources": "iQKit/iQKitResources.bundle",
    "vendored_libraries": "iQKit/libiQKit.a",
    "frameworks": [
        "AVFoundation",
        "CoreLocation",
        "CoreText",
        "CoreData",
        "QuartzCore"
    ],
    "libraries": "c++",
    "requires_arc": true,
    "dependencies": {
        "NFAllocInit": [
            "~> 1.0"
        ],
        "SVProgressHUD": [
            "~> 2.0"
        ],
        "SDWebImage": [
            "3.7.1"
        ],
        "SBJson": [
            "~> 5.0"
        ],
        "Masonry": [],
        "OpenCV": [
            "2.4.9"
        ]
    }
}

Pin It on Pinterest

Share This