put response handlers in new file
added get function to internal api