For a challenge
yarn
to install all dependences
yarn start
to start the application after install the dependences
npm install
to install all dependences
npm run start
to start the application after install the dependences**
yarn
to install all dependences
yarn start
to start the application after install the dependences
yarn typeorm migrations:run
to create tables in SQLite DB
npm install
to install all dependences
npm run start
to start the application after install the dependences**
npm run typeorm migrations:run
to create tables in SQLite DB
body JSON:
{
"name": "barbara",
"email":"barbara@email.com",
"password":"barbara123!"
}
http://localhost:3333/users POST: Create User
http://localhost:3333/users/id GET: List Specific User
http://localhost:3333/users GET: List All Users
http://localhost:3333/users/id PUT: Update User
http://localhost:3333/users/id DELETE: Delete User
http://localhost:3333/sessions POST: To Login and create a token
http://localhost:3333/pets/user-pets/userId GET: Get all pets from an user
body JSON:
{
"name": "caramelo",
"breed":"vira lata",
"age":7,
"weight":14,
"city": "rio de janeiro",
"state": "RJ",
"isAdopted": 1
}
http://localhost:3333/pets POST: Create Pet
http://localhost:3333/pets/id GET: List Specific PEt
http://localhost:3333/pets GET: List All Pets
http://localhost:3333/pets/id PUT: Update Pet
http://localhost:3333/pets/id DELETE: Delete Pet