I can get a wifi-enabled microcontroller delivered from China for $3.40 [1] including payment, picking, packing and delivery. And the product is at least $1 of that price.
I find it hard to believe Amazon is spending more than $2 on payment and delivery.