What is a survey's default block ID? | XM Community
Skip to main content
Question

What is a survey's default block ID?

  • 4 March 2022
  • 3 replies
  • 170 views

I've been going through the Qualtrics API. When dealing with creating qualtrics blocks (https://api.qualtrics.com/api-reference/b3A6NjEwODA-create-block), one parameter that I am required to give is a default block id. I can't for the life of me find out what that is, or where to find it. Any ideas?

3 replies

Badge +31

Hello ks376 you can open support mode by pressing ctrl+shift and clicking on tools. Opt for support mode and go to survey flow to view the block ID.

Badge +3

Aanurag_QC I tried that and it only showed me the flow IDs next to each block, as well as a weird decimal number like 0.05, 0.4, etc.
E.g. FL_2 - 0.1

Badge +1

Hi, not sure if you still need help with this, but for those also looking for an answer:

 

When you create a survey using the API, print out the response data. One of the objects will contain the default block ID.

 

e.g.,:

 

import http.client

conn = http.client.HTTPSConnection("your_datacenter_here.qualtrics.com")

payload = "{\n  \"SurveyName\": \"string\",\n  \"Language\": \"AR\",\n  \"ProjectCategory\": \"CORE\"\n}"

headers = {

    'Content-Type': "application/json",

    'Accept': "application/json",

    'X-API-TOKEN': "your_API_token"

}

conn.request("POST", "/API/v3/survey-definitions", payload, headers)

res = conn.getresponse()

data = res.read()

print(data.decode("utf-8")) # This will return the DefaultBlockID

 

The last string in the print statement will contain the default block ID.

Leave a Reply