Skip to content
This repository has been archived by the owner. It is now read-only.
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
.vs
 
 
 
 
 
 
 
 

WHMCS API C# Wrapper

This is an library to comunicate with the WHMCS API
Currently these functions are already implemented

Donate

How to install
.NET Core Version NuGet Packet Manager Console on VisualStudio Install-Package WHMCS_API -Version 1.0.0
.NET Framework Version NuGet Packet Manager Console on VisualStudio Install-Package WHMCS_API -Version 0.9.13
or
Releases project page (need to also download Newtonsoft.Json if not already included on your project)

The implemented functions are designed to be very easy to use The following code demonstrates to to implement the GetClientDetails on an ASP.net MVC app
More information on the project Wiki Getting Started

using WHMCS_API;
namespace YOUR_APP
{
    public class YOUR_CLASS
    {
        [HttpPost]
        public ActionResult ClientDetails(int clientID)
        {
            string username = "WHMCS_USERNAME";
            string password = "WHMCS_PASSWORD";
            string accessKey = "WHNMCS_ACCESS_KEY";
            string whmcsUrl = "WHMCS_USERFRONTEND_URL"; //ex: https://example.com/client
            API api = new API(username, password, accessKey, whmcsUrl);
            ViewBag.UserDetails = api.GetClientsDetails(clientID, Stats: true); //The model passed is of type GetClientsDetails
            return View();
        }
    }
}

You can still use this library to call non implemented
Read more at the project Wiki [Advanced Usage] Unsuported Actions

You can also create custom functions of already implemented functions.
Read more at the project Wiki [Advanced Usage] Supported Actions

Donate

About

An WHMCS API C# Wrapper

Topics

Resources

Packages

No packages published