Skip to main content

Finding available domain names

Project description

brand

Finding available domain names

To install: pip install brand

How to use

Example script

search_names.py shows an example of how to assemble brand functionalities to write a script that will search names of the form CVCVCV (C for consonant, V for vowel) with no more than 4 unique letters and where either the consonants or the vowels are all the same.

...
(10)12:49:07 - 2255: nesebe
(10)12:49:08 - 2256: nesede
(10)12:49:09 - 2257: nesefe
---> Found available name: nesefe
(10)12:49:09 - 2258: nesege
---> Found available name: nesege
(10)12:49:09 - 2259: nesele
---> Found available name: nesele
(10)12:49:11 - 2260: neseme
---> Found available name: neseme
(10)12:49:11 - 2261: nesene

The functions available to you

name_is_available

name_is_available checks if a name is available using the system's whois command.

from brand import name_is_available
assert name_is_available('google.com') is False
assert name_is_available('asdfaksdjhfsd2384udifyiwue.org') is True

The store

First, you'll need to provide a "store". That is, a dict-like object that will hold the names you've checked so far, under keys available_names.p and not_available.p (which contains the names that were checked, but not available).

The functions use this both to not check what you've already checked, and to store its results as they check names.

A store can be an actual dict, or a dict-like interface to files or a DB.

We advise to use py2store (which is installed with brand) to make dict-like interfaces to your storage system of choice.

When you ask brand to make a store with no further specifications, it makes a directory and places files in there for you.

import brand
s = brand.get_store()

Now you can use that store to see what's already available from past work (if anything).

available = brand.available_names(s)
not_available = brand.not_available_names(s)
len(available), len(not_available)

process_names

process_names will take some names (specified as an iterable, generator function, or pickle file) and check if each is available, saving the results in the given store.

try_these = ['google.com', 'gaggle.com', 'giggle.org', 'asdfiou3t.org']
process_names(try_these)

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

brand-0.0.4.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

brand-0.0.4-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file brand-0.0.4.tar.gz.

File metadata

  • Download URL: brand-0.0.4.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for brand-0.0.4.tar.gz
Algorithm Hash digest
SHA256 75aaa5bbb185ce45a5324c692326b63bd498414edde093a23526f301bbab8b26
MD5 f983f770712b74f5fc5323092c203336
BLAKE2b-256 6ae16144c37c6231a3f744223c89c6b0816105219be6235458e01ac9e48458b2

See more details on using hashes here.

File details

Details for the file brand-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: brand-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.6

File hashes

Hashes for brand-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 1102c9ae79fd2d02bd136c796f267d3bf495bd18f3f70d4f010037d9a6d4eb95
MD5 cf194496cddfe76ed794264800ce76b8
BLAKE2b-256 fc4ea0b2c2e338a401d0f651dc1fc2216e47f6001f0632e9e5348f8336947698

See more details on using hashes here.

Supported by

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