CloudcheckSDK 1.2.9

CloudcheckSDK 1.2.9

Maintained by Tom Carey.



  • By
  • Verifidentity

CloudcheckSDK

Version License Platform

Installation

CloudcheckSDK is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'CloudcheckSDK'

Alternatively, you can download the latest release tag and drop in the framework to your Xcode project

Instructions

Import the module

import CloudcheckSDK

First initialize the SDK with the key and secret provided to you. Contact [email protected] if you haven't got one.

CloudcheckAPI.loadAPI(key: "my_cloudcheck_key", secret: "my_cloudcheck_secret")

Cloudcheck UI

The simplest way to perform a verification is to use the provided verification workflow

let controller = CloudcheckViewController(mode: .live, reference: NSUUID().uuidString, delegate: self)
present(controller, animated: true, completion: nil)

The available modes for verification are .live and .verify. Use the mode that best suits your requirements.

Cloudcheck API

You can access the API via this SDK.

To make a verify request you will have to construct a CloudcheckSDK.CCVerifyRequest instance. Once all of the details are loaded into the request object, simply call:

let request = CCVerifyRequest()

CloudcheckAPI.verify(request, completion: { result in
  // Handle the result
  switch result {
    case .error(let error):
      // Handle the error
    case .response(let response):
      // Handle the response
  }
})

Cloudcheck Live

A Cloudcheck Live request must use our supplied view controllers. To start a Live request with a Capture Reference you can do so like this:

let controller = CloudcheckViewController(mode: .live, reference: myCaptureReference, delegate: self, config: CCConfig(), verificationReference: myVerificationReference)
present(controller, animated: true, completion: nil)

Note that Live only works on platforms that have a camera. If you try to run Live on a platform that doesn't have a camera, such as the iOS simulator, you will get an Invalid Platform error message.

Author

Verifidentity, [email protected]

License

CloudcheckSDK is available under the MIT license. See the LICENSE file for more info.