title: Python Request Post with param data
body: <p>This is the raw request for an API call:</p>
  
  <pre><code>POST http://192.168.3.45:8080/api/v2/event/log?sessionKey=b299d17b896417a7b18f46544d40adb734240cc2&amp;format=json HTTP/1.1
  Accept-Encoding: gzip,deflate
  Content-Type: application/json
  Content-Length: 86
  Host: 192.168.3.45:8080
  Connection: Keep-Alive
  User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
  
  {"eventType":"AAS_PORTAL_START","data":{"uid":"hfe3hf45huf33545","aid":"1","vid":"1"}}"""
  </code></pre>
  
  <p>This request returns a success (2xx) response.</p>
  
  <p>Now I am trying to post this request using <code>requests</code>:</p>
  
  <pre><code>&gt;&gt;&gt; import requests
  &gt;&gt;&gt; headers = {'content-type' : 'application/json'}
  &gt;&gt;&gt; data ={"eventType":"AAS_PORTAL_START","data{"uid":"hfe3hf45huf33545","aid":"1","vid":"1"}}
  &gt;&gt;&gt; url = "http://192.168.3.45:8080/api/v2/event/log?sessionKey=9ebbd0b25760557393a43064a92bae539d962103&amp;format=xml&amp;platformId=1"
  &gt;&gt;&gt; requests.post(url,params=data,headers=headers)
  &lt;Response [400]&gt;
  </code></pre>
  
  <p>Everything looks fine to me and I am not quite sure what I posting wrong to get a 400 response.</p>