This is so much worse than you are acknowledging OP but that’s ok, it comes in waves.
Why go to therapy? Your partner is just awful. He is doing that thing of talking about it like he was temporarily someone else, like it wasn’t him, like oh yes this is interesting academically, I wonder what exactly is going on here... He is being - has been - AWFUL to you and your relationship for a very long time.
Texting a girl from the bus - why would he even do this? He’s hardly going to admit to it if it was successful. Was this his attempt at “the worst I’ve ever done is ... and she wasn’t interested anyway” ?
He is an absolute shit. He’s been doing this online stuff for AGES. and “just looking” at prostitutes, oh come on.
It’s a given this guy will have more footprint online and will be in a flap now hiding stuff and cleaning up his tracks.
His comments of asking his IT friend and how it was going to be so embarrassing makes me cringe. This is just all lies.
Honestly OP I’ve been that soldier and I initially believed (in a completely perplexed state of mind, I had literally no point of reference for what I was seeing and hearing) what he said. Believed is too strong a word, I had suspended acceptance. I kept digging and it all tumbled out. But I work in IT and it wasn’t hard.
Tell your family the extent if what you know and draw strength from them. Tomorrow is just one day in your life don’t get too worked up over it. I’m really sorry you have this going on.