Sana Assistant (online)
Table of Contents

ProductSearchSuggestionsResponse reference

This article provides reference material about ProductSearchSuggestionsResponse record.

ProductSearchSuggestionsResponse record

Properties

Groups

The search suggestion groups.

Example:

var response = new ProductSearchSuggestionsResponse(
    Groups:
    [
        new ProductSearchSuggestionGroup(Name: "Suggestions", Suggestions: [new ProductSearchSuggestion(Value: "black")]),
        new ProductSearchSuggestionGroup(
            Name: "ProductCategory",
            Suggestions:
            [
                new ProductSearchSuggestion(
                    Value: "Black & White",
                    FacetFilter: new ProductSearchFacetFilter(
                        Values: [new ProductSearchFacetFieldValues(Name: "ProductCategory", Values: ["B&W"])],
                        RangeValues: []))
            ]),
        new ProductSearchSuggestionGroup(
            Name: "Color",
            Suggestions:
            [
                new ProductSearchSuggestion(
                    Value: "Black",
                    FacetFilter: new ProductSearchFacetFilter(
                        Values: [new ProductSearchFacetFieldValues(Name: "Color", Values: ["BLACK"])],
                        RangeValues: []))
            ]),
    ]); 

See also