The idempotencyKey just has to be a unique value in a 24 hour period, they mention UUIDv4 as its guaranteed unique always, but its not a requirement and uniqid() is more than sufficient for this.
If you’re still seeing duplicate payments then its something that idempotency wont fix and the issue is elsewhere. If you’re able to tie it down any further let me know and I’ll look into it.