Hello wojtek,
It seems that implementation of undo/redo commands via API wouldn't be straightforward, so I can suggest to consider some workaround for your task, i.e. duplicate the original model and then, when performing the selection of mesh faces to be cropped, apply the same face selection to the duplicated model (it should have the same order of the faces), then crop faces in the original model and remove faces in the duplicated model.