docs/ directory is a first-class component directory in Conductor that serves interactive API documentation. It auto-generates OpenAPI 3.1 specifications from your ensembles and agents, supports markdown documentation pages with Handlebars templating, and serves them through multiple documentation UIs.
Features
- First-class component directory - Just like
agents/andensembles/,docs/is a dedicated directory - Auto-generated OpenAPI specs - Scans your ensembles and agents to create accurate API docs
- Markdown documentation - Write
.mdfiles with frontmatter for custom pages - Multiple UI frameworks - Stoplight Elements, Redoc, Swagger UI, Scalar, RapiDoc
- Custom branding - Add your logo, colors, and styling
- Built-in caching - Fast documentation serving with optional KV caching
- Authentication - Public, authenticated, or admin-only documentation
- Handlebars templating - Dynamic content with variables
New to docs? Check out Your First Documentation for a comprehensive step-by-step guide.
Directory Structure
How It Works
Documentation is served via the built-indocs-serve ensemble which handles HTTP routing automatically. Your markdown files in docs/ are auto-discovered at build time.
Basic Setup
- Create markdown files in
docs/:
- Start the dev server:
- Access your docs:
Customizing Documentation
To customize your documentation, create a custom docs ensemble. This is where you configure themes, navigation, and UI framework. Createensembles/docs-custom.yaml:
Configuration Reference
All configuration is passed via the ensembleβsflow[].config:
Route Configuration
Control where and how docs are served via the trigger:public: false setting enforces authentication. Conductor validates Bearer tokens or API keys from request headers automatically.
UI Framework
Choose your preferred documentation UI:Theme & Branding
Customize the appearance:Navigation Configuration
Control how documentation pages are organized:Navigation Groups
Organize pages into collapsible groups:Caching
Enable caching for better performance:AI Enhancement
Use AI to improve documentation descriptions:Server URLs
Specify API server URLs in OpenAPI spec:Content Filtering
Control which endpoints appear in docs:Writing Documentation Pages
Markdown with Frontmatter
Create.md files in the docs/ directory:
Frontmatter Options
Handlebars Templating
Use Handlebars syntax for dynamic content:Reserved Routes
These routes are automatically generated:
Control visibility in your docs ensemble config:
Complete Example
Createensembles/docs-complete.yaml:
Global Configuration
You can also configure docs globally inconductor.config.ts:
Accessing Documentation
Best Practices
Organization
Security
- Use authentication for sensitive documentation
- Filter endpoints with
include/excludein config - Separate docs ensembles for different audiences
Performance
- Enable caching for production
- Use CDN through Cloudflare
- Minimize custom CSS
Troubleshooting
Docs Not Showing
- Verify
docs/directory exists with at least one.mdfile - Rebuild the project:
pnpm run build - Review logs for errors:
Authentication Issues
- Verify auth configuration
- Test with correct headers:
Pages Not Appearing
- Check frontmatter syntax is valid
- Verify file extension is
.md - Check
hideconfig doesnβt exclude the page
Next Steps
Your First Documentation
Step-by-step guide to setting up docs
Agents Overview
Learn about creating agents
Ensembles
Orchestrate multi-agent workflows
Security & Authentication
Secure your documentation

