2024-09-01 23:25:50 +03:00

25 lines
632 B
C#

using System.Net.Http;
using System.Net.Http.Headers;
using System.Reflection;
namespace YoutubeDownloader.Core.Utils;
public static class Http
{
public static HttpClient Client { get; } =
new()
{
DefaultRequestHeaders =
{
// Required by some of the services we're using
UserAgent =
{
new ProductInfoHeaderValue(
"YoutubeDownloader",
Assembly.GetExecutingAssembly().GetName().Version?.ToString(3)
),
},
},
};
}