That is actually a more recent (~20 years?) development. You cannot say anything about the quality of restrooms, but it is basically one company (Sanifair) for all of Germany that established a monopoly. People working there are often sub-contractors with bad working conditions. You get a coupon for the price you paid to exchange against wares at the local gas stop.
The coupon was created to get acceptance for paying, which wasn't common a few years back, but most of them never get redeemed. It is a business worth billions.
Unfortunately people tend to fall for coupons of any kind because they suggest you could save money.