<PackageReference Include="Microsoft.Rest.ClientRuntime" Version="2.3.21" />

Microsoft.Rest.HttpExtensions

public static class HttpExtensions
namespace Microsoft.Rest { public static class HttpExtensions { public static string AsString(this HttpContent content); public static HttpHeaders GetContentHeaders(this HttpRequestMessage request); public static HttpHeaders GetContentHeaders(this HttpResponseMessage response); public static string AsFormattedString(this HttpRequestMessage httpRequest); public static string AsFormattedString(this HttpResponseMessage httpResponse); public static string AsFormattedString<TKey, TValue>(this IDictionary<TKey, TValue> dictionary); public static JObject ToJson(this HttpHeaders headers); public static JObject ToJson(this IDictionary<string, IEnumerable<string>> headers); public static JObject GetHeadersAsJson(this HttpResponseMessage message); } }