Classification

Manifest

The manifest describes the parameters the Uniform tracker uses during the classification process. The settings included in the manifest are defined in a Uniform project under the sections Personalization and Testing.

Classification criteria is configured within Uniform, but that information is used outside of Uniform. For example, in order for the client-side tracker to classify visitors, the tracker must know what the classification rules are. The Uniform manifest is the way that information is provided to components that exist outside of Uniform.

The manifest is generated using the Uniform CLI.

The Uniform manifest is a JSON file that describes the classification rules that are configured in Uniform. In order for the Uniform tracker to classify a visitor, it needs to know this configuration. As a result, the Uniform tracker needs the manifest.

Uniform's classification and personalization features depend on the Context manifest. The manifest is used for client-side tracking and edge-side personalization.

You may want to retrieve the manifest when you build your front-end application or the application that runs edge-side personalization so it can be packaged along with the application.

These steps will you to download the manifest to a file manifest.json from a terminal.

  1. If it's not already installed, install the CLI.

  2. If it's not already installed, install the package @uniformdev/context globally.

  3. Create an API key with the following permissions:

    • Uniform Context > Manifest > Read
    • Run the following command:

    What has changed

    When the command finishes, a file manifest.json is created.

These steps will allow you to download the manifest to a file manifest.json using an npm script.

  1. If it's not already installed, install the CLI.

  2. If it's not already installed, install the package @uniformdev/context in the project. Create an API key with the following permissions:

    • Uniform Context > Manifest > Read
  3. Add the following file:

  4. Make the following change:

  5. You can run the command from a terminal, or as a part of another npm script using the following command:

    What has changed

    When the command finishes, a file manifest.json is created.

This section describes how to add a script that downloads the manifest to a Node project. Your CI/CD process can trigger the script in order to automate downloading the manifest.

Prerequisites

These instructions assume you already have a Node project and a Uniform project.

  1. Make sure the following dependencies are included in your Node project. If you need to add them, you can add them as developer dependencies:

  2. Make sure you have a .env file with the values needed to connect to your Uniform project.

  3. Add the following script to your package.json file:

    package.json

  4. To download the manifest, run the following command.

    Download manifest

    About this step

    A file named manifest.json is created in the root folder of your Node project.

The intent manifest is usually retrieved as a part of the build process for the front-end application using an npm script to call the Uniform CLI. However, it can be retrieved in other ways as well.