using System;
using System.Collections.Generic;
using System.Net;
namespace AMWD.Net.Api.Cloudflare
{
///
/// Options for the Cloudflare API.
///
public class ClientOptions
{
///
/// Gets or sets the default base url for the API.
///
public virtual string BaseUrl { get; set; } = "https://api.cloudflare.com/client/v4/";
///
/// Gets or sets the default timeout for the API.
///
public virtual TimeSpan Timeout { get; set; } = TimeSpan.FromSeconds(60);
///
/// Gets or sets the maximum number of retries for the API.
///
///
/// The API may respond with an 5xx error and a X-Should-Retry header indicating that the request should be retried.
///
public virtual int MaxRetries { get; set; } = 2;
///
/// Gets or sets additional default headers to every request.
///
public virtual IDictionary DefaultHeaders { get; set; } = new Dictionary();
///
/// Gets or sets additional default query parameters to every request.
///
public virtual IDictionary DefaultQueryParams { get; set; } = new Dictionary();
///
/// Gets or sets a value indicating whether to allow redirects.
///
public virtual bool AllowRedirects { get; set; }
///
/// Gets or sets a value indicating whether to use a proxy.
///
public virtual bool UseProxy { get; set; }
///
/// Gets or sets the proxy information.
///
public virtual IWebProxy? Proxy { get; set; }
}
}