younifyd
Menu

Create or replace quiz

Create or replace quiz

PUT/v1/quizzes/{quiz_id}

Use it in a workflow

  1. Add a step and choose the Constructor connector.
  2. Pick the Create or replace quiz action (under Quizzes).
  3. Fill in the fields below, then reference the result from later steps as {{createOrReplaceQuiz.response.data}}.

Request

Path parameters

quiz_idstringrequired

Query parameters

sectionstring

The section of the index to use. Defaults to `Products`.

Request body

Enter the body as JSON in the step's Body field.

display_namestringrequired

Name of the quiz to be displayed to end users

activeboolean

Identifies whether quiz should be displayed or not

Default true

logicobject

Logic that is used when going through quiz

questionsarray<oneOf>

A list of questions of the quiz

Default []

results_configany

Results configuration for the quiz

metadata_jsonobject

Metadata related to the quiz and its questions.

pre_filter_expressionobject

Pre-filter expression to be applied to all questions.

json
{
  "display_name": "string",
  "active": true,
  "logic": {},
  "questions": [],
  "results_config": null,
  "metadata_json": {},
  "pre_filter_expression": {}
}

Response

Returns 200 with an object. Read it in later steps with {{createOrReplaceQuiz.response.data.<field>}}.

display_namestring

Name of the quiz to be displayed to end users

activeboolean

Identifies whether quiz should be displayed or not

Default true

idstring

ID of the quiz.

questionsarray<oneOf>

A list of questions of the quiz

logicobject

Logic that is used when going through quiz

created_atstring (date-time)

Quiz creation date in ISO 8601 format

updated_atstring (date-time)

Last quiz update date in ISO 8601 format.

results_configany

Results configuration for the quiz

metadata_jsonobject

Metadata related to the quiz and its questions.

pre_filter_expressionobject

Pre-filter expression to be applied to all questions.

json
{
  "display_name": "string",
  "id": "string",
  "created_at": "2025-01-01T00:00:00Z",
  "updated_at": "2025-01-01T00:00:00Z",
  "active": true,
  "questions": [
    null
  ],
  "logic": {},
  "results_config": null,
  "metadata_json": {},
  "pre_filter_expression": {}
}

Need more? See the Constructor guide for connection setup and behaviour shared by every action.