Skip to main content
Estimated Time: 10-15 minutes Prerequisites: Working Conductor project

What You’ll Learn

By the end of this guide, you’ll understand how to:
  • πŸ“– Create a docs/ directory with auto-discovered markdown pages
  • ✍️ Write markdown documentation with frontmatter
  • 🎨 Customize themes and navigation via ensemble config
  • πŸ” Control documentation access with triggers
  • πŸ”„ Use Handlebars templating for dynamic content

Understanding Documentation in Conductor

The docs/ directory is a first-class component directory in Conductor, just like agents/ and ensembles/. It provides:
  • Auto-discovered markdown pages - Just add .md files
  • Built-in docs-serve ensemble - Handles HTTP routing automatically
  • Multiple UI frameworks (Stoplight, Redoc, Swagger, Scalar, RapiDoc)
  • Auto-generated navigation from file structure
The docs-serve ensemble is included in Conductor’s system templates. It automatically handles routing docs to /docs/* paths.

Step 1: Create the docs/ Directory

Initialize Your Docs

Create the docs directory with your first markdown file:
Create docs/getting-started.md:
Production: https://api.example.com Development: http://localhost:8787

3. Handle the Response

Visit the documentation:
You should see your markdown pages rendered along with auto-generated API documentation!

Step 2: Add More Documentation Pages

Create an Authentication Page

Create docs/authentication.md:

Token Expiration

Tokens expire after 30 days. Refresh them via the dashboard.

Theme Configuration

Configure the appearance via the ensemble’s flow[].config.theme:

Choose a UI Framework

Step 4: Control Access

Public Documentation

The default docs-serve uses public: true on the trigger:

Authenticated Documentation

For authenticated docs, create a custom ensemble:
The public: false setting enforces authentication. Conductor validates Bearer tokens or API keys from request headers automatically.

Step 5: Use Handlebars Templating

Dynamic Content

Your markdown pages support Handlebars:

Variables

Variables come from your configuration context. These are passed through the docs agent’s config.

Step 6: Navigation Configuration

Organize into sections via the ensemble config:

Reserved Sections

Conductor auto-generates sections for your agents and ensembles:

Accessing Your Documentation

Directory Structure

A well-organized docs directory:

Troubleshooting

Problem: /docs returns 404Solutions:
  1. Verify docs/ directory exists with at least one .md file
  2. Rebuild to trigger auto-discovery:
  3. Check logs for errors:
Problem: Markdown pages not showing in navigationSolutions:
  1. Check frontmatter syntax (must start with ---)
  2. Verify file extension is .md
  3. Check hidden: true isn’t set in frontmatter
  4. Rebuild the project
Problem: Can’t access authenticated docsSolutions:
  1. Verify trigger has public: false
  2. Configure auth rules in conductor.config.ts
  3. Test with correct headers:
Problem: Theme colors not showingSolutions:
  1. Verify theme section in ensemble config
  2. Check hex colors include # prefix
  3. Clear browser cache

Best Practices

Documentation

βœ… Do:
  • Keep pages focused and scannable
  • Include code examples for every endpoint
  • Use frontmatter for consistent metadata
  • Version your documentation with your API
❌ Don’t:
  • Write walls of text without headings
  • Skip authentication documentation
  • Include internal endpoints in public docs
  • Forget to update docs when API changes

Security

βœ… Do:
  • Use separate ensembles for public and internal documentation
  • Configure authentication via triggers
  • Sanitize examples (remove real API keys)
❌ Don’t:
  • Expose admin endpoints publicly
  • Include real tokens in examples

Summary

You’ve learned how to:
  • βœ… Create a docs/ directory with markdown files
  • βœ… Write markdown pages with frontmatter
  • βœ… Customize themes and navigation via ensemble config
  • βœ… Control access with trigger configuration
  • βœ… Use Handlebars for dynamic content
The docs/ directory is a first-class component in Conductor - just add your markdown files and they’re automatically discovered and served!

Next Steps

Documentation Reference

Complete configuration options

Your First Agent

Create AI-powered agents

Your First Ensemble

Orchestrate multi-agent workflows

Security & Authentication

Secure your APIs and documentation