Instruqt Labs (beta)
  • Instruqt
  • Getting started
    • Setting up Version Control
    • Install Instruqt CLI
    • Creating your first lab
    • Configuration basics
    • Exploring the lab configuration
    • Adding your first chapter
    • Configuring sandboxes
    • Adding quizzes
    • Adding tasks and gating content
    • Finishing up
  • Documentation
    • Writing Lab Content
      • Project Structure
      • Markdown and Components
    • Integrations
      • Version Control
    • Lab reference
      • Content
        • Lab
        • Page
        • Activities
          • Task
          • Quiz
            • Multiple Choice
            • Single Choice
            • Text Answer
            • Numeric Answer
        • Layout
        • Tabs
          • Terminal
          • Service
          • Editor
          • External Website
          • Note
      • Sandbox
        • Containers
          • Container
          • Sidecar Container
        • Kubernetes
          • Cluster
          • Config
          • Helm
        • Nomad
          • Cluster
          • Job
        • Networking
          • Network
          • Ingress
        • Cloud Accounts
          • AWS
          • Azure
          • Google Cloud
        • Terraform
        • Template
        • Exec
        • Copy
        • Certificates
          • Root
          • Leaf
        • Random
          • Number
          • ID
          • UUID
          • Password
          • Creature
      • Functions
    • Tools
      • Instruqt CLI
    • Glossary
Powered by GitBook
On this page
  • TextAnswerQuestion
  • Examples
Edit on GitHub
Export as PDF
  1. Documentation
  2. Lab reference
  3. Content
  4. Activities
  5. Quiz

Text Answer

TextAnswerQuestion

A question that requires a text answer.


resource "text_answer_question" "name" {
  ...
}

Attributes

Attribute
Description

Question question type: string

The question that needs to be answered.

Answer answer type: string

The correct answer to the question.

Exact exact type: bool

Whether the answer needs to be an exact match.

Hints hints type: []string

The hints to show to the participants.

Tags tags type: []string

The tags to associate with the question.

Computed Attributes

These attributes are computed when the config is parsed and applied, and are therefore only known at parsetime or runtime.

Attribute
Description

Meta ID meta.id string

The full ID of the resource e.g. `resource.type.name`. This is computed from the full resource path:

Meta Type meta.type string

The type of the resource. This taken from the type label of the resource definition.

Meta Name meta.name string

The name of the resource. This taken from the name label of the resource definition.

Examples

Full Example

resource "text_answer_question" "capital_france" {
	question = "What is the capital of France?"
	answer ="Paris"
	hints = [
    "They host the olympics in 2024",
		"The city is known for the Eiffel Tower"
	]
}
PreviousSingle ChoiceNextNumeric Answer

Last updated 1 month ago

question = "What language do they speak in France?"
answer = "French"
exact = false
hints = ["it starts with an 'f'", "it ends with 'rench'"]
tags = ["languages", "europe"]
// given the following resource
resource "container" "ubuntu" {
  ...
}

// the resulting id will be
resource.container.ubuntu
// given the following resource
resource "container" "ubuntu" {
  ...
}

// the resulting type will be
container
// given the following resource
resource "container" "ubuntu" {
  ...
}

// the resulting name will be
ubuntu