;

Update Test Settings

Update test settings for given test.

Update test settings for given test. Partial update is not supported. You need to first call “Get Test Settings” (unless you’ve done that already), store values or use somewhere in page, and send request with whole object along with changes values in remaining sub-objects.

Also, please note that, certain settings have some rules they obey like Allow Copy Paste which disable window violation popup. Please refer to app.interviewmocha UI for understanding features.

POST https://apiv3.interviewmocha.com/v3/tests/{testId}/settings
  • Docs
  • Try it
Request URL Parameters
Field Type Required Default Description
testId Integer64 Yes - Unique identifier of the test
Request Body Parameters
Field Type Required Default Description
testName String Yes - -
testAliasName String Yes - -
typeOfTest Integer Yes - -
practiceTest Integer Yes - -
randomQuestions Integer Yes 0 -
randomAnswers Integer Yes 0 -
showQuestionScore Integer Yes - -
sectionEndPopup Integer Yes 0 -
sectionTimeLeftAlert Integer Yes 0 -
candidateFeedback Integer Yes 0 -
sendTestReportEmailToCandidate Integer Yes 0 -
terminateTestOnImageViolation Integer Yes 0 -
terminateTestAfterViolationCount Integer Yes 0 - -
Example API endpoint

URL 1: /v3/tests/{testId}/settings

Sample Request Body
Request Body
{ "testSettings": { "testName": "A11", "testAliasName": "A11", "typeOfTest": 1, "practiceTest": 1 }, "questionSettings": { "randomQuestions": 0, "randomAnswers": 0, "showQuestionScore": 0 }, "displayMessageSettings": { "sectionEndPopup": 0, "sectionTimeLeftAlert":0, "candidateFeedback": 0 }, "emailSettings": { "sendTestReportEmailToCandidate": 0 }, "imageProctoringSettings": { "terminateTestOnImageViolation": 0, "terminateTestAfterViolationCount": 1 }, "windowViolationSettings": { "copyPaste": 0, "displayViolationSettings": { "displayViolationPopUp": 1, "terminateTestOnWindowViolation": 1, "terminateTestAfterViolationCount": 1 } } }
Successful response

Status 201 Created

Response
{ "testSettings": { "testName": "A11", "testAliasName": "A11", "typeOfTest": 1, "practiceTest": 1 }, "questionSettings": { "randomQuestions": 1, "randomAnswers": 1, "showQuestionScore": 1 }, "displayMessageSettings": { "sectionEndPopup": 1, "sectionTimeLeftAlert": 1, "candidateFeedback": 1 }, "emailSettings": { "sendTestReportEmailToCandidate": 0 }, "imageProctoringSettings": { "terminateTestOnImageViolation": 1, "terminateTestAfterViolationCount": 5 }, "windowViolationSettings": { "copyPaste": 1, "displayViolationSettings": { "displayViolationPopUp": 1, "terminateTestOnWindowViolation": 1, "terminateTestAfterViolationCount": 3 } } }
Failed response

Status 400 Bad Request

If required parameters have invalid values.

Response
{ "errors": [ "'Email' must not be empty.", "Email address is in invalid format" ] }
Parameter Value Description Parameter Type Data Type
testId test Id associated with particular test Query Integer64
testName Body String
testAliasName Body String
typeOfTest Body Integer
practiceTest Body Integer
randomQuestions Body Integer
randomAnswers Body Integer
showQuestionScore Body Integer
sectionEndPopup Body Integer
sectionTimeLeftAlert Body Integer
candidateFeedback Body Integer
sendTestReportEmailToCandidate Body Integer
terminateTestOnImageViolation Body Integer
terminateTestAfterViolationCount Body Integer
copyPaste Body Integer
displayViolationPopUp Body Integer
terminateTestOnWindowViolation Body Integer
terminateTestAfterViolationCount Body Integer
  • Response Body