Customizing the Web Interface through the API

Using the API to update your web interface's color scheme can be done easily and without having to restart any services or have any downtime. Some of these customizations can be done through the web interface of Files Advanced.

Installing CURL

  1. You will need to install Curl in order to use any API commands.
    1. Download Curl from the official site at: https://curl.haxx.se/download.html

      Note: Make sure to download a version that supports SSL!

    2. Follow the prompts from the Curl installer until the installation is finished or just extract the Curl archive.

Creating a custom color scheme

  1. Open an elevated command prompt and enter the following command:

    curl -X PUT -F customization_settings[color_scheme_administration_css_file]=@<path_to_file> -F customization_settings[color_scheme_client_scss_file]=@<path_to_file> -u <user>:<password> https://<your_site>/api/v1/settings/customization -v

    Note: The filenames have to use a specific naming syntax! color_scheme_<name_of_scheme>.css for the Administration console and web_client_<name_of_scheme>.scss for the Web client console. <name_of_scheme> is the name of your new scheme which will be displayed in the Files Advanced interface and it must be the same for both files.

    The above command will:

  2. Here is an example of how the command looks if you want to upload a scheme for the Administration part of the interface and a scheme for the web client that are located.
  3. In this example both files are located in D:\WebUI and we pick NewColor as the color scheme name that will be visible in the web interface:

    curl -X PUT -F customization_settings[color_scheme_administration_css_file]=@D:\WebUI\color_scheme_NewColor.css -F customization_settings[color_scheme_client_scss_file]=@D:\WebUI\web_client_NewColor.scss -u administrator:123456 https://myCompany.com/api/v1/settings/customization

  4. You can also use the -F customization_settings[color_scheme]=<name_of_scheme> command to switch your current theme to the new theme you are adding. Adding this command to the rest looks like this:

    curl -X PUT -F customization_settings[color_scheme_administration_css_file]=@D:\WebUI\color_scheme_NewColor.css -F customization_settings[color_scheme_client_scss_file]=@D:\WebUI\web_client_NewColor.scss -F customization_settings[color_scheme]=NewColor -u administrator:123456 https://myCompany.com/api/v1/settings/customization -v

Troubleshooting