- Table of Contents
- About The Project
- Getting Started
- Testing
- API Documentation
- Functional Documentation
- Roadmap
- Contributing
- License
- Contributers
Ketofan is a digital healthcare booking platform. We aim to automate physician, clinic and hospital bookings making healthcare easily accessible. Patients are able to search, compare, and book the best doctors in just 1 minute. Doctors also provide Patients with seamless healthcare experiences.
KETOFAN API
KETOFAN WEBSITE
KETOFAN FRONTEND
This is an example of how you may give instructions on setting up your project locally. To get a local copy up and running follow these simple example steps.
- Clone the repo
git clone https://github.com/fuboki10/Ketofan-Back-End.git
- Install dependencies (it will create the database automatically)
npm install
For developers, you can directly use our development.json
located in config\development.json
or modify it if you like.
For production, you need to make your own config\production.json
with the following structure.
{
"JWT_KEY": "foo",
"JWT_EXPIRES_IN": "30d",
"NODE_ENV": "production",
"DB": "postgres://<user>:<password>@<host>:<port>/ketofan",
"PORT": "3000",
"SENDGRID_API_KEY": "SG."
}
JWT_KEY
: Your json web token secret key.JWT_EXPIRES_IN
: The period token can last before expiring expressed in seconds or a string describing a time spanEg:
60
,"2 days"
,"10h"
,"7d"
. A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default ("120"
is equal to"120ms"
).DB
: Your database pathEg:
"postgres://<user>:<password>@localhost:<port>/ketofan"
If you're hosting on your localhost server.PORT
: Your api hosting portNODE_ENV
: It must be"production"
in order to run the api on production otherwise useconfig\development.json
SENDGRID_API_KEY
: SENDGRID api key to send emails
- Running on development
npm run dev
- Running on production
Upon creating config\production.json
like in Environmental Variables section. run this script:
npm run build
npm start
- Migration
npm run migrate
- Seeds
npm run seed
- Roll back migration
npm run unmigrate
- Create Database
npm run db:create
The tests can be found in tests
, and each controller has its own test file in tests\unit\controller
. Mongoose models tests are also found in tests\unit\models
as well as middleware which is located at tests\unit\middlewares
.
run the following script:
npm test
https://documenter.getpostman.com/view/10395649/TzXtJLpG
install the latest version on npm globally (might require sudo
if you are on linux):
npm install -g jsdoc
in order to generate the documentation, run the jsdoc
command:
jsdoc -r ./src
By default, the generated documentation is saved in a directory named out
. You
can use the --destination
(-d
) option to specify another directory.
See the open issues for a list of proposed features (and known issues).
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b AmazingFeature-Feat
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin AmazingFeature-Feat
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Abdelrahman Tarek |
Abdelrahman Arafat |
Hassan Mohamed |
Ahmed Walid |