a written contract ratifying the legality of an insurance agreement.