Domain generators¶
Warning
The current page still doesn't have a translation for this language.
But you can help translating it: Contributing.
AcademicTitleGenerator¶
Generate locale-aware academic titles from the configured dataset.
Why: Use AcademicTitleGenerator when person records need locale-specific academic titles with a controlled prevalence; omit the field rather than generating an empty title when the target does not model titles.
Category: person.
Output: str | null.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset that supplies locale-appropriate academic titles.quota:float; Default0.5— Probability that a generated record receives a title instead of no value.
CNPJGenerator¶
Generate formatted Brazilian CNPJ business-registration numbers.
Why: Use CNPJGenerator for Brazilian organization fixtures that require formatted CNPJ-shaped tax identifiers; use CPFGenerator for individual taxpayers.
Category: br.
Output: str.
1 | |
CPFGenerator¶
Generate formatted Brazilian CPF individual taxpayer numbers.
Why: Use CPFGenerator for Brazilian person fixtures that require formatted CPF-shaped taxpayer identifiers; use CNPJGenerator for organizations.
Category: br.
Output: str.
1 | |
CompanyNameGenerator¶
Generate synthetic organization names from built-in name fragments.
Why: Use CompanyNameGenerator for varied synthetic organization names without loading a source dataset; use the Company entity when legal form, address, sector, and contacts must remain coherent.
Category: organization.
Output: str.
1 | |
DataFakerGenerator¶
Generate locale-aware values through a named Python Faker provider.
Why: Use DataFakerGenerator when a named Faker provider supplies the required locale-aware value; the selected provider owns the concrete output type.
Category: faker.
Output: method-specific Faker value.
1 | |
Parameters¶
method:str; Defaultrequired— Public Python Faker provider method invoked for each generated value.locale:str | null; Defaulten_US— Faker locale used to load provider data and formatting rules.
DepartmentNameGenerator¶
Generate organization department names from a locale-aware dataset.
Why: Use DepartmentNameGenerator for organization structures that need realistic localized department labels; use a weighted source list when the organization has a fixed taxonomy.
Category: organization.
Output: str.
1 | |
Parameters¶
locale:str | null; DefaultNone— Locale used to choose the department-name dataset.
DomainGenerator¶
Generate internet domain names from a country-specific weighted dataset.
Why: Use DomainGenerator for country-weighted internet domains or as the correlated domain part of email addresses; use a source reference when domains must belong to known customers.
Category: net.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset that weights top-level domains and name fragments.
EANGenerator¶
Generate EAN-13 product codes, optionally unique within one process.
Why: Use EANGenerator for product fixtures that need EAN-13-shaped identifiers; enable unique only for bounded single-process pools and use a key strategy when global uniqueness is required.
Category: ecommerce.
Output: str.
1 | |
Parameters¶
locale:str | null; Defaulten_US— Faker locale used by the barcode provider.unique:bool; DefaultFalse— Whether the in-process Faker provider must avoid repeated EAN values.
EmailAddressGenerator¶
Generate dataset-aware email addresses, optionally based on a person's name.
Why: Use EmailAddressGenerator when email values should correlate with a person's supplied name and regional domain data; use DataFakerGenerator for an unrelated standalone email.
Category: person.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset used for names and domain weighting.given_name:str | null; DefaultNone— Optional given name embedded into the local part.family_name:str | null; DefaultNone— Optional family name embedded into the local part.
FamilyNameGenerator¶
Generate locale-aware family names from the configured dataset.
Why: Use FamilyNameGenerator when family names must follow one explicit regional dataset.
Category: person.
Output: str.
1 | |
Parameters¶
dataset:str | null; Defaultrequired— Country dataset that supplies weighted family names.
GenderGenerator¶
Generate female, male, or other values using configurable quotas.
Why: Use GenderGenerator when demographic fixtures require explicit female, male, and other proportions; use a source value when categories or quotas come from governed production data.
Category: person.
Output: str.
1 | |
Parameters¶
female_quota:float | null; DefaultNone— Probability assigned to the female category.other_gender_quota:float | null; DefaultNone— Probability assigned to the other category; the remainder is male.
GivenNameGenerator¶
Generate locale-aware given names, optionally constrained by gender.
Why: Use GivenNameGenerator when synthetic names must follow one regional dataset and optionally correlate with gender; use the Person entity when name, address, contact, and demographics must be coherent together.
Category: person.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset that supplies weighted given names.gender:str | null; DefaultNone— Optional gender category used to select the corresponding name pool.
IbanGenerator¶
Generate a structurally valid ISO 13616 IBAN for the dataset's country.
Why: Use IbanGenerator for test payment accounts that need a country-shaped IBAN with a valid checksum; use a source reference instead when existing account identity must be preserved.
Category: finance.
Output: str.
1 | |
Parameters¶
dataset:str | None; DefaultNone— ISO country dataset that determines the IBAN length and structure.
MedicalLicenseGenerator¶
Generate state-prefixed medical licence identifiers.
Why: Use MedicalLicenseGenerator when synthetic clinician records need recognisable state-scoped licence keys; use NpiGenerator when the requirement is a national provider identifier.
Category: healthcare.
Output: str.
1 | |
Parameters¶
dataset:str | None; DefaultNone— Country dataset used to resolve supported state or region codes.states:Iterable[str] | None; DefaultNone— Allowed state or region prefixes sampled for each licence.digits:int; Default6— Number of numeric characters appended to the selected prefix.
NobilityTitleGenerator¶
Generate locale-aware nobility titles from the configured dataset.
Why: Use NobilityTitleGenerator when locale-specific person fixtures deliberately model rare nobility titles; omit it when the business schema has no title concept.
Category: person.
Output: str | null.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset supplying locale-specific nobility titles.gender:str | null; DefaultNone— Optional gender category used to select matching titles.noble_quota:float | null; DefaultNone— Probability that a row receives a nobility title instead of no value.
NpiGenerator¶
Generate 10-digit National Provider Identifiers.
Why: Use NpiGenerator when US healthcare test records need NPI-shaped provider identifiers; use MedicalLicenseGenerator for state-scoped licence values.
Category: healthcare.
Output: str.
1 | |
PasswordGenerator¶
Generate secure passwords with configurable complexity.
Why: Use PasswordGenerator for authentication test fixtures that must satisfy explicit character-class complexity; never use generated values as production credentials.
Category: net.
Output: str.
1 | |
Parameters¶
length:int; Default16— Total password length; must meet the implementation's minimum.include_special:bool; DefaultTrue— Whether at least one supported special character is included.include_numbers:bool; DefaultTrue— Whether at least one numeric character is included.include_uppercase:bool; DefaultTrue— Whether at least one uppercase character is included.
PhoneNumberGenerator¶
Generate locale-aware phone numbers from the configured dataset.
Why: Use PhoneNumberGenerator for locale-shaped contact fixtures with optional area-code or mobile constraints; use a source reference when numbers must preserve existing customer identity.
Category: address.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset controlling the phone-number shape.area_code:str | null; DefaultNone— Optional area code forced into the generated number.is_mobile:bool; DefaultFalse— Optional flag selecting a mobile rather than general number pattern.
PlanCodeGenerator¶
Generate deterministic plan codes with configurable prefix and length.
Why: Use PlanCodeGenerator for compact catalogue keys whose business prefix identifies a plan family; use PrefixedIdGenerator when the body must follow a non-numeric pattern.
Category: insurance.
Output: str.
1 | |
Parameters¶
prefix:str | None; DefaultNone— Business prefix placed before the numeric plan-code body.digits:int; Default6— Fixed number of digits in the generated body.
PolicyNumberGenerator¶
Generate policy numbers with alphabetic and numeric sections.
Why: Use PolicyNumberGenerator for insurance policy identifiers with recognisable prefix, letter, and digit sections; use PrefixedIdGenerator when a regex-like body is the real contract.
Category: insurance.
Output: str.
1 | |
Parameters¶
prefix:str; DefaultPOL— Fixed business prefix at the start of each policy number.alpha:int; Default3— Number of uppercase letters generated after the prefix.digits:int; Default8— Number of digits generated after the alphabetic section.
RoutingNumberGenerator¶
Generate a 9-digit ABA routing number with checksum validation.
Why: Use RoutingNumberGenerator for US banking fixtures that require an ABA-compatible checksum; do not treat the generated value as an identifier of a real institution.
Category: finance.
Output: str.
1 | |
Parameters¶
prefix:str | None; DefaultNone— Optional leading digits retained before the checksum is calculated.
SSNGenerator¶
Generate locale-aware social-security identification numbers through Faker.
Why: Use SSNGenerator for locale-shaped social-security identifiers in synthetic person records; use Hash on a source identifier when stable de-identification is required.
Category: us.
Output: str.
1 | |
Parameters¶
locale:str | null; Defaulten_US— Faker locale selecting the social-security-number provider.
SectorGenerator¶
Generate industry-sector names from a country-specific dataset.
Why: Use SectorGenerator for organization fixtures that need country- or locale-appropriate industry sectors; use a weighted source list when a governed sector taxonomy is authoritative.
Category: organization.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset used when no explicit locale is supplied.locale:str | null; DefaultNone— Optional locale that overrides dataset selection for sector labels.
StreetNameGenerator¶
Generate locale-aware street names from the configured dataset.
Why: Use StreetNameGenerator for standalone locale-aware street labels; use the Address entity when street, city, postcode, region, and contact fields must be coherent.
Category: address.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset that supplies weighted street names.
TaxIdGenerator¶
Generate deterministic, country-flavored tax IDs without external data files.
Why: Use TaxIdGenerator for deterministic country-flavoured tax-ID fixtures when exact national validation is not required; use CPF or CNPJ for their supported Brazilian identifier shapes.
Category: finance.
Output: str.
1 | |
Parameters¶
dataset:str | null; DefaultNone— Country dataset controlling the prefix and numeric shape.
TokenGenerator¶
Generate various types of secure tokens.
Why: Use TokenGenerator for opaque synthetic session, API, or reset-token fixtures with a chosen encoding; never use generated values as production security tokens.
Category: net.
Output: str | bytes.
1 | |
Parameters¶
token_type:str; Defaulthex— Output encoding: hexadecimal, raw bytes, or URL-safe Base64.entropy:int; Default32— Number of random input bytes before encoding.
UrlGenerator¶
Generate locale-aware URLs with optional allowed schemes.
Why: Use UrlGenerator for locale-aware web-address fixtures constrained to allowed schemes; use DomainGenerator when only the host name is required.
Category: net.
Output: str.
1 | |
Parameters¶
locale:str | null; DefaultNone— Faker locale used to generate URL components.schemes:list[str] | null; DefaultNone— Allowed URI schemes; generated values are rewritten to one of these schemes.