"[W]here there is a valid final judgment the doctrine of res judicata, or claim preclusion, bars future litigation between those parties on the same causes of action" ( Matter of Hodes v Axelrod, 70 NY2d 364, 372). This doctrine is based on the principle that a "judgment in one action is conclusive in a later one not only as to any matters actually litigated therein, but also as to any that might have been so litigated, when the two causes of action have such a measure of identity that a different judgment in the second would destroy or impair rights or interests established by the first" ( Schuylkill Fuel Corp. v Nieberg Realty Corp., 250 NY 304, 306-307 [1929]). Even assuming that plaintiff Biberaj had been a party defendant in the prior action ( Nahzi v Lieblich, 69 AD3d 427, lv denied 15 NY3d 703), res judicata would not apply because the defendants in the prior action were not required to assert as a counterclaim the claim they bring in this action. The judgment in the prior action established that defendant, the plaintiff in that action, was entitled to a percentage of the sale price of real property owned by defendant Lot 1555 Corp. In this action, plaintiffs claim that they loaned defendant a substantial sum to purchase a cooperative apartment. The judgment they seek would not destroy or impair rights or interests established by the first judgment.