Overview

Getting Started

Prerequisites#

  • Node.js — check the .nvmrc file in the repo for the exact version
  • MongoDB > 4.0.0installation guide

To keep your local Node version in sync with the deployed server, use nvm. It installs the version listed in .nvmrc automatically when you run nvm install.

Verify your installs:

node -v
mongo --version

Install#

Clone the repository and install dependencies:

git clone https://github.com/cboard-org/cboard-api.git
cd cboard-api
nvm install
npm install -g yarn
yarn install

Start the database#

Start MongoDB (process management docs):

mongod

Configure environment variables#

Before starting the API, set up your environment — see Environment Configuration.

Run the API server#

In a separate terminal tab or window:

npm run dev

This restarts the server automatically when files change. Alternatively:

npm run start

Both commands start a server listening on port 10010. You can now make calls to the API.

If you run into trouble, double check the prerequisites above are installed correctly.

Next steps#

Updated

Was this page helpful?