https://github.com/fullstackacademy/unit4.petfinder.starter
https://github.com/fullstackacademy/unit4.petfinder.starter
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/fullstackacademy/unit4.petfinder.starter
- Owner: FullstackAcademy
- Created: 2023-04-12T03:01:34.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-08-14T13:29:09.000Z (almost 2 years ago)
- Last Synced: 2025-03-29T16:11:09.793Z (about 1 year ago)
- Language: JavaScript
- Size: 82 KB
- Stars: 1
- Watchers: 26
- Forks: 380
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Workshop: Backend Fundamentals - Pet Finder
## Introduction
In this workshop, you'll be provided this GitHub repo with details for a full operational CRUD API that uses Express.JS, PostgreSQL, and other technologies that you've been trained on.
## Problems to Solve
Begin this Career Simulation by cloning the GitHub repo, pseudocoding prompts, installing dependencies and solving the problems below.
### Problem 1: GET all pets
The GET route for all pets is currently "under construction". Navigate to `index.js` and find the GET method at `/api/v1/pets` and write the code to get all pets from the database.
### Problem 2: GET pets by name
The GET route for pets by name is currently "under construction". Navigate to `index.js` and find the GET method at `/api/v1/pets/:name` and write the code to get a pet by name from the database.
### Problem 3: GET pet by owner's name with a query string
The GET route for pets by owner's name is currently "under construction". Navigate to `index.js` and find the GET method at `/api/v1/pets/owner` and write the code to get a pet by owner's name from the database.
### STRETCH GOAL: Problem 4: Serve a static index.html file
The GET route for serving a static index.html file is currently "under construction". Navigate to `index.js` and find the GET method at `/` and write the code to serve a static index.html file.
### Endpoints
Port 8080 by default.
| Method | Endpoint | Description |
| ------ | ------------------ | ------------------------------ |
| GET | / | Serve a static index.html file |
| GET | /api | Returns 'Hello World!' |
| GET | /api/v1/pets | Get all pets |
| GET | /api/v1/pets/:name | Get a pet by name |
| GET | /api/v1/pets/owner | Get a pet by owner's name |