Skip to main content
Use the BookStack Connector to ingest content from BookStack into the mAItion knowledge base.

What It Does

  • fetches shelves, books, chapters, and pages from a BookStack instance via its REST API
  • converts page content to Markdown for indexing, preferring BookStack’s native Markdown and falling back to converted HTML
  • resolves each item’s owning shelf, even for books, chapters, and pages where the API doesn’t return shelf_id directly
  • runs ingestion on configurable schedules

Required Environment Variables

Set these in .env.rag:
  • BOOKSTACK1_BASE_URL: base URL of your BookStack instance (example: https://wiki.example.com)
  • BOOKSTACK1_TOKEN_ID: API token ID
  • BOOKSTACK1_TOKEN_SECRET: API token secret
  • BOOKSTACK1_SCHEDULES: ingestion interval in seconds (default: 3600)
Generate an API token from your BookStack user profile page (Edit Profile → API Tokens). The token owner must have the Access System API permission, otherwise BookStack rejects API requests.

config.yaml Example

.env.rag Example

Configuration Reference

Multiple BookStack Sources

Add more sources entries (bookstack2, bookstack3, etc) with separate env vars per source.