add HTTPAPI implementation
make it works (execpt the cookie issue atm)