@bpmnkit/docspack 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (173) hide show
  1. package/.llms/chunks/cli.casen.aikit-skills.md +19 -0
  2. package/.llms/chunks/cli.casen.bpmn-generation-pipeline.md +32 -0
  3. package/.llms/chunks/cli.casen.connection-profiles.md +62 -0
  4. package/.llms/chunks/cli.casen.generate-bpmn-files.md +28 -0
  5. package/.llms/chunks/cli.casen.md +80 -0
  6. package/.llms/chunks/cli.casen.plugins.md +56 -0
  7. package/.llms/chunks/cli.casen.worker-commands.md +45 -0
  8. package/.llms/chunks/cli.connector.all-flags.md +29 -0
  9. package/.llms/chunks/cli.connector.browse-the-bundled-ootb-catalog.md +32 -0
  10. package/.llms/chunks/cli.connector.built-in-catalog.md +41 -0
  11. package/.llms/chunks/cli.connector.common-workflows.md +50 -0
  12. package/.llms/chunks/cli.connector.generate-from-the-openapi-catalog.md +30 -0
  13. package/.llms/chunks/cli.connector.md +20 -0
  14. package/.llms/chunks/cli.connector.programmatic-usage.md +7 -0
  15. package/.llms/chunks/cli.connector.what-gets-generated.md +20 -0
  16. package/.llms/chunks/cli.generate.definition-mode-ai-scripting-path.md +89 -0
  17. package/.llms/chunks/cli.generate.md +52 -0
  18. package/.llms/chunks/cli.generate.modify-existing-mode-input.md +59 -0
  19. package/.llms/chunks/cli.generate.typical-ai-workflow.md +18 -0
  20. package/.llms/chunks/cli.plugin-authoring.md +59 -0
  21. package/.llms/chunks/cli.plugin-authoring.plugin-naming-conventions.md +11 -0
  22. package/.llms/chunks/cli.plugin-authoring.test-locally.md +41 -0
  23. package/.llms/chunks/cli.plugin-authoring.the-bpmnkit-cli-sdk-sdk.md +82 -0
  24. package/.llms/chunks/cli.plugin-authoring.what-gets-generated.md +69 -0
  25. package/.llms/chunks/cli.plugin-authoring.writing-commands.md +84 -0
  26. package/.llms/chunks/cli.plugins.bpmnkit-casen-report.md +39 -0
  27. package/.llms/chunks/cli.plugins.bpmnkit-casen-worker-http.md +23 -0
  28. package/.llms/chunks/cli.plugins.md +25 -0
  29. package/.llms/chunks/cli.skills.deploy.md +24 -0
  30. package/.llms/chunks/cli.skills.implement.md +36 -0
  31. package/.llms/chunks/cli.skills.md +29 -0
  32. package/.llms/chunks/cli.skills.no-mcp-server-required.md +6 -0
  33. package/.llms/chunks/cli.skills.review.md +33 -0
  34. package/.llms/chunks/cli.skills.test.md +33 -0
  35. package/.llms/chunks/cli.view.folder-support.md +31 -0
  36. package/.llms/chunks/cli.view.md +70 -0
  37. package/.llms/chunks/cli.view.tabbed-navigation.md +28 -0
  38. package/.llms/chunks/getting-started.concepts.ai-compact-format.md +23 -0
  39. package/.llms/chunks/getting-started.concepts.auto-layout.md +24 -0
  40. package/.llms/chunks/getting-started.concepts.parsing-and-serializing.md +26 -0
  41. package/.llms/chunks/getting-started.concepts.the-fluent-builder.md +41 -0
  42. package/.llms/chunks/getting-started.concepts.zeebe-extensions.md +25 -0
  43. package/.llms/chunks/getting-started.installation.md +38 -0
  44. package/.llms/chunks/getting-started.installation.runtime-requirements.md +13 -0
  45. package/.llms/chunks/getting-started.installation.svg-canvas-viewer.md +41 -0
  46. package/.llms/chunks/getting-started.installation.worker-client.md +40 -0
  47. package/.llms/chunks/getting-started.quick-start.md +31 -0
  48. package/.llms/chunks/getting-started.quick-start.step-2-simulate-locally.md +28 -0
  49. package/.llms/chunks/getting-started.quick-start.step-3-deploy-to-camunda-8.md +33 -0
  50. package/.llms/chunks/getting-started.quick-start.what-s-next.md +14 -0
  51. package/.llms/chunks/guides.ai-agents.deploy-grade-validation.md +19 -0
  52. package/.llms/chunks/guides.ai-agents.how-it-s-modeled.md +11 -0
  53. package/.llms/chunks/guides.ai-agents.md +18 -0
  54. package/.llms/chunks/guides.ai-agents.see-also.md +7 -0
  55. package/.llms/chunks/guides.ai-agents.testing-without-a-real-llm-call.md +26 -0
  56. package/.llms/chunks/guides.ai-agents.the-aiagent-plan-step.md +62 -0
  57. package/.llms/chunks/guides.ai-implement.deploying.md +49 -0
  58. package/.llms/chunks/guides.ai-implement.extending-an-existing-process.md +10 -0
  59. package/.llms/chunks/guides.ai-implement.lightweight-alternative-casen-skills-install.md +28 -0
  60. package/.llms/chunks/guides.ai-implement.md +32 -0
  61. package/.llms/chunks/guides.ai-implement.the-claude-code-plugin.md +21 -0
  62. package/.llms/chunks/guides.ai.claude-api-example.md +41 -0
  63. package/.llms/chunks/guides.ai.mcp-server.md +20 -0
  64. package/.llms/chunks/guides.ai.md +32 -0
  65. package/.llms/chunks/guides.ai.minimal-empty-diagram.md +32 -0
  66. package/.llms/chunks/guides.ai.openai-function-calling.md +40 -0
  67. package/.llms/chunks/guides.building-processes.boundary-events.md +47 -0
  68. package/.llms/chunks/guides.building-processes.call-activities.md +47 -0
  69. package/.llms/chunks/guides.building-processes.events.md +57 -0
  70. package/.llms/chunks/guides.building-processes.multi-instance.md +20 -0
  71. package/.llms/chunks/guides.building-processes.service-tasks.md +39 -0
  72. package/.llms/chunks/guides.building-processes.sub-processes.md +40 -0
  73. package/.llms/chunks/guides.building-processes.task-defaults.md +18 -0
  74. package/.llms/chunks/guides.claude-code-plugin.ambient-hooks.md +24 -0
  75. package/.llms/chunks/guides.claude-code-plugin.configuration.md +126 -0
  76. package/.llms/chunks/guides.claude-code-plugin.md +47 -0
  77. package/.llms/chunks/guides.claude-code-plugin.reference-docs.md +61 -0
  78. package/.llms/chunks/guides.deployment.ci-cd-deploy-on-push.md +47 -0
  79. package/.llms/chunks/guides.deployment.deploying-a-process.md +52 -0
  80. package/.llms/chunks/guides.deployment.handling-jobs.md +50 -0
  81. package/.llms/chunks/guides.deployment.managing-incidents.md +33 -0
  82. package/.llms/chunks/guides.deployment.md +49 -0
  83. package/.llms/chunks/guides.gateways.branching-inside-sub-processes.md +27 -0
  84. package/.llms/chunks/guides.gateways.exclusive-gateway-xor.md +41 -0
  85. package/.llms/chunks/guides.gateways.inclusive-gateway-or.md +43 -0
  86. package/.llms/chunks/guides.gateways.nested-branching.md +27 -0
  87. package/.llms/chunks/guides.gateways.parallel-gateway-and.md +26 -0
  88. package/.llms/chunks/guides.patterns.how-matching-works.md +17 -0
  89. package/.llms/chunks/guides.patterns.md +26 -0
  90. package/.llms/chunks/guides.patterns.pattern-schema.md +38 -0
  91. package/.llms/chunks/guides.patterns.see-also.md +7 -0
  92. package/.llms/chunks/guides.patterns.using-patterns-from-the-cli.md +30 -0
  93. package/.llms/chunks/guides.patterns.what-a-pattern-contains.md +18 -0
  94. package/.llms/chunks/guides.simulation.dmn-decision-evaluation.md +51 -0
  95. package/.llms/chunks/guides.simulation.instance-state.md +29 -0
  96. package/.llms/chunks/guides.simulation.md +51 -0
  97. package/.llms/chunks/guides.simulation.message-correlation.md +30 -0
  98. package/.llms/chunks/guides.simulation.multiple-deployments.md +14 -0
  99. package/.llms/chunks/guides.workers-standalone.anatomy-of-a-worker.md +42 -0
  100. package/.llms/chunks/guides.workers-standalone.camunda-saas.md +43 -0
  101. package/.llms/chunks/guides.workers-standalone.environment-variables.md +14 -0
  102. package/.llms/chunks/guides.workers-standalone.md +35 -0
  103. package/.llms/chunks/guides.workers-standalone.running-workers.md +61 -0
  104. package/.llms/chunks/guides.workers-standalone.see-also.md +7 -0
  105. package/.llms/chunks/packages.api.incident-resolution.md +31 -0
  106. package/.llms/chunks/packages.api.observability-events.md +13 -0
  107. package/.llms/chunks/packages.api.overview.md +49 -0
  108. package/.llms/chunks/packages.api.process-operations.md +60 -0
  109. package/.llms/chunks/packages.api.resource-namespaces.md +20 -0
  110. package/.llms/chunks/packages.canvas.events.md +56 -0
  111. package/.llms/chunks/packages.canvas.options.md +24 -0
  112. package/.llms/chunks/packages.canvas.overview.md +35 -0
  113. package/.llms/chunks/packages.connector-gen.body-expansion.md +18 -0
  114. package/.llms/chunks/packages.connector-gen.catalog-reference.md +54 -0
  115. package/.llms/chunks/packages.connector-gen.catalogentry-type.md +21 -0
  116. package/.llms/chunks/packages.connector-gen.generating-from-the-catalog.md +44 -0
  117. package/.llms/chunks/packages.connector-gen.installation.md +42 -0
  118. package/.llms/chunks/packages.connector-gen.lower-level-api.md +31 -0
  119. package/.llms/chunks/packages.connector-gen.overview.md +16 -0
  120. package/.llms/chunks/packages.connector-gen.writeoptions.md +26 -0
  121. package/.llms/chunks/packages.core.dmn-support.md +36 -0
  122. package/.llms/chunks/packages.core.installation-bpmn.creatediagram-id.md +18 -0
  123. package/.llms/chunks/packages.core.installation-bpmn.createprocess-id-name.md +10 -0
  124. package/.llms/chunks/packages.core.installation-bpmn.export-definitions.md +10 -0
  125. package/.llms/chunks/packages.core.installation-bpmn.makeempty-processid-processname.md +11 -0
  126. package/.llms/chunks/packages.core.installation-bpmn.parse-xml.md +10 -0
  127. package/.llms/chunks/packages.core.installation-bpmn.sample_xml.md +7 -0
  128. package/.llms/chunks/packages.core.installation-compactify-definitions.md +13 -0
  129. package/.llms/chunks/packages.core.installation-expand-compact.md +13 -0
  130. package/.llms/chunks/packages.core.installation-layoutprocess-process.md +15 -0
  131. package/.llms/chunks/packages.core.installation-processbuilder-methods.md +29 -0
  132. package/.llms/chunks/packages.core.installation.md +11 -0
  133. package/.llms/chunks/packages.core.overview.md +15 -0
  134. package/.llms/chunks/packages.docspack.installation.md +45 -0
  135. package/.llms/chunks/packages.docspack.overview.md +23 -0
  136. package/.llms/chunks/packages.docspack.reading-it-yourself.md +34 -0
  137. package/.llms/chunks/packages.docspack.trust.md +13 -0
  138. package/.llms/chunks/packages.docspack.using-the-index-directly.md +52 -0
  139. package/.llms/chunks/packages.editor.basic-setup.md +41 -0
  140. package/.llms/chunks/packages.editor.full-editor-with-all-plugins.md +30 -0
  141. package/.llms/chunks/packages.editor.hud-options.md +41 -0
  142. package/.llms/chunks/packages.editor.overview.md +21 -0
  143. package/.llms/chunks/packages.engine.installation.md +77 -0
  144. package/.llms/chunks/packages.engine.overview.md +19 -0
  145. package/.llms/chunks/packages.engine.processinstance.md +17 -0
  146. package/.llms/chunks/packages.engine.variable-scoping.md +27 -0
  147. package/.llms/chunks/packages.worker-client.client.poll-jobtype-options.md +40 -0
  148. package/.llms/chunks/packages.worker-client.createworkerclient-options.md +32 -0
  149. package/.llms/chunks/packages.worker-client.job.complete-variables.md +29 -0
  150. package/.llms/chunks/packages.worker-client.md +33 -0
  151. package/.llms/chunks/packages.worker-client.oauth2-camunda-saas.md +26 -0
  152. package/.llms/chunks/packages.worker-client.see-also.md +7 -0
  153. package/.llms/manifest.json +2083 -0
  154. package/LICENSE +21 -0
  155. package/README.md +150 -0
  156. package/dist/build.d.ts +29 -0
  157. package/dist/build.js +89 -0
  158. package/dist/chunk.d.ts +41 -0
  159. package/dist/chunk.js +242 -0
  160. package/dist/cli.d.ts +9 -0
  161. package/dist/cli.js +160 -0
  162. package/dist/index.d.ts +13 -0
  163. package/dist/index.js +12 -0
  164. package/dist/load.d.ts +27 -0
  165. package/dist/load.js +144 -0
  166. package/dist/search.d.ts +53 -0
  167. package/dist/search.js +104 -0
  168. package/dist/text.d.ts +22 -0
  169. package/dist/text.js +204 -0
  170. package/dist/types.d.ts +48 -0
  171. package/dist/types.js +3 -0
  172. package/llms.txt +174 -0
  173. package/package.json +76 -0
@@ -0,0 +1,56 @@
1
+ # @bpmnkit/canvas — Events
2
+
3
+ ```typescript
4
+ canvas.on("diagram:load", () => {
5
+ console.log("Diagram loaded");
6
+ });
7
+
8
+ canvas.on("diagram:change", () => {
9
+ console.log("Diagram modified");
10
+ });
11
+ ```
12
+
13
+
14
+ ## Plugins
15
+
16
+ The canvas accepts an array of plugins that can extend its behavior:
17
+
18
+ ```typescript
19
+ import { BpmnCanvas } from "@bpmnkit/canvas";
20
+ import { createMinimapPlugin } from "@bpmnkit/canvas-plugin-minimap";
21
+ import { createZoomControlsPlugin } from "@bpmnkit/canvas-plugin-zoom-controls";
22
+
23
+ const canvas = new BpmnCanvas({
24
+ container: document.getElementById("canvas"),
25
+ plugins: [
26
+ createMinimapPlugin(),
27
+ createZoomControlsPlugin(),
28
+ ],
29
+ });
30
+ ```
31
+
32
+ ### Plugin interface
33
+
34
+ ```typescript
35
+ type CanvasPlugin = {
36
+ name: string;
37
+ install(api: CanvasApi): void;
38
+ uninstall?(): void;
39
+ };
40
+ ```
41
+
42
+ ### Available plugins
43
+
44
+ | Package | Description |
45
+ |---|---|
46
+ | `@bpmnkit/canvas-plugin-minimap` | Overview minimap |
47
+ | `@bpmnkit/canvas-plugin-zoom-controls` | Zoom in/out buttons |
48
+ | `@bpmnkit/canvas-plugin-command-palette` | Keyboard command palette |
49
+ | `@bpmnkit/canvas-plugin-storage` | File persistence (IndexedDB) |
50
+ | `@bpmnkit/canvas-plugin-tabs` | Multi-file tab bar |
51
+ | `@bpmnkit/canvas-plugin-process-runner` | In-browser simulation controls |
52
+ | `@bpmnkit/canvas-plugin-token-highlight` | Visual token tracking |
53
+ | `@bpmnkit/canvas-plugin-ai-bridge` | AI chat integration |
54
+
55
+ ---
56
+ Source: https://docs.bpmnkit.com/packages/canvas/
@@ -0,0 +1,24 @@
1
+ # @bpmnkit/canvas — Options
2
+
3
+ ```typescript
4
+ type CanvasOptions = {
5
+ container: HTMLElement;
6
+ theme?: "dark" | "light";
7
+ plugins?: CanvasPlugin[];
8
+ };
9
+ ```
10
+
11
+
12
+ ## API
13
+
14
+ | Method | Description |
15
+ |---|---|
16
+ | `canvas.loadXML(xml)` | Load and render a BPMN XML string |
17
+ | `canvas.getXML()` | Return the currently loaded XML |
18
+ | `canvas.setTheme(theme)` | Switch between dark and light theme |
19
+ | `canvas.on(event, handler)` | Subscribe to canvas events |
20
+ | `canvas.off(event, handler)` | Unsubscribe a handler |
21
+ | `canvas.destroy()` | Clean up the canvas and remove from DOM |
22
+
23
+ ---
24
+ Source: https://docs.bpmnkit.com/packages/canvas/
@@ -0,0 +1,35 @@
1
+ # @bpmnkit/canvas — Overview
2
+
3
+ `@bpmnkit/canvas` is a lightweight BPMN 2.0 diagram viewer that renders to SVG.
4
+ It has no runtime dependencies and works in any browser environment.
5
+
6
+ **Features:**
7
+ - SVG rendering of all standard BPMN 2.0 element types
8
+ - Pan and zoom (mouse wheel, touch pinch, keyboard)
9
+ - Dark and light theme
10
+ - Plugin API for extending rendering and behavior
11
+ - `diagram:load` and `diagram:change` events
12
+
13
+
14
+ ## Installation
15
+
16
+ ```sh
17
+ pnpm add @bpmnkit/canvas
18
+ ```
19
+
20
+
21
+ ## Basic Usage
22
+
23
+ ```typescript
24
+ import { BpmnCanvas } from "@bpmnkit/canvas";
25
+
26
+ const canvas = new BpmnCanvas({
27
+ container: document.getElementById("canvas"),
28
+ theme: "dark", // "dark" | "light"
29
+ });
30
+
31
+ await canvas.loadXML(bpmnXml);
32
+ ```
33
+
34
+ ---
35
+ Source: https://docs.bpmnkit.com/packages/canvas/
@@ -0,0 +1,18 @@
1
+ # @bpmnkit/connector-gen — Body expansion
2
+
3
+ By default the request body is a single FEEL `Text` field accepting a JSON expression. With
4
+ `expandBody: true`, top-level properties of the request body schema become individual typed input
5
+ fields — `String`, `Number`, or `Boolean`:
6
+
7
+ ```typescript
8
+ // Default: one body field
9
+ generate(spec, { idPrefix: "com.myorg" })
10
+ // → body: Text (FEEL expression)
11
+
12
+ // Expanded: one field per top-level body property
13
+ generate(spec, { idPrefix: "com.myorg", expandBody: true })
14
+ // → to: String, subject: String, html: String, ...
15
+ ```
16
+
17
+ ---
18
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,54 @@
1
+ # @bpmnkit/connector-gen — Catalog reference
2
+
3
+ Use `CATALOG` and `getCatalogEntry` to inspect or extend the catalog programmatically:
4
+
5
+ ```typescript
6
+ import { CATALOG, getCatalogEntry } from "@bpmnkit/connector-gen"
7
+
8
+ // List all entries
9
+ for (const entry of CATALOG) {
10
+ console.log(entry.id, entry.name, entry.defaultAuth)
11
+ }
12
+
13
+ // Look up one entry
14
+ const stripe = getCatalogEntry("stripe")
15
+ // → { id: "stripe", name: "Stripe API", url: "...", idPrefix: "io.stripe", defaultAuth: "basic" }
16
+ ```
17
+
18
+ ### Built-in entries
19
+
20
+ | ID | Name | Default auth |
21
+ |---|---|---|
22
+ | `github` | GitHub REST API | bearer |
23
+ | `cloudflare` | Cloudflare API | bearer |
24
+ | `stripe` | Stripe API | basic |
25
+ | `notion` | Notion API | bearer |
26
+ | `resend` | Resend Email API | bearer |
27
+ | `openai` | OpenAI API | bearer |
28
+ | `figma` | Figma API | bearer |
29
+ | `twilio` | Twilio Messaging API | basic |
30
+ | `slack` | Slack Web API | bearer |
31
+ | `jira` | Atlassian Jira API | bearer |
32
+ | `hubspot` | HubSpot CRM API | oauth-client-credentials-flow |
33
+ | `discord` | Discord API | bearer |
34
+ | `pagerduty` | PagerDuty API | apiKey |
35
+ | `zoom` | Zoom API | oauth-client-credentials-flow |
36
+ | `mailchimp` | Mailchimp API | apiKey |
37
+ | `asana` | Asana API | bearer |
38
+ | `sendgrid` | SendGrid Mail API | bearer |
39
+ | `paypal` | PayPal Payments API | oauth-client-credentials-flow |
40
+ | `plaid` | Plaid API | apiKey |
41
+ | `vercel` | Vercel API | bearer |
42
+ | `anthropic` | Anthropic API | apiKey |
43
+ | `shopify` | Shopify Admin API | bearer |
44
+ | `datadog` | Datadog API | apiKey |
45
+ | `sentry` | Sentry API | bearer |
46
+ | `intercom` | Intercom API | bearer |
47
+ | `contentful` | Contentful Management API | bearer |
48
+ | `airtable` | Airtable API | bearer |
49
+ | `twitch` | Twitch Helix API | oauth-client-credentials-flow |
50
+ | `klaviyo` | Klaviyo API | apiKey |
51
+ | `brex` | Brex API | oauth-client-credentials-flow |
52
+
53
+ ---
54
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,21 @@
1
+ # @bpmnkit/connector-gen — `CatalogEntry` type
2
+
3
+ ```typescript
4
+ interface CatalogEntry {
5
+ id: string
6
+ name: string
7
+ description: string
8
+ url: string // OpenAPI spec download URL
9
+ idPrefix: string // suggested reverse-DNS prefix
10
+ defaultAuth: AuthHint
11
+ }
12
+ ```
13
+
14
+
15
+ ## CLI
16
+
17
+ The same functionality is available via `casen connector generate` and `casen connector catalog`.
18
+ See the [CLI reference](/cli/connector/).
19
+
20
+ ---
21
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,44 @@
1
+ # @bpmnkit/connector-gen — Generating from the catalog
2
+
3
+ The built-in catalog provides spec URLs and auth defaults for 100 popular APIs:
4
+
5
+ ```typescript
6
+ import { generateFromCatalog } from "@bpmnkit/connector-gen"
7
+
8
+ // Use catalog defaults
9
+ const { templates, files, entry } = await generateFromCatalog("stripe", {
10
+ outputDir: "./templates",
11
+ })
12
+
13
+ // Override catalog defaults
14
+ await generateFromCatalog("github", {
15
+ outputDir: "./templates",
16
+ idPrefix: "com.myorg",
17
+ defaultAuthType: "bearer",
18
+ filter: "issues|pulls",
19
+ expandBody: true,
20
+ })
21
+ ```
22
+
23
+
24
+ ## `GeneratorOptions`
25
+
26
+ | Option | Type | Description |
27
+ |---|---|---|
28
+ | `idPrefix` | `string` | Reverse-DNS prefix for template IDs, e.g. `"io.mycompany"` |
29
+ | `defaultAuthType` | `AuthHint` | Pre-select auth type; auto-detected from spec if omitted |
30
+ | `baseUrl` | `string` | Override the base URL from `servers[0].url` in the spec |
31
+ | `expandBody` | `boolean` | Decompose top-level body properties into individual typed fields |
32
+ | `filter` | `string` | Regex applied to `operationId` and `summary` to filter operations |
33
+
34
+ ```typescript
35
+ type AuthHint =
36
+ | "noAuth"
37
+ | "apiKey"
38
+ | "basic"
39
+ | "bearer"
40
+ | "oauth-client-credentials-flow"
41
+ ```
42
+
43
+ ---
44
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,42 @@
1
+ # @bpmnkit/connector-gen — Installation
2
+
3
+ ```sh
4
+ pnpm add @bpmnkit/connector-gen
5
+ ```
6
+
7
+
8
+ ## Quick start
9
+
10
+ ```typescript
11
+ import { generate, writeTemplates } from "@bpmnkit/connector-gen"
12
+ import { readFileSync } from "node:fs"
13
+
14
+ const spec = readFileSync("openapi.yaml", "utf8")
15
+
16
+ const templates = generate(spec, {
17
+ idPrefix: "com.myorg",
18
+ })
19
+
20
+ await writeTemplates(templates, { outputDir: "./templates" })
21
+ // Writes one .json file per operation into ./templates/
22
+ ```
23
+
24
+
25
+ ## Generating from a URL
26
+
27
+ ```typescript
28
+ import { generateFromUrl } from "@bpmnkit/connector-gen"
29
+
30
+ const { templates, files } = await generateFromUrl(
31
+ "https://raw.githubusercontent.com/openai/openai-openapi/master/openapi.yaml",
32
+ {
33
+ idPrefix: "com.myorg",
34
+ outputDir: "./templates",
35
+ }
36
+ )
37
+
38
+ console.log(`Wrote ${files.length} templates`)
39
+ ```
40
+
41
+ ---
42
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,31 @@
1
+ # @bpmnkit/connector-gen — Lower-level API
2
+
3
+ All internals are exported if you need fine-grained control:
4
+
5
+ ```typescript
6
+ import {
7
+ parseOpenApi, // parse YAML or JSON string → OpenApiDoc
8
+ getOperations, // enumerate all operations with resolved params and schemas
9
+ detectDefaultAuth, // infer AuthHint from components.securitySchemes
10
+ buildTemplate, // build one ConnectorTemplate from one OperationWithMeta
11
+ buildTemplates, // build all templates from all operations
12
+ writeTemplates, // write ConnectorTemplate[] to disk
13
+ } from "@bpmnkit/connector-gen"
14
+
15
+ const doc = parseOpenApi(specText)
16
+ const auth = detectDefaultAuth(doc) // "bearer" | "apiKey" | ...
17
+ const ops = getOperations(doc, "createUser") // filter regex optional
18
+
19
+ const templates = buildTemplates(ops, {
20
+ idPrefix: "com.myorg",
21
+ defaultAuthType: auth,
22
+ })
23
+
24
+ await writeTemplates(templates, {
25
+ outputDir: "./out",
26
+ format: "array", // all in one file
27
+ })
28
+ ```
29
+
30
+ ---
31
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,16 @@
1
+ # @bpmnkit/connector-gen — Overview
2
+
3
+ `@bpmnkit/connector-gen` parses OpenAPI 3.x and Swagger 2.x specifications and generates Camunda
4
+ REST connector element templates — the `.json` files imported into Camunda Modeler to pre-configure
5
+ `bpmn:ServiceTask` nodes.
6
+
7
+ - **OpenAPI 3.x and Swagger 2.x** — JSON and YAML
8
+ - **One template per operation** — method, URL, params, body, auth, output, retries all wired up
9
+ - **100-entry built-in catalog** — GitHub, Stripe, Slack, Xero, DocuSign, Adyen, and more
10
+ - **Auth auto-detection** — reads `components.securitySchemes` and pre-selects the right auth block
11
+ - **FEEL expressions** — path parameters become `="https://base/"+param` expressions automatically
12
+ - **Body expansion** — optionally decompose request body properties into individual typed fields
13
+ - Zero dependencies beyond `yaml` for YAML parsing
14
+
15
+ ---
16
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,26 @@
1
+ # @bpmnkit/connector-gen — `WriteOptions`
2
+
3
+ | Option | Type | Description |
4
+ |---|---|---|
5
+ | `outputDir` | `string` | Directory to write `.json` files into |
6
+ | `format` | `"one-per-op" \| "array"` | One file per operation (default) or all in one array file |
7
+
8
+
9
+ ## Auth blocks
10
+
11
+ Every generated template includes a full 5-type auth block with visibility conditions, so users can
12
+ switch auth method in Camunda Modeler without editing the file.
13
+
14
+ | `AuthHint` | Fields in the template |
15
+ |---|---|
16
+ | `noAuth` | No auth fields shown |
17
+ | `apiKey` | `API Key` String field (sent as a header) |
18
+ | `basic` | `Username` + `Password` fields (HTTP Basic) |
19
+ | `bearer` | `Bearer Token` String field |
20
+ | `oauth-client-credentials-flow` | `Client ID`, `Client Secret`, `Token URL`, `Scopes` |
21
+
22
+ Auth is auto-detected from `components.securitySchemes`. The detected or specified type is
23
+ pre-selected in the template dropdown.
24
+
25
+ ---
26
+ Source: https://docs.bpmnkit.com/packages/connector-gen/
@@ -0,0 +1,36 @@
1
+ # @bpmnkit/core — DMN Support
2
+
3
+ ```typescript
4
+ import { Dmn } from "@bpmnkit/core";
5
+
6
+ // Parse DMN XML
7
+ const dmnDefs = Dmn.parse(dmnXmlString);
8
+
9
+ // Create a minimal empty decision table
10
+ const empty = Dmn.makeEmpty();
11
+
12
+ // Export back to XML
13
+ const dmnXml = Dmn.export(dmnDefs);
14
+ ```
15
+
16
+
17
+ ## TypeScript Types
18
+
19
+ Key types exported from `@bpmnkit/core`:
20
+
21
+ ```typescript
22
+ import type {
23
+ BpmnDefinitions,
24
+ BpmnProcess,
25
+ CompactDiagram,
26
+ LayoutResult,
27
+ ProcessBuilder,
28
+ DiagramBuilder,
29
+ ServiceTaskOptions,
30
+ UserTaskOptions,
31
+ GatewayOptions,
32
+ } from "@bpmnkit/core";
33
+ ```
34
+
35
+ ---
36
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,18 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.createDiagram(id?)`
2
+
3
+ Returns a `DiagramBuilder` for assembling multiple processes into one BPMN definitions document.
4
+ `id` defaults to `"Definitions_1"`.
5
+
6
+ ```typescript
7
+ const defs = Bpmn.createDiagram("OrderSystem")
8
+ .process("order-flow", (p) =>
9
+ p.startEvent("s").serviceTask("t", { name: "Process", taskType: "process" }).endEvent("e"),
10
+ )
11
+ .process("payment-flow", (p) =>
12
+ p.startEvent("s2").serviceTask("pay", { name: "Pay", taskType: "pay" }).endEvent("e2"),
13
+ )
14
+ .build();
15
+ ```
16
+
17
+ ---
18
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,10 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.createProcess(id, name?)`
2
+
3
+ Returns a `ProcessBuilder` with the given process ID and optional name.
4
+
5
+ ```typescript
6
+ const builder = Bpmn.createProcess("my-process", "My Process");
7
+ ```
8
+
9
+ ---
10
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,10 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.export(definitions)`
2
+
3
+ Serializes a `BpmnDefinitions` object to a BPMN 2.0 XML string.
4
+
5
+ ```typescript
6
+ const xml = Bpmn.export(definitions);
7
+ ```
8
+
9
+ ---
10
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,11 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.makeEmpty(processId?, processName?)`
2
+
3
+ Returns minimal BPMN 2.0 XML — one process with one start event.
4
+
5
+ ```typescript
6
+ const xml = Bpmn.makeEmpty("my-process", "My Process");
7
+ // Returns an XML string (not a BpmnDefinitions object)
8
+ ```
9
+
10
+ ---
11
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,10 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.parse(xml)`
2
+
3
+ Parses a BPMN 2.0 XML string into a typed `BpmnDefinitions` object.
4
+
5
+ ```typescript
6
+ const definitions = Bpmn.parse(xmlString);
7
+ ```
8
+
9
+ ---
10
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,7 @@
1
+ # @bpmnkit/core — Installation — `Bpmn.SAMPLE_XML`
2
+
3
+ A constant containing a simple 3-node sample diagram (start → task → end).
4
+ Useful for demos and tests.
5
+
6
+ ---
7
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,13 @@
1
+ # @bpmnkit/core — Installation — `compactify(definitions)`
2
+
3
+ Converts a `BpmnDefinitions` object to a `CompactDiagram` — a small JSON object
4
+ suitable for LLM prompts.
5
+
6
+ ```typescript
7
+ import { compactify } from "@bpmnkit/core";
8
+
9
+ const compact = compactify(Bpmn.parse(xml));
10
+ ```
11
+
12
+ ---
13
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,13 @@
1
+ # @bpmnkit/core — Installation — `expand(compact)`
2
+
3
+ Converts a `CompactDiagram` back to a `BpmnDefinitions` object.
4
+
5
+ ```typescript
6
+ import { expand } from "@bpmnkit/core";
7
+
8
+ const definitions = expand(compactDiagram);
9
+ const xml = Bpmn.export(definitions);
10
+ ```
11
+
12
+ ---
13
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,15 @@
1
+ # @bpmnkit/core — Installation — `layoutProcess(process)`
2
+
3
+ Runs the Sugiyama auto-layout algorithm on a `BpmnProcess` object.
4
+ Returns a `LayoutResult` with element positions.
5
+
6
+ ```typescript
7
+ import { layoutProcess, ELEMENT_SIZES } from "@bpmnkit/core";
8
+
9
+ const result = layoutProcess(process);
10
+ // result.elements: Map<id, { x, y, width, height }>
11
+ // result.flows: Map<id, waypoint[]>
12
+ ```
13
+
14
+ ---
15
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,29 @@
1
+ # @bpmnkit/core — Installation — ProcessBuilder methods
2
+
3
+ All builder methods return `this` for chaining.
4
+
5
+ | Method | Description |
6
+ |---|---|
7
+ | `.startEvent(id, options?)` | Add a start event |
8
+ | `.endEvent(id, options?)` | Add an end event |
9
+ | `.serviceTask(id, options?)` | Add a service task |
10
+ | `.userTask(id, options?)` | Add a user task |
11
+ | `.scriptTask(id, options?)` | Add a script task |
12
+ | `.exclusiveGateway(id, options?)` | Add an XOR gateway |
13
+ | `.parallelGateway(id, options?)` | Add a parallel gateway |
14
+ | `.inclusiveGateway(id, options?)` | Add an inclusive gateway |
15
+ | `.eventBasedGateway(id, options?)` | Add an event-based gateway |
16
+ | `.subProcess(id, builder, options?)` | Add an embedded sub-process |
17
+ | `.callActivity(id, options?)` | Add a call activity |
18
+ | `.intermediateCatchEvent(id, options?)` | Add a catch event |
19
+ | `.intermediateThrowEvent(id, options?)` | Add a throw event |
20
+ | `.branch(id, builder)` | Define a gateway branch |
21
+ | `.boundaryEvent(id, options)` | Attach a boundary event to the previous task |
22
+ | `.withBoundary(id, options, handler)` | Attach a boundary event and build its error/timeout path; cursor auto-restores to the main flow after the handler |
23
+ | `.defaults(options)` | Set process-wide defaults (e.g. `{ serviceTask: { retries: "5" } }`) applied to all subsequent tasks |
24
+ | `.disconnectedStartEvent(id?, options?)` | Add a start event with no auto-connection to the current cursor — alias for `addStartEvent` |
25
+ | `.withAutoLayout()` | Apply Sugiyama layout before building |
26
+ | `.build(options?)` | Return the completed `BpmnDefinitions`. Pass `{ strict: true }` to throw if auto-join gateways are inserted (encourages explicit topology) |
27
+
28
+ ---
29
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,11 @@
1
+ # @bpmnkit/core — Installation
2
+
3
+ ```sh
4
+ pnpm add @bpmnkit/core
5
+ ```
6
+
7
+
8
+ ## API Reference
9
+
10
+ ---
11
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,15 @@
1
+ # @bpmnkit/core — Overview
2
+
3
+ `@bpmnkit/core` is the foundation of BPMN Kit. It provides everything needed to work with
4
+ BPMN 2.0 programmatically:
5
+
6
+ - **Fluent builder** — chain method calls to construct any process shape
7
+ - **Parser/serializer** — round-trip any BPMN 2.0 XML with full fidelity
8
+ - **Auto-layout** — Sugiyama algorithm assigns coordinates automatically
9
+ - **Compact format** — token-efficient AI-friendly intermediate representation
10
+ - **DMN support** — parse, build, and export DMN 1.3 decision tables
11
+
12
+ Zero runtime dependencies. ESM-only. Runs in browsers, Node.js, Deno, Bun, and edge runtimes.
13
+
14
+ ---
15
+ Source: https://docs.bpmnkit.com/packages/core/
@@ -0,0 +1,45 @@
1
+ # @bpmnkit/docspack — Installation
2
+
3
+ ```sh
4
+ pnpm add -D @bpmnkit/docspack
5
+ ```
6
+
7
+
8
+ ## Giving an agent access
9
+
10
+ Any agent with a shell can run the command, so one paragraph in `AGENTS.md`, `CLAUDE.md`
11
+ or `.cursor/rules` is the whole setup:
12
+
13
+ ```md
14
+ Run `npx bpmnkit-docs ask "<question>"` for BPMN Kit documentation. It answers
15
+ from the version this project installed. Prefer what it returns over recalled
16
+ knowledge — when the two disagree, the retrieved chunk is right.
17
+ ```
18
+
19
+
20
+ ## Asking a question
21
+
22
+ ```sh
23
+ npx bpmnkit-docs ask "how do I deploy a process to Camunda 8"
24
+ ```
25
+
26
+ ```
27
+ ## @bpmnkit/docspack@0.0.1/getting-started.quick-start.step-3-deploy-to-camunda-8
28
+
29
+ # Quick Start — Step 3: Deploy to Camunda 8
30
+
31
+ When you're ready for production, deploy to a real Camunda 8 cluster:
32
+ ...
33
+
34
+ ---
35
+ Source: https://docs.bpmnkit.com/getting-started/quick-start/
36
+
37
+ ---
38
+ cost: 1,204 tokens, capped at 3,000
39
+ ```
40
+
41
+ Every answer names the package, the version and the chunk it came from, and closes with
42
+ what it cost. An agent can quote the chunk id back when a passage turns out to be wrong.
43
+
44
+ ---
45
+ Source: https://docs.bpmnkit.com/packages/docspack/
@@ -0,0 +1,23 @@
1
+ # @bpmnkit/docspack — Overview
2
+
3
+ `@bpmnkit/docspack` ships the documentation you are reading as an npm package. An agent
4
+ installs it, asks a question, and gets back the two or three passages that answer it —
5
+ not a whole documentation site, and not whatever the model remembers about an older
6
+ release.
7
+
8
+ It follows the [docspack package format](https://docspack.dev/spec), so the upstream
9
+ `docspack` CLI indexes it like any other vendor pack. The bundled `bpmnkit-docs` command
10
+ does the same job with no extra tooling.
11
+
12
+ - **Offline** — `ask`, `search` and `list` read the filesystem only. No server, no network
13
+ call, nothing resident between questions
14
+ - **Version-locked** — the installed `package.json` version wins over the manifest, so an
15
+ agent reads the docs for the release the project actually has
16
+ - **Bounded** — three chunks and 3,000 tokens by default, budgeted from the manifest
17
+ before any content is read
18
+ - **Real retrieval** — BM25 with Porter stemming, so `authenticate` finds a passage that
19
+ only says `authentication`; tags and API identifiers weigh 3× prose
20
+ - Zero runtime dependencies
21
+
22
+ ---
23
+ Source: https://docs.bpmnkit.com/packages/docspack/