Welcome to the Northcoders News API! This project serves as the backend API for Northcoders News, providing the following endpoints topics, articles, and comments.
To run this API on your machine, you will need Node.js and Postgres installed on your machine.
To install Postgres, go to: https://www.postgresql.org/download/ The version required is a minimum of v. 12.1
To install Node, go to: https://nodejs.org/en/download/ The version required is a minimum of v. 13.8.0
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
1.Clone a copy of the repository on your machine using the below command:
git clone https://github.com/asme10/nc-news-api
-
Install the required dependencies:
npm install
1.Setup the database by running the below script:
npm run setup-dbs
2.Setup the database by running the below script:
npm run seed
1.To store configuration settings that control how an application behaves.
.env.development
.env.test
1.To run the tests written for the API during the TDD process (including tests for error handling), run the following command:
npm run test
2.To run the tests written for the utils functions, run the following command:
npm run test-utils
This project was built using the following technologies:
- Node.js - JavaScript server-side runtime environment
- Express - Node.js web application server framework
- PostgreSQL - Open source object-relational database system