WHMCS + Blesta License Verification Discord Bot

Howdy y’all! Just thought I’d share a little project I’ve been working on. I actually created this bot several months ago, but just got around to refactoring and posting up the code today. Shoutout to @JackHadrill and @doghouch for helping me test the bot out a bunch over the past couple months.

GitHub repo: GitHub - masonr/Discord-Billing-License-Bot: Simple Discord bot that will verify WHMCS and Blesta billing panel licenses

Purpose:

Simple Discord bot that will verify WHMCS and Blesta billing panel licenses. Call the bot’s command and pass a domain as an argument and it will attempt to verify the license.

How to Get Bot:

Two options - hosted or self-hosted.

  • Hosted: I’m hosting the bot on one of my servers, so you can invite the bot to your Discord server using this link: Discord. The bot does not need any permissions.
  • Self-Hosted: Alternatively, you can host the bot yourself using the instructions on the GitHub page. All the code and instructions are available on the GitHub project page. The bot requires Python 3 and two modules (Discord client + Beautiful Soup) to run.

Usage:

!command [domain]   
!command help   

Supported Commands:

!license - checks WHMCS and Blesta license validity   
!licence - (same as above)     
!whmcs - checks WHMCS license validity   
!blesta - checks Blesta license validity  

Example Commands:

!license google.com  
!whmcs unknown.host  
!blesta billing.hostingcompany.net  
!license help  

Screenshots:

!license command with valid license -

!license command with invalid license -

!whmcs command with valid license -

!blesta command with valid license -

!license command with error -

!license help command -

Questions/Feedback:

I’m open to any questions or feedback that you may have. Any features you think that would be beneficial, feel free to suggest them or fork the repo + PR your changes. Feel free to email or PM me if you encounter any errors or have any issues getting the bot sorted.

Cheers!
-Mason

12 Likes

Ah yes, I remember seeing this. Great work! :smiley:

1 Like

Just curious, how do you verify Blesta licenses? I don’t believe they have a public verification portal (as with WHMCS)?

1 Like

They do, it’s here: License Verification | Blesta

It’s very similar to WHMCS’s verification page, but requires a csrftoken and a cookie to properly submit a query to the page. You’ll see the extra jazz in the code to make that happen.

1 Like

I was not aware of that page, thanks.

1 Like

So glad you didn’t do ho-ost. You’d find out my dark nulled secrets.

Nice project.

1 Like

You’re in the clear… for now :wink:

And thank you, kind sir!

2 Likes

Got the Bot approved on the Discord Bot site :smiley:

2 Likes

Nice! Thanks to your source code, I’ve implemented similar functionality into my tools API :stuck_out_tongue: You can make a GET or POST request containing a domain and then receive true or false whether the domain is authorized or not. I also added support for CPanel.

Got to say, the Blesta integration was pretty annoying to do! Would’ve taken a lot longer if I didn’t have your code as a reference.

1 Like

Sweet! :smiley: glad the code was useful!

Not sure why Blesta’s verification page is set up the way it is and it took a ton of trial and error with curl commands till I finally figured out what’s needed with the POST message, but eventually figured it out :stuck_out_tongue:

Also, now that you mention it I may add cPanel verification to the bot.

1 Like