added URI parsing capabilities, updated error structure, updated tests