Except they didn’t. Whomever [sic] purchased the stock initially did, and often that amount is a shadow of what the stock is currently traded at.
This ignores two other very important roles that subsequent shareholders play:
Give initial investors the opportunity re-deploy their capital elsewhere when they choose to do so.
Signal the value of the company’s equity, in real time, on the open market. When the stock is trading above IPO price (as your rebuttal implies), this enables the company to raise more capital by borrowing against its equity and/or selling shares of its own stock.
In light of these critical roles, it’s vastly unfair to say that shareholders contribute nothing to the delivery of goods and services—quite the opposite.