Question T4603
Visible to All Users

Evaluate Survey outside of browser

created 5 years ago

We have a use case for SurveyJS in which it would be useful to take a survey definition and a set of answers, and evaluate that survey with those answers outside of the browser in server side code to find the values of the surveys calculatedValues with those given answers.

Is there a way to create the survey model and interrogate its calculated values outside of the browser?

We have a commercial license for the editor if that's relevant.

Answers approved by surveyjs Support

created 5 years ago

Hello Julian,
You are talking about SurveyJS Library, and it is under MIT license.
You can use SurveyJS Model without browser. All our Unit Tests (about 2,000) are written in this way. You can create SurveyModel:
var survey = new Survey.SurveyModel(yourJSON); and then use survey API to do what you need. cacluated values will work. You can review our unit tests, for example this file to better understand the idea.

Thank you,
Andrew
SurveyJS Team