Skip to content

This is an application used for voting for ideas by it's users, created with Node.js, Typescript and AWS Lambda

Notifications You must be signed in to change notification settings

godwintrav/Idea-Voting-App-AWS-Lambda

Repository files navigation

Running this project locally

A lot of this project can be run locally using serverless-offline and a local dynamo DB instance.

Install Dependencies

Run npm i npm i -g serverless

Dynamo Setup

  • ensure you have java engine installed on your machine Get it here
  • run sls dynamodb install

Running everything locally

To start the local API you just need to run npm run offline.

Testing

To test the get endpoint you can do a get request to this url

http://localhost:3000/dev/flights?origin=Saint%20Petersburg&destination=Bucharest&fromDate=1630073644000&toDate=1630073645000

to test the post flight you can post to

http://localhost:3000/dev/flights/b335c8cd-c9bd-4a21-8898-e1a885e2aec6 with the following body

{
    "passengers": [
        {"name": "test passenger"}
    ]
}

You can then retry the existing get request

About

This is an application used for voting for ideas by it's users, created with Node.js, Typescript and AWS Lambda

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published