Welcome to BF! NYC to Buffalo will be a great ride.
Check out --
https://www.dot.ny.gov/bicycle -- for info on bicycle route maps that NYS puts out for free. You could take the Route 17 corridor from NYC to Buffalo or you could take the Route 9 corridor from NYC to Albany and then the Route 5 corridor from Albany to Buffalo. That latter option is a
much more scenic run because you could spend a lot of miles hugging the Hudson River and Mohawk River/Erie Canalway if you tailored your route to do so. In addition, hugging the Hudson R and Erie Canalway/Mohawk R will keep you close to all kinds of food/beverage options and amenities of every kind. It’s hard to travel 10 miles without hitting at least some little town or village, as opposed to the Route 17 corridor--which involves some serious sparsely-populated country cycling. Also check out --
Parks & Trails New York | Cycling the Erie Canal bike tour -- for info, maps and a book about the Erie Canalway bike trail. I think the maps they offer are free (?) but the book isn’t, although the book is still far more than worth the purchase price for the quality/depth of info it provides.
Good luck with your NYC-Buffalo tour. That’s a run that a lot of New Yorkers dream about doing but very few ever get around to doing.