Ma Adopt Kan, the adoption pets website, is designed to help people adopt pets easily. The website will allow users to post pets for adoption and request to adopt a pet. The website is easy to use and helps connect caregivers with people looking to adopt pets in need of a home. The website will have many features, such as post management, adopting confirmation system, and login. All of these will help users to adopt easily without using other platforms that are hard to use.
- Clone the repository:
git clone https://github.com/CSC105-2024/G11-MaAdoptKan.git cd G11-MaAdoptKan
- React.ts
- Vite
- Axios
- React Router DOM
- Tailwind CSS
- Zod
- React Icon
-
Navigate to the frontend directory:
cd frontend
-
Install dependencies:
npm install
-
Start the development server:
npm run dev
-
The client will be running on http://localhost:5173.
- Node.js
- Hono
- JWT
- User
Method | Endpoint | Description |
---|---|---|
POST | /user/create |
Create new user. |
POST | /user/login |
Login user |
GET | /user/get?id={id} |
Get user by using user ID. |
GET | /user/getAll |
Get all users |
GET | /user/pets |
Get all pets from user |
- Request
Method | Endpoint | Description |
---|---|---|
POST | /request/create |
Create new request. |
GET | /request/get?id={id} |
Get request by using request ID. |
GET | /request/getAll |
Get all requests. |
GET | /request/pet/:petId |
Get all requests from pet. |
DELETE | /request/delete/:id |
Delete request. |
- Pet
Method | Endpoint | Description |
---|---|---|
POST | /pet/create |
Create new pet. |
PATCH | /pet/edit |
Edit a pet |
GET | /pet/get?petId={petId} |
Get pet by using pet ID. |
GET | `/pet/getAll?count={count} | Get all pets by counting to display. |
DELETE | /pet/delete?petId={petId} |
Delete pet by using pet ID. |
-
Navigate to the backend directory:
cd backend
-
Install dependencies & Genrate the database:
npm install npx prisma generate
-
Create a
.env
file and configure the following variables:DATABASE_URL="file:./dev.db" JWT_SECRET_TOKEN=66cb176ce3489eb8020d44d492825a259589203dfc4b480556d97f51a742d2a1
-
Start the development server:
npm run dev
-
The server will be running on http://localhost:3000