Showing results for 
Show  only  | Search instead for 
Did you mean: 

Displaying Badge Count

How do you call the metric for "a logged in user's badge count, as shown on the "userbadgespage"


My attempt at this is


<#-- User Badge Count Variable
<#assign badgeCount = rest("/users/login/${}/profile/").value />

<a href="javascript&colon;void(0);">You have ${badgeCount!""}</a>
Learning Content Strategist
3 Replies 3

@ryandewitt - Try this V2 call - select user_badges from users where id = '47'

The size returned is your number of badges.


I hope this helps.

Varun : Weaving magic with Khoros!

Recent Ideas: Advanced Private Messages | Rewarding Module | Badges for Threads

Hi @VarunGrazitti ,

Is there a call that can give us a number of users with a certain number of badges.? For example we would like to find out how many users in the community have 16 or 5 badges for example.




This is very interesting looking forward to the answer from Varun. 

This is what I got. 

If you can grab "badge_count" and then set a "low_badge" Boolean

<#if rest("/users/id/" + + "/profiles/name/badge_count").value == "">
<#assign low_badge=false>
<#assign low_badge=true>

Basically, Sounds like a If statement would solve this.  


Learning Content Strategist

Welcome to the Technology board!

Curious about our platform? Looking to connect on social technology? You've come to the right place!

Are you a Khoros customer? For direct assistance from our Support team, please visit the Support Forum.