Contractualism is a theory of Metaethics that attempts to derive morality from an agreement that even selfish agents would willingly sign if they knew about it (Scott Alexander).
“Moral contractualism is a consequence of logical decision theory, which we’ve all agreed to use.”—Eliezer Yudkowsky
T. M. Scanlon states it as such:
An act is wrong if its performance under the circumstances would be disallowed by any set of principles for the general regulation of behaviour that no one could reasonably reject as a basis for informed, unforced, general agreement. (Scanlon 1998, p. 153).
External sources:
Whose Utilitarianism? by Scott Alexander
The Invisible Nation – Reconciling Utilitarianism And Contractualism by Scott Alexander
Cooperation Un-Veiled by Scott Alexander