Is it bad to fast while pregnant?

I go to church and we have a day every month where we unite and fast. Now that I’m pregnant I don’t know if it’s safe for my baby...