Skip to content

MishraShardendu22/Dragon-Ball-Api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

98 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🐉 Dragon Ball API

Note: The documentation includes examples and an Ask-AI chat bot to help you explore the API easily!
Live Alternate API URL: Dragon Ball API

Love Dragon Ball? This API is built for fans! Access, manage, and update Dragon Ball trivia with our Express-based custom REST API.

API Documentation API Link


⚙️ Features

  • Built using Express.js & TypeScript
  • MongoDB backend with Mongoose
  • JWT-based secured endpoints
  • Auto-generated OpenAPI schema
  • Tested via Keploy (AI-powered API testing)
  • Integrated with GitHub Actions CI/CD
  • Full CRUD support for managing questions
  • Swagger-compatible OpenAPI spec
  • Nextra-based documentation site

📍 API Endpoints

Method Endpoint Description Authentication
GET / Welcome page with docs link No
GET /random Get a random question No
GET /question/:id Get a question by ID No
GET /series/:series Get questions by series No
POST /add Add a new question No
PUT /question/:id Full update of a question by ID No
PATCH /question/:id Partial update of a question by ID No
DELETE /question/:id Delete a question by ID Yes (Admin)
DELETE /delete Delete all questions Yes (Admin)
POST /GetTokenAdmin Get JWT token for admin actions No

🧪 API Testing with Keploy

  • ✅ OpenAPI schema auto-generated
  • ✅ Curl command-based testing
  • ✅ Test cases captured via traffic
  • ✅ Integrated into CI/CD

📷 Test Results

Keploy Test Results


🛠 Tech Stack

  • Express.js - Node.js framework
  • TypeScript - Type-safe development
  • MongoDB - NoSQL database
  • JWT - Secure token authentication
  • Keploy - AI-powered API testing
  • GitHub Actions - CI/CD automation
  • Nextra - Docs generation

🧩 Project Setup

git clone https://github.com/shardendu-mishra/dragon-ball-api.git
cd dragon-ball-api
npm install

Set Env Vars

ADMIN_USERNAME=your_admin_username
ADMIN_PASSWORD=your_admin_password
JWT_SECRET=your_jwt_secret
MONGODB_URI=your_mongodb_uri

Run Locally

npm run start

🔁 CI/CD

GitHub Actions runs Keploy tests on every push. See .github/workflows/keploy.yml


📜 OpenAPI Schema

Auto-generated using Swagger JSDoc annotations. Available at GET /swagger (if implemented) or in swagger.yaml


🔗 Useful Links


🤝 Contributing

Open PRs and suggestions are welcome.


👤 Author

Shardendu Mishra GitHub: @ShardenduMishra22


About

Love Dragon Ball ? This API is for you !!!! Live on :

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •