SARS-CoV-2 vaccines are effective at limiting disease severity, but effectiveness is lower among patients with cancer or immunosuppression. Effectiveness wanes with time and varies by vaccine type. Moreover, vaccines are based on the ancestral SARS-CoV-2 spike-protein that emerging variants may evade. Here, we describe a mechanistic mathematical model for vaccination-induced immunity, validate it with available clinical data, and predict vaccine effectiveness for varied vaccine platforms in the setting of variants with ability to escape immunity, increased virulence, or enhanced transmissibility. We further account for concurrent cancer or underlying immunosuppression. The model confirms enhanced immunogenicity following booster vaccination in immunosuppressed patients but predicts at least one more booster dose is required for these individuals to maintain protection. We further studied the impact of variants on immunosuppressed individuals as a function of the interval between multiple booster doses. Our model is useful for planning future vaccinations, and tailoring strategies to risk groups.