Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
580 changes: 140 additions & 440 deletions README.md

Large diffs are not rendered by default.

9 changes: 6 additions & 3 deletions docs/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,14 @@ content SHA. Uncurated tags are resolved live against GitHub and cached
locally — handy for trying a brand-new upstream release before it's
curated.

## Tokens (CIP-0112 / V2)
## Tokens

**V1 or V2?**
This tool targets **Token Standard V2 (CIP-0112)** only. V1 / CIP-0056 is
not supported. See [tokens.md](tokens.md).
Both, routed per instrument. Reads and transfers work against
**CIP-0056** (Final) instruments — what existing assets such as Canton
Coin implement on stable Splice releases. Creating a **new** instrument
uses **Token Standard V2 (CIP-0112**, approved but not yet final**)**,
which requires the alpha track below. See [tokens.md](tokens.md).

**Why is V2 "alpha" and what does `--profile tokens-v2` do?**
V2 runs on a special upstream Splice build (alpha protocol 35) on the
Expand Down
30 changes: 18 additions & 12 deletions docs/tokens.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
# Tokens — Canton Token Standard V2 on LocalNet

canton-devkit ships first-class tooling for the **Canton Token Standard
V2** (the CIP-0112 path) so you can create an instrument, mint/transfer/
burn holdings, fund parties, and reconcile balances against a live
LocalNet — from the CLI **or** the Web UI, by readable party alias, with
without surfacing raw JWTs, ports, or full contract IDs in every command.

> **Scope: V2 / CIP-0112 only.** This tooling targets the Token Standard
> V2 (CIP-0112) surface. V1 / CIP-0056 is **not** supported. V2 is
> currently an opt-in *alpha* track (see [the alpha caveat](#the-v2-alpha-caveat));
> it will be promoted to the default channel once V2 lands in mainline Splice.
# Tokens — Canton Token Standard on LocalNet

canton-devkit ships first-class tooling for the Canton Token Standard so
you can create an instrument, mint/transfer/burn holdings, fund parties,
and reconcile balances against a live LocalNet — from the CLI **or** the
Web UI, by readable party alias, without surfacing raw JWTs, ports, or
full contract IDs in every command.

> **Scope: both token-standard generations, routed per instrument.**
> Reads and transfers work against
> [CIP-0056](https://github.com/global-synchronizer-foundation/cips/blob/main/cip-0056/cip-0056.md)
> (Final) instruments — what existing assets such as Canton Coin
> implement on stable Splice releases. Creating a **new** instrument uses
> the Token Standard V2
> ([CIP-0112](https://github.com/global-synchronizer-foundation/cips/blob/main/cip-0112/cip-0112.md),
> approved but not yet final) surface, which is an opt-in *alpha* track
> (see [the alpha caveat](#the-v2-alpha-caveat)); it will be promoted to
> the default channel once V2 lands in mainline Splice.

---

Expand Down
14 changes: 9 additions & 5 deletions internal/skills/docs/token-flow.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
---
name: canton-token-flow
description: Create and exercise CIP-0112 token flows (create, mint, transfer, burn, balance) on a Canton LocalNet. Use when the user wants to test token operations locally.
description: Create and exercise Canton Token Standard flows (create, mint, transfer, burn, balance) on a Canton LocalNet. Use when the user wants to test token operations locally.
---

# Token flows (CIP-0112)
# Token flows (Canton Token Standard)

Exercise token-standard operations on LocalNet via `dpm localnet token`.
Targets CIP-0112 (Token Standard V2) as the default path. For LocalNet
testing only — not a production issuer/custodian/wallet.
Both generations are supported, routed per instrument: CIP-0056 (Final —
existing assets such as Canton Coin) for reads and transfers; creating a
new instrument uses Token Standard V2 (CIP-0112, alpha) and needs
`--version token-standard-v2 --profile tokens-v2`. For LocalNet testing
only — not a production issuer/custodian/wallet.

## When to use
The user asks to "create a test token", "mint/transfer/burn tokens", or
Expand Down Expand Up @@ -44,6 +47,7 @@ The user asks to "create a test token", "mint/transfer/burn tokens", or
## Guardrails
- This is a LocalNet faucet/testing surface, not production token
infrastructure. Do not point it at MainNet.
- V2 (CIP-0112) only — V1 / CIP-0056 is not supported by this CLI.
- Creating/minting/burning targets Token Standard V2 (CIP-0112, alpha)
instruments; CIP-0056 instruments support reads and transfers only.
- All operations go through the Ledger API / Registry API on the
selected instance; verify with `token balance` after each step.
24 changes: 12 additions & 12 deletions website/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -12,22 +12,22 @@ export default defineConfig({
description:
'One command to a full Canton LocalNet — spin up, inspect, and tear down a complete Canton developer stack.',
customCss: [
// Self-hosted fonts (Fontsource) + typography tuning.
'@fontsource-variable/inter',
'@fontsource-variable/jetbrains-mono',
// Self-hosted fonts (see src/fonts/ for licenses) + typography.
'./src/styles/fonts.css',
'./src/styles/custom.css',
],
expressiveCode: {
// Code-block typography is resolved at build time by
// Expressive Code — plain CSS overrides don't reach the
// inner <pre>, so set it here (this fixes the browser
// falling back to its default monospace inside frames).
// Design system: code blocks stay dark ink in BOTH themes
// (one dark syntax theme), 4px radius, JetBrains Mono.
themes: ['github-dark'],
styleOverrides: {
codeFontFamily: "'JetBrains Mono Variable', ui-monospace, 'SF Mono', Menlo, monospace",
codeFontSize: '0.875rem',
codeLineHeight: '1.7',
uiFontFamily: "'Inter Variable', ui-sans-serif, system-ui, sans-serif",
borderRadius: '0.5rem',
codeFontFamily: "'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace",
codeFontSize: '0.8125rem',
codeLineHeight: '1.6',
uiFontFamily: "'Archivo', -apple-system, 'Segoe UI', sans-serif",
borderRadius: '4px',
codeBackground: '#0B0F1A',
frames: { editorBackground: '#0B0F1A', terminalBackground: '#0B0F1A', terminalTitlebarBackground: '#10151F', editorTabBarBackground: '#10151F', shadowColor: 'transparent' },
},
},
social: [
Expand Down
2 changes: 1 addition & 1 deletion website/docs-map.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export const docsMap = [
{ src: 'explorer.md', dest: 'guides/explorer', description: 'Browse the Active Contract Set, recent transactions, and a ledger timeline of a running LocalNet from the Web UI — with CLI equivalents for scripting.' },
{ src: 'observability.md', dest: 'guides/observability', description: 'Enable the observability profile for Prometheus + Grafana, understand the live Splice metric naming convention, and toggle the sidecars at runtime.' },
{ src: 'dashboard-customization.md', dest: 'guides/dashboard-customization', description: 'Extend, replace, or restore the bundled Grafana dashboard for a running LocalNet — panels, template variables, and persistence across down/up cycles.' },
{ src: 'tokens.md', dest: 'guides/tokens', description: 'Create, mint, transfer, and burn CIP-0112 (Token Standard V2) instruments against a live LocalNet from the CLI or the Web UI.' },
{ src: 'tokens.md', dest: 'guides/tokens', description: 'Work with Canton Token Standard instruments on a live LocalNet — CIP-0056 assets and Token Standard V2 (CIP-0112) — from the CLI or the Web UI.' },
{ src: 'homebrew.md', dest: 'guides/homebrew', description: 'Install canton-devkit via the Homebrew tap or direct formula, and how the formula is kept in sync on every release.' },
{ src: 'faq.md', dest: 'reference/faq', description: 'Common questions about canton-devkit: what it is, how the CLI and Web UI relate, versions, and day-to-day usage.' },
{ src: 'versions.md', dest: 'reference/versions', description: 'How DevKit pins tested Splice LocalNet versions by commit SHA and content hash, discovers upstream tags, and resolves uncurated versions on opt-in.' },
Expand Down
20 changes: 0 additions & 20 deletions website/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
},
"dependencies": {
"@astrojs/starlight": "^0.41.2",
"@fontsource-variable/inter": "^5.2.8",
"@fontsource-variable/jetbrains-mono": "^5.2.8",
"astro": "^7.0.5",
"sharp": "^0.35.3"
}
Expand Down
124 changes: 67 additions & 57 deletions website/src/content/docs/index.mdx
Original file line number Diff line number Diff line change
@@ -1,70 +1,80 @@
---
title: Canton DevKit
description: One command to a full Canton LocalNet — spin up, inspect, and tear down a complete Canton developer stack.
template: splash
hero:
tagline: One command to a full Canton LocalNet
actions:
- text: Get started
link: getting-started/
icon: right-arrow
- text: View on GitHub
link: https://github.com/bitdynamics-ab/canton-devkit
icon: external
variant: minimal
description: Run a complete local Canton network — synchronizer, participant, Splice apps, wallets, explorer — with one command.
---

import { Card, CardGrid } from '@astrojs/starlight/components';
canton-devkit runs a complete local [Canton](https://canton.network/)
network on your machine: a Canton synchronizer and participant, the
Splice validator and super-validator apps, and three party wallets
(app-user, app-provider, super-validator), each with signed JWTs. One
binary, one command, nothing to configure.

`canton-devkit` is a single-binary toolkit for spinning up, inspecting, and tearing
down a complete [Canton](https://canton.network/) developer stack — Canton
synchronizer + participant, Splice super-validator apps, three party wallets
(app-user, app-provider, SV), Scan explorer, and signed JWTs.
```
$ canton-devkit localnet up demo
✓ Splice 0.6.4 cache hit
✓ Compose started · 12 containers
✓ Health checks · canton · splice · postgres
✓ JWTs signed · app-user · app-provider · super-validator
✦ "demo" is ready · Splice 0.6.4 · ready in 1m 24s
```

## Getting started
It is a thin wrapper over the upstream
[Splice LocalNet](https://github.com/canton-network/splice) — pinned to
immutable commit SHAs, verified by content hash, no forks, no patched
images. The only prerequisite is Docker with Compose v2; the devkit's
preflight checks for at least 8 GB of Docker memory (12 GB recommended)
and 10 GB of free disk.

Start with [Installation & Getting Started](getting-started/) for install paths,
Docker prerequisites, and a zero-to-running LocalNet walkthrough.
## Install

<CardGrid>
<Card title="One command" icon="rocket">
No YAML editing, no env-file shuffling. `up` downloads Splice, signs JWTs,
brings up a dozen containers, prints endpoints. Cold start ~90&nbsp;s.
</Card>
<Card title="Two surfaces" icon="laptop">
Same code, two skins: a CLI for terminals &amp; CI, a
Vite/React Web UI for browser-driven inspection. Always at parity.
</Card>
<Card title="Zero lock-in" icon="approve-check">
No forks, no patches. Thin wrapper over upstream
[Splice LocalNet](https://github.com/canton-network/splice), pinned to
immutable commit SHAs and verified by content hash.
</Card>
<Card title="Snapshot &amp; restore" icon="seti:db">
Save a working state to a `.tgz`, hand it to a teammate, replay it on CI.
Restore a captured state in seconds.
</Card>
<Card title="Single binary" icon="download">
`go install` or `dpm install package` — same artefact. macOS arm64, Linux
amd64, Windows amd64. No JVM, no Python, no Node at runtime.
</Card>
<Card title="Observability built-in" icon="magnifier">
Optional `--profile observability` adds Prometheus + Grafana with a
Canton dashboard. The CLI scrapes the same metrics.
</Card>
</CardGrid>
Follow [Installation & Getting Started](getting-started/) — it covers
the DPM component, standalone binaries for macOS/Linux/Windows,
Homebrew, APT, and `go install`, plus the Docker prerequisites and a
zero-to-running walkthrough.

## Documentation
```sh
canton-devkit localnet doctor # verify Docker, memory, disk, ports
canton-devkit localnet up demo # bring up a network named "demo"
```

- [LocalNet lifecycle](guides/localnet-lifecycle/) — up, inspect, multiple instances, clean up
- [Tokens (CIP-0112 / V2)](guides/tokens/)
- [Contract explorer](guides/explorer/)
- [Observability](guides/observability/)
- [FAQ](reference/faq/)
- [Troubleshooting](reference/troubleshooting/)
- [Known limitations](reference/limitations/)
## What you get

- **A CLI and a Web UI at parity** — every operation works from both.
`localnet ui` serves a local dashboard: lifecycle, container health
and logs, a contract explorer with per-party visibility, DAR
management, metrics, and the token workspace.
- **The full development loop** — DAR upload/inspect/diff with hot
redeploy (`dar watch`), live ledger inspection (`contracts watch`,
`tx ls / replay`), token flows for both standard generations
(CIP-0056 assets and Token Standard V2 instruments), and portable
snapshot/restore of a network's entire state.
- **CI-ready behavior** — stable exit codes, `--format json`
everywhere it matters, deterministic ports on request
(`--port-base`), and a ready-made
[GitHub Actions example](https://github.com/bitdynamics-ab/canton-devkit/blob/main/examples/ci/github-actions.yml).
- **Optional observability** — `--profile observability` adds
Prometheus and Grafana with a curated Canton dashboard.

## Guides

- [LocalNet lifecycle](guides/localnet-lifecycle/) — zero to running,
multiple instances, deterministic ports, teardown
- [Contract explorer](guides/explorer/) — ACS, transactions, per-party views
- [Observability](guides/observability/) — Prometheus + Grafana profile
- [Dashboard customization](guides/dashboard-customization/)
- [Tokens](guides/tokens/) — CIP-0056 assets and Token Standard V2 (CIP-0112) flows
- [Homebrew install](guides/homebrew/)

## Reference

- [Splice version catalogue](reference/versions/) — how versions are pinned
- [Packaging & distribution](reference/packaging/)
- [Telemetry](reference/telemetry/) — what is collected, how to opt out
- [FAQ](reference/faq/) · [Troubleshooting](reference/troubleshooting/) ·
[Known limitations](reference/limitations/)

:::note
**Not for production.** This is a developer tool. For production Canton
deployments, see the official [Canton documentation](https://docs.daml.com/canton/).
This is a developer tool, not a production deployment path. For
production Canton, see the official
[Canton documentation](https://docs.daml.com/canton/).
:::
Loading
Loading