Identifiers

UUIDs, ULIDs, national tax IDs, ISBNs and other identifiers with valid check digits. See all field types and the options every field takes.

uuid

Random UUID version 4.

Also takes the common options and textual constraints.

uuid.yaml
- { name: id, type: uuid }

uuidv4

Same as uuid.

Also takes the common options and textual constraints.

uuidv4.yaml
- { name: id, type: uuidv4 }

ulid

ULID: 26 characters, sortable by creation time.

Also takes the common options and textual constraints.

ulid.yaml
- { name: id, type: ulid }

mongodbObjectId

24-character hexadecimal MongoDB ObjectId.

Also takes the common options and textual constraints.

mongodbObjectId.yaml
- { name: _id, type: mongodbObjectId }

identifier

National or business identifier with valid check digits.

Parameter Values Default Description
kind cpf, cnpj, ssn, ein, uuid, slug Required. cpf and cnpj (Brazil), ssn and ein (United States), uuid, slug.
formatted boolean false Include the usual punctuation, e.g. 123.456.789-09 instead of 12345678909.

Also takes the common options and textual constraints.

identifier.yaml
- { name: tax_id, type: identifier, kind: cpf, formatted: true }

isbn

ISBN-10 or ISBN-13 with a valid check digit.

Parameter Values Default Description
version 10, 13 10 or 13. Without it, either form is generated.
formatted boolean false Separate the groups with hyphens.
digitsOnly boolean Only digits: not allowed with isbn10, whose check digit can be X.

Also takes the common options and textual constraints.

isbn.yaml
- { name: isbn, type: isbn, version: 13 }

isbn10

ISBN-10. The check digit can be X.

Parameter Values Default Description
formatted boolean false Separate the groups with hyphens.

Also takes the common options and textual constraints.

isbn10.yaml
- { name: isbn, type: isbn10 }

isbn13

ISBN-13 with a valid check digit.

Parameter Values Default Description
formatted boolean false Separate the groups with hyphens.

Also takes the common options and textual constraints.

isbn13.yaml
- { name: isbn, type: isbn13, formatted: true }

issn

ISSN with a valid check digit.

Parameter Values Default Description
formatted boolean false Write it as 1234-5679.

Also takes the common options and textual constraints.

issn.yaml
- { name: issn, type: issn, formatted: true }

semver

Semantic version such as 2.14.7.

Also takes the common options and textual constraints.

semver.yaml
- { name: version, type: semver }

slug

Lowercase ASCII slug of hyphen-joined words: baking-chess-hiking.

Parameter Values Default Description
words integer 3 Number of words.

Also takes the common options and textual constraints.

slug.yaml
- { name: slug, type: slug, words: 2 }