I had a similar situation. If you trust and feel comfortable with your boyfriend, I think it would be a good idea to be honest about when this happened. If you feel you have to hide it, it’s just going to add another layer of shame to the equation.
For me, I had some sort of mental-physical block where he couldn’t get it in, I think it’s from the trauma but I never got diagnosed or anything. What eventually helped for me was just time, trust, and being comfortable with my boyfriend. If I ever was distressed he would immediately stop and hold me. I agree with everyone in talking to a professional, maybe someone with experience in SA situations! But just know, it gets better :)