Governments hire companies (contractors) to do work that is well outside the standard city services (well, sometimes they even hire companies to do the normal city services). This is just Google paying for a trial for the city. I'm sure they will later charge other cities so it looks like most hired contractors that a city uses.
Part of the question is if we should rely on a single company for so many different things. A company that’s controlled by only two people.
This is maybe not an issue today, but what happens once the founders die and their inheritors take over control? Children of founders tend to purely focus on profit, and such a focus might lead to a Google led in the way Comcast is led today.
And I don’t want to see a Google, Amazon, etc – likely even larger than now – with such leadership. Ideally we wouldn’t leave that much power to such a low number of people we can’t even elect.