better exception handling for require
wip of bitly implementation