summaryrefslogtreecommitdiff
path: root/docs/user
diff options
context:
space:
mode:
authorCory Benfield <lukasaoz@gmail.com>2016-05-03 08:07:30 +0100
committerCory Benfield <lukasaoz@gmail.com>2016-05-03 08:07:30 +0100
commit339e950dc70718104d82ea635252cababa1a276b (patch)
treec3e783f14467684b482e85e678846435f1f18a31 /docs/user
parent296928f36f9e6a1041769ebe3d15f322bff51206 (diff)
downloadpython-requests-339e950dc70718104d82ea635252cababa1a276b.tar.gz
Add section on SOCKS proxies.
Diffstat (limited to 'docs/user')
-rw-r--r--docs/user/advanced.rst23
1 files changed, 23 insertions, 0 deletions
diff --git a/docs/user/advanced.rst b/docs/user/advanced.rst
index efdc406a..f15ac553 100644
--- a/docs/user/advanced.rst
+++ b/docs/user/advanced.rst
@@ -544,6 +544,29 @@ any request to the given scheme and exact hostname.
Note that proxy URLs must include the scheme.
+SOCKS
+^^^^^
+
+.. versionadded:: 2.10.0
+
+In addition to basic HTTP proxies, requests also supports proxies using the
+SOCKS protocol. This is an optional feature that requires that additional
+third-party libraries be installed before use.
+
+You can get the dependencies for this feature from ``pip``:
+
+.. code-block:: bash
+
+ $ pip install requests[socks]
+
+Once you've installed those dependencies, using a SOCKS proxy is just as easy
+as using a HTTP one::
+
+ proxies = {
+ 'http': 'socks5://user:pass@host:port',
+ 'https': 'socks5://user:pass@host:port'
+ }
+
.. _compliance:
Compliance