Created
June 10, 2011 08:28
-
-
Save gennad/1018459 to your computer and use it in GitHub Desktop.
Send json POST request
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib2 | |
import json | |
# Whatever structure you need to send goes here: | |
jdata = json.dumps({"username":"...", "password":"..."}) | |
urllib2.urlopen("http://www.example.com/", jdata) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment