From 898465756a600958fdfee6aef43134cab7d75a7d Mon Sep 17 00:00:00 2001 From: benjaminran Date: Fri, 3 Apr 2015 07:58:42 -0700 Subject: [PATCH] added custom header precedence info --- docs/user/quickstart.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/user/quickstart.rst b/docs/user/quickstart.rst index e26abaad..cb187797 100644 --- a/docs/user/quickstart.rst +++ b/docs/user/quickstart.rst @@ -190,6 +190,15 @@ For example, we didn't specify our content-type in the previous example:: >>> r = requests.get(url, headers=headers) +Note: Custom headers are given less precedence than more specific sources of information. For instance: + +* Authorization headers will be overridden by any alternative auth source found. +* Authorization headers will be removed if you get redirected off-host. +* Proxy-Authorization headers will be overridden by proxy credentials provided in the URL. +* Content-Length headers will be overridden when we can determine the length of the content. + +Furthermore, Requests does not change its behavior at all based on which custom headers are specified. The headers are simply passed on into the final request. + More complicated POST requests ------------------------------