I'm in the UK so haven't heard of Miralax I'm afraid but I went straight to lactulose and fibogel combo as recommended by my GI dr. You start off small with lactulose (10mls or so) and then you can build up to 40-60mls a day if you need (I found as the pregnancy progressed I had to but seem to have stabalised on 35mls for now) but best to do anything more than about 20mls in 2 or 3 shots throughout day. I have heard of stomach cramping with lactulose but I've never had it fortunately, I think it's one of those things that either works for people or doesn't suit them. Drinking plenty of water with lactulose is needed to help those stools come out soft.
I think Rectogesic is called Rectiv in the US
https://www.rectiv.com/en/about_rectiv If you do use this ointment, use less than what the packet says and don't insert up the rectum, my GI told me to just put a small pea size amount around the entrance to the anus and it will soak in. This mitigates the headache side effect as you're using less. I've found it extremely effective if used either before or after a bowel movement.
Instillagel was something else I used when things were really bad- this is a local anaesthetic and I'd use it before a BM, and then rectogesic afterwards. Again something my GI recommended.
Pregnancy should be a time of joy, so I'm sorry you are suffering. I know exactly how consuming it is and just stay hopeful it won't last forever and you've healed before :)