requests 2.32.3


pip install requests

  Latest version

Released: May 29, 2024


Meta
Author: Kenneth Reitz
Requires Python: >=3.8

Classifiers

Development Status
  • 5 - Production/Stable

Environment
  • Web Environment

Intended Audience
  • Developers

License
  • OSI Approved :: Apache Software License

Natural Language
  • English

Operating System
  • OS Independent

Programming Language
  • Python
  • Python :: 3
  • Python :: 3.8
  • Python :: 3.9
  • Python :: 3.10
  • Python :: 3.11
  • Python :: 3.12
  • Python :: 3 :: Only
  • Python :: Implementation :: CPython
  • Python :: Implementation :: PyPy

Topic
  • Internet :: WWW/HTTP
  • Software Development :: Libraries

Requests

Requests is a simple, yet elegant, HTTP library.

>>> import requests
>>> r = requests.get('https://httpbin.org/basic-auth/user/pass', auth=('user', 'pass'))
>>> r.status_code
200
>>> r.headers['content-type']
'application/json; charset=utf8'
>>> r.encoding
'utf-8'
>>> r.text
'{"authenticated": true, ...'
>>> r.json()
{'authenticated': True, ...}

Requests allows you to send HTTP/1.1 requests extremely easily. There’s no need to manually add query strings to your URLs, or to form-encode your PUT & POST data — but nowadays, just use the json method!

Requests is one of the most downloaded Python packages today, pulling in around 30M downloads / week— according to GitHub, Requests is currently depended upon by 1,000,000+ repositories. You may certainly put your trust in this code.

Downloads Supported Versions Contributors

Installing Requests and Supported Versions

Requests is available on PyPI:

$ python -m pip install requests

Requests officially supports Python 3.8+.

Supported Features & Best–Practices

Requests is ready for the demands of building robust and reliable HTTP–speaking applications, for the needs of today.

  • Keep-Alive & Connection Pooling
  • International Domains and URLs
  • Sessions with Cookie Persistence
  • Browser-style TLS/SSL Verification
  • Basic & Digest Authentication
  • Familiar dict–like Cookies
  • Automatic Content Decompression and Decoding
  • Multi-part File Uploads
  • SOCKS Proxy Support
  • Connection Timeouts
  • Streaming Downloads
  • Automatic honoring of .netrc
  • Chunked HTTP Requests

API Reference and User Guide available on Read the Docs

Read the Docs

Cloning the repository

When cloning the Requests repository, you may need to add the -c fetch.fsck.badTimezone=ignore flag to avoid an error about a bad commit (see this issue for more background):

git clone -c fetch.fsck.badTimezone=ignore https://github.com/psf/requests.git

You can also apply this setting to your global Git config:

git config --global fetch.fsck.badTimezone ignore

Kenneth Reitz Python Software Foundation

2.32.3 May 29, 2024
2.32.2 May 21, 2024
2.32.1 May 20, 2024
2.32.0 May 20, 2024
2.31.0 May 22, 2023
2.30.0 May 03, 2023
2.29.0 Apr 26, 2023
2.28.2 Jan 12, 2023
2.28.1 Jun 29, 2022
2.28.0 Jun 09, 2022
2.27.1 Jan 05, 2022
2.27.0 Jan 03, 2022
2.26.0 Jul 13, 2021
2.25.1 Dec 16, 2020
2.25.0 Nov 11, 2020
2.24.0 Jun 17, 2020
2.23.0 Feb 19, 2020
2.22.0 May 16, 2019
2.21.0 Dec 10, 2018
2.20.1 Nov 08, 2018
2.20.0 Oct 18, 2018
2.19.1 Jun 14, 2018
2.19.0 Jun 12, 2018
2.18.4 Aug 15, 2017
2.18.3 Aug 02, 2017
2.18.2 Jul 25, 2017
2.18.1 Jun 14, 2017
2.18.0 Jun 14, 2017
2.17.3 May 29, 2017
2.17.2 May 29, 2017
2.17.1 May 29, 2017
2.17.0 May 29, 2017
2.16.5 May 28, 2017
2.16.4 May 27, 2017
2.16.3 May 27, 2017
2.16.2 May 27, 2017
2.16.1 May 27, 2017
2.16.0 May 27, 2017
2.15.1 May 27, 2017
2.14.2 May 10, 2017
2.14.1 May 09, 2017
2.14.0 May 09, 2017
2.13.0 Jan 24, 2017
2.12.5 Jan 18, 2017
2.12.4 Dec 14, 2016
2.12.3 Dec 01, 2016
2.12.2 Nov 30, 2016
2.12.1 Nov 16, 2016
2.12.0 Nov 15, 2016
2.11.1 Aug 17, 2016
2.11.0 Aug 08, 2016
2.10.0 Apr 29, 2016
2.9.2 Apr 29, 2016
2.9.1 Dec 21, 2015
2.9.0 Dec 15, 2015
2.8.1 Oct 13, 2015
2.8.0 Oct 06, 2015
2.7.0 May 03, 2015
2.6.2 Apr 23, 2015
2.6.1 Apr 23, 2015
2.6.0 Mar 14, 2015
2.5.3 Feb 24, 2015
2.5.2 Feb 23, 2015
2.5.1 Dec 23, 2014
2.5.0 Dec 01, 2014
2.4.3 Oct 06, 2014
2.4.2 Oct 05, 2014
2.4.1 Sep 09, 2014
2.4.0 Aug 29, 2014
2.3.0 May 16, 2014
2.2.1 Jan 23, 2014
2.2.0 Jan 09, 2014
2.1.0 Dec 05, 2013
2.0.1 Oct 24, 2013
2.0.0 Sep 24, 2013
1.2.3 May 25, 2013
1.2.2 May 21, 2013
1.2.1 May 20, 2013
1.2.0 Mar 31, 2013
1.1.0 Jan 10, 2013
1.0.4 Dec 23, 2012
1.0.3 Dec 18, 2012
1.0.2 Dec 17, 2012
1.0.1 Dec 17, 2012
1.0.0 Dec 17, 2012
0.14.2 Oct 27, 2012
0.14.1 Oct 01, 2012
0.14.0 Sep 02, 2012
0.13.9 Aug 25, 2012
0.13.8 Aug 20, 2012
0.13.7 Aug 19, 2012
0.13.6 Aug 06, 2012
0.13.5 Jul 27, 2012
0.13.4 Jul 27, 2012
0.13.3 Jul 12, 2012
0.13.2 Jun 29, 2012
0.13.1 Jun 08, 2012
0.13.0 May 30, 2012
0.12.1 May 08, 2012
0.12.0 May 03, 2012
0.11.2 Apr 23, 2012
0.11.1 Mar 31, 2012
0.10.8 Mar 09, 2012
0.10.7 Mar 08, 2012
0.10.6 Feb 26, 2012
0.10.4 Feb 20, 2012
0.10.3 Feb 20, 2012
0.10.2 Feb 15, 2012
0.10.1 Jan 23, 2012
0.10.0 Jan 22, 2012
0.9.3 Jan 19, 2012
0.9.2 Jan 19, 2012
0.9.1 Jan 06, 2012
0.9.0 Dec 28, 2011
0.8.9 Dec 28, 2011
0.8.8 Dec 28, 2011
0.8.7 Dec 24, 2011
0.8.6 Dec 19, 2011
0.8.5 Dec 14, 2011
0.8.4 Dec 11, 2011
0.8.3 Nov 27, 2011
0.8.2 Nov 19, 2011
0.8.1 Nov 15, 2011
0.8.0 Nov 13, 2011
0.7.6 Nov 07, 2011
0.7.5 Nov 05, 2011
0.7.4 Oct 27, 2011
0.7.3 Oct 23, 2011
0.7.2 Oct 23, 2011
0.7.1 Oct 23, 2011
0.7.0 Oct 23, 2011
0.6.6 Oct 19, 2011
0.6.5 Oct 19, 2011
0.6.4 Oct 14, 2011
0.6.3 Oct 14, 2011
0.6.2 Oct 09, 2011
0.6.1 Aug 21, 2011
0.6.0 Aug 17, 2011
0.5.1 Jul 24, 2011
0.5.0 Jun 22, 2011
0.4.1 May 25, 2011
0.4.0 May 15, 2011
0.3.4 May 14, 2011
0.3.3 May 12, 2011
0.3.2 Apr 15, 2011
0.3.1 Apr 01, 2011
0.3.0 Feb 25, 2011
0.2.4 Feb 19, 2011
0.2.3 Feb 15, 2011
0.2.2 Feb 14, 2011
0.2.1 Feb 14, 2011
0.2.0 Feb 14, 2011
0.0rc0 Jun 17, 2020

Wheel compatibility matrix

Platform Python 3
any

Files in release

Extras:
Dependencies:
charset-normalizer (<4,>=2)
idna (<4,>=2.5)
urllib3 (<3,>=1.21.1)
certifi (>=2017.4.17)