Solmicro.DigitalHub.Client.dll
Solmicro.DigitalHub.Client.dll is developed in .NET Standard 2.0.
It contains several classes that expose the necessary functions to operate with different documents. For example:
InvoicingClientis the class used to operate with the Invoicing API endpoints, mainly used by Veri*Factu and TicketBAI.AccountingBookClientis the class used to operate with the AccountingBook API endpoints, mainly used by Batuz Bizkaia and SII.
This DLL can be obtained by searching for Zucchetti.SDH.Client in the following NuGet repository:
NuGet – Zucchetti.SDH.Client
From Visual Studio it can be found as shown in the following image:

To use Solmicro.DigitalHub.Client.dll, you must instantiate it together with Newtonsoft.Json.dll and configure it as described below:
Authentication based on certificates accessible by the third-party application
string companyId = ""; // The unique identifier of the company
// Provided by SDH administrators
string installationId = ""; // The Installation identifier
// Provided by SDH administrators
// A companyId may have multiple installationId values
string serviceUrl = ""; // The SDH web service URL
SDHAuthorization auth = new ()
{
// Certificate instance
// Used to retrieve the certificate whose Thumbprint
// has been provided to SDH administrators
//
// new Certificate(x509Certificate2)
// new Certificate(serialNumberOrHash)
// new Certificate(fromFileName, passwordFromFileName)
};
InvoicingClient client = new InvoicingClient(); // For Invoicing endpoints
// AccountingBookClient client = new AccountingBookClient(); // For AccountingBook endpoints
client.Set(companyId, installationId, serviceUrl, auth);
Authentication based on Azure
string companyId = ""; // The unique identifier of the company
// Provided by SDH administrators
string installationId = ""; // The Installation identifier
// Provided by SDH administrators
string serviceUrl = ""; // The SDH web service URL
SDHAuthorization authAzureOption1 = new ()
{
clientId = "", // Azure client identifier
clientSecret = "" // Azure client secret
};
SDHAuthorization authAzureOption2 = new ()
{
clientId = "", // Azure client identifier
certificate =
// Certificate instance
//
// new Certificate(x509Certificate2)
// new Certificate(serialNumberOrHash)
// new Certificate(fromFileName, passwordFromFileName)
};
InvoicingClient client = new InvoicingClient(); // For Invoicing endpoints
// AccountingBookClient client = new AccountingBookClient(); // For AccountingBook endpoints
client.Set(companyId, installationId, serviceUrl, authOption);
Certificate Class
The Certificate class is used to obtain the certificate. It supports constructors with:
X509Certificate2: An object from the X509Certificate2 class.serialNumberOrHash: A string containing the SerialNumber or Thumbprint to locate the certificate installed in the user's personal store on the machine consuming the integration. It must be installed as exportable.fromFileNameandpasswordFromFileName: Path to a file containing the certificate, and the password for that certificate.