I'm trying to design an API backend (for a mobile app) around the concept of a leaderboard.
Some of the requirements:
- I am interested only in assigning points following the validation of certain rules
- the backend should be multi app: app1 should have some rules, app2 can have another set of rules
- the backend receives actions made by users on the mobile app and has to validate if those actions are valid and assign points
- rules can be something like:
give the user 10 points if it's the first time you see action A in 24 hours
give the user 10 points if action B happens but don't give the points if you see action B more than 10 times per week
there has to be a log of the previous actions so it can be reported to the mobile app
compute points, leaderboard scores and reports (in a given time frame)
I looked into merit but I didn't understand if a model can have multiple point rules files (eg: userA belongs to appA so rulesB don't apply to him) and if there's a trail of every action or just the current score.
In brief: does merit support of all of that? If not, what do you suggest?