@sampuli/data 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +51 -10
  2. package/dist/cli.js +13148 -0
  3. package/package.json +4 -1
package/README.md CHANGED
@@ -1,25 +1,66 @@
1
1
  # @sampuli/data
2
2
 
3
- **Format-true synthetic test data for countries worldwide.** National IDs, tax
4
- numbers, IBANs & SWIFT/BIC, bank accounts, phone numbers and ready-made KYC /
5
- transfer / payment scenarios — each in the correct format for its own country,
6
- generated on the spot.
3
+ [![npm version](https://img.shields.io/npm/v/@sampuli/data.svg)](https://www.npmjs.com/package/@sampuli/data)
4
+ [![downloads](https://img.shields.io/npm/dm/@sampuli/data.svg)](https://www.npmjs.com/package/@sampuli/data)
5
+ [![CI](https://github.com/kevinbett/sampuli/actions/workflows/ci.yml/badge.svg)](https://github.com/kevinbett/sampuli/actions/workflows/ci.yml)
6
+ [![license](https://img.shields.io/npm/l/@sampuli/data.svg)](./README.md)
7
+ [![zero deps](https://img.shields.io/badge/dependencies-0-brightgreen.svg)](#)
8
+
9
+ > **Synthetic test data that passes your own validators — 90 countries.**
10
+
11
+ Most fake-data tools give you `John Doe` and a random 16-digit number. `@sampuli/data`
12
+ gives you a **KRA PIN that passes a KRA validator**, a **real bank's SWIFT/BIC**, a
13
+ **valid IBAN** (mod-97), an **ICAO-9303 passport MRZ**, a **Luhn-valid card** — each
14
+ one shaped to its country's actual rules (checksums, prefixes, bank codes). Entirely
15
+ synthetic; corresponds to no real person or account.
16
+
17
+ ```bash
18
+ npm install @sampuli/data
19
+ ```
20
+
21
+ **▶ Try it in your browser, no install:** [sampuli.site](https://sampuli.site) · or in your terminal: `npx @sampuli/data ke.person`
22
+
23
+ ## Why not faker / Mockaroo?
24
+
25
+ | | faker.js | Mockaroo | **@sampuli/data** |
26
+ |---|:---:|:---:|:---:|
27
+ | Country-specific ID / tax formats | ✗ | partial | **✓ 90 countries** |
28
+ | Checksum-valid (Luhn, mod-97, mod-11…) | ✗ | ✗ | **✓** |
29
+ | Real bank names + SWIFT/BIC | ✗ | ✗ | **✓** |
30
+ | Valid IBANs, CLABE, NUBAN… | ✗ | ✗ | **✓** |
31
+ | Passport MRZ (ICAO-9303) | ✗ | ✗ | **✓** |
32
+ | Coherent records (bank↔SWIFT, gender↔name) | partial | ✗ | **✓** |
33
+ | Reproducible seeds · zero deps · free | ✓ | – | **✓** |
34
+
35
+ Built for **QA and CI at banks and fintechs** — test data that *passes your own
36
+ format validation*, so you can exercise KYC, onboarding and payment flows without
37
+ touching real PII.
38
+
39
+ <details><summary>Older intro / disclaimer</summary>
7
40
 
8
41
  One API, dozens of countries: Kenyan KRA PINs & M-Pesa numbers, Nigerian BVNs,
9
42
  German & Gulf IBANs, Italian Codice Fiscale, Brazilian CPF/CNPJ, Mexican CLABE,
10
- Turkish TCKN, Singapore NRIC — and many more, each shaped to its national rules
11
- (checksums, prefixes, bank codes).
43
+ Turkish TCKN, Singapore NRIC — and many more.
12
44
 
13
45
  > **Every value is entirely synthetic.** It matches the real *format* only and
14
46
  > corresponds to no real person, account, or registered number. Never present
15
47
  > any output as a genuine ID, tax number, IBAN, or bank account.
16
48
 
17
- Built for QA and CI at banks and fintechs anywhere — test data that *passes
18
- your own format validation*. Free, no volume caps.
19
- The engine behind [Sampuli](https://sampuli.site).
49
+ </details>
50
+
51
+ ## From the terminal (CLI)
52
+
53
+ No code needed — try it with `npx`:
20
54
 
21
55
  ```bash
22
- npm install @sampuli/data
56
+ npx @sampuli/data ke.person # one Kenyan record (JSON)
57
+ npx @sampuli/data ke.kra_pin # a single value
58
+ npx @sampuli/data ng.person -n 100 # 100 records
59
+ npx @sampuli/data de.person -f name,account,card,passport_mrz
60
+ npx @sampuli/data ke.person -n 500 --csv # CSV to stdout
61
+ npx @sampuli/data ke.preset:kyc # a KYC scenario
62
+ npx @sampuli/data --list # list all 90 country codes
63
+ npx @sampuli/data --list ke # a country's fields & presets
23
64
  ```
24
65
 
25
66
  ## Quick start