toByteString package:uuid-types

Encode a UUID into a ByteString in network order. This uses the same encoding as the Binary instance.