add error, progress, success handler