Library to convert python requests object to curl command.
Project description
# Curlify - convert python requests request object to cURL command
## Installation
```sh
pip install curlify
```
## Changes
### v.1.2
* Order of headers is deterministic (thanks to @tomviner)
## Example
```py
import curlify
import requests
response = requests.get("http://google.ru")
print(curlify.to_curl(response.request))
# curl -X GET -H 'Connection: keep-alive' -H 'Accept-Encoding: gzip, deflate' -H 'Accept: */*' -H 'User-Agent: python-requests/2.7.0 CPython/2.7.11 Darwin/15.6.0' -d '' 'http://www.google.ru/'
```
## Installation
```sh
pip install curlify
```
## Changes
### v.1.2
* Order of headers is deterministic (thanks to @tomviner)
## Example
```py
import curlify
import requests
response = requests.get("http://google.ru")
print(curlify.to_curl(response.request))
# curl -X GET -H 'Connection: keep-alive' -H 'Accept-Encoding: gzip, deflate' -H 'Accept: */*' -H 'User-Agent: python-requests/2.7.0 CPython/2.7.11 Darwin/15.6.0' -d '' 'http://www.google.ru/'
```
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
curlify-1.2.1.tar.gz
(2.6 kB
view details)
File details
Details for the file curlify-1.2.1.tar.gz.
File metadata
- Download URL: curlify-1.2.1.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a16221e2a70298a1ae196fa736caee99995757c4f73a2ebb5836c0d89d96ced3
|
|
| MD5 |
65a941a567d3a8ae4b13cc154c57ef10
|
|
| BLAKE2b-256 |
c036371146021d6534e2602300abcd7f8e4d2326d8e71a1ef88b7da43dfd538c
|