python http server example with api Example 1: simple http server python python -m SimpleHTTPServer 8080 Example 2: http.server python python -m http.server 8000