A stackoverflow discussion about how to use python to make an xmlhttprequest. I looked this up because that's how you're supposed to interact with unmark's pseudo API. The accepted answer shows how to do it with scrapy, but I think it could be adapted for use with the requests module. The HTTP method would be POST, and one of the headers would be "X-Requested-With: XMLHttpRequest". It's worth a shot, at any rate.
The main thrust of the article is how to whip together a quick and dirty HTTP server for static pages using Python and Cherrypy. I saved this article because the worst-ranked response also tells you how to hardcode (read, make configurable at runtime) the port and IP address a CherryPy instance listens on.
cherrypy.server.socket_port = 80
cherrypy.server.socket_host = '0.0.0.0'
3745 links, including 199 private