31 weeks, contractions and back pain

Alyssa • 24 and have two kids. Married ❤
I am 31 weeks and went into l&d last night because of severe back pain. Something didn't feel right so I decided to be safe than sorry. Turns out I've been having slight contractions and that's what could be causing my back pain. They gave me flexeril to help relax the muscules but I don't want to take too many meds. They said my cervix is closed and everything so I looked good. Anyone else experiencing this? Is it common?