Andamio Logo
Developer Guides

Your First Andamio App

Learn Andamio by building — create a course and enroll your first student

Your First Andamio App

Create a course, add a module, enroll as a student, and submit an assignment — all on preprod.

Time: ~30 minutes. Prerequisite: Getting Started.

Start from the template: Clone the andamio-app-template to follow along. It includes production-ready hooks for transaction handling — see the How Transactions Work section for details.


Step 1: Understand the Transaction Flow

Every action in Andamio follows the same pattern:

Your App → Gateway (build) → Wallet (sign) → Gateway (submit) → Cardano
  1. Build: Your app requests a transaction from the Gateway
  2. Sign: The user signs with their wallet
  3. Submit: The signed transaction goes back to the Gateway
  4. Confirm: The Gateway submits to Cardano and tracks confirmation

Step 2: Create a Course

Open your app template at localhost:3000 and navigate to the course creation page.

If you don't see course creation options, your Access Token may not have course creator permissions. On preprod, you can grant yourself permissions — see Course Creator Setup below.

What happens on-chain

When you create a course, Andamio:

  • Mints a Course Token representing your course
  • Creates a Course State UTxO holding course metadata
  • Links your Access Token as the course creator

This is your first real transaction. Watch the confirmation — it takes about 20 seconds on preprod.


Step 3: Add a Module

Courses contain modules. Each module can have:

  • Learning content (off-chain, referenced by hash)
  • Assignments (on-chain commitments)

Add a simple module to your course. The module metadata lives off-chain, but the module's existence is recorded on-chain.


Step 4: Enroll as a Student

Now switch perspectives. Using a different wallet (or the same one on a test course), enroll as a student.

What happens on-chain

Enrollment creates:

  • A Student Token linking you to the course
  • An Enrollment UTxO tracking your progress

You now have an on-chain relationship with the course.


Step 5: Submit an Assignment

Complete the loop by submitting an assignment. This demonstrates the full Andamio workflow:

  1. Student submits work (reference to off-chain content)
  2. Transaction records submission on-chain
  3. Course creator can now review and accept/reject

Summary

ActionOn-chain Result
Create courseCourse Token + Course State UTxO
Add moduleModule reference in course state
Enroll studentStudent Token + Enrollment UTxO
Submit assignmentAssignment UTxO with submission reference

Every interaction follows the same build → sign → submit pattern. The Gateway handles transaction construction; your app handles UX.

Next Steps


Appendix: Course Creator Setup

On preprod, you can grant course creator permissions to your Access Token:

  1. Go to preprod.app.andamio.io
  2. Connect your wallet
  3. Navigate to Admin → Permissions
  4. Add your Access Token as a course creator

This is a preprod convenience — on mainnet, permissions are managed by instance administrators.