Genshin public REST API serving data from a Web Scraping approach
| Environment | Swagger Online Docs |
|---|---|
| Production |
| Feature | Endpoint | Status |
|---|---|---|
| Puppeteer Setup | - | ✅ |
| Database Setup | - | ✅ |
| Docker Setup | - | ✅ |
| Public Swagger | GET /docs | ✅ |
| Signup | POST /api/v1/auth/register | ✅ |
| Login | POST /api/v1/auth/login | ✅ |
| Characters List | GET /api/v1/characters | ✅ |
| Character Details | GET /api/v1/characters/:id | ✅ |
| Deploy v0.1.0 | https://genshin-api.santospatrick.com/docs | ✅ |
- Setup a PostgreSQL database (example with docker):
docker run --name database -e POSTGRES_PASSWORD=root -p 5432:5432 -d postgres
-
Duplicate
.env.exampleto.envfulfilling variables as needed -
Run the following commands:
yarn install
yarn adonis key:generate
yarn adonis migration:run
yarn dev
- Done 🎉 (access http://localhost:3333)
- Clone this repo:
git clone [email protected]:santospatrick/genshin-api.git
- Duplicate
.env.exampleto.envfulfilling variables as needed
cp .env.example .env
vim .env
# edit variables- Run docker-compose and migrations:
docker-compose up -d
docker exec -it YourAppName sh
yarn adonis key:generate
yarn adonis migration:run
- Done 🎉
Download project's postman collection to test endpoints
