As suggested before, connect to the DB directly.
Otherwise, in case you already have a web application you want to/must use, you can use Requests
Here it shows how to post data in several ways, e.g.
as form fields
>>> payload = {'key1': 'value1', 'key2': 'value2'}
>>> r = requests.post("http://httpbin.org/post", data=payload)
>>> print(r.text)
{
...
"form": {
"key2": "value2",
"key1": "value1"
},
...
}
or json-encoded
>>> import json
>>> url = 'https://api.github.com/some/endpoint'
>>> payload = {'some': 'data'}
>>> r = requests.post(url, data=json.dumps(payload))
Requests supports use of HTTPS/SSL.