Scared pls help

My boyfriend just told me that the last time we had sex which was 2 days ago, he came in me. while we were having sex and we were in missionary position i had a little pain in my stomach so we switch to a different position so i’m curious if that could of been because of my iud. i’ve had it for about 3 months now and i’m scared that i could get pregnant 😓. please leave any advice, i will take a test on friday. i had just gotten off my period when this happened and it came back a little after we got done and it ended today.