I am working on an app which is built through Shopify App Cli. Hence the backend is in Koa.js and front end is using Next.js. Also I am using MongoDB for database.
The app stores some data regarding the shop in the database.
What I want to do is call an api so that all the data saved about the Shop that is currently saved in the database be wiped from the database when the user uninstalls the app.
From my research it seems I need to use a webhook for that. But I really don't have any ideas about webhooks nor do I know how to integrate it.
Please help me resolve this.