http - How to Form-encode a dictionary in Python? -


i interacting rest api , need explicitly form-encode request body before sending.

the urllib module has urlencode method, see no equivalent form-encode, presumably dictionaries automatically encoded when using urllib post request.

is there built in method can use form-encode object? example:

params={'f':'json','type':'map'} post_body = formencode(params) 

producing post_body:

f=json type=map 

in instance i'm using winhttprequest through win32com module can take care of authentication natively don't need handle credentials in script.


Comments

Popular posts from this blog

java - Jasper subreport showing only one entry from the JSON data source when embedded in the Title band -

serialization - Convert Any type in scala to Array[Byte] and back -

SonarQube Plugin for Jenkins does not find SonarQube Scanner executable -