An API that serves data from MLBB Wiki, currently the available data that can be requested are:
- Heroes Data
- Equipment Data
- Emblem Data
This API also uses cron jobs that automatically updates the data once a week.
DISCLAIMER: this project is not affiliated with Moonton or MLBB Wiki and serves as learning purpose only.
Here are the available endpoints for this API:
- [GET] Return All Hero Data
https://mlbb-wiki-api.vercel.app/api/heroes
- [GET] Return Hero Data by ID
https://mlbb-wiki-api.vercel.app/api/heroes/[id]
- [GET] Return All Equipment Data
https://mlbb-wiki-api.vercel.app/api/equipment
- [GET] Return Equipment Data by ID
https://mlbb-wiki-api.vercel.app/api/equipment/[id]
- [GET] Return All Emblem Data
https://mlbb-wiki-api.vercel.app/api/emblem
- This API has a rate limit of 120 requests per minute for each endpoint
- This API is developed in focus for Vercel Deployment
- Some limitations when deploying in Vercel (especially when using Hobby Plan) is the timeout duration when executing serverless functions, Vercel allows a maximum duration of 60 seconds and a memory of 1024 MB for serverless functions.
- This project can only run in production mode, learn more about how to run it locally here
- Clone this repository
git clone https://github.com/ervin-sungkono/qr-code-gen.git
- Install dependency
npm install
- Copy environment variables and fill in the required values
- CRON_SECRET: Random string for running cron jobs in Vercel, Click Here to learn about setting cron jobs in Vercel
cp .env.example .env
- Run the app
npm run dev
This project is deployed using Vercel, to learn more about deploying Next.js app on Vercel Click Here