-
-
Notifications
You must be signed in to change notification settings - Fork 11
libcURL.RequestHeaderEngine
Andrew Lambert edited this page Nov 26, 2024
·
10 revisions
libcURL.RequestHeaderEngine
Protected Class RequestHeaderEngine
This class presents an interface to libcURL's request header management features (the "request header engine"). Each instance of cURLClient has its own request header engine.
Use this class to add, remove, and update custom request headers. Do not use this class to add, remove, or update HTTP cookies for a request; use the CookieEngine class instead.
Generally, you should not create your own instances of this class. Instead use the RequestHeaders reference belonging to the cURLClient whose request headers you want to modify.
Dim curl As New cURLClient
curl.RequestHeaders.SetHeader("X-Example-Header", "Example Value") ' sets a header
curl.RequestHeaders.SetHeader("Accept", "text/html") ' overrides the default Accept header
curl.RequestHeaders.RemoveHeader("X-Example-Header") ' clears a header by name
curl.RequestHeaders.Reset() ' clears all headers and resets defaults
Wiki home | Project page | Bugs | Become a sponsor
Text and code examples are Copyright ©2014-24 Andrew Lambert, offered under the CC BY-SA 3.0 License.