Broken marriage, cheating, and miscarriage

I really think I've ruined my life and I know everything is my fault. Me and my husband's marriage was in a weird place where we were just both working a lot. I got a connection with my coworker. I knew he was married and I was married and I shouldn't have messed with fire but I did.... And I got pregnant... His wife found out. She told my husband. Both my husband and coworker wanted me to abort. My husband made it clear that was the only way he would stay. I decided to keep the baby and my husband left me. My coworker blocked me. My kids went with their dad because they were mad at me. I haven't seen my kids in 3 months and at my doctor's appointment I found out I lost the baby. I have to go in for a D/C. I'm completely alone with no one and have lost my baby...