Template Author Badge

Hey people,

I’ve got a badge idea for ask.replit.com!

Template Author Badges

Template Author badges are for those users who have made a template that got popular, there 3 badges for this, let’s start with the badges icons :

  1. First we have the Bronze Template Author badge
    El_texto_del_párrafo-removebg-preview
    And here we have a preview of it on the badges page :
    Añadir un título (4)

  2. We then have the Silver Template Author badge
    image__4_-removebg-preview
    And here we have a preview of it on the badges page :
    Añadir un título (2)

  3. Finally we have the Gold Template Author badge
    image__5_-removebg-preview
    And here we have a preview of it on the badges page :
    Añadir un título (3)

Now you might be thinking this :

How do people get the badge?

Well, it’s very simple. The idea is to create a group called Template Authors, this group will be private, which means that to enter to the group you will need to send a message. I thought about this as a perfect message :

Hey,

I’d like to enter the Template Authors Group. I’ve got a template called TEMPLATE NAME with NUMBER OF FORKS. You can see the template on my Replit account, my username is REPLIT USERNAME, and since it has more than 1K forks I should receive all of the 3 badges.

For example if I had a template with 2639 forks and I wanted to enter to the group my admission message would look like this :

Hey,

I’d like to enter the Template Authors Group. I’ve got a template called Custom Discord Status Bot with 2693 forks. You can see the template on my Replit account, my username is Hugoonreplit, and since it has more than 1K forks I should receive all of the 3 badges.

What do you think about this badge?

5 Likes

I like the idea but its going to get repetitive needing to grant the badges to people. I would rather there be an automated process on Replit to use the API to automatically grant the badge.

4 Likes

@not-ethan, That’s perfect!

How could this be made?

What part? The badge could be made by any admin but the automatically granting it would be done by Replit engineers with an API key given by an admin

That’s a good idea, do you think it would take long for someone to write the code?

1 Like

If I were to write it yes it would. I cant figure out how to make an API call for the life of me. But for somebody that knows how to use an API I don’t think it would take that long. They would add a check when a repl is forked to see if it is the 25th, 50th or 100th fork of that repl.

4 Likes

I think that a Discourse plugin would need to be made for this, maybe it would be a good bounty!

2 Likes

It would probably be easier to add code to the backend of Replit instead of making a whole extension.

3 Likes

Hi,

I wrote code to award badges using the API but unfortunately the JSON that is available through Discourse is quite limited. The way badges are meant to be awarded automatically is through writing SQL code and, to do this, you need a premium account (which costs a disproportionate amount of money each month).

At present badge awarding is a manual (bulk) process, which is why it happens once a month. If anyone has any suggestion how it could be improved with an alternative approach I’d be very happy to listen!

3 Likes

One possible way is to ask the engeners for a data dump for emails of users for a template with more than x forks. Then add all accounts with one of those email to a group and then award everybody in that group the badge. I thnk that could be done currently with the limitation.

2 Likes

Good idea. It might not pick up everyone though as some don’t use same username / email address. It would still be a manual process to match up the email addresses to account details but after that point I agree the group would be a good solution. Thanks @not-ethan

3 Likes

Nope. Its an SQL query. Dont know how you bulk award the monthly badges exactly but you may be able to just do it that way.

1 Like

I said group since I remember a post on meta about that. THought you need an SQL query like I said above

I’m getting around the SQL query by doing a bit of Excel wrangling each month.

That must be painful needing to do that every month. We really need to start self hosting

1 Like

(Slightly off-topic) It would be good if Replit Ask accounts could be properly connected with Replit (ie you could sign in with Replit or you could add your Replit account as a social account or something). This could also help with this as you wouldn’t need to post about your Replit account, there could just be like a query to GraphQL (I’m not sure how that works) to figure out if a user has a template with the required amount of forks.

3 Likes

I thought about this multiple times, it could be made with the Replit API, I think this might not be possible, in 5 mins check the new post I will put here, It’s a better idea, I think!

Hey Ian,

I think I’ve got a better idea. So the idea would be to make a command bot called @templatebot, if the user messages the template bot and tags him with the template link the bot will click on the link and check the template, it’ll go something like this :

  1. User sends message tagging @templatebot with template link
  2. The bot checks if it’s a template, if it’s not respond with this message :

    Repl is not a template

  3. If the repl is a template he should see the forks
  4. The bot should then decide between these things :
  • If the template has 25 or more forks award Bronze Template Author badges
  • If the template has 100 or more forks award Bronze Template Author and Silver Template Author badge
  • If the template has 1000 or more forks award Bronze Template Author, Silver Template Author and the Gold Template Author badge

It’s as simple as that, but it’s not as simple. The bot should be a bot command, the user should just tag the person, I posted on meta.discourse.com a topic on how I could make a Discourse command bot and I got this topic as a response. In the topic the user explains how to make a command bot.

The idea is if Replit could give cycles to an employee and that employee could put a bounty, I could make the bounty description! For the bounty we need a Ruby dev, I think I’ve got someone in mind!

2 Likes

It’d be a good idea @MattDESTROYER!

1 Like

There is an internal feature request I believe (@IanAtCSTeach can you confirm?). Also I made a topic about SSO How will SSO work when implimented

2 Likes