TypeSafeSDK.Question (TypeSafeSDK v0.2.0)

Copy Markdown View Source

Question validation and legacy wire normalization. Strict evaluation uses TypeSafeSDK.Prepared.

Summary

Functions

Validates one question with strict semantic rules, without sending HTTP.

Validates and returns the question, or raises a path-aware SDK error.

Types

Functions

normalize_questions(questions)

@spec normalize_questions(map()) :: {:ok, map()} | {:error, TypeSafeSDK.Error.t()}

validate(question)

@spec validate(term()) :: :ok | {:error, TypeSafeSDK.Error.t()}

Validates one question with strict semantic rules, without sending HTTP.

validate!(question)

@spec validate!(term()) :: term()

Validates and returns the question, or raises a path-aware SDK error.