Skip to content

leoddc/porch-mock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mock Endpoint

This is a mock endpoint which responds with a list of n fake addresses in the form:

[
{
    "firstName":"Dixie",
    "lastName":"Huels",
    "donatingFood":true,
    "donatingMoney":true,
    "location":
        {
            "lat":47.6914,
            "lon":175.4313
        }
}
...
]

To use the endpoint:

  1. clone this repository
  2. run npm install to install dependencies
  3. specify the number of donors you want to get using the numberOfFakes const
  4. specify the error rate (.0 for no errors, 1.1 for error every time, .5 for 50/50, etc) using errorChance const
  5. run npm start to run the API locally
  6. Make requests to http://localhost:3000/donor-list

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published