The py-restlib: [http://code.google.com/p/py-restlib] is a GNU GPL library that implements a REST client interface for Python. Here it goes its Getting Started section: Introduction Py-restlib is supposed to be a simple REST client interface for python. But, it also claims that writing a python client to communicate with RESTful applications on the Web should be… Continue reading A REST client interface for Python
Month: July 2008
Python POST request
If you’re trying to send a python POST request with httplib, but it’s not working like example tells. Try this minor fix: Here is an example session that shows how to “POST” requests: >>> import httplib, urllib >>> params = urllib.urlencode({‘spam’: 1, ‘eggs’: 2, ‘bacon’: 0}) >>> headers = {“Content-Type”: “application/x-www-form-urlencoded”, … “Accept”: “text/plain”} >>>… Continue reading Python POST request