what was going on?

I am 28 weeks pregnant &  last night I woke up at 3am. My stomach was hurting really bad and I thought it was because I didn't go pee before I went to bed. Turns out I just didn't have to pee, my stomach was hurting so bad & Tmi but I got really bad diarrhea & it was hurting me even more because the baby was moving while I had it going on, last night I felt so bad I was sweating really bad & when I went to bed I was shaking and I was really really itchy, it was weird.. Has this happened to anybody? Should I be concerned? I woke up pretty fine, but it didn't seem normal to me what was going on last night.