You might be having a threatened miscarriage/abortion
or probably already in the stage of inevitable miscarriage. i'll suggest you see your doctor or a gyn-obs immediately for a confirmatory diagnosis after doing a pelvic exams ( digital vagina exams, speculum exams and possibly a pelvic ultrasound
). From then, exact management of what is going on with you will be established.
Wish you the best