Skip to content

Tutorials

Learn Ambiten by building real systems instead of isolated examples.

Tutorials are designed to show how the runtime behaves across complete application workflows: context propagation, middleware execution, transactions, tenant isolation, instrumentation, and operational boundaries working together inside one system.

Stage 1HTTP Request

The request enters the framework with tenant and request metadata.

Stage 2Adapter

The framework request is normalized into Ambiten’s runtime shape.

Stage 3Adapter Runtime

Tenant identity, request metadata, and runtime options are resolved.

Stage 4AmbitenContext

A scoped execution boundary is created for the current async flow.

Stage 5Route / Resolver / Handler

Application logic calls models without manual infrastructure plumbing.

Stage 6AmbitenModel

The model receives the operation and binds it to the active runtime scope.

Stage 7Schema + Middleware

Validation, lifecycle hooks, and runtime policies execute around the operation.

Stage 8Infrastructure Resolution

The database, client, and session are resolved from the model context.

Stage 9AmbitenClient

The provider implementation bridges execution into the MongoDB driver.

Stage 10MongoDB

The database operation executes against the resolved tenant and collection scope.

Stage 11Result

Post-hooks, instrumentation, and response handling complete the request.

Why tutorials exist

Ambiten is not only a collection of APIs.

It is a runtime system.

Understanding individual methods is useful, but production behavior emerges from how execution boundaries interact across adapters, context, models, middleware, transactions, and infrastructure resolution.

That is why the tutorials focus on complete runtime flows rather than disconnected snippets.

The goal is to help you understand how systems remain predictable as they grow in complexity.

What you will learn

Each tutorial is built around a real architectural pattern rather than a synthetic example.

You will see how runtime context moves through requests, how middleware shapes behavior centrally, how tenant isolation remains enforced automatically, and how instrumentation exposes operational behavior without polluting business logic.

The tutorials also demonstrate how transactions, policies, and runtime guarantees interact under realistic workloads instead of only in simplified examples.

Learning structure

Every tutorial follows the same architectural progression.

PlainText
Product Definition
→ Data Modeling
→ Runtime Setup
→ Feature Workflows
→ Runtime Behavior
→ Operational Insight

This structure keeps the focus on execution behavior instead of only implementation details.

You are not only learning how to write features.

You are learning how those features behave inside a controlled runtime system.

Available tutorials

Available

Document-to-PDF SaaS

Build a tenant-aware SaaS product with tier policies, transaction-safe workflows, runtime instrumentation, and operational visibility.

Tenant isolationUsage policiesTransaction flow
Start tutorial
Planned

GraphQL Runtime

Expose Ambiten models through GraphQL while preserving context propagation, middleware behavior, and resolver-safe execution.

Resolver contextExecution flowPolicy enforcement
Coming soon
Planned

Multi-Tenant Platform

Design tenant-aware infrastructure with provider routing, runtime policy boundaries, and operational isolation strategies.

Tenant routingIsolation strategyRuntime policies
Coming soon
Planned

Background Workers

Run queues and scheduled jobs with explicit runtime scope so asynchronous execution remains observable and context-safe.

Worker scopeRetry handlingTrace continuity
Coming soon

Build a Document-to-PDF SaaS

This tutorial walks through a complete multi-tenant SaaS application with tenant-aware execution, transaction-safe workflows, instrumentation-driven observability, and usage-tier enforcement.

The system includes real operational concerns such as usage limits, upgrade flows, runtime policy enforcement, and request-scoped execution behavior.

Instead of treating Ambiten as an isolated data layer, the tutorial demonstrates how the runtime coordinates the entire execution path.

Start tutorial

What makes these tutorials different

Most tutorials on the web focus on calling APIs.

Ambiten tutorials focus on execution architecture.

The emphasis is on runtime boundaries, operational correctness, scalability, and system behavior under production conditions rather than only showing how to invoke methods.

That distinction matters because most complexity in modern systems comes from execution coordination, not from individual database calls.

When to use tutorials

Tutorials are most useful when you want to understand how multiple runtime concepts work together inside a complete application.

They are especially useful if you want to:

  • move beyond isolated examples
  • understand request-scoped execution
  • study multi-tenant runtime behavior
  • see how instrumentation and middleware interact
  • learn how Ambiten behaves under realistic architectural conditions

For lower-level API details, use the core documentation and reference sections.

Summary

Tutorials are where the Ambiten runtime becomes concrete.

They demonstrate how context propagation, middleware, transactions, instrumentation, and tenant-aware execution combine to support real production-style systems instead of isolated code samples.

Next step

Build a Document-to-PDF SaaS

Context-aware execution infrastructure for multi-tenant systems.