Skip to content

Configuration - Vainu

This section describes how you configure ACD for Vainu. You need to configure ACD in these places:

Runtime Configuration

ACD uses Vainu API to provide company data. It's a one-to-one mapping between Lime CRM's company limetype and Vainu's /companies/ endpoint.

To see available mapping properties, head over to Vainu's Swagger documentation and look at the fields under Response Schema. When you map Vainu´s data to Lime properties in the configuration, you should be aware that although the helper text suggests to use worksites, this is not supported by the Vainu API, and you do not have to add a prefix to your field.

Example

This is a complete Vainu provider specific configuration for ACD. See general configuration for a description of each parameter.

{
  "mapping": [
    {
      "limeProperty": "name",
      "providerProperty": "company_name"
    },
    {
      "limeProperty": "postaladdress1",
      "providerProperty": "address"
    },
    {
      "limeProperty": "postalzipcode",
      "providerProperty": "postal"
    },
    {
      "limeProperty": "postalcity",
      "providerProperty": "city"
    },
    {
      "limeProperty": "visitingaddress1",
      "providerProperty": "visiting_address"
    },
    {
      "limeProperty": "visitingzipcode",
      "providerProperty": "visiting_postal"
    },
    {
      "limeProperty": "visitingcity",
      "providerProperty": "visiting_city"
    },
    {
      "limeProperty": "www",
      "providerProperty": "link"
    },
    {
      "limeProperty": "phone",
      "providerProperty": "phone"
    },
    {
      "limeProperty": "acd_vatno",
      "providerProperty": "business_id"
    },
    {
      "limeProperty": "acd_email",
      "providerProperty": "email"
    },
    {
      "limeProperty": "acd_unitstatus",
      "providerProperty": "status"
    },
    {
      "limeProperty": "acd_legalform",
      "providerProperty": "form_of_company"
    },
    {
      "limeProperty": "acd_turnover",
      "providerProperty": "turn_over"
    },
    {
      "limeProperty": "acd_turnovercurrency",
      "providerProperty": "currency_code"
    },
    {
      "limeProperty": "acd_noofemployeescompany",
      "providerProperty": "staff_number"
    }
  ],
  "propertiesToPopulateSearchWith": {
    "searchText": [
      "name"
    ]
  },
  "limetypeCompany": "company",
  "propertyProviderId": "acd_id",
  "propertyLastUpdated": "acd_lastupdated",
  "propertyResponsible": "coworker",
  "propertySavingError": "acd_errormessage",
  "provider": "vainu",
  "customCommandId": "",
  "propertyName": "name",
  "vainu": {
      "country": "NL"
  },
  "last_checked_for_updates": "2022-06-10 07:10:03"
}

Application Configuration

ACD is using the application level configuration in order to configure API credentials for Vainu.

Windows on-premise Installations

For Windows on-premise installations, the application level configuration is expressed in the file:

%ProgramData%\Lundalogik\LIME Pro Server\application_config.yaml

Add the following to the application_config.yaml file:

<application-name>:
  secrets:
    addon-acd:
      vainu:
        credentials:
          api_key: <api-key>

Restart the web server.

Cloud

For Cloud installations, the application level configuration is configured in CAFE (Cloud Administration).

Add the following to the Secret box in the application configuration in CAFE:

addon-acd:
  vainu:
    credentials:
      api_key: <api-key>

View Configuration

Add ACD's web component and the newly created fields to the company view configuration as described below.

Company

Card

Note

Remember to do this for all existing variants.

  1. Add ACD's web component acd-update-object as a widget on the card view configuration. image

  2. Add the following as a section to your card view configuration.

        {
          "title": "Vainu Information",
          "controls": [
            {
              "property": "acd_unitstatus",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_email",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_vatno",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_legalform",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_turnover",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_turnovercurrency",
              "readonly": true,
              "visibleOnCreate": false
            },
            {
              "property": "acd_noofemployeescompany",
              "readonly": true,
              "visibleOnCreate": false
            }
          ]
        }
    

Table

Add the following as column properties to the table view configuration.

    {
      "property": "acd_lastupdated",
      "isDefault": false
    },
    {
      "property": "acd_email",
      "isDefault": false
    },
    {
      "property": "acd_vatno",
      "isDefault": false
    },
    {
      "property": "acd_legalform",
      "isDefault": false
    },
    {
      "property": "acd_turnover",
      "isDefault": false
    },
    {
      "property": "acd_turnovercurrency",
      "isDefault": false
    },
    {
      "property": "acd_noofemployeescompany",
      "isDefault": false
    }