how to send application/x-www-form-urlencoded JSON string in python botlle server
<p>I want to post a JSON string in the format of </p>

<pre><code>application/x-www-form-urlencoded
</code></pre>

<p>using python's bottle</p>

<p>Here's the web service I had written</p>

<pre><code>import json
from bottle import route, run, request

@route('/ocr_response2', method='POST')
def ocr_response2():
    word = request.json
    print word


if __name__ == "__main__":
    run(host='0.0.0.0', port=8080, debug=True)
</code></pre>

<p>I know this would work if <code>contentType: "application/json",</code>
But can't figure out if content type is <code>application/x-www-form-urlencoded
</code></p>

<p>Here's how i am sending the data </p>

<pre><code>import requests

d = {'spam': 20, 'eggs': 3}
requests.post("http://XX.XX.XX.XXX:8080", data=d)
</code></pre>