To setup WHMCS SSO, you need to generate some OpenID API credentials and normal API credentials on your WHMCS installation.
Navigate to the OpenID Connect page on WHMCS, under Setup > OpenID Connect
. You'll find a button to generate new API credentials for OpenID on that page - click that green button.
Next, you will need to add these two authorised redirect URL's for your game panel domain name. Obviously, changing the actual domain name to the domain your game panel is accessible on:
https://your.panel.gg/account/sso <https://your.panel.gg/auth/login/sso
>
Once you click save, it should send you to a page with the information we need to put into your game panel. We'll need these later.
Navigate to the API credentials page on WHMCS, under Setup > Staff Management > Manage API Credentials
First, we need to create an API role to setup the permissions
You only need to assign the two following permissions to the API role:
Authentication > ValidateLogin
Client > GetClientDetails
These permissions are so users who login with SSO can use their WHMCS password on SFTP.
Now we can generate the API credentials for WISP, with the new role we just made. Navigate back to the API Credentials
tab & click Generate New API Credential
Select your user from the dropdown, and select the API role we just made, then hit that juicy generate button
This step is pretty important, so read it carefully. WHMCS will show a popup that looks like this. It's very important you don't close this popup before copying the information into WISP, because you will not be able to see the secret again!
Navigate to Admin Panel → Administration → Settings → WHMCS SSO tab. Here you'll input all the information we just generated on WHMCS.
The API Credentials from that popup on the previous step go in the area with the red rectangle.
The OpenID information we generated earlier in the guide will go into the area with the blue rectangle.
Your WHMCS URL should be set to the root directory for your WHMCS installation. For example, if your WHMCS was installed at wisp.gg/billing/ - that should be your WHMCS URL.
Finally, click the Enabled button in the top left and click save in the bottom right. To test if the integration is working, deploy a game server from WHMCS with an email that isn't already a registered user in your game panel.
<aside>
⚠️ The integration will only work with new users that our WHMCS module creates. Existing users on your game panel will need to manually link their game panel account to their billing account by going to My Account
and clicking the Link Account
button near the bottom.
</aside>