Loading...
  • Customer Experience
    Customer Experience
  • Employee Experience
    Employee Experience
  • Brand Experience
    Brand Experience
  • Product Experience
    Product Experience
  • Core XM
    Core XM

Importing Custom Topics

What's on This Page:


Was this helpful?


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

The feedback you submit here is used only to help improve this page.

That’s great! Thank you for your feedback!

Thank you for your feedback!


About Importing Custom Topics

With the Sensitive Data Policy feature, you can import custom topics you want to be flagged when users in your brand are building surveys, when users collect data, and when respondents are providing answers to a survey. This page describes how to format a JSON file to successfully import these topics.

When using a JSON file, the topics you import are always added as new topics, not added onto existing similar ones. For example, if you manually selected Social Security as a topic and then imported a JSON file with a topic called Social Security that had additional key words, you would have two Social Security topics in your Sensitive Data Policy. This does not hurt the tool’s ability to check your brand for privacy violations in any way.

Qtip: This feature is NOT related to Text iQ Topics. Only Brand Administrators have access to this feature.
Attention: Sensitive Data Policy is not available to all brands. Please contact your Account Executive or Customer Success Representative if you are interested in gaining access.

Editing the JSON File

  1. Enter the name of your first topic.
  2. Enter the keywords. Each should be in quotes and be separated by a comma.
  3. Enter the Regex.
    Qtip: Keywords are used to flag potentially problematic questions, and regexes are used to flag problematic responses. If you would like something to be flagged in both places, you should add keywords and regexes.
  4. Enter an example of this Regex you have defined.
  5. Enter additional Regex, if your topic has more than one possible format.
  6. Name the category the topic belongs to.
  7. Enter the tags for this category. Each should be in quotes and be separated by a comma.
  8. Enter a custom message, if desired.
  9. Separate additional topics by a comma.
  10. Create your second topic, following the format described in steps 1-9.
  11. End your JSON file with a bracket.
Qtip: Pay careful attention to where brackets begin and end! Indenting lines can help you align where brackets open and close.

Formatting a JSON File for Import

This section will go over how to format a JSON file so you can import custom topics into your PII checker.

Below is an example of a completed JSON file, indicating where one custom topic (Social Security Number) ends, and the other (First name) begins.

File Type and Program

Click Example to download an example of a JSON file. Please do not deviate from the format provided.

You can create and edit JSON files in any text editor program on your desktop. For example, TextEdit, Sublime Editor, or Notepad++.

Name and Keywords of Topics

These are custom topics – that means you can name them whatever you want! For example, you may want to make sure users on your brand don’t try to collect Social Security Numbers. You could call the topic “Social Security Number.”

The keywords are then how you identify someone is trying to collect a Social Security Number. To flag a question, you might look for the keywords “ssid,” “ssn,” and “social security number.” These keywords are not case sensitive.


  {
    "name": "Social Security Number",
    "keywords": {
      "default": [
        "social security number",
        "ssn",
        "ssid"
      ]
    }

Category and Tags for Topics

Categories are a means of organizing the different topics you’d like Qualtrics to flag. Like names, categories can also be called whatever you want. For example, for the topic “First name,” the category might be “Global,” since this is revealing and private information across the globe, and will apply to users collecting data in any region. In contrast, “Social Security Number” might be categorized as “USPII,” since U.S. implies it’s a U.S. classification system, and PII implying it is very private and protected information.

Tags are to help you search and define a given category. For USPII, the tags may be “US,” “government,” and “ID.”


    "category": "USPII",
    "tags": [
      "US",
      "Government",
      "ID"
    ]

Custom Message

You can define a custom message that appears to your users whenever they try to use flagged keywords in their survey.

If you do not want to include a custom message, you can simply eliminate this field from the file.


    "customKeywordMessage": {
      "message": "this is a custom keyword message"
    }

Regex

Regex (short for “regular expression”) defines parameters for topic values.

Attention: Regex is always evaluated case-insensitively when used here.

For example, think of a question such as, “What is your phone number?” For U.S. phone numbers, we only want answers that contain numbers, and we don’t want it to be more than ten digits long.


    "regexes": {
      "default": [
        {
          "value": "^\\d{3}-\\d{3}-\\d{4}$",
          "examples": [
            "123-456-7890"
          ]
        },
        {
          "value": "^\\d{10}$",
          "examples": [
            "1234567890"
          ]
        }

Qualtrics Support is unable to advise on regex, since it is technically custom coding. However, you can check out these resources for more help:

Example of Complete JSON File

[
  {
    "name": "Social Security Number",
    "keywords": {
      "default": [
        "social security number",
        "ssn",
        "ssid"
      ]
    },
    "regexes": {
      "default": [
        {
          "value": "^\\d{3}-\\d{2}-\\d{4}$",
          "examples": [
            "123-45-6789"
          ]
        },
        {
          "value": "^\\d{9}$",
          "examples": [
            "123456789"
          ]
        }
      ]
    },
    "category": "USPII",
    "tags": [
      "US",
      "Government",
      "ID"
    ],
    "customKeywordMessage": {
      "message": "this is a custom keyword message"
    }
  },
  {
    "name": "First name",
    "keywords": {
      "default": [
        "first name"
      ]
    },
    "regexes": {
      "default": [
        {
          "value": "/first name/i",
          "examples": [
            "first name"
          ]
        }
      ]
    },
    "category": "Global",
    "tags": []
  }
]

Importing Multiple Custom Topics

  1. Go to the Admin page.
    Going to the data privacy tab
  2. Select the Data Privacy tab.
  3. Go to the Sensitive Data Policy section.
  4. Click Add Custom Topic.
  5. Click Import Topics.
  6. Click Example to download an example json file.
    Import window
  7. Format your JSON file following the directions on this page.
  8. Click Browse to upload your finished JSON.
  9. Click Import.

Adding a Single Custom Topic

  1. Go to the Admin page.
    Navigating to sensitive data of data privacy admin tab
  2. Select the Data Privacy tab.
  3. Go to the Sensitive Data Policy section.
  4. Click Add Custom Topic.
  5. Select Add Custom Topic.
  6. Name your topic.
    Fields at top of edit custom topic window
  7. Select a category for this topic.
  8. Add a description. This is optional, but can help clarify what this topic is for to toher Brand Admins.
  9. Download the Example.
    further down, under Dictionary Detector section
  10. Edit your JSON to include a list of keywords. Do not worry about regex; that will be the next step.
    Qtip: This JSON formatting is similar to what is explained earlier on the page, but only pertains to one topic and its associated keywords per file, not multiple topics.
  11. Click Browse to upload your file.
  12. Click Add Expression to add Regex.  The left Regular Expression field will contain the Regex itself, while the right Examples field allows you to give an example that matches the Regex set.
    Shows what dictionary looks like uploaded, as well as regex

    Qtip: Qualtrics Support is unable to advise on regex, since it is technically custom coding. However, you can check out these resources for more help:

    Attention: Regex is always evaluated case-insensitively here.
  13. If you wish for this custom topic to have its sensitive data be redacted from survey builders, select Override Global Policy Settings under the Policy Settings header, then select the next option. Learn more about global and specific topic redaction on Global vs. Topic Redaction.
    Policy Settings at the bottom of the window
  14. Click Save.

Qtip: Use the Test this topic section to test random phrases and words for how they flag. This can help you figure out if you set up your custom topic correctly.

Test this Topic field. Blue test button. Red this phrase was not flagged by the system error message