Get Badges
Get all created badges for creator
Authorization
bearer In: header
Header Parameters
Host name of the dashboard, ex: mydomain.tagmango.com
Response Body
application/json
application/json
application/json
curl -X GET "https://api-prod-new.tagmango.com/api/v1/external/gamification/badges" \ -H "x-whitelabel-host: string"[
{
"_id": "6659ca9e5f2acb7abfdcd8fd",
"creator": "6149b1e5612c4e5fd96041d3",
"name": "Hall Of Fame",
"description": "Something about the badge",
"imageUrl": "https://testing.tagmango.com/assets/badge-icon-922e7f499bc0045d7af8ac771eebe2fe.png",
"enableAutomation": true,
"pointsThreshold": 100,
"pointCategoryForAutomation": "lifetime",
"automationEnabledMangoes": [
"6659ca9e5f2acb7abfdcd8fd",
"6659ca9e5f2acb7abfdcd8fd"
],
"createdAt": "2024-05-31T13:03:26.375Z",
"updatedAt": "2024-07-19T12:32:51.071Z"
}
]{
"code": 400,
"type": "Bad request",
"statusMessage": "BAD_REQUEST",
"message": "Invalid request",
"success": false
}{
"code": 401,
"type": "Unauthorized",
"statusMessage": "UNAUTHORIZED",
"message": "Invalid token",
"success": false
}Update Points For Users PATCH
Update points for multiple users at once. - Provides unique identifiers for the points assigned to the users - There are different categories of points assign by the TagMango system - dailyActive, likeOnPost, commentOnPost, messageInRoom, createPost, 10perCourseCompletion, 50perCourseCompletion, 100perCourseCompletion, attendance, signUpThroughAffiliate **Note** - This endpoint can be used to assign points to multiple users at once. - It can also be used to revoke points from users by passing negative score.
Create Badge POST
Create a new badge. - If automation is enabled, then the badge will be assigned to the users automatically. - Automation may take time to reflect. There are two types of badges automation - 1. Automation by points threshold - When user reaches this points threshold, the badge will be assigned to the user automatically, if points fall below the threshold then it will be removed from the user. 2. Automation by mango subscription - When user subscribes to any of these mangoes, then the badge will be assigned to the user automatically. If subscription expired or removed then it will be removed from the user. **Note** Only one of the automation type can be enabled at a time.