Admin Guide

Managing Videos, Homework & Tests

Each episode can contain three types of content: a video stream, homework assignments, and tests with auto-graded questions. This page covers how to create and manage all three.

Content Creation Workflow

Upload Video Stream URL, format, res Add Homework Title, instructions, score Build Test Questions, pass score Publish Channel Feed goes live on Roku STEP 1 STEP 2 STEP 3 STEP 4

Figure 5: Content Creation Workflow -- Video to Publish

Setting Up Video Streams

Each episode can have one video asset. The video is set up on the Video tab of the episode detail page.

  1. Navigate to the Episode Detail

    Go to /episodes/{episode_id} and ensure the Video tab is selected.

  2. Enter the Stream URL

    Provide the HLS (.m3u8), MP4, or DASH manifest URL. This URL should point to your CDN-hosted video file.

  3. Configure Format and Quality
    • Stream Format: HLS, MP4, or DASH
    • Resolution: 480p, 720p, 1080p, or 4K
    • Duration: Total duration in seconds
    • Content Rating: TV-G, TV-PG, TV-14, or TV-MA
  4. Add Metadata

    Set a short description (max 200 chars) and thumbnail URL. These appear in the Roku feed and student interface.

  5. Save

    Click Save Video. The video asset is created or updated (upsert behavior).

Bunny.net Integration: The platform has configuration slots for Bunny.net CDN (bunny_api_key, bunny_library_id, bunny_cdn_hostname) for video hosting. Once configured, you can use Bunny.net URLs as your stream URLs for optimal Roku playback.
bash
curl -X POST http://localhost:8065/api/episodes/{episode_id}/video \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "collection_item_id": "{episode_id}",
    "stream_url": "https://cdn.bunny.net/library/12345/video.m3u8",
    "stream_format": "HLS",
    "duration_seconds": 1800,
    "resolution": "1080p",
    "content_rating": "TV-G",
    "short_description": "Introduction to Physics",
    "thumbnail_url": "https://cdn.bunny.net/library/12345/thumb.jpg"
  }'

Creating Homework Assignments

Homework assignments are attached to episodes. Students must complete them after watching the associated video.

  1. Open the Homework Tab

    On the episode detail page, switch to the Homework tab.

  2. Click "Add Homework"

    The homework modal opens with the following fields:

    • Title (required): Assignment name
    • Description: Brief overview
    • Instructions: Detailed instructions for students
    • Max Score: Maximum points (default: 100)
    • Due Days After Watch: Deadline in days after video completion (default: 7)
    • Required: Whether this homework counts toward the grade
  3. Save the Homework

    Click Save. The assignment appears in the homework list.

Students submit homework through the student companion app. Submissions include text and optional attachment URLs. Admins then grade submissions manually.

bash
# Create homework for an episode
curl -X POST http://localhost:8065/api/episodes/{episode_id}/homework \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Physics Lab Report",
    "description": "Write a lab report on the demonstrated experiment",
    "instructions": "1. Describe the hypothesis\n2. Document observations\n3. State conclusions",
    "max_score": 100,
    "due_days_after_watch": 7,
    "is_required": true
  }'

# Grade a submission
curl -X PUT http://localhost:8065/api/episodes/homework/submissions/{id}/grade \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"score": 85, "feedback": "Excellent work on the hypothesis section."}'

Building Tests

Tests assess student understanding with auto-graded questions. The test system supports three question types.

Creating a Test

  1. Open the Test Tab

    On the episode detail page, switch to the Test tab.

  2. Click "Create Test"

    Configure the test settings:

    • Title (required): Test name
    • Time Limit: Minutes allowed (0 = unlimited)
    • Passing Score: Minimum percentage to pass (default: 70%)
    • Max Attempts: Number of retakes allowed (default: 3, 0 = unlimited)
    • Shuffle Questions: Randomize question order
    • Show Correct Answers: Reveal answers after attempt
  3. Save and Add Questions

    After saving the test, click the Questions button to open the question builder.

Question Types

TypeAuto-GradedHow to Set Up
Multiple Choice Yes Enter options one per line. Prefix the correct answer with * (e.g., *Correct Answer)
True / False Yes Options auto-fill as True/False. Mark the correct one with *
Short Answer Partial Enter the expected correct answer. Exact match comparison is case-insensitive

Question Builder Walkthrough

  1. Select Question Type

    Choose from the dropdown: Multiple Choice, True/False, or Short Answer.

  2. Enter Question Text

    Type the question in the text area.

  3. Set Answer Options

    For MC/TF: enter options one per line. Prefix correct answers with *. For Short Answer: enter the expected answer in the dedicated field.

  4. Configure Points and Explanation

    Set the point value (default: 1) and an optional explanation that can be shown after the attempt.

  5. Add the Question

    Click Add Question. It appears in the questions list with type badge and point value. Repeat for all questions.

Auto-Grading Behavior: Multiple choice and true/false questions are auto-graded immediately on submission. Short answer questions use case-insensitive exact matching. For more nuanced grading, review short answer responses manually.
bash
# Create a test
curl -X POST http://localhost:8065/api/episodes/{episode_id}/tests \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Physics Chapter 1 Quiz",
    "time_limit_minutes": 30,
    "passing_score": 70,
    "max_attempts": 3,
    "shuffle_questions": true
  }'

# Add a multiple choice question
curl -X POST http://localhost:8065/api/episodes/tests/{test_id}/questions \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "question_text": "What is the SI unit of force?",
    "question_type": "multiple_choice",
    "options": [
      {"text": "Newton", "is_correct": true},
      {"text": "Joule", "is_correct": false},
      {"text": "Watt", "is_correct": false},
      {"text": "Pascal", "is_correct": false}
    ],
    "points": 2,
    "explanation": "Newton (N) is the SI unit of force."
  }'