Skip to main content

Add Survey Translations Walkthrough

Step 1. Create a Survey with Default Language​

The Create Survey API endpoint requires the Language parameter in order to set the default language of the survey. We will use English for our Default Survey Language in the following examples.

curl -X POST -H 'X-API-TOKEN: <API Token>' -H 'Content-Type: application/json' -d '{
"SurveyName":"CSAT Survey",
"Language":"EN",
"ProjectCategory":"CORE"
}' https://{env}.qualtrics.com/API/v3/survey-definitions

Change your Default Survey Language​

You can specify a unique Default Language by setting the Language parameter on survey creation. You can also update a survey's Default Language using Update Options SurveyLanguage parameter.

Step 2. Enable an Additional Language on Your Survey​

Update Languages will walk you through how to do this. Here's a synopsis:

curl -XPUT -H '<API Token>' -H 'Content-Type: application/json'  https://co1.qualtrics.com/API/v3/surveys/SV_eJaSDWOzgn2X2V7/languages -d '{
"AvailableLanguages": [
"EN",
"ES",
"FR"
]
}'

Step 3. Add Translations to the Survey​

As usual, you can do this in multiple ways depending on the state of your survey.

Option 1. Create Question with Translations​

Here we will create a Question with both French FR and Spanish ES translations. We use the Language field to specify our translations for each language.

curl -XPOST -H 'X-API-TOKEN: <API Token>' -H 'Content-Type: application/json' https://co1.qualtrics.com/API/v3/survey-definitions/SV_eJaSDWOzgn2X2V7/questions -d '{
"QuestionText": "What is your favorite color?",
"DataExportTag": "Q2",
"QuestionType": "MC",
"Selector": "SAVR",
"SubSelector": "TX",
"Configuration": {
"QuestionDescriptionOption": "UseText"
},
"QuestionDescription": "What is your favorite color?",
"Choices": {
"1": {
"Display": "red"
},
"2": {
"Display": "green"
},
"3": {
"Display": "blue"
}
},
"ChoiceOrder": [
"1",
"2",
"3"
],
"Validation": {
"Settings": {
"ForceResponse": "OFF",
"ForceResponseType": "ON",
"Type": "None"
}
},
"Language": {
"FR": {
"QuestionText": "Quelle est votre couleur préférée?",
"Choices": {
"1": {
"Display": "rouge"
},
"2": {
"Display": "vert"
},
"3": {
"Display": "bleu"
}
}
},
"ES": {
"QuestionText": "¿Cuál es tu color favorito?",
"Choices": {
"1": {
"Display": "Rojo"
},
"2": {
"Display": "Verde"
},
"3": {
"Display": "Azul"
}
}
}
},
"QuestionID": "QID2"
}'

Option 2. Update Translations for a Language​

You can also modify the translations for a given Language across all Survey elements by using the Update Survey Translations endpoint.

Here's a quick example where we fix the capitalization of the colors in Spanish from Option 1 above.

curl -XPUT -H '<API Key>' -H 'Content-Type: application/json' https://co1.qualtrics.com/API/v3/surveys/SV_eJaSDWOzgn2X2V7/translations/ES -d '{
"QID1_QuestionText": "¿Cuál es tu color favorito?",
"QID1_Choice1": "rojo",
"QID1_Choice2": "verde",
"QID1_Choice3": "azul"
}'