Medical and biological sense: the body's ability to resist infection, or the process of becoming immune.
ワクチンで免疫をつける。
Build immunity with a vaccine.
Some diseases give you immunity once you've had them.
being hardened; being unaffected; being accustomed
Figurative extension: so used to criticism, hardship, or a situation that one is no longer bothered by it. Often used with 〜に免疫がある or 〜に免疫ができる.
彼は批判に免疫がある。
He is immune to criticism.
都会の騒音にはもう免疫ができた。
I've become accustomed to the noise of the city.
He's already become immune to criticism.
Many people have immunity against this virus.
After working overtime every day, I've become used to the busyness.
You get vaccinated to build up immunity.
Many people have no immunity to this disease.
immunity
immunogen