npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

uyduruk

v0.1.0

Published

Turkish mock data generator — Türkçe sahte veri üretici

Readme

uyduruk

Türkçe sahte veri üretici — Turkish mock/fake data generator.

Gerçekçi Türkçe test verisi: isim, adres, TC kimlik no, IBAN, VKN, kredi kartı, plaka, şirket, tarih ve daha fazlası. Seed'lenebilir (deterministik), sıfır bağımlılık, tree-shakeable, ~40 KB gzip (çekirdek).

npm version license

Canlı demo → alan seç, kayıt üret, JSON/CSV/SQL/TypeScript olarak indir.

Bu README hem Türkçe hem İngilizce. / This README is bilingual — jump to English.


Türkçe

Kurulum

npm install uyduruk
# veya: pnpm add uyduruk / yarn add uyduruk

Node.js ≥18, ESM ve CJS ikisi de destekleniyor.

Hızlı başlangıç

import { Uyduruk } from "uyduruk";

const uyduruk = new Uyduruk({ seed: 42 }); // seed opsiyonel — verilmezse rastgele

uyduruk.person.fullName(); // "Özcan Üstün"
uyduruk.location.fullAddress(); // "Nurgül Sokak No:32 Daire 21, Felahiye/Kayseri 38750"
uyduruk.identity.tcKimlikNo(); // "23252928182" — algoritmik olarak geçerli
uyduruk.identity.iban(); // "TR030001201257095669698013"
uyduruk.finance.creditCard(); // { number, scheme, bank, expiryMonth, expiryYear, cvv }

Seed vermezseniz her çalıştırmada farklı veri üretilir. Aynı seed, aynı sürümde her zaman aynı çıktıyı verir (bkz. Seed determinizmi).

dataset() ile toplu üretim

Alan adı → üretici eşlemesiyle tek çağrıda kayıt dizisi üretir (demo sitenin de kullandığı yol):

const kayitlar = uyduruk.dataset(100, {
  id: "index",
  ad: "person.fullName",
  eposta: "contact.email",
  sehir: "location.cityName",
  tc: "identity.tcKimlikNo",
  kayitTarihi: "datetime.past",
});
// [{ id: 1, ad: "Ali Kurt", eposta: "[email protected]", sehir: "Kayseri",
//    tc: "97633119346", kayitTarihi: 2025-10-19T07:00:27.998Z }, ...]

Geçersiz bir path ("person.foo" gibi) hem derleme zamanında (TypeScript GeneratorPath tipiyle) hem çalışma zamanında hata verir — sessiz fallback yok.

API özeti

Tüm API isimleri İngilizce, üretilen veri Türkçe.

| Modül | Örnek metodlar | |---|---| | person | firstName(), lastName(), fullName(), gender(), title(), jobTitle(), birthDate(), age(), maritalStatus(), bloodType(), profile() | | location | city(), cityName(), district(), region(), street(), postalCode(), plateCode(), areaCode(), coordinates(), fullAddress() | | contact | phoneMobile(), phoneLandline(), email(), username(), website() | | identity | tcKimlikNo(), iban(), vkn(), passportNumber() (+ validateTcKimlikNo, validateIban, validateVkn) | | company | name(), sector(), department(), slogan(), taxOffice() | | finance | price(), priceFormatted(), bankName(), creditCard(), creditCardNumber(), accountNumber() | | vehicle | plate(), brand(), model(), year(), color() | | datetime | past(), future(), recent(), weekday(), month(), formatted() | | text | word(), sentence(), paragraph(), slug() |

location.district(), location.postalCode(), location.plateCode(), contact.phoneLandline(), company.taxOffice(), vehicle.plate() gibi metodlar opsiyonel bir cityName parametresi alır — verilirse il/ilçe/posta kodu/plaka/alan kodu birbiriyle tutarlı üretilir (rastgele il + rastgele ilçe eşleştirmesi yapılmaz).

Bilinmeyen bir il/ilçe/banka/marka adı verilirse (location.district("Olmayanşehir") gibi) sessizce rastgele bir değere düşülmez, UyduruExtError fırlatılır.

uyduruk/mahalle alt paketi

Mahalle (32.142) ve köy (18.162) verisi tek başına ~350 KB gzip olduğu için çekirdek pakete dahil değil — import { mahalle } from "uyduruk" yazsanız bile bu veri bundle'ınıza girmez, ayrı bir subpath'ten opt-in:

import { mahalle } from "uyduruk/mahalle";

mahalle.neighborhood("İstanbul", "Kadıköy"); // { name: "Hasanpaşa", postalCode: "34722" }
mahalle.village("Sivas", "Zara"); // { name: "Sorkun", postalCode: "58702" }

MahalleModule da { seed } alır ve kendi seed() metoduna sahiptir — ana Uyduruk örneğinden bağımsız, ayrı bir rastgelelik akışı.

Doğrulayıcılar

Üreticilerin kullandığı algoritmalar ayrıca dışa açık:

import { validateTcKimlikNo, validateIban, validateVkn, validateLuhn } from "uyduruk";

validateTcKimlikNo("90909090904"); // true

Seed determinizmi ve sürüm politikası

  • Aynı seed minor sürümler içinde aynı çıktıyı üretir.
  • Veri dosyalarına ekleme/çıkarma (yeni isim, yeni şirket adı vb.) minor sürüm gerektirir ve CHANGELOG'da "seed output changed" başlığıyla belirtilir — patch sürümlerde seed çıktısı asla değişmez.
  • Seed'lenmiş çıktıyı snapshot testi olarak saklıyorsanız sürümü sabitleyin: "uyduruk": "1.2.3" (caret/tilde kullanmayın).

Veri kaynakları

| Veri | Kaynak | Lisans | |---|---|---| | İl / ilçe / mahalle / köy / posta kodu | turkiye-api (Ubeyde Emir Özdemir) | MIT | | Kredi kartı BIN önekleri | Kredi-Kart-Bin-Listesi (SqlHareketi) | MIT | | VKN üretim algoritması | vkn-tckn-generator (fakarsu1) — sadece algoritma, veri değil | MIT | | Ad / soyad listeleri | Proje sahibi tarafından hazırlanmış özgün liste | Ayrı bir lisans kaynağı yok |

TC kimlik no ve IBAN algoritmaları kamuya açık resmi kontrol basamağı formüllerinden (mod 11 / mod 10, ISO 7064 mod 97-10) uygulanmıştır, üçüncü taraf veri kaynağı kullanılmamıştır.

⚠️ Uyarılar

  • Kriptografik amaçla kullanmayın. Üretecin çekirdeğinde Math.random() tabanlı bir PRNG (mulberry32) var — güvenlik tokenı, şifre, oturum anahtarı vb. üretmek için uygun değildir.
  • Üretilen TC kimlik no, IBAN, VKN ve kredi kartı numaraları gerçek hiçbir kişiye, hesaba veya işletmeye karşılık gelmez. Sadece algoritmik olarak geçerli (kontrol basamağı doğru) test verisidir — gerçek kayıtlarla eşleşme tamamen tesadüfidir.

Demo site

denizayhan04.github.io/uyduruk — alan seçin, kayıt sayısı ve seed belirleyin, JSON/JSON Lines/CSV/SQL INSERT/TypeScript arayüzü olarak dışa aktarın; "Kod olarak" sekmesi aynı sonucu üreten uyduruk kodunu gösterir.

Geliştirme (monorepo)

pnpm install
pnpm --filter uyduruk build       # paket
pnpm --filter uyduruk test        # 264 test
pnpm --filter uyduruk-site dev    # demo site (paketi workspace üzerinden import eder)

Lisans

MIT


English

Realistic Turkish mock data: names, addresses, national ID numbers (TC Kimlik No), IBAN, tax numbers (VKN), credit cards, license plates, companies, dates and more. Seedable (deterministic), zero dependencies, tree-shakeable, ~40 KB gzip (core).

Install

npm install uyduruk

Node.js ≥18, both ESM and CJS supported.

Quick start

import { Uyduruk } from "uyduruk";

const uyduruk = new Uyduruk({ seed: 42 }); // optional — omit for random data

uyduruk.person.fullName(); // "Özcan Üstün"
uyduruk.location.fullAddress(); // "Nurgül Sokak No:32 Daire 21, Felahiye/Kayseri 38750"
uyduruk.identity.tcKimlikNo(); // "23252928182" — algorithmically valid
uyduruk.identity.iban(); // "TR030001201257095669698013"

Bulk generation with dataset()

const rows = uyduruk.dataset(100, {
  id: "index",
  name: "person.fullName",
  email: "contact.email",
  city: "location.cityName",
  nationalId: "identity.tcKimlikNo",
  createdAt: "datetime.past",
});
// [{ id: 1, name: "Ali Kurt", email: "[email protected]", city: "Kayseri",
//    nationalId: "97633119346", createdAt: 2025-10-19T07:00:27.998Z }, ...]

Invalid paths are rejected both at compile time (via the GeneratorPath type) and at runtime — no silent fallback.

API overview

| Module | Sample methods | |---|---| | person | firstName(), lastName(), fullName(), gender(), title(), jobTitle(), birthDate(), age(), maritalStatus(), bloodType(), profile() | | location | city(), cityName(), district(), region(), street(), postalCode(), plateCode(), areaCode(), coordinates(), fullAddress() | | contact | phoneMobile(), phoneLandline(), email(), username(), website() | | identity | tcKimlikNo(), iban(), vkn(), passportNumber() (+ validateTcKimlikNo, validateIban, validateVkn) | | company | name(), sector(), department(), slogan(), taxOffice() | | finance | price(), priceFormatted(), bankName(), creditCard(), creditCardNumber(), accountNumber() | | vehicle | plate(), brand(), model(), year(), color() | | datetime | past(), future(), recent(), weekday(), month(), formatted() | | text | word(), sentence(), paragraph(), slug() |

Methods like location.district(), location.postalCode(), location.plateCode(), company.taxOffice(), vehicle.plate() accept an optional cityName — when given, the city/district/postal code/plate/area code stay consistent with each other (never a random city paired with a random district).

An unknown city/district/bank/brand name throws UyduruExtError instead of silently falling back to a random value.

uyduruk/mahalle subpath

Neighborhood (32,142) and village (18,162) data is ~350 KB gzip on its own, so it's excluded from the core bundle entirely — importing uyduruk never pulls it in, even if you also import the subpath elsewhere:

import { mahalle } from "uyduruk/mahalle";

mahalle.neighborhood("İstanbul", "Kadıköy"); // { name: "Hasanpaşa", postalCode: "34722" }
mahalle.village("Sivas", "Zara"); // { name: "Sorkun", postalCode: "58702" }

Seed determinism & versioning policy

  • The same seed produces the same output within a minor version.
  • Adding/removing data (a new name, a new company name, etc.) requires a minor version bump, called out in the CHANGELOG under "seed output changed" — patch releases never change seeded output.
  • If you store seeded output as snapshot-test fixtures, pin the exact version: "uyduruk": "1.2.3" (no caret/tilde).

Data sources

| Data | Source | License | |---|---|---| | Provinces / districts / neighborhoods / villages / postal codes | turkiye-api (Ubeyde Emir Özdemir) | MIT | | Credit card BIN prefixes | Kredi-Kart-Bin-Listesi (SqlHareketi) | MIT | | VKN generation algorithm | vkn-tckn-generator (fakarsu1) — algorithm only, no data used | MIT | | First/last name lists | Original list authored by the project owner | No separate license |

The TC Kimlik No and IBAN algorithms are implemented from publicly documented official checksum formulas (mod 11 / mod 10, ISO 7064 mod 97-10) — no third-party data source was used for either.

⚠️ Warnings

  • Do not use this for cryptographic purposes. The generator's core is a Math.random()-seeded PRNG (mulberry32) — it is not suitable for security tokens, passwords, session keys, or anything security-sensitive.
  • Generated national IDs, IBANs, tax numbers, and credit card numbers do not correspond to any real person, account, or business. They are algorithmically valid (correct checksum) test data only — any resemblance to real records is coincidental.

Live demo

denizayhan04.github.io/uyduruk — pick fields, set record count and seed, export as JSON/JSON Lines/CSV/SQL INSERT/TypeScript interface; the "As code" tab shows the uyduruk code that reproduces the same result.

License

MIT