Click or drag to resize

WebExtensionsAddBasicAuthenticationHeader Method

Adds basic authentication header to an HttpClient

Namespace: GSF.Web
Assembly: GSF.Web (in GSF.Web.dll) Version: 2.4.207-beta
Syntax
public static void AddBasicAuthenticationHeader(
	this HttpClient client,
	string userName,
	string password
)
View Source

Parameters

client  HttpClient
HttpClient instance to add authentication header.
userName  String
User name for basic authentication.
password  String
Password for basic authentication.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type HttpClient. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also