You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Use the starter kit to get your docs deployed and ready to customize.
3
+
This repository contains the public Mintlify documentation site for KHAL OS. It is the public-facing docs surface for product concepts, app/pack authoring, SDK usage, and release/customer handoff guidance.
4
4
5
-
Click the green **Use this template** button at the top of this repo to copy the Mintlify starter kit. The starter kit contains examples with
5
+
## Local development
6
6
7
-
- Guide pages
8
-
- Navigation
9
-
- Customizations
10
-
- API reference pages
11
-
- Use of popular components
12
-
13
-
**[Follow the full quickstart guide](https://starter.mintlify.com/quickstart)**
14
-
15
-
## AI-assisted writing
16
-
17
-
Set up your AI coding tool to work with Mintlify:
7
+
Run commands from the repository root, where `docs.json` lives:
18
8
19
9
```bash
20
-
npx skills add https://mintlify.com/docs
21
-
```
22
-
23
-
This command installs Mintlify's documentation skill for your configured AI tools like Claude Code, Cursor, Windsurf, and others. The skill includes component reference, writing standards, and workflow guidance.
24
-
25
-
See the [AI tools guides](/ai-tools) for tool-specific setup.
26
-
27
-
## Development
28
-
29
-
Install the [Mintlify CLI](https://www.npmjs.com/package/mint) to preview your documentation changes locally. To install, use the following command:
30
-
31
-
```
32
-
npm i -g mint
10
+
npx --yes mint@latest dev
11
+
npx --yes mint@latest broken-links
33
12
```
34
13
35
-
Run the following command at the root of your documentation, where your `docs.json` is located:
14
+
If you prefer a global CLI, install Mintlify with `npm i -g mint` and run `mint dev` or `mint broken-links`.
36
15
37
-
```
38
-
mint dev
39
-
```
16
+
## Public/private boundary
40
17
41
-
View your local preview at `http://localhost:3000`.
18
+
These docs are public. Do not add secrets, tokens, credentials, customer identifiers, private hostnames, internal IPs, live monitoring URLs, admin usernames, migration/cutover notes, or operator-only runbook commands. Keep production operations and private topology in internal Hermes/KHAL runbooks unless Felipe explicitly approves publication.
42
19
43
-
## Publishing changes
20
+
## Pack distribution policy
44
21
45
-
Install our GitHub app from your [dashboard](https://dashboard.mintlify.com/settings/organization/github-app) to propagate changes from your repo to your deployment. Changes are deployed to production automatically after pushing to the default branch.
22
+
Pack/app repos are git-native: Marketplace/App Store installation reads the git repo and `khal-app.json`, then builds/loads the app from that source. Do not document `pack-*` repos as npm or GitHub Packages artifacts.
46
23
47
-
## Need help?
24
+
The npm packages that belong in public docs are the app-kit/framework packages only:
48
25
49
-
### Troubleshooting
26
+
-`@khal-os/sdk`
27
+
-`@khal-os/ui`
28
+
-`@khal-os/types`
29
+
-`@khal-os/dev-cli`
50
30
51
-
- If your dev environment isn't running: Run `mint update` to ensure you have the most recent version of the CLI.
52
-
- If a page loads as a 404: Make sure you are running in a folder with a valid `docs.json`.
Open a PR for documentation changes and request review before publishing or merging to the default branch. Public docs changes need product/schema review for technical truth and public/private boundary review for safety.
Copy file name to clipboardExpand all lines: dev/local-dev-and-testing.mdx
+9-7Lines changed: 9 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -23,7 +23,7 @@ bun run watch
23
23
```
24
24
</CodeGroup>
25
25
26
-
The build produces CJS + ESM + `.d.ts`outputs into `package/dist/`. The publish pipeline only ships what's under `package/`.
26
+
The build produces frontend bundle outputs into `package/dist/` when the current build pipeline is available. Pack/app repos are installed from git; do not describe `package/` as an npm publish artifact.
27
27
28
28
## Typecheck and lint
29
29
@@ -85,17 +85,19 @@ For full-stack packs, a lightweight integration test talks to your service over
85
85
</Step>
86
86
</Steps>
87
87
88
-
## The `khal-dev` QA CLI
88
+
## The `khal` developer CLI
89
89
90
-
The `@khal-os/dev-cli` package ships `khal-dev` — a pack-focused QA toolkit. Subcommands live under `app-kit/packages/dev-cli/src/commands/`.
90
+
The `@khal-os/app-kit` package ships the `khal` binary. Developer-loop commands live under `khal dev`; run `khal dev --help` on your installed copy for the current list.
91
91
92
92
Key commands:
93
93
94
94
-`khal new app <name>` — scaffold a new pack from the bundled `app` template (also `khal new service <name>` and `khal new workflow <name>`).
95
-
-`khal-dev qa <sub>` — the QA family. Inspect `app-kit/packages/dev-cli/src/commands/qa/` for the current list of sub-checks; `khal-dev qa --help` on your installed copy is authoritative.
95
+
-`khal dev design-system --no-browser` — serve the bundled feature catalog without launching a browser, useful for CI/tests.
96
+
-`khal dev manifest` — validate and inspect a `khal-app.json` manifest.
97
+
-`khal dev qa <sub>` — the QA family. `khal dev qa --help` on your installed copy is authoritative for the current subcommands.
96
98
97
99
<Note>
98
-
The exact QA subcommand list evolves with the toolchain. Run `khal-dev qa --help` for the live list rather than memorizing it.
100
+
The exact QA subcommand list evolves with the toolchain. Run `khaldev qa --help` for the live list rather than memorizing it.
99
101
</Note>
100
102
101
103
## Debug tips
@@ -116,14 +118,14 @@ The exact QA subcommand list evolves with the toolchain. Run `khal-dev qa --help
116
118
</CardGroup>
117
119
118
120
<Frame>
119
-
<imgalt="khal-dev qa output during a local test run"src="/images/khal-dev-qa.png" />
121
+
<imgalt="khaldev qa output during a local test run"src="/images/khal-dev-qa.png" />
120
122
</Frame>
121
123
122
124
## What's next
123
125
124
126
<CardGroupcols={2}>
125
127
<Cardtitle="Publish your pack"icon="upload"href="/release/publish-your-pack">
description: "Which package manager to use where — pnpm for the SDK workspace, bun for pack-* repos — and the commands that get everything compiling."
3
+
description: "Which package manager to use where — pnpm for app-kit and current khal-new app repos, bun only where an older repo already commits Bun metadata."
4
4
---
5
5
6
-
KhalOS uses two package managers on purpose. The **SDK workspace**(the `@khal-os/*` packages you'll import into your pack) is a `pnpm` monorepo. Each **`pack-*` repo** (including `pack-template`) is a `bun` workspace. Knowing which tool runs where is the only setup detail that trips up first-time contributors.
6
+
KhalOS uses package managers by repo contract. The **app-kit workspace**publishes the framework packages and the `khal` CLI. Current apps scaffolded with `khal new` use the package manager emitted in their next-steps output; older pack repos may still be Bun workspaces. When in doubt, follow the lockfile and scripts committed in the repo you are editing.
7
7
8
8
## TL;DR
9
9
10
10
<CardGroupcols={2}>
11
11
<Cardtitle="pnpm"icon="box">
12
-
For the `@khal-os/*` SDK workspace. `pnpm install`, `pnpm build`, `pnpm typecheck`, `pnpm lint`.
12
+
For the app-kit framework workspace. `pnpm install`, `pnpm build`, `pnpm typecheck`, `pnpm lint`.
13
13
</Card>
14
-
<Cardtitle="bun"icon="bolt">
15
-
For every `pack-*` repo (the scaffold you clone from `pack-template`). `bun install`, `bun run build`, `bun run typecheck`.
14
+
<Cardtitle="pnpm in new app repos"icon="box-open">
15
+
Current `khal new app` output says `pnpm install`, then `khal start`. Build with the repo's scripts, for example `pnpm build` when the scaffold exposes `"build": "khal build"`.
16
+
</Card>
17
+
<Cardtitle="bun in older pack repos"icon="bolt">
18
+
Use Bun only where the repo already commits Bun metadata and scripts. Typical older commands are `bun install`, `bun run build`, `bun run typecheck`.
16
19
</Card>
17
20
</CardGroup>
18
21
19
22
## Node version
20
23
21
-
Install **Node 20 or newer**. The `@khal-os/*` packages target modern Node and `bun` itself installs cleanly on 20.x. If you use `nvm`, run `nvm use` inside any repo that ships an `.nvmrc`.
24
+
Install **Node 20 or newer**. The app-kit packages target modern Node, and both `pnpm` and `bun` install cleanly on 20.x. If you use `nvm`, run `nvm use` inside any repo that ships an `.nvmrc`.
22
25
23
26
```bash
24
27
node --version # v20.x or newer
25
28
pnpm --version # any recent release
26
-
bun --version # 1.x
29
+
bun --version # 1.x, only needed for repos that already use Bun
27
30
```
28
31
29
-
## The SDK workspace — `pnpm`
32
+
## The app-kit workspace — `pnpm`
30
33
31
-
The SDK workspace ships the four framework packages your pack will depend on: `@khal-os/sdk`, `@khal-os/ui`, `@khal-os/types`, and `@khal-os/dev-cli`. It uses `pnpm` and Turbo under the hood.
34
+
The app-kit workspace ships the framework packages your pack will depend on (`@khal-os/sdk`, `@khal-os/ui`, `@khal-os/types`) plus the `@khal-os/app-kit` package that exposes the `khal` CLI. It uses `pnpm` and Turbo under the hood.
32
35
33
36
<CodeGroup>
34
-
35
37
```bash pnpm
36
38
pnpm install # install workspace deps
37
39
pnpm build # turbo run build — build every package
38
40
pnpm typecheck # turbo run typecheck across the workspace
39
41
pnpm lint # biome check
40
42
pnpm lint:fix # biome check --write .
41
43
```
42
-
43
44
</CodeGroup>
44
45
45
-
You usually don't need to run these yourself: the packages publish from CI to GitHub Packages, and your pack consumes them as ordinary npm dependencies. Install them here only if you're debugging an SDK issue or running a local snapshot of the SDK against your pack.
46
+
Those framework packages may be consumed as npm dependencies by pack/app repos. That does not make `pack-*` repos npm packages; pack identity and install content remain git-native.
46
47
47
-
## Pack repos — `bun`
48
+
## Pack/app repos — follow the scaffold
48
49
49
-
Every `pack-*` repo — including the scaffold you clone from `pack-template` — uses `bun` as both its package manager and its runtime. `bun install` is fast, workspaces are first-class, and the included bundler already matches the toolchain the template expects.
50
+
Current `khal new app <name>` output tells you to run `pnpm install` and then `khal start`. The generated root `package.json` exposes `"dev": "khal dev"` and `"build": "khal build"`, so use the package manager that installs the root workspace and then run the scripts it provides.
50
51
51
52
<CodeGroup>
52
-
53
-
```bash bun
54
-
bun install # install pack deps
55
-
bun run build # build the frontend package
56
-
bun run typecheck # type-check all workspaces
57
-
bun run lint # biome lint
58
-
bun run test# run tests (if present)
53
+
```bash Current khal new app
54
+
pnpm install # install app deps, as emitted by current scaffold next steps
55
+
pnpm build # runs khal build through the generated package.json script
56
+
khal start # start the local KhalOS dev loop
59
57
```
60
58
59
+
```bash Older Bun pack repo
60
+
bun install # install deps when the repo already uses Bun
61
+
bun run build # build using that repo's existing script
62
+
bun run typecheck # type-check if the repo defines the script
63
+
```
61
64
</CodeGroup>
62
65
63
66
<Callouttype="warning">
64
-
Don't cross the streams. Running `pnpm install`inside a `pack-*` repo, or `bun install`inside the SDK workspace, will produce a lockfile the other tool ignores — and the next person on the repo will have to untangle it. When in doubt, check which lockfile is already committed.
67
+
Don't cross the streams. Running `bun install`in a pnpm scaffold, or `pnpm install`in an older Bun-only pack repo, can produce a lockfile the repo does not use. When in doubt, check which lockfile and scripts are already committed.
65
68
</Callout>
66
69
67
70
## Verifying your setup
68
71
69
72
After you've cloned the workspace, pick one of each and confirm both install cleanly:
70
73
71
74
<Steps>
72
-
<Steptitle="SDK workspace">
75
+
<Steptitle="App-kit workspace">
73
76
```bash
74
77
cd repos/app-kit
75
78
pnpm install && pnpm build
@@ -78,18 +81,19 @@ After you've cloned the workspace, pick one of each and confirm both install cle
78
81
`pnpm build` should finish with every package green in the Turbo summary.
79
82
</Step>
80
83
81
-
<Steptitle="A reference pack">
84
+
<Steptitle="A scaffolded pack/app">
82
85
```bash
83
-
cd repos/pack-template
84
-
bun install && bun run build
86
+
khal new app hello-fde
87
+
cd hello-fde
88
+
pnpm install && pnpm build
85
89
```
86
90
87
-
`bun run build` should emit CJS + ESM + `.d.ts`outputs into `package/dist/`.
91
+
`pnpm build` should run the scaffold's `khal build` script and emit bundle outputs into `package/dist/` when the current build pipeline is available.
88
92
</Step>
89
93
</Steps>
90
94
91
95
<Frame>
92
-

96
+

93
97
</Frame>
94
98
95
99
## Next steps
@@ -99,6 +103,6 @@ After you've cloned the workspace, pick one of each and confirm both install cle
99
103
Scaffold a new pack with `khal new app <name>` and get a "Hello FDE" component shipping.
Copy file name to clipboardExpand all lines: getting-started/your-first-pack.mdx
+41-7Lines changed: 41 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,19 +6,51 @@ description: "Scaffold a pack with `khal new`, edit a React component, and see i
6
6
A pack is a self-contained KhalOS app: a frontend React package plus an optional backend service, a manifest that declares both, and a Helm chart for shipping. In this walkthrough you'll go from an empty directory to a running "Hello FDE" pack in under ten minutes.
7
7
8
8
<Callouttype="info">
9
-
This page is the fast path. For the full pack contract — every manifest field, every CI workflow, every deploy mode — follow the **Next steps** links at the bottom.
9
+
This page is the fast path. For the full pack contract — every manifest field, every install mode, every design-system expectation — follow the **Next steps** links at the bottom.
10
+
</Callout>
11
+
12
+
<Callouttype="warning">
13
+
Packs are installed from git. Do not add `.npmrc`, `publishConfig`, npm publish scripts/workflows, or `frontend.package` to a new pack manifest.
10
14
</Callout>
11
15
12
16
## 1. Scaffold with `khal new`
13
17
14
18
`@khal-os/app-kit` ships a `khal new` command that stamps out a complete pack locally. It bundles three templates — `app` (full-stack), `service` (backend-only), and `workflow` (Temporal) — and emits a runnable project with no network calls.
15
19
20
+
Verify the CLI you are about to use:
21
+
22
+
```bash
23
+
khal --version
24
+
khal new --list
25
+
```
26
+
27
+
Expected shape:
28
+
29
+
```text
30
+
1.x.y
31
+
Bundled templates:
32
+
app v1.x.y
33
+
service v1.x.y
34
+
workflow v1.x.y
35
+
```
36
+
37
+
Package note: the npm package is `@khal-os/app-kit` and its binary is `khal`. As of 2026-05-18, npm reports `latest` as `1.0.14` and `next` as `1.0.24`; use an installed, verified `khal` binary for scaffolding until the public `latest` tag is promoted to the release you want to document.
38
+
16
39
```bash
17
40
khal new app <name>
18
41
cd<name>
19
42
```
20
43
21
-
Replace `<name>` with your pack's identifier — lowercase, hyphen-separated, and short. It becomes the Helm chart name, the manifest `id`, and the package name. `khal new` substitutes the token everywhere it appears in the bundled template.
44
+
Replace `<name>` with your pack's identifier — lowercase, hyphen-separated, and short. It becomes the manifest `id`, local build workspace name, and any generated backend/chart names. `khal new` substitutes the token everywhere it appears in the bundled scaffold.
45
+
46
+
Current scaffold output ends with:
47
+
48
+
```text
49
+
Next steps:
50
+
1. cd <name>
51
+
2. pnpm install
52
+
3. khal start
53
+
```
22
54
23
55
<Callouttype="tip">
24
56
Run `khal new` with no arguments to see the three available types and their one-line descriptions. Add `--list` to inspect the bundled template versions.
@@ -71,15 +103,14 @@ If your pack is **frontend-only**, delete the `service/` directory and remove th
71
103
## 4. Build and typecheck
72
104
73
105
```bash
74
-
bun install
75
-
bun run build
76
-
bun run typecheck
106
+
pnpm install
107
+
pnpm build
77
108
```
78
109
79
-
`bun run build` produces CJS + ESM bundles plus TypeScript declarations in `package/dist/`. `bun run typecheck` validates both the frontend package and the service (if present).
110
+
Current `khal new app` scaffolds expose a root `"build": "khal build"` script. Run the scripts committed in your generated `package.json`; older pack repos may still expose separate `bun run build` or `bun run typecheck` scripts.
80
111
81
112
<Frame>
82
-

113
+

83
114
</Frame>
84
115
85
116
## 5. See it in the shell
@@ -115,4 +146,7 @@ You've got two paths to render your pack in a live shell:
0 commit comments