First way to avoid getting scammed is to be Skeptical about everything, and unsolicited private messages or DMs should be treated with Skepticism hence if otherwise any dreams sold to you by anyone should not be bought, don't hesitate to leave such conversations that have too much of promise of returns to you.
The power of knowledge can be really underrated I most cases as this is still happening in current times and people are still getting scammed. The first Red flag of a scam is unsolicited messages like you mentioned OP, but greed for what is being offered blinds the eyes of victims and unguaranteed promises leave them vulnerable to this scams.
The idea that "nothing good comes easy" isn't just a saying but a true life experience that is being practiced everyday and the idea of that should always keep everyone at alert as to cases of scams that come with such strategy.