//example URL: vanillanav:navigateTo?venueId=8037&referenceId=19144 public func navigate(venueId: Int, destinationId: Int) -> Bool { let navigateUrl = NSURL(string: "vanillanav:navigateTo?venueId=\(venueId)&referenceId=\(destinationId)")! let sharedApp = UIApplication.sharedApplication() if sharedApp.canOpenURL(navigateUrl) { sharedApp.openURL(navigateUrl) return true } else { let storeUrl = NSURL(string: "itms-apps://itunes.apple.com/ro/app/vanillanav/id1007116984")! sharedApp.openURL(storeUrl) return false } }