Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Node-Prod

A simple API built with TypeScript and Express.js for registering NFL jerseys, including player names, jersey numbers, teams, and delivery information from Alagoinhas, BA.

Technologies Used

  • TypeScript
  • Node.js
  • Express
  • Helmet

Getting Started

Prerequisites

Make sure you have Node.js and npm installed on your machine.

Installation

  1. Clone the repository:
    git clone https://github.com/WesleyBSa/node-prod.git
  2. Navigate to the project directory:
    cd node-prod
  3. Install the dependencies:
    npm install

Running the Server

To start the server, run the following command:

npm start

The server will start running at http://localhost:5757/.

API Endpoints

  • GET /ping: Check if the server is running.
  • GET /produtos: Retrieve a list of all NFL jerseys.
  • GET /produtos/:id: Retrieve information about a specific NFL jersey by ID.
  • POST /produtos: Register a new NFL jersey.
  • GET /transporte/:de/:para: Get delivery information between two locations.

Example Request

Register a new NFL jersey:

curl -X POST http://localhost:5757/produtos \
-H "Content-Type: application/json" \
-d '{"name": "Tom Brady", "number": 12, "team": "N.E Patriots", "id": 1, "transporte": "Air"}'

License

This project is licensed under the MIT License. See the LICENSE file for more details.

Contact

If you have any questions or suggestions, feel free to reach out at batistawesley948@gmail.com.

About

A simple API built with TypeScript and Express.js for registering NFL jerseys.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages