Best friend and ex

Before I start this rant I want to disclose that I am in high school. (Also I did not know who to talk to about this so I’m ranting here)

My ex and my “best friend” have become extremely close. Closer than I am or ever was to either of them. It didn’t bother me ever that they were friends until they started becoming this close.

I also found out that basically the majority of what they talk about is jsut them talking about me behind my back. These are both people I seriously trusted with everything. And they seem to be sharing all of the private information that I shared with them to each other. However a large part of my problem is that I can’t confront them because I’m not supposed to know this. I am taking care of my friends streaks because her phone got taken away. And I accidentally clicked open the message strand. I went to close it because before I found all this out I really didn’t care. But the first thing I saw was my name so of course I was curious and read it.

What they were talking about was seriously private information I had told my ex that I SPECIFICALLY ASKED HE DOESN’T TELL ANYBODY. Which is that I’m taking birth control (I’m not sexually active but my mom asked me to start taking it)

Because I saw these messages I was curious if they had said anything else about me. So I scrolled and the next thing I saw was my friend telling my ex that he’s her “only real friend” and that sometimes she doesn’t even want to talk to me. But when I see her in person she acts like she loves me, she literally says that she loves me. So it’s very two faced and fake.

The majority of the messages I saw were discussing me and things I thought I was saying privately. I don’t know what to do please help

I’m so angry about it but I really have no idea what to do.