In my understanding:
I got hit with a baseball bat - means someone hit you with a baseball bat.
'I got hit by a baseball bat' - to me, it means that the bat was not held by anyone, but rather flying or falling from somewhere, being thrown at you etc.
Either way I hope you're fine