Skip to content

apifortress/apif-faker

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Apif Faker

This library based on java faker provides several methods to generate fake data

List of Methods

Addresses and Countries

  • streetName(): provides random street name
  • streetAddressNumber(): provides random address number
  • streetAddress(): provides random street and address number. If secondary specifided provides apt number.
  • secondaryAddress(): provides random apt number
  • zipCode(): provides random zip code. If state provided provides proper zip code for the state **(valid only for US states)
  • streetSuffix(): provides random street suffix
  • streetPrefix(): provides random street prefix
  • citySuffix(): provides random city suffix
  • cityPrefix(): provides random city prefix
  • city(): provides random city Name
  • cityName(): provides random city Name
  • state(): provides random state/province
  • buildingNumber(): provides random build number
  • fullAddress(): provides random full adress
  • country(): provides random country
  • countryCode(): provides random country code
  • countryCodeSL(): provides random country code in small letters
  • countryCodeSL3d(): provides random country code in small letters on 3 digits
  • capital(): provides random capital city

People and People identity

  • fullName(): provides random full name
  • firstName(): provides random first name
  • lastName(): provides random last name
  • profession(): provides random profession
  • timeZone(): provides random time zone
  • validID(): provides random valid ID
  • invalidID(): provides random invalid ID
  • validSSN(): provides random valid SSN
  • invalidSSN(): provides random invalid SSN
  • phone(): provides random phone number
  • mobile(): provides random mobile number

Internet

  • emailAddress(): provides random email address
  • domainName(): provides random domain name
  • domainWord(): provides random word
  • domainSuffix(): provides random suffix
  • url(): provides random url
  • password(<minimumLength,maximumLength,includeUppercase,includeSpecial,includeDigit>): provides random password

Credit Card

  • creditCardNumber(): provides random credit card number
  • creditCardExpiry(): provides random credit card expire date
  • creditCardType(): provides random credit card type

Products

  • productName(): provides random product name
  • material(): provides random material
  • price(): provides random price
  • promotionCode(): provides random promotion code

Companies

  • companyName(): provides random company name
  • suffix(): provides random company suffix
  • industry(): provides random industry

Currency

  • currency(): provides random currency
  • currencyCode(): provides random currency code

Random Numbers

  • integer(<min,max>): provides random integer number
  • decimal(<min,max,maxdecimals>): provides random decimal number
  • uuid(): provides random unique identifier

Boolean

  • bool(): provides random boolean value

Collection/single Data

  • collection(<number_of_elements,"method">):
    • provides a list of elements generated by "method".
    • The single element is a simple string.
    • The size of the list is equal to the number_of_elements
  • collection(<number of elements,["method1","method2",...,"methodN2]>):
    • provides a list of elements generated by the list of methods provided.
    • The single element is a list.
    • The size of the list is equal to the number_of_elements
  • collection(<number of elements,[method1: 'method1',method2:'method2',...,methodN:'methodN'>):
    • provides a list of elements generated by the list of methods provided.
    • The single element is a map.
    • The size of the list is equal to the number_of_elements
  • single(<"method">):
    • provides an element generated by "method".
    • The element is a simple string.
  • single(<["method1","method2",...,"methodN2]>):
    • provides an element generated by the list of methods provided.
    • The element is a list.
  • single(<[method1: 'method1',method2:'method2',...,methodN:'methodN'>):
    • provides an element generated by the list of methods provided.
    • The single element is a map

Packages

No packages published

Languages

  • Java 91.0%
  • Groovy 9.0%