Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jornatf/mongodb-node-api

A Starter Node.js API skeleton with MongoDB.
https://github.com/jornatf/mongodb-node-api

api api-rest babel babel-preset design-pattern framework javascript js mongo mongodb mongoose mongoosejs node nodejs nodemon template template-project

Last synced: 27 days ago
JSON representation

A Starter Node.js API skeleton with MongoDB.

Awesome Lists containing this project

README

        

# mongodb-node-api

**A Starter Node.js API skeleton with MongoDB.**

## Setup

### Installation

1. First, click on the **"Use this template"** button.
2. Install all npm packages with the command:

```bash
$ npm install
```

### Environment

You can type command:

```bash
$ cp .env.example .env
```

or manually create a `.env` file to the project root and copy/paste this default variables:

```
PORT=3000
MONGODB_NAME=test
MONGODB_URI="mongodb://localhost:27017/"
```

> [!NOTE]
> To fill `MONGODB_NAME` (database name) and `MONGODB_URI` variables, please refer to your MongoDB account.

## Testing and development

```bash
$ npm run dev
```

### MongoDB

This app uses [Mongoose](https://mongoosejs.com/) to interact with your Mongo database.

## Deployment

You can deploy with **Vercel**: [see more](https://vercel.com/) and check `vercel.json` file.

👇 Clone and Deploy now HERE by clicking here

[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fjornatf%2Fmongodb-node-api)

## Licence and contributing

Current licence is `MIT`.

**You are free to modify and improve this git project.**