I wonder how Stripe generates their IDs. They look quite nice.

They use a type safe extension of UUIDv7 Here is a go implementation and explanation: https://github.com/jetpack-io/typeid