/turing-api

Rest Api for Turing Shop Challenge

Primary LanguageJavaScript

Turing API

Build Status

Setup

Install

git clone https://github.com/reiosantos/turing-api.git

cd turing-api

Set the environment variables needed to run the application, A sample .env.sample file contains all the variables that should be defined.

These variables must be set before starting the app:

STRIPE_SECRET_KEY
MAILGUN_API_KEY
MAILGUN_DOMAIN

Prepare and run on development without docker

npm install
npm run start:dev

start the api using docker

docker build -t turing-api .
docker run -p 5000:5000 -e STRIPE_SECRET_KEY=somekey -e MAILGUN_API_KEY=getthisfrommailgun -e MAILGUN_DOMAIN=anotheronefrommailgun turing-api

or using the env file

docker run -p 5000:5000 --env-file .env turing-api

Access the api on

http://localhost:5000/api

The API Documentation can be found at http://localhost:5000/api/docs