Add html api to support rendering html files. Fix bug in rendering /api/XXXX
Merge branch 'add_html_api'