Connecting Microsoft Sharepoint to Haiilo's AI Assistant

To enable Haiilo's AI Assistant to use content from your Microsoft SharePoint sites, you'll want to set up an app registration with Microsoft and add credentials to Haiilo. 

When Microsoft is connected to the AI Assistant, your users can get answers from supported text-based files (e.g., PDFs, Word documents, PowerPoint presentations, and text files). By default, all documents across SharePoint are considered, but you can optionally limit indexing to specific SharePoint sites in the configuration. Users will only have access to the information they have permission to access on Microsoft.

You cannot use the same app registration as the one you use for authentication, user directories, and M365 add-on features. You need to create a new one.

Set up an app registration in Microsoft

You need admin rights in your Microsoft Entra ID account to complete these steps.

Create an app

  1. Log in to the Microsoft Azure Platform.
  2. Go to Microsoft Entra ID > App registrations > New registration.
  3. Give your app a name, e.g., Haiilo AI Assistant sync.
  4. For Supported account types, choose Single tenant.
  5. Select Register.
  6. On the app Overview page, copy and save the Application (client) ID and Directory (tenant) ID for later use.

App registration overview page in Microsoft Azure.png

Define API permissions

  1. Go to API permissions.
  2. Select Add a permission > Microsoft Graph > Application permissions.
  3. Add the following API permissions:
    • Directory.Read.All
    • Sites.Read.All
  4. Then, select Add a permission > Microsoft SharePoint > Application permissions.
  5. Add the following API permission:
    • Sites.Read.All
    • Alternatively, if your access is managed by SharePoint Groups, add the permission Sites.FullControl.All instead.
  6. Select Grant admin consent for app_name for the added permissions and ensure the status for all permissions is marked Granted for your_tenant.

Create certificate (OpenSSL)

You'll need to create a certificate that Microsoft can use to verify the app registration. The public certificate (.crt) is uploaded to Microsoft Entra ID, while the combined certificate file (.pem) is added to the Haiilo configuration.

  1. Before you begin: Install OpenSSL if it's not already available on your system. Then open a command line tool, such as PowerShell on Windows or Terminal on macOS.
  2. Run the following commands to generate the certificate files required for the Microsoft integration. The file names, certificate name, and validity period used in the examples below can be adjusted to match your requirements.
    1. Generate a private key: openssl genrsa -out azure-app.key 2048. This creates a 2048-bit private key file named azure-app.key.
    2. Create a self-signed public certificate: openssl req -new -x509 -key azure-app.key -out azure-app.crt -days 365 -subj "/CN=HaiiloAzureAppCert". This creates a certificate file named azure-app.crt that is valid for 365 days. 
    3. Combine the private key and certificate into a PEM file: cat azure-app.key azure-app.crt > azure-app.pem. This creates a file named azure-app.pem that contains both the private key and the certificate, and will be used when configuring the Microsoft integration in Haiilo.
  3. Then, in your Microsoft app registration, go to Certificates & secrets.
  4. Select Upload certificate and choose the created .crt file. Optionally, define a description.
  5. Select Add.

After completing these steps, keep the .pem file available. You'll need it in the next step.

Configure the content type on Haiilo

You need "Manage AVA" permission to configure these settings.

  1. In Haiilo, go to Administration AVA > AI Assistant.

  2. Toggle Enable Microsoft integration.

  3. Input the Directory (tenant) ID that you copied from Microsoft Entra ID into the Tenant ID field.
  4. Input the Application (client) ID that you copied from Microsoft Entra ID into the Client ID field.
  5. Enter the certificate value from the created .pem file into the Certificate (PEM) field.
  6. Optionally, limit the indexing to only certain SharePoint sites. If left blank, all sites are indexed.
  7. Select Save changes to apply.

Was this article helpful?

0 out of 0 found this helpful