Ever wondered how those coin operated vending machines came about?

Ever wondered how those coin operated vending machines came about?