https://github.com/alejandrosuero/nodejs-api
REST API deployed on fl0
https://github.com/alejandrosuero/nodejs-api
express expressjs nodejs nodejs-api rest-api
Last synced: 2 months ago
JSON representation
REST API deployed on fl0
- Host: GitHub
- URL: https://github.com/alejandrosuero/nodejs-api
- Owner: AlejandroSuero
- Created: 2023-09-15T15:52:35.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-21T14:31:26.000Z (over 1 year ago)
- Last Synced: 2025-03-28T16:55:09.785Z (2 months ago)
- Topics: express, expressjs, nodejs, nodejs-api, rest-api
- Language: JavaScript
- Homepage: https://nodejs-api-fss8-dev.fl0.io/movies
- Size: 83 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# NodeJS REST API
A REST API using NodeJS and Express.
In this I am going to create an API to display, update, post and delete movies.
## Installation
You can use whatever package manager that you want. I am going to show it with
npm.```bash
# Using -E to install exact version (best practice for production dependencies)
npm install express zod -E# Dev dependencies
npm install -D eslint
```### Eslint configuration (optional)
In my case a like to use a separate file for the linter, in this case
```.eslintrc.json``` and ```.eslintignore```.I like using standar as a base configuration.
```bash
npm init @eslint/config
# After hitting select how you want it to be configured
```## Usage
As I am using the REST arquitecture every resource is an endpoint. In this case
```movies``` is the resource and the specific **movie** is going to be another
endpoint.### Endpoints
- [x] http://localhost:/movies
- [x] http://localhost:/movies/:idIn the case there is a need for filtering a genre in the list of movies, we could
treat it as another resource but in this case is going to be a query paramater
to filter.- [x] http://localhost:/movies?genre=