It’s best not to compost cream – or any other dairy products.
While it will rot down, rats or other undesirable animals may be attracted to your compost heap in the meantime.
You could add it but it’s not going to add a lot of bulk to your heap and in our opinion, the risk isn’t worth the reward.