use http error constants, beautify collision handling