//okhttp/okhttp3/Request/Builder/addHeader
addHeader¶
[common]\ expect open fun addHeader(name: String, value: String): Request.Builder
Adds a header with name and value. Prefer this method for multiply-valued headers like "Cookie".
Note that for some headers including Content-Length
and Content-Encoding
, OkHttp may replace value with a header derived from the request body.
[jvm, nonJvm]\ [jvm, nonJvm]\ actual open fun addHeader(name: String, value: String): Request.Builder