http: implement callbacks