index.rst 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. urllib3
  2. =======
  3. .. toctree::
  4. :hidden:
  5. :maxdepth: 2
  6. For Enterprise <https://tidelift.com/subscription/pkg/pypi-urllib3?utm_source=pypi-urllib3&utm_medium=referral&utm_campaign=docs>
  7. user-guide
  8. advanced-usage
  9. reference/index
  10. contributing
  11. urllib3 is a powerful, *sanity-friendly* HTTP client for Python. Much of the
  12. Python ecosystem :ref:`already uses <who-uses>` urllib3 and you should too.
  13. urllib3 brings many critical features that are missing from the Python
  14. standard libraries:
  15. - Thread safety.
  16. - Connection pooling.
  17. - Client-side SSL/TLS verification.
  18. - File uploads with multipart encoding.
  19. - Helpers for retrying requests and dealing with HTTP redirects.
  20. - Support for gzip and deflate encoding.
  21. - Proxy support for HTTP and SOCKS.
  22. - 100% test coverage.
  23. urllib3 is powerful and easy to use::
  24. >>> import urllib3
  25. >>> http = urllib3.PoolManager()
  26. >>> r = http.request('GET', 'http://httpbin.org/robots.txt')
  27. >>> r.status
  28. 200
  29. >>> r.data
  30. 'User-agent: *\nDisallow: /deny\n'
  31. For Enterprise
  32. --------------
  33. `urllib3 is available as part of the Tidelift Subscription <https://tidelift.com/subscription/pkg/pypi-urllib3?utm_source=pypi-urllib3&utm_medium=referral&utm_campaign=docs>`_
  34. urllib3 and the maintainers of thousands of other packages are working with Tidelift to deliver one enterprise subscription that covers all of the open source you use.
  35. If you want the flexibility of open source and the confidence of commercial-grade software, this is for you.
  36. |learn-more|_ |request-a-demo|_
  37. .. |learn-more| image:: https://raw.githubusercontent.com/urllib3/urllib3/master/docs/images/learn-more-button.png
  38. .. _learn-more: https://tidelift.com/subscription/pkg/pypi-urllib3?utm_source=pypi-urllib3&utm_medium=referral&utm_campaign=docs
  39. .. |request-a-demo| image:: https://raw.githubusercontent.com/urllib3/urllib3/master/docs/images/demo-button.png
  40. .. _request-a-demo: https://tidelift.com/subscription/request-a-demo?utm_source=pypi-urllib3&utm_medium=referral&utm_campaign=docs
  41. Installing
  42. ----------
  43. urllib3 can be installed with `pip <https://pip.pypa.io>`_::
  44. $ pip install urllib3
  45. Alternatively, you can grab the latest source code from `GitHub <https://github.com/urllib3/urllib3>`_::
  46. $ git clone git://github.com/urllib3/urllib3.git
  47. $ python setup.py install
  48. Usage
  49. -----
  50. The :doc:`user-guide` is the place to go to learn how to use the library and
  51. accomplish common tasks. The more in-depth :doc:`advanced-usage` guide is the place to go for lower-level tweaking.
  52. The :doc:`reference/index` documentation provides API-level documentation.
  53. .. _who-uses:
  54. Who uses urllib3?
  55. -----------------
  56. * `Requests <http://python-requests.org/>`_
  57. * `Pip <https://pip.pypa.io>`_
  58. * & more!
  59. License
  60. -------
  61. urllib3 is made available under the MIT License. For more details, see `LICENSE.txt <https://github.com/urllib3/urllib3/blob/master/LICENSE.txt>`_.
  62. Contributing
  63. ------------
  64. We happily welcome contributions, please see :doc:`contributing` for details.