In **Python** post request is more complicated as compare to other requests.but here is the solution for post request in python.
**Example#1:**
>>> payload = {'key1': 'value1', 'key2': 'value2'}
>>> r = requests.post("http://httpbin.org/post", data=payload)
>>> print(r.text)
{
...
"form": {
"key2": "value2",
"key1": "value1"
},
...
}
**Example#2:**
>>> import requests
>>> r = requests.post('http://httpbin.org/post', json={"key": "value"})
>>> r.status_code
200
>>> r.json()
{'args': {},
'data': '{"key": "value"}',
'files': {},
'form': {},
'headers': {'Accept': '*/*',
'Accept-Encoding': 'gzip, deflate',
'Connection': 'close',
'Content-Length': '16',
'Content-Type': 'application/json',
'Host': 'httpbin.org',
'User-Agent': 'python-requests/2.4.3 CPython/3.4.0',
'X-Request-Id': 'xx-xx-xx'},
'json': {'key': 'value'},
'origin': 'x.x.x.x',
'url': 'http://httpbin.org/post'}
**BUT IN YOUR SCENARIO**
you're using the burp suite to get data and post data in python (I don't know which specific version of python are you using) but you should follow basic method of post request in python.if you're using the brup suite and must read the [**brup suite documentation**][1]
Here is the [**documentation link**][2] which'll explain you each step one by one and do keep an eye on the notes and TODOs while following the step (in your scenario).
[1]: https://portswigger.net/burp/help/contents
[2]: http://docs.python-requests.org/en/master/user/quickstart/#more-complicated-post-requests
As of Requests version 2.4.2 and onwards, you can alternatively use 'json' parameter in the call which makes it simpler.
>>> import requests
>>> r = requests.post('http://httpbin.org/post', json={"key": "value"})
>>> r.status_code
200
>>> r.json()
{'args': {},
'data': '{"key": "value"}',
'files': {},
'form': {},
'headers': {'Accept': '*/*',
'Accept-Encoding': 'gzip, deflate',
'Connection': 'close',
'Content-Length': '16',
'Content-Type': 'application/json',
'Host': 'httpbin.org',
'User-Agent': 'python-requests/2.4.3 CPython/3.4.0',
'X-Request-Id': 'xx-xx-xx'},
'json': {'key': 'value'},
'origin': 'x.x.x.x',
'url': 'http://httpbin.org/post'}
EDIT: This feature has been added to the official documentation. You can view it here: [Requests documentation][1]
[1]: http://docs.python-requests.org/en/master/user/quickstart/#more-complicated-post-requests