StoryCAD API

The StoryCAD mascot, a writer shouldering a giant pencil

Programmatic story outlining for .NET. StoryCADLib lets you build, analyze, and transform .stbx story outlines from your own code, in console apps, web APIs, batch jobs, and AI agents, with no UI required.

Every outline is a StoryModel: a tree of typed story elements, such as characters, scenes, problems, and settings, that each API call reads from or writes to.

It’s the same engine that powers StoryCAD, a free, open-source outlining tool for fiction writers, exposed as a headless library and published on NuGet.

What the API does

  • Manage outlines: create, open, and save .stbx story outlines.
  • Work with elements: add and edit characters, scenes, problems, settings, and more, then search and link them together.
  • Apply story structure: drive beat sheets and master plots from built-in writing-craft data.
  • Run headless: use it in console apps, web APIs, and batch pipelines without a window.
  • Integrate with AI: pre-built Semantic Kernel functions and an MCP server expose the API to Claude Desktop, Claude Code, and other agents.

Every operation returns an OperationResult<T>. Check IsSuccess before reading Payload.

Get started

Where to find more

Concepts covers the data model and terminology: the StoryModel, the eleven element types, and the built-in resource data. The Glossary defines the terms used across this site. Operations holds task-oriented how-tos for search, resource workflows, and beat sheets, while Samples has runnable code and the API Reference documents every method. Semantic Kernel and MCP integration live under Advanced.

License

StoryCADLib is released under the GNU GPL v3 license.