Critterbase is a shared component of BiodiversityHubBC that manages information about individual animals, including capture and mortality events, measurements, markings, family relationships, and photos.
This API includes various modules, each with their own endpoints:
1. Access: /api/access/
2. Artifact: /api/artifacts/
3. Bulk: /api/bulk/
4. Capture: /api/captures/
5. Collection Unit: /api/collection-units/
6. Critter: /api/critters/
7. Family: /api/family/
8. Location: /api/locations/
9. Lookup: /api/lookups/
10. Marking: /api/markings/
11. Measurement: /api/measurements/
12. Mortality: /api/mortality/
13. User: /api/users/
14. Xref: /api/xref/
- Clone the project (only once)
git clone https://github.com/bcgov/critterbase-api- Change into Critterbase directory (every time)
cd critterbase-api- Generate environment variables (only once)
make env- Build and run containers (every time)
make backendNote: See Makefile for additional project commands
Note: npm run start is used in the deployment pipeline to start the server and apply pending database migrations.
To run tests, run the following command
npm run test