AnnA Corporate User
Anna Corporate User is a resource that makes possible for you to create corporate users and generate an authentication hash for the specified user
Using AnnaCorporateUserClient class
Section titled “Using AnnaCorporateUserClient class”This class will provide you methods to create, update or inactivate a corporate user in AnnA.
Example:
var corporateUserClient = new AnnaCorporateUserClient("YOUR_ANNA_ENVIRONMENT_BASE_URL", new AnnaCorporateUserClientConfig { CompanyHash = "YOURCOMPANYHASH", EncryptionKey = "YOUR_CORPORATEUSER_ENCRYPTION_KEY", DecryptionKey = "YOUR_CORPORATEUSER_DECRYPTION_KEY", });Generate user hash
Section titled “Generate user hash”This method generates a hash for AnnA Embedded Chat authentication.
string response = corporateUserClient.GenerateUserHash("YOUR_CORPORATE_USER_ID");if you want the AnnA Chat to execute a service when it opens, you can provide the start service parameter.
string response = corporateUserClient.GenerateUserHash("YOUR_CORPORATE_USER_ID", "@START_SERVICE");Update/Create user
Section titled “Update/Create user”This method update/insert a corporate user in AnnA and generates a hash for AnnA Embedded Chat authentication.
string response = corporateUserClient.UpsertCorporateUser(new CorporateUser { UserId = "USER_ID", Username = "USERNAME" });Inactivate user
Section titled “Inactivate user”This method inactivates a corporate user in AnnA
string response = corporateUserClient.InactivateUser("USER_ID");