Proxy-related settings are settings you use to specify attributes in order to use a proxy server for your request. See Using a Proxy Server for more information on how to use a proxy server with HttpCommand.
Settings
ProxyURL
Description
The URL for the proxy server which will relay the request.
The HTTP headers, if any, specifically for the proxy server's CONNECT request to the host.
Default
0 2⍴⊂''
Details
The format for ProxyHeaders is the same as Headers. If you specify proxy authentication either as a part of ProxyURL or by setting ProxyAuth and ProxyAuthType, HttpCommand will create a Proxy-Authorization header.
ProxyAuth
Description
This setting is the authentication/authorization string appropriate for the authentication scheme specified in ProxyAuthType. Used along with ProxyAuthType, ProxyAuth is a shortcut for setting the proxy-authorization HTTP header for requests that require proxy authentication. If ProxyAuth is non-empty, HttpCommand will create a 'proxy-authorization' header and and set its value to ProxyAuthType,' ',ProxyAuth. If you happen set both ProxyAuth and a proxy-authorization header, ProxyAuth takes precedence.
For HTTP Basic Authentication, ProxyAuth can be set to any of
HttpCommand.Base64Encode 'userid:password'
'userid' 'password'
'userid:password'
For the latter two items above:
it is permissible to not set ProxyAuthType as HttpCommand will infer the authorization scheme is HTTP Basic.
HttpCommand will properly format and Base64Encode the header value.
Alternatively, if you provide HTTP Basic credentials in ProxyURL as in 'http://username:password@someproxy.com', HttpCommand will automatically generate a proper 'proxy-authorization' header.
ProxyAuthType
Description
This setting is used in conjunction with ProxyAuth and is a character vector indicating the authentication scheme. Three common authentication schemes are:
'Basic' for HTTP Basic Authentication
'Bearer' for OAuth 2.0 token authentication
'Token' for other token-based authentication schemes such as GitHub's Personal Access Token scheme
Other values may be used as necessary for your particular HTTP request.
Default
''
Example(s)
h.ProxyAuthType←'Basic'
Details
If ProxyAuthType is not set and ProxyAuth is set to either a character vector in the form 'userid:password' or a 2-element vector of character vectors as in ('userid' 'password')HttpCommand will infer the ProxyAuthType to be 'Basic'.