Add key constraints.