# Examples

> Learn Univer CLI SDK content operations, Office file import and export, visual inspection, and Worktree in order.

- Human documentation: [https://office.univer.ai/cli/examples](https://office.univer.ai/cli/examples)

- Agent Markdown: [https://office.univer.ai/cli/examples.md](https://office.univer.ai/cli/examples.md)

- Language: `en`

- Source file: `content/docs/cli/examples.mdx`

---

[`univer-cli-examples`](https://github.com/dream-num/univer-cli-examples) contains four independent, runnable teaching
applications. Each directory has its own `package.json` and lockfile. Every example retains the preceding capabilities
and adds one topic.

## Learning order

| Example                 | Learn                                             | Added capability                        |
| ----------------------- | ------------------------------------------------- | --------------------------------------- |
| `01-content-operations` | Read, edit, and view Sheet, Doc, and Slide Units  | CLI, Server, Web, Collaboration Runtime |
| `02-file-exchange`      | Import and export Office files                    | Exchange, UnitData, native binding      |
| `03-visual-inspection`  | Check the actual rendered Unit                    | Render Page, Screenshot, Layout Lint    |
| `04-worktree`           | Isolate agent edits and hand them to human review | Worktree, Ready, Merge, Reopen          |

## Run an example

Use the same startup sequence inside any example directory:

```bash
pnpm install
pnpm build
pnpm link-cli
pnpm start-server
```

After the Server starts, run `univer-example-cli` from another terminal. Each example README contains its complete,
copyable flow and an Agent skill prompt.

These are minimal teaching assemblies, not complete products. The application still owns commands, targets, identity
and authorization, output, and deployment.

> **View complete source**
>
> Browse and run the numbered examples in
> [univer-cli-examples](https://github.com/dream-num/univer-cli-examples).
