Flu shots

At what point in pregnancy are they safe to get? I didn't get one when I was pregnant with DS b/c I wasn't out of my first trimester when shots were available, but I'm not sure how far along you have to be for it to be safe.