// Copyright (c) Microsoft. All rights reserved.
using System;
using System.Net.Http;
using Microsoft.Extensions.Logging;
using Microsoft.SemanticKernel.Data;
namespace Microsoft.SemanticKernel.Plugins.Web.Bing;
///
/// Options used to construct an instance of
///
public sealed class BingTextSearchOptions
{
///
/// The URI endpoint of the Bing search service. The URI must use HTTPS.
///
public Uri? Endpoint { get; init; } = null;
///
/// The HTTP client to use for making requests.
///
public HttpClient? HttpClient { get; init; } = null;
///
/// The to use for logging. If null, no logging will be performed.
///
public ILoggerFactory? LoggerFactory { get; init; } = null;
///
/// instance that can map a to a
///
public ITextSearchStringMapper? StringMapper { get; init; } = null;
///
/// instance that can map a to a
///
public ITextSearchResultMapper? ResultMapper { get; init; } = null;
///
/// Gets or sets the market where results come from (e.g., "en-US").
/// Applied as a default to every search from this instance.
/// See .
///
public string? Market { get; init; }
///
/// Gets or sets the freshness filter for results ("Day", "Week", "Month", or a date range like "2024-01-01..2024-12-31").
/// Applied as a default to every search from this instance.
///
public string? Freshness { get; init; }
///
/// Gets or sets the safe search level ("Off", "Moderate", or "Strict").
/// Applied as a default to every search from this instance.
///
public string? SafeSearch { get; init; }
///
/// Gets or sets the 2-character country code for the country where results come from (e.g., "US").
/// Applied as a default to every search from this instance.
///
public string? CountryCode { get; init; }
///
/// Gets or sets the preferred language to use for user interface strings (e.g., "en").
/// Applied as a default to every search from this instance.
///
public string? SetLanguage { get; init; }
///
/// Gets or sets a comma-delimited list of answer types to include in the response (e.g., "Webpages,Images").
/// Applied as a default to every search from this instance.
///
public string? ResponseFilter { get; init; }
///
/// Gets or sets the number of answers that the response should include.
/// Applied as a default to every search from this instance.
///
public int? AnswerCount { get; init; }
///
/// Gets or sets a comma-delimited list of answer types to promote to the mainline (e.g., "Webpages,Videos").
/// Applied as a default to every search from this instance.
///
public string? Promote { get; init; }
///
/// Gets or sets a value indicating whether to include display string decorations such as hit highlighting markers.
/// Applied as a default to every search from this instance.
///
public bool? TextDecorations { get; init; }
///
/// Gets or sets the type of markers to use for text decorations ("Raw" or "HTML").
/// Applied as a default to every search from this instance.
///
public string? TextFormat { get; init; }
}