Skip to content

Support for UUIDv7 Generation #3699

@Redtigercod4

Description

@Redtigercod4

Clear and concise description of the problem

As a developer using Faker I would like the ability to generate compliant UUIDv7 values that I can use with Zod (https://zod.dev). I noticed the issue raised about ULID (#2648) in which organisation members were open to adding the functionality when the requirement was raised. (#2648 (comment)) (#2648 (comment))

Suggested solution

Introduction of faker.string.uuidv7() or faker.string.uuid({ version: 7 }) or similar within the string module.

Alternative

I have considered extending the package with a custom implementation but feel that this would be beneficial to the wider community.

Additional context

UUIDv7 Specification: https://www.rfc-editor.org/rfc/rfc9562#name-uuid-version-7

Metadata

Metadata

Labels

c: featureRequest for new featurem: stringSomething is referring to the string modules: acceptedAccepted feature / Confirmed bug

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions