Do you have to have someone consent to text them?

I DM'd someone I knew on social media and asked them if I could text them. My first question was do you have the same contact info since we last spoke and they said Yeah. I haven't spoken to them in years and the last time we spoke it was heated.
Do you have to have someone consent to text them?
Post Opinion