Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gr7800/dataneoronassignment
Data Neuron is an API for managing products with functionalities like adding, updating, deleting, and retrieving products. It also provides endpoint to track API call counts.
https://github.com/gr7800/dataneoronassignment
body-parser corse css expressjs html javascript mongodb nodejs react-icons react-redux reactjs redux resizable-panels tailwindcss
Last synced: 3 days ago
JSON representation
Data Neuron is an API for managing products with functionalities like adding, updating, deleting, and retrieving products. It also provides endpoint to track API call counts.
- Host: GitHub
- URL: https://github.com/gr7800/dataneoronassignment
- Owner: gr7800
- Created: 2024-04-02T14:24:23.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-04-04T12:39:46.000Z (7 months ago)
- Last Synced: 2024-04-05T12:47:08.470Z (7 months ago)
- Topics: body-parser, corse, css, expressjs, html, javascript, mongodb, nodejs, react-icons, react-redux, reactjs, redux, resizable-panels, tailwindcss
- Language: JavaScript
- Homepage: https://dataneuronasignment.netlify.app/
- Size: 209 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Data Neuron API
Data Neuron is an API for managing products with functionalities like adding, updating, deleting, and retrieving products. It also provides endpoint to track API call counts.
### BaseUrl : https://dataneoron.onrender.com/dataneuron
## Table of Contents
* Getting Started
* Prerequisites
* Installation
* Usage
* Endpoints
* Contributing
* License
* Getting Star### Getting Started
#### Prerequisites
Before running the application, make sure you have the following installed:* Node.js
* MongoDB#### 1. Installation
Clone the repository:``` git clone ```
#### 2. Install dependencies
```
cd data-neuron-api
npm install
```
#### 3. Set up environment variablesCreate a .env file in the root directory and add the following:
```
PORT=8080
MONGODB_URI=
```
#### 4. Start the server```
npm start
```
## Usage
* Endpoints
### 1. Add Product```
URL: /addMethod: POST
Request Body:
{
"name": "Product Name",
"description": "Product Description",
"price": 10,
"quantity": 100
}
```### 2. Update Product
```
URL: /dataneuron/update/:idMethod: PATCH
Request Body:
{
"name": "Updated Product Name",
"description": "Updated Product Description",
"price": 15,
"quantity": 50
}
```
### 3. Get All Products
```
URL: /dataneuron/all
Method: GET
```### 4. Get API Call Count
```
URL: /dataneuron/count
Method: GET
```
### 5. Delete Product
```
URL: /dataneuron/delete/:id
Method: DELETE
```### 6. Delete All Products
```
URL: /dataneuron/deleteall
Method: DELETE
```