Deductions & credits

I got married in 2023 and our AGI will be above 300k. However prior to marriage in 2022 my spouse had an AGI less than 150k. Can we claim the 7500k tax credit on our 2023 taxes when filing as married jointly? My initial thought is yes but wanted to double check before making the purchase. TIA