Skip to main content

License

Random-Text

A Random Object Generator for Addresses, Names, Reviews, Testimonials, Business Names, and Random Objects.

Sources

Description Type Link
Random Data Website General Click
Randommer Data Website General Click
Random Geek Jokes Jokes Click
Evil Insult Generator Jokes Click
Dad Jokes Jokes Click
Shibe Generator Images Click
Testimonial Generator Text Click
Text Generator Text Click
Faker Images/General Click

To use the Randommer API you will require a API Key. To create one is free. Follow link to website and register as a user and you will find API Key in your "account" section. Don't forget to pass in the API key to the RandomTextClient if you want to use the second generator.

Requirements

  • Python >= 3.6

Getting started

pip install random-text

random-text is simple to use -- take a look at the below example:

from randomText import RandomTextClient

client = RandomTextClient(api_key='api_key')

Available methods:

Basic Usage (No Api Key Required)

df = client.address.get_random(size=1)
print(df.head(2))

Advanced Usage - Requires API Key when creating the client.

business_name = client.fancy_random.generate_business_name(size=2)
brand_name = client.fancy_random.generate_brand_name(starting_word='funny')
product_reviews = client.fancy_random.generate_product_reviews(size=2, product='toy')

Available Methods

Module Example Output
Address client.address.get_random(size=5) df of addresses
Appliances client.appliance.get_random(size=5) df of appliances
Apps client.app.get_random(size=5) df of apps
Banks client.bank.get_random(size=5) df of banks :bank:
Beers client.beer.get_random(size=5) df of beers :beers:
Blood client.blood.get_random(size=5) df of blood types
Credit Cards client.business_credit_card.get_random(size=5) df of credit card numbers :credit_card:
Cannabis client.cannabis.get_random(size=5) df of cannabis data
Code client.code.get_random(size=5) df of code
Coffee client.coffee.get_random(size=5) df of coffee :coffee:
Commerce client.commerce.get_random(size=5) df of products
Company client.company.get_random(size=5) df of company data
Computer client.computer.get_random(size=5) df of operating systems
Crypto client.crypto.get_random(size=5) df of Crypto hashes
Crypto Coin client.crypto_coin.get_random(size=5) df of crypto coins
Color client.color.get_random(size=5) df of colors
Dessert client.dessert.get_random(size=5) df of desserts
Devices client.device.get_random(size=5) df of phones :iphone:
Food client.food.get_random(size=5) df of foods
Names client.name.get_random(size=5) df of full names :name_badge:
Hipster client.hipster.get_random(size=5) df of hipster text
Invoice client.invoice.get_random(size=5) df of invoice data
User client.user.get_random(size=5) df of user data
Stripe client.stripe.get_random(size=5) df of stripe financial data
Subscription client.subscription.get_random(size=5) df of subscriptions
Vehicle client.vehicle.get_random(size=5) df of vehicles :car:
Id_Number client.id_number.get_random(size=5) df of id numbers - Including SSN
Internet Stuff client.internet_stuff.get_random(size=5) df of logins and browser info
Lorem Ipsum client.lorem_ipsum.get_random(size=5) df of fake text for website
Lorem Pixel client.lorem_pixel.get_random(size=5) df of fake image data
Lorem Flickr client.lorem_flickr.get_random(size=5) df of fake image from flickr
Nation client.nation.get_random(size=5) df of nations
Number client.number.get_random(size=5) df of numbers
Phone Number client.phone_number.get_random(size=5) df of Phone Numbers :telephone:
Place Hold It client.placeholdit.get_random(size=5) df of placeholder images
Restaurant client.restaurant.get_random(size=5) df of restaurants
Fancy Random client.fancy_random.generate_business_name(size=5) df of fake business Names
Fancy Random client.fancy_random.generate_brand_name(starting_word='funny') df of brand names
Fancy Random client.fancy_random.generate_product_reviews(size=2, product='toy') df of product reviews
Geek Jokes client.geek.get_joke() df of geek jokes
Evil Insults client.evil.generate_insult() df of insults
Dad Jokes client.dad.get_dad_joke() df of dad jokes
Dad Jokes client.dad.search_dad_jokes(page=1, limit=2, term='cat') df of found dad jokes
Shibe client.shibe.generate_images(size=1) df of shibe images
Testimonials client.testimonial.generate_random() df of Testimonials
Meta client.meta.get_paragraphs(size=2) df of paragraphs
Meta client.meta.get_sentences(size=2) df of sentences
Meta client.meta.get_doc(paragraph_size=5, sentence_size=2) df of paragraphs and sentences
Faker client.faker.get_addresses(self, size=1, country='en_US') df of addresses
Faker client.faker.get_books(self, size=1, country='en_US') df of books
Faker get_companies(self, size=1, country='en_US') df of companies
Faker get_credit_cards(self, size=1, country='en_US') df of cc
Faker get_places(self, size=1, country='en_US') df of longitude and latitude of places
Faker get_users(self, size=1, country='en_US') df of users
Faker get_texts(self, size=1, characters=350, country='en_US') df of text
Faker get_products(self, size=1, price_min=0.01, price_max=10.35, taxes=25, categories_type='', country='en_US') df of products by category
Faker get_persons(self, size=1, gender='male', birthday_start='1991-01-01', birthday_end='2022-01-01', country='en_US') df of people
Faker get_images(self, size=1, type='any', width='640', height='480', country='en_US') df of images

TO DO

  1. Add as many random open api's from the web. Based off https://github.com/public-apis/public-apis

Tests

To run tests:

python -m unittest discover -p *test.py

Disclaimer

  1. This library depends on the source API's still working as intended. If they change or pull their resources the code will no longer work as none of the logic is done in this library but pulled from around the web.

Metadata

Release files for random-text 1.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for random-text 1.8.0
File Size Uploaded
random-text-1.8.0.tar.gz 11.3 kB Details

Release files / random-text-1.8.0.tar.gz

Download URL random-text-1.8.0.tar.gz
Size 11.3 kB
Tags Source
SHA-256 checksum
How to use checksums
5d037d805cb7a714379dd69d26d21c24836cfd93b6a4fe456dabe1a3a4474721
BLAKE2b-256 checksum
How to use checksums
b158296a83d218d66ba324171a5b423f77aea559e2c4c3edb6f53635e7c039df
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.8.0

Release history Release notifications | RSS feed

This release

1.8.0 This release

1 release file

1.7.0

1 release file

1.6.0

1 release file

1.5.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page