Coherent pulse stacking (CPS) is a new time-domain coherent addition technique that stacks several optical pulses into a single output pulse, enabling high pulse energy and high average power. A Z-domain model targeting the pulsed laser is assembled to describe the optical interference process. An algorithm, extracting the cavity phase and pulse phases from limited data, where only the pulse intensity is available, is developed to diagnose optical cavity resonators. We also implement the algorithm on the cascaded system of multiple optical cavities, achieving phase errors less than 1.0°(root mean square), which could ensure the stability of CPS.