adding debug output
fixing base url