CuratedRecommendationsRequest

public struct CuratedRecommendationsRequest : Equatable, Hashable, Codable
extension CuratedRecommendationsRequest: Sendable

Parameters for requesting curated recommendations from the Merino API.

  • The locale to use when selecting recommendations.

    Declaration

    Swift

    public var locale: CuratedRecommendationLocale
  • Optional ISO 3166-1 region code (e.g. "US", "GB") to further refine results.

    Declaration

    Swift

    public var region: String?
  • Maximum number of recommendations to return. Defaults to 100 if not specified.

    Declaration

    Swift

    public var count: Int32?
  • Optional list of topic slugs to filter recommendations by (e.g. "business", "tech").

    Declaration

    Swift

    public var topics: [String]?
  • Optional list of feed types to include in the response (e.g. "sections").

    Declaration

    Swift

    public var feeds: [String]?
  • Optional per-section follow/block preferences.

    Declaration

    Swift

    public var sections: [SectionSettings]?
  • Optional experiment name for server-side A/B testing.

    Declaration

    Swift

    public var experimentName: String?
  • Optional experiment branch for server-side A/B testing.

    Declaration

    Swift

    public var experimentBranch: String?
  • Whether to include the interest picker in the response.

    Declaration

    Swift

    public var enableInterestPicker: Bool
  • Declaration

    Swift

    public init(
        /**
         * The locale to use when selecting recommendations.
         */locale: CuratedRecommendationLocale, 
        /**
         * Optional ISO 3166-1 region code (e.g. `"US"`, `"GB"`) to further refine results.
         */region: String? = nil, 
        /**
         * Maximum number of recommendations to return. Defaults to 100 if not specified.
         */count: Int32? = 100, 
        /**
         * Optional list of topic slugs to filter recommendations by (e.g. `"business"`, `"tech"`).
         */topics: [String]? = nil, 
        /**
         * Optional list of feed types to include in the response (e.g. `"sections"`).
         */feeds: [String]? = nil, 
        /**
         * Optional per-section follow/block preferences.
         */sections: [SectionSettings]? = nil, 
        /**
         * Optional experiment name for server-side A/B testing.
         */experimentName: String? = nil, 
        /**
         * Optional experiment branch for server-side A/B testing.
         */experimentBranch: String? = nil, 
        /**
         * Whether to include the interest picker in the response.
         */enableInterestPicker: Bool = false)