Skip to main content

Fake address and IBAN generator for 200+ countries — async-first Python library

Project description

SmartFaker

Fake address & IBAN generator for 200+ countries — async-first Python library

PyPI version Python License

SmartFaker generates realistic fake postal addresses and IBAN numbers for over 200 countries. It is async-first with synchronous wrappers, requires no external API, and ships bundled country data.

Installation

pip install smartfaker

Quick Start

from smartfaker import Faker

faker = Faker()

# Sync usage
addr = faker.address_sync("us")
iban = faker.iban_sync("DE")

print(addr["city"], addr["zip"])
print(iban["iban"])
# Async usage
import asyncio
from smartfaker import Faker

faker = Faker()

async def main():
    addr = await faker.address("gb")
    iban = await faker.iban("FR")
    print(addr, iban["iban"])

asyncio.run(main())

Features

  • 200+ countries — bundled JSON address data for every country and territory
  • IBAN generation — 57 countries with country-specific algorithms and MOD-97 validation
  • Async-first — all generation methods are async; sync wrappers included
  • Field filtering — request only the fields you need
  • Batch generation — generate addresses for multiple countries in one call
  • Zero external dependencies beyond pycountry

API

Address generation

# Single address
addr = faker.address_sync("us")

# Multiple addresses
addrs = faker.address_sync("fr", amount=5)

# Specific fields only
addr = faker.address_sync("de", fields=["city", "zip", "street"])

# Batch — multiple countries
import asyncio
results = asyncio.run(faker.batch_addresses(["us", "gb", "de"]))

IBAN generation

# Single IBAN
iban = faker.iban_sync("DE")
print(iban["iban"])     # DE...
print(iban["details"])  # {"bank_code": ..., "account_number": ...}

# Multiple IBANs
ibans = faker.iban_sync("GB", amount=3)

# List supported countries
for c in faker.iban_countries():
    print(c["country_code"], c["country_name"])

License

LGPL-3.0-or-later © ISmartCoder | t.me/TheSmartDev

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

smartfaker-3.25.2.tar.gz (189.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

smartfaker-3.25.2-py3-none-any.whl (246.8 kB view details)

Uploaded Python 3

File details

Details for the file smartfaker-3.25.2.tar.gz.

File metadata

  • Download URL: smartfaker-3.25.2.tar.gz
  • Upload date:
  • Size: 189.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for smartfaker-3.25.2.tar.gz
Algorithm Hash digest
SHA256 d43f5691b79064d20f4a765435136ed1bfe7a52ce35bc3944199d450494d5c59
MD5 106f2aa06ecef96bfadb2d7d1b3a1df8
BLAKE2b-256 4215ca9c9fcba5050c58470e5f2915d4a3a4949c5f168ef6e5da85323ceb4f96

See more details on using hashes here.

File details

Details for the file smartfaker-3.25.2-py3-none-any.whl.

File metadata

  • Download URL: smartfaker-3.25.2-py3-none-any.whl
  • Upload date:
  • Size: 246.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for smartfaker-3.25.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ceb15116acb181e4e4ef3122eb3a2d9a8da7a455a46666d2957d9f68ba170c9c
MD5 99d1eb5ab6343efcb529f2c99086f426
BLAKE2b-256 65326050668ce3dfa9aebfa7bdee80fbceffd9a42f10dc6f9b7f48c55c8557ce

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page