I'm not sure about paying the driver directly, but at least TCA and Staxi have an app that supports credit card (and PayPal).
This one accepts CC too: https://www.amsterdamtaxi-online.com/
It's a statistical sample of one, but on January 1st 2020, I paid for a taxi from Schiphol to the Amsterdam Marriott with a Visa, and again the next day in the other direction. Apropos of nothing, the first taxi was a Tesla.
Transportation in Cancun can be a bit of a challenge. When you get out of customs, you will be accosted by aggressive car rental sales people and once you step out of the airport doors there are even more aggressive taxi agents.
Last time I was there (in June) we checked the rental places at the airport and they all had horror stories on Yelp (https://www....
Here's the best answer from the local foreigner: now there is an app like that! It's called UBcab and it's available in english. The price is quite fixed and easy to locate where you are etc. The arm sticking thing is literally a danger so better use official taxis or just walk if it's downtown the place is so cramped that taxi could be a waste of money. But ...