This repository implements the
Open Cap Format (OCF) as DAML
contracts for Canton. It also publishes generated JavaScript bindings and the built OpenCapTable DAR
as
@fairmint/open-captable-protocol-daml-js.
npm install @fairmint/open-captable-protocol-daml-jsThe browser-safe root entry point exports the generated OpenCapTable namespace, bundled DAML/Splice dependencies, and the three entry-point template IDs:
import { Fairmint, OCP_TEMPLATES } from '@fairmint/open-captable-protocol-daml-js';
const { OpenCapTable } = Fairmint;
const capTableTemplateId = OCP_TEMPLATES.capTable;The package also exposes stable subpaths for deployment metadata and the DAR:
import factoryIds from '@fairmint/open-captable-protocol-daml-js/ocp-factory-contract-id.json';
import {
getOpenCapTableDarPath,
resolveOpenCapTableDarPath,
} from '@fairmint/open-captable-protocol-daml-js/openCapTableDarPath';The DAR itself is exported at @fairmint/open-captable-protocol-daml-js/opencaptable.dar. Check
package.json for
the complete export map and
scripts/test-imports.ts
for the executable package-surface contract. resolveOpenCapTableDarPath checks
OPEN_CAP_TABLE_DAR_PATH, then the packaged DAR, then optional local-checkout paths; see its
source and options
for exact resolution behavior.
The public GitHub wiki is the
canonical guide for contract architecture, OCF validation, development, testing, DAR backup, and
release policy. The active package's
daml.yaml,
multi-package.yaml,
package.json,
and scripts/ remain
the source of truth for current versions, dependencies, and automation.
Requires Node.js 22+ (see @fairmint/canton-dev-tools).
npm install
npx canton-dev-tools install-dpm-sdks
npm run build
npm testnpm run build syncs Splice DARs, generates CapTable.daml, runs prepare-build into
generated/build/, then builds with dpm. No Splice git submodule is required.
When generated bindings or the published npm surface are affected, also run:
npm run codegen
npm run verify-packageSee Development and Testing for the generated-file boundary and specialized checks.