ZoltarQuestionData

Creates immutable, content-addressed scalar or categorical questions and exposes their display metadata. ZoltarQuestionData source contract

Read surface

Use getQuestionId before submission; questionCreatedTimestamp and questions for direct lookup; getQuestionCount and getQuestions for indexed or paged discovery; and getQuestionEndDate, getOutcomeLabels, splitUint256IntoTwoWithInvalid, hasNonZeroScalarReservedBits, isMalformedAnswerOption, and getAnswerOptionName when validating or displaying answers. In the QuestionData tuple, startTime and endTime are uint48, while numTicks is uint120; clients must use these exact widths because they determine the getQuestionId and createQuestion selectors.

State-changing interactions

Transaction Caller Main prerequisites State or asset effect Primary signals
createQuestion(questionData, outcomeOptions) Anyone Question ID not already created; end time is on or after start time. Scalar questions use no labels, require display maximum greater than minimum, and positive ticks. Categorical questions require nonempty labels whose keccak256(abi.encode(label)) values are strictly descending. Stores the question at its deterministic content hash, records the creation timestamp, appends it to discovery order, and stores categorical labels when supplied. QuestionCreated