SearchInAppsSDK Framework Reference

ContextualSearchRuntime


@interface ContextualSearchRuntime : NSObject

Runtime for issuing contextual search requests. The runtime can be reused across the app after it is initialized.

  • Creates a new Search Runtime. The Search Runtime can be created at app startup and only needs to be created once. It can be reused throuhgout the app’s lifecycle.

    Declaration

    Objective-C

    - (nonnull instancetype)init;
  • Gets search suggestions. \param withOptions The input options used to generate search suggestions.

    Declaration

    Objective-C

    - (void)getSearchSuggestionsWithOptions:
                (GetSearchSuggestionsOptions *_Nonnull)getSearchSuggestionsOptions
                          completionHandler:
                              (void (^_Nonnull)(SearchSuggestions *_Nullable,
                                                NSError *_Nullable))
                                  completionHandler;
  • Gets trending searches. \param withOptions The input options used to generate trending searches.

    Declaration

    Objective-C

    - (void)getTrendingSearchesWithOptions:
                (GetTrendingSearchesOptions *_Nullable)getTrendingSearchesOptions
                         completionHandler:
                             (void (^_Nonnull)(SearchSuggestions *_Nullable,
                                               NSError *_Nullable))
                                 completionHandler;