replace the phase and callback action to an enum