Lithosphere The Lithium Community

%3CLINGO-SUB%20id%3D%22lingo-sub-455230%22%20slang%3D%22en-US%22%3EUnique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-455230%22%20slang%3D%22en-US%22%3E%3CP%3EDoes%20anyone%20know%20if%20you%20can%20send%20unique%20notifications%20for%20specific%20badges%20link%20you%20can%20for%20ranks%3B%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fcommunity.lithium.com%2Ft5%2FRankings%2FSend-different-rank-up-notifications-for-different-ranks%2Fta-p%2F72102%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fcommunity.lithium.com%2Ft5%2FRankings%2FSend-different-rank-up-notifications-for-different-ranks%2Fta-p%2F72102%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EJust%20looking%20at%20ways%20that%20we%20can%20let%20users%20know%20what%20the%20next%20badge%20in%20the%20track%20is.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-458449%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-458449%22%20slang%3D%22en-US%22%3E%3CP%3E%3Ca%20href%3D%22https%3A%2F%2Flithosphere.lithium.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F33381%22%3E%40DanK%3C%2Fa%3E%26nbsp%3B-%20Sure%2C%20let%20me%20know%20if%20this%20works%20for%20you.%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-456023%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-456023%22%20slang%3D%22en-US%22%3EInteresting%2C%20I%20will%20do%20some%20testing%20and%20see%20what%20we%20can%20produce.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-455944%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-455944%22%20slang%3D%22en-US%22%3E%3CP%3E%3Ca%20href%3D%22https%3A%2F%2Flithosphere.lithium.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F33381%22%3E%40DanK%3C%2Fa%3E%26nbsp%3B%3Ca%20href%3D%22https%3A%2F%2Flithosphere.lithium.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F12041%22%3E%40JasonHill%3C%2Fa%3E%26nbsp%3B-%20I%20believe%20this%20is%20something%20which%20is%20feasible%20but%20requires%20some%20tweaks%20and%20customization.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAs%20described%20in%20email%20template%20context%20object%20there%20is%20no%20way%20to%20get%20the%20badge%20id%2C%20however%2C%20we%20can%20get%20the%20badges%20title%20using%20%24%7Bnotification.badge.title%7D%26nbsp%3Bcontext%20object%20which%20can%20be%20used%20inside%20text%20keys.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Ee.g%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%3EbadgeChanged.privateMessage.%3CSTRONG%3E%26lt%3Bbadge-title%26gt%3B%3C%2FSTRONG%3E.template.html_content%20%3D%20content%20here%3C%2FPRE%3E%3CP%3Eso%20let's%20say%20badge%20title%20is%26nbsp%3BPhilosopher%2C%26nbsp%3Bso%20our%20key%20will%20look%20like.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%3EbadgeChanged.privateMessage.%3CEM%3E%3CSTRONG%3EPhilosopher%3C%2FSTRONG%3E%3C%2FEM%3E.template.html_content%20%3D%20content%20here%26nbsp%3B%26nbsp%3B%3C%2FPRE%3E%3CP%3EThere%20might%20be%20one%20issue%20when%20there%20is%20a%20space%20inside%20badges%20name%20e.g%26nbsp%3BGave%201%20Kudos.%26nbsp%3BYou%20can%20replace%20the%20space%20using%20velocity%26nbsp%3B.replace%26nbsp%3Bfunction%20as%20text%20keys%20don't%20support%20space.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20hope%20this%20might%20be%20helpful%20to%20give%20this%20customization%20a%20start.%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-455247%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-455247%22%20slang%3D%22en-US%22%3E%3CP%3ELove%20it%26nbsp%3B%3Ca%20href%3D%22https%3A%2F%2Flithosphere.lithium.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F33381%22%3E%40DanK%3C%2Fa%3E.%20I%20hope%20the%20answer%20doesn't%20come%20back%20that%20this%20isn't%20possible%2C%20because%20it's%20an%20excellent%20idea.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EJason%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-455245%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-455245%22%20slang%3D%22en-US%22%3E%3CP%3EI%20know%20its%20possible%20for%20ranks%20what%20I%20want%20to%20do%20is%20a%20similar%20thing%20for%20badges.%20Perhaps%20an%20example%20will%20help.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EDefault%20email%20text%20could%20be%20something%20simple%20like%20this%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EHi%20%26lt%3Buser%26gt%3B%2C%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EYou%20just%20earned%20a%20the%20%26lt%3Bbadge%26gt%3B%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3E%26lt%3Bbadge-image%26gt%3B%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EThanks%20for%20being%20a%20member.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3EYour%20%26lt%3Bcommunityname%26gt%3B%20Team%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWhat%20I%20am%20looking%20to%20do%20is%20replace%20that%20with%20more%20meaningful%20specific%20text%20like%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EHi%20%26lt%3Buser%26gt%3B%2C%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EYou%20just%20earned%20a%20the%20badge%20for%20getting%20your%2010th%20solution%20on%20community.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3E%26lt%3Bbadge-image%26gt%3B%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EWe%20really%20appreciate%20you%20taking%20the%20time%20to%20share%20your%20knowledge%2C%20you%20are%20well%20on%20your%20way%20to%20earning%20the%20Author%2025%20Solutions%20badge.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CBR%20%2F%3E%3CEM%3EThanks%20for%20being%20a%20member.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3EYour%20%26lt%3Bcommunityname%26gt%3B%20Team%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOr%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EHi%20%26lt%3Buser%26gt%3B%2C%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EYou%20just%20earned%20a%20the%20badge%20for%20posting%20your%20first%20question.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3E%26lt%3Bbadge-image%26gt%3B%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EWhile%20you%20are%20waiting%20for%20our%20members%20to%20respond%2C%20perhaps%20you%20would%20like%20to%20setup%20your%20profile.%20Check%20out%20our%20welcome%20page%20for%20more%20details.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CEM%3EThanks%20for%20being%20a%20member.%3C%2FEM%3E%3C%2FP%3E%3CP%3E%3CEM%3EYour%20%26lt%3Bcommunityname%26gt%3B%20Team%3C%2FEM%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-455244%22%20slang%3D%22en-US%22%3ERe%3A%20Unique%20badge%20notifications%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-455244%22%20slang%3D%22en-US%22%3E%3CP%3E%3Ca%20href%3D%22https%3A%2F%2Flithosphere.lithium.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F33381%22%3E%40DanK%3C%2Fa%3E%26nbsp%3B-%20According%20the%20document%20you%20shared%2C%20we%20can%20send%20different%20notification%20for%20different%20ranks.%20And%20in%20those%20text%20Keys%20for%20different%20message%2C%20you%20can%20include%20the%20next%20badge%20to%20be%20achieved.%26nbsp%3B%20You%20won't%20be%20able%20to%20get%20dynamically%20which%20one%20is%20next%20badge%20or%20the%20description%20of%20next%20badge%20inside%20email%20template.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Honored Contributor Honored Contributor
Honored Contributor

Unique badge notifications

Does anyone know if you can send unique notifications for specific badges link you can for ranks; https://community.lithium.com/t5/Rankings/Send-different-rank-up-notifications-for-different-ranks/t...

 

Just looking at ways that we can let users know what the next badge in the track is.

0 Kudos
6 Replies
Honored Contributor
Honored Contributor

Re: Unique badge notifications

@DanK - According the document you shared, we can send different notification for different ranks. And in those text Keys for different message, you can include the next badge to be achieved.  You won't be able to get dynamically which one is next badge or the description of next badge inside email template. 

 

 

 

Give kudos if you find my posts helpful or mark solution if it answers your query.
Tariq
0 Kudos
Reply
Loading...
Highlighted
Honored Contributor Honored Contributor
Honored Contributor

Re: Unique badge notifications

I know its possible for ranks what I want to do is a similar thing for badges. Perhaps an example will help.

 

Default email text could be something simple like this;

 

Hi <user>,

 

You just earned a the <badge>

<badge-image>

 

Thanks for being a member.

Your <communityname> Team

 

What I am looking to do is replace that with more meaningful specific text like;

 

Hi <user>,

 

You just earned a the badge for getting your 10th solution on community.

<badge-image>

 

We really appreciate you taking the time to share your knowledge, you are well on your way to earning the Author 25 Solutions badge.


Thanks for being a member.

Your <communityname> Team

 

Or;

 

Hi <user>,

 

You just earned a the badge for posting your first question.

<badge-image>

 

While you are waiting for our members to respond, perhaps you would like to setup your profile. Check out our welcome page for more details.

 

Thanks for being a member.

Your <communityname> Team

Reply
Loading...
Honored Contributor Honored Contributor
Honored Contributor

Re: Unique badge notifications

Love it @DanK. I hope the answer doesn't come back that this isn't possible, because it's an excellent idea.

 

Jason

Generic1.jpg

Reply
Loading...
Honored Contributor
Honored Contributor

Re: Unique badge notifications

@DanK @JasonHill - I believe this is something which is feasible but requires some tweaks and customization. 

 

As described in email template context object there is no way to get the badge id, however, we can get the badges title using ${notification.badge.title} context object which can be used inside text keys. 

 

e.g 

 

badgeChanged.privateMessage.<badge-title>.template.html_content = content here

so let's say badge title is Philosopher, so our key will look like. 

 

 

badgeChanged.privateMessage.Philosopher.template.html_content = content here  

There might be one issue when there is a space inside badges name e.g Gave 1 Kudos. You can replace the space using velocity .replace function as text keys don't support space. 

 

I hope this might be helpful to give this customization a start. 

Give kudos if you find my posts helpful or mark solution if it answers your query.
Tariq
Reply
Loading...
Honored Contributor Honored Contributor
Honored Contributor

Re: Unique badge notifications

Interesting, I will do some testing and see what we can produce.
Reply
Loading...
Honored Contributor
Honored Contributor

Re: Unique badge notifications

@DanK - Sure, let me know if this works for you. 

Give kudos if you find my posts helpful or mark solution if it answers your query.
Tariq
0 Kudos
Reply
Loading...