Thanks for posting,
Amongst the various causes of miscarriage
are infections especially of pelvic origin. Per your description it is very likely that the pain you have during urination or BM might be as a result of a UTI or acute PID or another source of infection (probably gut). Since you are not still bleeding, excluding retained product/incomplete miscarriage could be made easier for the doctor but should be considered a possibility (and that you can actually start bleeding again if that is the case). After examination by your doctor, you will be required to do urinalysis
, blood tests( for signs of infection) and probably a pelvic scan. If infection is the cause, then an appropriate course of antibiotics could be given to treat it. The infection must not be as a result of typical STD
microbes but other bacteria that may or may not live naturally in you could be the cause.
Hope this is useful
Hope this helps