I have managed to be friends with an ex and he has supported me post break up at some really tough times (bereavement, illness) with friendship and being someone I can ugly cry in front of.
I think we managed to stay friends because we never fell out, the break up was so very sad because we loved each other but just had different values in many ways - work ethic, family dynamics, him needing a rocket up his arse and me needing to chill the fuck out!
The only way we made it work was by having 6 months post break up of no contact whatsoever, so we didn't get into the getting back together / one more night etc that I've had with some exes.
I don't know how it would work though in a relationship with kids because obviously you can't not have contact.
I would say though unfortunately he has kept our friendship (which is a chat maybe every few months if something has happened eg family friend ill as we had five years together so we both part of the other family at one point) hidden from his current girlfriend and the minute I found out he said she had an issue with me and I was like of course she does I don't fucking blame her because you've made it one by keeping secrets!
Said I wouldn't speak to him any more if that was how he was behaving. So we ended up going for dinner the three of us and it was actually quite, we both took the piss out of him for certain things and she could see there was no physical / sexual tension between us.
However after a while she started (quite fairly) having an issue with me again because he went back to not mentioning he'd spoken to me on the phone then she'd found out.
Anyway, we don't talk anymore because I don't want to be that ex girlfriend who falls back on a nice ex when I need someone to talk to, at the expense of another woman's confidence and security.
So I think try to think ahead a little - if you're too close now it will be a real ouch when one of you starts seeing someone I think. And makes it harder to decide when is the right time to tell them - are you telling your friend or the father of your kids (same person but different roles)
I think in your case have a breather - civil and kid chat for a few weeks at least while you get your head around things. I'm sure you can build your way up to a type of friendship in your own way. Sending positive thoughts! 