This project is built using Encore and integrates with the Petfinder API to search for adoptable pets.
- Install Node.js (LTS recommended)
- Install Encore CLI
- Create a Petfinder API key
Clone the repository and install dependencies:
git clone https://github.com/encoredev/encore-petfinder-api.git
cd encore-petfinder-api
npm install
Create a .env.test
file and add the following:
PET_FINDER_API_KEY=your_api_key
PET_FINDER_SECRET=your_api_secret
Start the Encore backend:
encore run
The API should now be available at http://localhost:4000
.
Run tests using Vitest via Encore:
encore test
Method | Endpoint | Description |
---|---|---|
GET | /pets |
Retrieve a list of pets |
POST | /search |
Search pets by criteria |