@thecorporation/cli 26.3.47 → 26.3.49
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.
- package/dist/index.js +1661 -886
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -571,7 +571,7 @@ import {
|
|
|
571
571
|
isEntityScopedKind,
|
|
572
572
|
extractId
|
|
573
573
|
} from "@thecorporation/corp-tools";
|
|
574
|
-
var NodeReferenceStorage, ReferenceResolver;
|
|
574
|
+
var NodeReferenceStorage, GLOBAL_KEY, ReferenceResolver;
|
|
575
575
|
var init_references = __esm({
|
|
576
576
|
"src/references.ts"() {
|
|
577
577
|
"use strict";
|
|
@@ -590,39 +590,178 @@ var init_references = __esm({
|
|
|
590
590
|
return getActiveEntityId(this.cfg);
|
|
591
591
|
}
|
|
592
592
|
};
|
|
593
|
+
GLOBAL_KEY = "__global__";
|
|
593
594
|
ReferenceResolver = class {
|
|
594
595
|
client;
|
|
595
596
|
cfg;
|
|
596
597
|
tracker;
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
bankAccountsCache = /* @__PURE__ */ new Map();
|
|
602
|
-
paymentsCache = /* @__PURE__ */ new Map();
|
|
603
|
-
payrollRunsCache = /* @__PURE__ */ new Map();
|
|
604
|
-
distributionsCache = /* @__PURE__ */ new Map();
|
|
605
|
-
reconciliationsCache = /* @__PURE__ */ new Map();
|
|
606
|
-
taxFilingsCache = /* @__PURE__ */ new Map();
|
|
607
|
-
deadlinesCache = /* @__PURE__ */ new Map();
|
|
608
|
-
classificationsCache = /* @__PURE__ */ new Map();
|
|
609
|
-
bodiesCache = /* @__PURE__ */ new Map();
|
|
610
|
-
meetingsCache = /* @__PURE__ */ new Map();
|
|
611
|
-
seatsCache = /* @__PURE__ */ new Map();
|
|
612
|
-
agendaCache = /* @__PURE__ */ new Map();
|
|
613
|
-
resolutionsCache = /* @__PURE__ */ new Map();
|
|
614
|
-
documentsCache = /* @__PURE__ */ new Map();
|
|
615
|
-
workItemsCache = /* @__PURE__ */ new Map();
|
|
616
|
-
valuationsCache = /* @__PURE__ */ new Map();
|
|
617
|
-
safeNotesCache = /* @__PURE__ */ new Map();
|
|
618
|
-
roundsCache = /* @__PURE__ */ new Map();
|
|
619
|
-
serviceRequestsCache = /* @__PURE__ */ new Map();
|
|
598
|
+
// Single unified cache: ResourceKind → (cacheKey → records)
|
|
599
|
+
recordsCache = /* @__PURE__ */ new Map();
|
|
600
|
+
// Cap table is fetched as a single object; instruments/share_classes are
|
|
601
|
+
// derived from it, so we keep its own dedicated cache.
|
|
620
602
|
capTableCache = /* @__PURE__ */ new Map();
|
|
621
|
-
|
|
603
|
+
// Dispatch table: ResourceKind → fetcher that receives the scope and
|
|
604
|
+
// returns the raw (uncached) records for that kind.
|
|
605
|
+
fetchers;
|
|
622
606
|
constructor(client, cfg) {
|
|
623
607
|
this.client = client;
|
|
624
608
|
this.cfg = cfg;
|
|
625
609
|
this.tracker = new ReferenceTracker(new NodeReferenceStorage(cfg));
|
|
610
|
+
this.fetchers = /* @__PURE__ */ new Map([
|
|
611
|
+
["entity", async (_scope) => ({
|
|
612
|
+
key: GLOBAL_KEY,
|
|
613
|
+
records: await this.client.listEntities()
|
|
614
|
+
})],
|
|
615
|
+
["agent", async (_scope) => ({
|
|
616
|
+
key: GLOBAL_KEY,
|
|
617
|
+
records: await this.client.listAgents()
|
|
618
|
+
})],
|
|
619
|
+
["contact", async ({ entityId }) => {
|
|
620
|
+
if (!entityId) throw new Error("An entity context is required to resolve contacts.");
|
|
621
|
+
return { key: entityId, records: await this.client.listContacts(entityId) };
|
|
622
|
+
}],
|
|
623
|
+
["share_transfer", async ({ entityId }) => {
|
|
624
|
+
if (!entityId) throw new Error("An entity context is required to resolve share transfers.");
|
|
625
|
+
return { key: entityId, records: await this.client.listShareTransfers(entityId) };
|
|
626
|
+
}],
|
|
627
|
+
["invoice", async ({ entityId }) => {
|
|
628
|
+
if (!entityId) throw new Error("An entity context is required to resolve invoices.");
|
|
629
|
+
return { key: entityId, records: await this.client.listInvoices(entityId) };
|
|
630
|
+
}],
|
|
631
|
+
["bank_account", async ({ entityId }) => {
|
|
632
|
+
if (!entityId) throw new Error("An entity context is required to resolve bank accounts.");
|
|
633
|
+
return { key: entityId, records: await this.client.listBankAccounts(entityId) };
|
|
634
|
+
}],
|
|
635
|
+
["payment", async ({ entityId }) => {
|
|
636
|
+
if (!entityId) throw new Error("An entity context is required to resolve payments.");
|
|
637
|
+
return { key: entityId, records: await this.client.listPayments(entityId) };
|
|
638
|
+
}],
|
|
639
|
+
["payroll_run", async ({ entityId }) => {
|
|
640
|
+
if (!entityId) throw new Error("An entity context is required to resolve payroll runs.");
|
|
641
|
+
return { key: entityId, records: await this.client.listPayrollRuns(entityId) };
|
|
642
|
+
}],
|
|
643
|
+
["distribution", async ({ entityId }) => {
|
|
644
|
+
if (!entityId) throw new Error("An entity context is required to resolve distributions.");
|
|
645
|
+
return { key: entityId, records: await this.client.listDistributions(entityId) };
|
|
646
|
+
}],
|
|
647
|
+
["reconciliation", async ({ entityId }) => {
|
|
648
|
+
if (!entityId) throw new Error("An entity context is required to resolve reconciliations.");
|
|
649
|
+
return { key: entityId, records: await this.client.listReconciliations(entityId) };
|
|
650
|
+
}],
|
|
651
|
+
["tax_filing", async ({ entityId }) => {
|
|
652
|
+
if (!entityId) throw new Error("An entity context is required to resolve tax filings.");
|
|
653
|
+
return { key: entityId, records: await this.client.listTaxFilings(entityId) };
|
|
654
|
+
}],
|
|
655
|
+
["deadline", async ({ entityId }) => {
|
|
656
|
+
if (!entityId) throw new Error("An entity context is required to resolve deadlines.");
|
|
657
|
+
return { key: entityId, records: await this.client.listDeadlines(entityId) };
|
|
658
|
+
}],
|
|
659
|
+
["classification", async ({ entityId }) => {
|
|
660
|
+
if (!entityId) throw new Error("An entity context is required to resolve contractor classifications.");
|
|
661
|
+
return { key: entityId, records: await this.client.listContractorClassifications(entityId) };
|
|
662
|
+
}],
|
|
663
|
+
["body", async ({ entityId }) => {
|
|
664
|
+
if (!entityId) throw new Error("An entity context is required to resolve governance bodies.");
|
|
665
|
+
return { key: entityId, records: await this.client.listGovernanceBodies(entityId) };
|
|
666
|
+
}],
|
|
667
|
+
["meeting", async ({ entityId, bodyId }) => {
|
|
668
|
+
if (!entityId) throw new Error("An entity context is required to resolve meetings.");
|
|
669
|
+
const cacheKey = `${entityId}:${bodyId ?? "*"}`;
|
|
670
|
+
const meetings = [];
|
|
671
|
+
if (bodyId) {
|
|
672
|
+
meetings.push(...await this.client.listMeetings(bodyId, entityId));
|
|
673
|
+
} else {
|
|
674
|
+
const bodies = await this.getCachedRecords("body", { entityId });
|
|
675
|
+
for (const body of bodies) {
|
|
676
|
+
const resolvedBodyId = extractId(body, ["body_id", "id"]);
|
|
677
|
+
if (!resolvedBodyId) continue;
|
|
678
|
+
meetings.push(...await this.client.listMeetings(resolvedBodyId, entityId));
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
return { key: cacheKey, records: meetings };
|
|
682
|
+
}],
|
|
683
|
+
["seat", async ({ entityId, bodyId }) => {
|
|
684
|
+
if (!entityId) throw new Error("An entity context is required to resolve seats.");
|
|
685
|
+
const cacheKey = `${entityId}:${bodyId ?? "*"}`;
|
|
686
|
+
const seats = [];
|
|
687
|
+
if (bodyId) {
|
|
688
|
+
seats.push(...await this.client.getGovernanceSeats(bodyId, entityId));
|
|
689
|
+
} else {
|
|
690
|
+
const bodies = await this.getCachedRecords("body", { entityId });
|
|
691
|
+
for (const body of bodies) {
|
|
692
|
+
const resolvedBodyId = extractId(body, ["body_id", "id"]);
|
|
693
|
+
if (!resolvedBodyId) continue;
|
|
694
|
+
seats.push(...await this.client.getGovernanceSeats(resolvedBodyId, entityId));
|
|
695
|
+
}
|
|
696
|
+
}
|
|
697
|
+
return { key: cacheKey, records: seats };
|
|
698
|
+
}],
|
|
699
|
+
["agenda_item", async ({ entityId, meetingId }) => {
|
|
700
|
+
if (!entityId || !meetingId) {
|
|
701
|
+
throw new Error("Entity and meeting context are required to resolve agenda items.");
|
|
702
|
+
}
|
|
703
|
+
return {
|
|
704
|
+
key: `${entityId}:${meetingId}`,
|
|
705
|
+
records: await this.client.listAgendaItems(meetingId, entityId)
|
|
706
|
+
};
|
|
707
|
+
}],
|
|
708
|
+
["resolution", async ({ entityId, meetingId }) => {
|
|
709
|
+
if (!entityId) throw new Error("An entity context is required to resolve resolutions.");
|
|
710
|
+
const cacheKey = `${entityId}:${meetingId ?? "*"}`;
|
|
711
|
+
const resolutions = [];
|
|
712
|
+
if (meetingId) {
|
|
713
|
+
resolutions.push(...await this.client.getMeetingResolutions(meetingId, entityId));
|
|
714
|
+
} else {
|
|
715
|
+
const meetings = await this.getCachedRecords("meeting", { entityId });
|
|
716
|
+
for (const meeting of meetings) {
|
|
717
|
+
const resolvedMeetingId = extractId(meeting, ["meeting_id", "id"]);
|
|
718
|
+
if (!resolvedMeetingId) continue;
|
|
719
|
+
resolutions.push(...await this.client.getMeetingResolutions(resolvedMeetingId, entityId));
|
|
720
|
+
}
|
|
721
|
+
}
|
|
722
|
+
return { key: cacheKey, records: resolutions };
|
|
723
|
+
}],
|
|
724
|
+
["document", async ({ entityId }) => {
|
|
725
|
+
if (!entityId) throw new Error("An entity context is required to resolve documents.");
|
|
726
|
+
return { key: entityId, records: await this.client.getEntityDocuments(entityId) };
|
|
727
|
+
}],
|
|
728
|
+
["work_item", async ({ entityId }) => {
|
|
729
|
+
if (!entityId) throw new Error("An entity context is required to resolve work items.");
|
|
730
|
+
return { key: entityId, records: await this.client.listWorkItems(entityId) };
|
|
731
|
+
}],
|
|
732
|
+
["valuation", async ({ entityId }) => {
|
|
733
|
+
if (!entityId) throw new Error("An entity context is required to resolve valuations.");
|
|
734
|
+
return { key: entityId, records: await this.client.getValuations(entityId) };
|
|
735
|
+
}],
|
|
736
|
+
["safe_note", async ({ entityId }) => {
|
|
737
|
+
if (!entityId) throw new Error("An entity context is required to resolve SAFE notes.");
|
|
738
|
+
return { key: entityId, records: await this.client.getSafeNotes(entityId) };
|
|
739
|
+
}],
|
|
740
|
+
["instrument", async ({ entityId }) => {
|
|
741
|
+
if (!entityId) throw new Error("An entity context is required to resolve cap table resources.");
|
|
742
|
+
const capTable = await this.getCapTable(entityId);
|
|
743
|
+
return {
|
|
744
|
+
key: entityId,
|
|
745
|
+
records: Array.isArray(capTable.instruments) ? capTable.instruments : []
|
|
746
|
+
};
|
|
747
|
+
}],
|
|
748
|
+
["share_class", async ({ entityId }) => {
|
|
749
|
+
if (!entityId) throw new Error("An entity context is required to resolve cap table resources.");
|
|
750
|
+
const capTable = await this.getCapTable(entityId);
|
|
751
|
+
return {
|
|
752
|
+
key: entityId,
|
|
753
|
+
records: Array.isArray(capTable.share_classes) ? capTable.share_classes : []
|
|
754
|
+
};
|
|
755
|
+
}],
|
|
756
|
+
["round", async ({ entityId }) => {
|
|
757
|
+
if (!entityId) throw new Error("An entity context is required to resolve rounds.");
|
|
758
|
+
return { key: entityId, records: await this.client.listEquityRounds(entityId) };
|
|
759
|
+
}],
|
|
760
|
+
["service_request", async ({ entityId }) => {
|
|
761
|
+
if (!entityId) throw new Error("An entity context is required to resolve service requests.");
|
|
762
|
+
return { key: entityId, records: await this.client.listServiceRequests(entityId) };
|
|
763
|
+
}]
|
|
764
|
+
]);
|
|
626
765
|
}
|
|
627
766
|
/**
|
|
628
767
|
* Public generic resolver for any resource kind.
|
|
@@ -846,64 +985,63 @@ var init_references = __esm({
|
|
|
846
985
|
return `Ambiguous ${kindLabel(kind)} reference "${ref}". Matches: ${previews}. Try: corp find ${kind} ${JSON.stringify(ref)}`;
|
|
847
986
|
}
|
|
848
987
|
async listRecords(kind, scope) {
|
|
849
|
-
const records = await (
|
|
850
|
-
switch (kind) {
|
|
851
|
-
case "entity":
|
|
852
|
-
return this.listEntities();
|
|
853
|
-
case "contact":
|
|
854
|
-
return this.listContacts(scope.entityId);
|
|
855
|
-
case "share_transfer":
|
|
856
|
-
return this.listShareTransfers(scope.entityId);
|
|
857
|
-
case "invoice":
|
|
858
|
-
return this.listInvoices(scope.entityId);
|
|
859
|
-
case "bank_account":
|
|
860
|
-
return this.listBankAccounts(scope.entityId);
|
|
861
|
-
case "payment":
|
|
862
|
-
return this.listPayments(scope.entityId);
|
|
863
|
-
case "payroll_run":
|
|
864
|
-
return this.listPayrollRuns(scope.entityId);
|
|
865
|
-
case "distribution":
|
|
866
|
-
return this.listDistributions(scope.entityId);
|
|
867
|
-
case "reconciliation":
|
|
868
|
-
return this.listReconciliations(scope.entityId);
|
|
869
|
-
case "tax_filing":
|
|
870
|
-
return this.listTaxFilings(scope.entityId);
|
|
871
|
-
case "deadline":
|
|
872
|
-
return this.listDeadlines(scope.entityId);
|
|
873
|
-
case "classification":
|
|
874
|
-
return this.listClassifications(scope.entityId);
|
|
875
|
-
case "body":
|
|
876
|
-
return this.listBodies(scope.entityId);
|
|
877
|
-
case "meeting":
|
|
878
|
-
return this.listMeetings(scope.entityId, scope.bodyId);
|
|
879
|
-
case "seat":
|
|
880
|
-
return this.listSeats(scope.entityId, scope.bodyId);
|
|
881
|
-
case "agenda_item":
|
|
882
|
-
return this.listAgendaItems(scope.entityId, scope.meetingId);
|
|
883
|
-
case "resolution":
|
|
884
|
-
return this.listResolutions(scope.entityId, scope.meetingId);
|
|
885
|
-
case "document":
|
|
886
|
-
return this.listDocuments(scope.entityId);
|
|
887
|
-
case "work_item":
|
|
888
|
-
return this.listWorkItems(scope.entityId);
|
|
889
|
-
case "agent":
|
|
890
|
-
return this.listAgents();
|
|
891
|
-
case "valuation":
|
|
892
|
-
return this.listValuations(scope.entityId);
|
|
893
|
-
case "safe_note":
|
|
894
|
-
return this.listSafeNotes(scope.entityId);
|
|
895
|
-
case "instrument":
|
|
896
|
-
return this.listInstruments(scope.entityId);
|
|
897
|
-
case "share_class":
|
|
898
|
-
return this.listShareClasses(scope.entityId);
|
|
899
|
-
case "round":
|
|
900
|
-
return this.listRounds(scope.entityId);
|
|
901
|
-
case "service_request":
|
|
902
|
-
return this.listServiceRequestRecords(scope.entityId);
|
|
903
|
-
}
|
|
904
|
-
})();
|
|
988
|
+
const records = await this.getCachedRecords(kind, scope);
|
|
905
989
|
return this.attachStableHandles(kind, records, scope.entityId);
|
|
906
990
|
}
|
|
991
|
+
/**
|
|
992
|
+
* Returns the cached records for a given kind and scope, invoking the
|
|
993
|
+
* fetcher on a cache miss. Does NOT attach stable handles — use
|
|
994
|
+
* `listRecords` for that.
|
|
995
|
+
*/
|
|
996
|
+
async getCachedRecords(kind, scope) {
|
|
997
|
+
const fetcher = this.fetchers.get(kind);
|
|
998
|
+
if (!fetcher) {
|
|
999
|
+
throw new Error(`No fetcher registered for resource kind "${kind}".`);
|
|
1000
|
+
}
|
|
1001
|
+
let kindCache = this.recordsCache.get(kind);
|
|
1002
|
+
if (!kindCache) {
|
|
1003
|
+
kindCache = /* @__PURE__ */ new Map();
|
|
1004
|
+
this.recordsCache.set(kind, kindCache);
|
|
1005
|
+
}
|
|
1006
|
+
const probeKey = this.probeKey(kind, scope);
|
|
1007
|
+
if (probeKey !== void 0) {
|
|
1008
|
+
const hit2 = kindCache.get(probeKey);
|
|
1009
|
+
if (hit2) return hit2;
|
|
1010
|
+
const { key: key2, records: records2 } = await fetcher(scope);
|
|
1011
|
+
kindCache.set(key2, records2);
|
|
1012
|
+
return records2;
|
|
1013
|
+
}
|
|
1014
|
+
const { key, records } = await fetcher(scope);
|
|
1015
|
+
const hit = kindCache.get(key);
|
|
1016
|
+
if (hit) return hit;
|
|
1017
|
+
kindCache.set(key, records);
|
|
1018
|
+
return records;
|
|
1019
|
+
}
|
|
1020
|
+
/**
|
|
1021
|
+
* Returns the expected cache key for a given kind and scope without
|
|
1022
|
+
* invoking the fetcher. Returns `undefined` if the key cannot be
|
|
1023
|
+
* determined without fetching (e.g., composite-key kinds that need to
|
|
1024
|
+
* enumerate sub-resources first).
|
|
1025
|
+
*/
|
|
1026
|
+
probeKey(kind, scope) {
|
|
1027
|
+
switch (kind) {
|
|
1028
|
+
case "entity":
|
|
1029
|
+
case "agent":
|
|
1030
|
+
return GLOBAL_KEY;
|
|
1031
|
+
case "meeting":
|
|
1032
|
+
case "seat":
|
|
1033
|
+
if (!scope.entityId) return GLOBAL_KEY;
|
|
1034
|
+
return `${scope.entityId}:${scope.bodyId ?? "*"}`;
|
|
1035
|
+
case "agenda_item":
|
|
1036
|
+
if (!scope.entityId || !scope.meetingId) return GLOBAL_KEY;
|
|
1037
|
+
return `${scope.entityId}:${scope.meetingId}`;
|
|
1038
|
+
case "resolution":
|
|
1039
|
+
if (!scope.entityId) return GLOBAL_KEY;
|
|
1040
|
+
return `${scope.entityId}:${scope.meetingId ?? "*"}`;
|
|
1041
|
+
default:
|
|
1042
|
+
return scope.entityId ?? GLOBAL_KEY;
|
|
1043
|
+
}
|
|
1044
|
+
}
|
|
907
1045
|
async attachStableHandles(kind, records, entityId) {
|
|
908
1046
|
const missing = records.map((record) => ({ record, described: describeReferenceRecord2(kind, record) })).filter(
|
|
909
1047
|
(entry) => entry.described !== null && !(typeof entry.record.handle === "string" && entry.record.handle.trim().length > 0)
|
|
@@ -938,221 +1076,6 @@ var init_references = __esm({
|
|
|
938
1076
|
}
|
|
939
1077
|
return records;
|
|
940
1078
|
}
|
|
941
|
-
async listEntities() {
|
|
942
|
-
if (!this.entityCache) {
|
|
943
|
-
this.entityCache = await this.client.listEntities();
|
|
944
|
-
}
|
|
945
|
-
return this.entityCache;
|
|
946
|
-
}
|
|
947
|
-
async listContacts(entityId) {
|
|
948
|
-
if (!entityId) throw new Error("An entity context is required to resolve contacts.");
|
|
949
|
-
const cached = this.contactsCache.get(entityId);
|
|
950
|
-
if (cached) return cached;
|
|
951
|
-
const contacts = await this.client.listContacts(entityId);
|
|
952
|
-
this.contactsCache.set(entityId, contacts);
|
|
953
|
-
return contacts;
|
|
954
|
-
}
|
|
955
|
-
async listShareTransfers(entityId) {
|
|
956
|
-
if (!entityId) throw new Error("An entity context is required to resolve share transfers.");
|
|
957
|
-
const cached = this.shareTransfersCache.get(entityId);
|
|
958
|
-
if (cached) return cached;
|
|
959
|
-
const transfers = await this.client.listShareTransfers(entityId);
|
|
960
|
-
this.shareTransfersCache.set(entityId, transfers);
|
|
961
|
-
return transfers;
|
|
962
|
-
}
|
|
963
|
-
async listInvoices(entityId) {
|
|
964
|
-
if (!entityId) throw new Error("An entity context is required to resolve invoices.");
|
|
965
|
-
const cached = this.invoicesCache.get(entityId);
|
|
966
|
-
if (cached) return cached;
|
|
967
|
-
const invoices = await this.client.listInvoices(entityId);
|
|
968
|
-
this.invoicesCache.set(entityId, invoices);
|
|
969
|
-
return invoices;
|
|
970
|
-
}
|
|
971
|
-
async listBankAccounts(entityId) {
|
|
972
|
-
if (!entityId) throw new Error("An entity context is required to resolve bank accounts.");
|
|
973
|
-
const cached = this.bankAccountsCache.get(entityId);
|
|
974
|
-
if (cached) return cached;
|
|
975
|
-
const bankAccounts = await this.client.listBankAccounts(entityId);
|
|
976
|
-
this.bankAccountsCache.set(entityId, bankAccounts);
|
|
977
|
-
return bankAccounts;
|
|
978
|
-
}
|
|
979
|
-
async listPayments(entityId) {
|
|
980
|
-
if (!entityId) throw new Error("An entity context is required to resolve payments.");
|
|
981
|
-
const cached = this.paymentsCache.get(entityId);
|
|
982
|
-
if (cached) return cached;
|
|
983
|
-
const payments = await this.client.listPayments(entityId);
|
|
984
|
-
this.paymentsCache.set(entityId, payments);
|
|
985
|
-
return payments;
|
|
986
|
-
}
|
|
987
|
-
async listPayrollRuns(entityId) {
|
|
988
|
-
if (!entityId) throw new Error("An entity context is required to resolve payroll runs.");
|
|
989
|
-
const cached = this.payrollRunsCache.get(entityId);
|
|
990
|
-
if (cached) return cached;
|
|
991
|
-
const payrollRuns = await this.client.listPayrollRuns(entityId);
|
|
992
|
-
this.payrollRunsCache.set(entityId, payrollRuns);
|
|
993
|
-
return payrollRuns;
|
|
994
|
-
}
|
|
995
|
-
async listDistributions(entityId) {
|
|
996
|
-
if (!entityId) throw new Error("An entity context is required to resolve distributions.");
|
|
997
|
-
const cached = this.distributionsCache.get(entityId);
|
|
998
|
-
if (cached) return cached;
|
|
999
|
-
const distributions = await this.client.listDistributions(entityId);
|
|
1000
|
-
this.distributionsCache.set(entityId, distributions);
|
|
1001
|
-
return distributions;
|
|
1002
|
-
}
|
|
1003
|
-
async listReconciliations(entityId) {
|
|
1004
|
-
if (!entityId) throw new Error("An entity context is required to resolve reconciliations.");
|
|
1005
|
-
const cached = this.reconciliationsCache.get(entityId);
|
|
1006
|
-
if (cached) return cached;
|
|
1007
|
-
const reconciliations = await this.client.listReconciliations(entityId);
|
|
1008
|
-
this.reconciliationsCache.set(entityId, reconciliations);
|
|
1009
|
-
return reconciliations;
|
|
1010
|
-
}
|
|
1011
|
-
async listTaxFilings(entityId) {
|
|
1012
|
-
if (!entityId) throw new Error("An entity context is required to resolve tax filings.");
|
|
1013
|
-
const cached = this.taxFilingsCache.get(entityId);
|
|
1014
|
-
if (cached) return cached;
|
|
1015
|
-
const filings = await this.client.listTaxFilings(entityId);
|
|
1016
|
-
this.taxFilingsCache.set(entityId, filings);
|
|
1017
|
-
return filings;
|
|
1018
|
-
}
|
|
1019
|
-
async listDeadlines(entityId) {
|
|
1020
|
-
if (!entityId) throw new Error("An entity context is required to resolve deadlines.");
|
|
1021
|
-
const cached = this.deadlinesCache.get(entityId);
|
|
1022
|
-
if (cached) return cached;
|
|
1023
|
-
const deadlines = await this.client.listDeadlines(entityId);
|
|
1024
|
-
this.deadlinesCache.set(entityId, deadlines);
|
|
1025
|
-
return deadlines;
|
|
1026
|
-
}
|
|
1027
|
-
async listClassifications(entityId) {
|
|
1028
|
-
if (!entityId) throw new Error("An entity context is required to resolve contractor classifications.");
|
|
1029
|
-
const cached = this.classificationsCache.get(entityId);
|
|
1030
|
-
if (cached) return cached;
|
|
1031
|
-
const classifications = await this.client.listContractorClassifications(entityId);
|
|
1032
|
-
this.classificationsCache.set(entityId, classifications);
|
|
1033
|
-
return classifications;
|
|
1034
|
-
}
|
|
1035
|
-
async listBodies(entityId) {
|
|
1036
|
-
if (!entityId) throw new Error("An entity context is required to resolve governance bodies.");
|
|
1037
|
-
const cached = this.bodiesCache.get(entityId);
|
|
1038
|
-
if (cached) return cached;
|
|
1039
|
-
const bodies = await this.client.listGovernanceBodies(entityId);
|
|
1040
|
-
this.bodiesCache.set(entityId, bodies);
|
|
1041
|
-
return bodies;
|
|
1042
|
-
}
|
|
1043
|
-
async listMeetings(entityId, bodyId) {
|
|
1044
|
-
if (!entityId) throw new Error("An entity context is required to resolve meetings.");
|
|
1045
|
-
const cacheKey = `${entityId}:${bodyId ?? "*"}`;
|
|
1046
|
-
const cached = this.meetingsCache.get(cacheKey);
|
|
1047
|
-
if (cached) return cached;
|
|
1048
|
-
const meetings = [];
|
|
1049
|
-
if (bodyId) {
|
|
1050
|
-
meetings.push(...await this.client.listMeetings(bodyId, entityId));
|
|
1051
|
-
} else {
|
|
1052
|
-
const bodies = await this.listBodies(entityId);
|
|
1053
|
-
for (const body of bodies) {
|
|
1054
|
-
const resolvedBodyId = extractId(body, ["body_id", "id"]);
|
|
1055
|
-
if (!resolvedBodyId) continue;
|
|
1056
|
-
meetings.push(...await this.client.listMeetings(resolvedBodyId, entityId));
|
|
1057
|
-
}
|
|
1058
|
-
}
|
|
1059
|
-
this.meetingsCache.set(cacheKey, meetings);
|
|
1060
|
-
return meetings;
|
|
1061
|
-
}
|
|
1062
|
-
async listSeats(entityId, bodyId) {
|
|
1063
|
-
if (!entityId) throw new Error("An entity context is required to resolve seats.");
|
|
1064
|
-
const cacheKey = `${entityId}:${bodyId ?? "*"}`;
|
|
1065
|
-
const cached = this.seatsCache.get(cacheKey);
|
|
1066
|
-
if (cached) return cached;
|
|
1067
|
-
const seats = [];
|
|
1068
|
-
if (bodyId) {
|
|
1069
|
-
seats.push(...await this.client.getGovernanceSeats(bodyId, entityId));
|
|
1070
|
-
} else {
|
|
1071
|
-
const bodies = await this.listBodies(entityId);
|
|
1072
|
-
for (const body of bodies) {
|
|
1073
|
-
const resolvedBodyId = extractId(body, ["body_id", "id"]);
|
|
1074
|
-
if (!resolvedBodyId) continue;
|
|
1075
|
-
seats.push(...await this.client.getGovernanceSeats(resolvedBodyId, entityId));
|
|
1076
|
-
}
|
|
1077
|
-
}
|
|
1078
|
-
this.seatsCache.set(cacheKey, seats);
|
|
1079
|
-
return seats;
|
|
1080
|
-
}
|
|
1081
|
-
async listAgendaItems(entityId, meetingId) {
|
|
1082
|
-
if (!entityId || !meetingId) {
|
|
1083
|
-
throw new Error("Entity and meeting context are required to resolve agenda items.");
|
|
1084
|
-
}
|
|
1085
|
-
const cached = this.agendaCache.get(`${entityId}:${meetingId}`);
|
|
1086
|
-
if (cached) return cached;
|
|
1087
|
-
const items = await this.client.listAgendaItems(meetingId, entityId);
|
|
1088
|
-
this.agendaCache.set(`${entityId}:${meetingId}`, items);
|
|
1089
|
-
return items;
|
|
1090
|
-
}
|
|
1091
|
-
async listResolutions(entityId, meetingId) {
|
|
1092
|
-
if (!entityId) throw new Error("An entity context is required to resolve resolutions.");
|
|
1093
|
-
const cacheKey = `${entityId}:${meetingId ?? "*"}`;
|
|
1094
|
-
const cached = this.resolutionsCache.get(cacheKey);
|
|
1095
|
-
if (cached) return cached;
|
|
1096
|
-
const resolutions = [];
|
|
1097
|
-
if (meetingId) {
|
|
1098
|
-
resolutions.push(...await this.client.getMeetingResolutions(meetingId, entityId));
|
|
1099
|
-
} else {
|
|
1100
|
-
const meetings = await this.listMeetings(entityId);
|
|
1101
|
-
for (const meeting of meetings) {
|
|
1102
|
-
const resolvedMeetingId = extractId(meeting, ["meeting_id", "id"]);
|
|
1103
|
-
if (!resolvedMeetingId) continue;
|
|
1104
|
-
resolutions.push(...await this.client.getMeetingResolutions(resolvedMeetingId, entityId));
|
|
1105
|
-
}
|
|
1106
|
-
}
|
|
1107
|
-
this.resolutionsCache.set(cacheKey, resolutions);
|
|
1108
|
-
return resolutions;
|
|
1109
|
-
}
|
|
1110
|
-
async listDocuments(entityId) {
|
|
1111
|
-
if (!entityId) throw new Error("An entity context is required to resolve documents.");
|
|
1112
|
-
const cached = this.documentsCache.get(entityId);
|
|
1113
|
-
if (cached) return cached;
|
|
1114
|
-
const docs = await this.client.getEntityDocuments(entityId);
|
|
1115
|
-
this.documentsCache.set(entityId, docs);
|
|
1116
|
-
return docs;
|
|
1117
|
-
}
|
|
1118
|
-
async listWorkItems(entityId) {
|
|
1119
|
-
if (!entityId) throw new Error("An entity context is required to resolve work items.");
|
|
1120
|
-
const cached = this.workItemsCache.get(entityId);
|
|
1121
|
-
if (cached) return cached;
|
|
1122
|
-
const items = await this.client.listWorkItems(entityId);
|
|
1123
|
-
this.workItemsCache.set(entityId, items);
|
|
1124
|
-
return items;
|
|
1125
|
-
}
|
|
1126
|
-
async listAgents() {
|
|
1127
|
-
if (!this.agentsCache) {
|
|
1128
|
-
this.agentsCache = await this.client.listAgents();
|
|
1129
|
-
}
|
|
1130
|
-
return this.agentsCache;
|
|
1131
|
-
}
|
|
1132
|
-
async listValuations(entityId) {
|
|
1133
|
-
if (!entityId) throw new Error("An entity context is required to resolve valuations.");
|
|
1134
|
-
const cached = this.valuationsCache.get(entityId);
|
|
1135
|
-
if (cached) return cached;
|
|
1136
|
-
const valuations = await this.client.getValuations(entityId);
|
|
1137
|
-
this.valuationsCache.set(entityId, valuations);
|
|
1138
|
-
return valuations;
|
|
1139
|
-
}
|
|
1140
|
-
async listSafeNotes(entityId) {
|
|
1141
|
-
if (!entityId) throw new Error("An entity context is required to resolve SAFE notes.");
|
|
1142
|
-
const cached = this.safeNotesCache.get(entityId);
|
|
1143
|
-
if (cached) return cached;
|
|
1144
|
-
const safeNotes = await this.client.getSafeNotes(entityId);
|
|
1145
|
-
this.safeNotesCache.set(entityId, safeNotes);
|
|
1146
|
-
return safeNotes;
|
|
1147
|
-
}
|
|
1148
|
-
async listRounds(entityId) {
|
|
1149
|
-
if (!entityId) throw new Error("An entity context is required to resolve rounds.");
|
|
1150
|
-
const cached = this.roundsCache.get(entityId);
|
|
1151
|
-
if (cached) return cached;
|
|
1152
|
-
const rounds = await this.client.listEquityRounds(entityId);
|
|
1153
|
-
this.roundsCache.set(entityId, rounds);
|
|
1154
|
-
return rounds;
|
|
1155
|
-
}
|
|
1156
1079
|
async getCapTable(entityId) {
|
|
1157
1080
|
if (!entityId) throw new Error("An entity context is required to resolve cap table resources.");
|
|
1158
1081
|
const cached = this.capTableCache.get(entityId);
|
|
@@ -1161,22 +1084,6 @@ var init_references = __esm({
|
|
|
1161
1084
|
this.capTableCache.set(entityId, capTable);
|
|
1162
1085
|
return capTable;
|
|
1163
1086
|
}
|
|
1164
|
-
async listInstruments(entityId) {
|
|
1165
|
-
const capTable = await this.getCapTable(entityId);
|
|
1166
|
-
return Array.isArray(capTable.instruments) ? capTable.instruments : [];
|
|
1167
|
-
}
|
|
1168
|
-
async listShareClasses(entityId) {
|
|
1169
|
-
const capTable = await this.getCapTable(entityId);
|
|
1170
|
-
return Array.isArray(capTable.share_classes) ? capTable.share_classes : [];
|
|
1171
|
-
}
|
|
1172
|
-
async listServiceRequestRecords(entityId) {
|
|
1173
|
-
if (!entityId) throw new Error("An entity context is required to resolve service requests.");
|
|
1174
|
-
const cached = this.serviceRequestsCache.get(entityId);
|
|
1175
|
-
if (cached) return cached;
|
|
1176
|
-
const requests = await this.client.listServiceRequests(entityId);
|
|
1177
|
-
this.serviceRequestsCache.set(entityId, requests);
|
|
1178
|
-
return requests;
|
|
1179
|
-
}
|
|
1180
1087
|
};
|
|
1181
1088
|
}
|
|
1182
1089
|
});
|
|
@@ -2279,7 +2186,7 @@ var init_workspace = __esm({
|
|
|
2279
2186
|
throw new Error(`Failed to resolve entity: ${err}`);
|
|
2280
2187
|
}
|
|
2281
2188
|
},
|
|
2282
|
-
examples: ["corp use", "corp use
|
|
2189
|
+
examples: ["corp use acme", "corp use ent_abc123"]
|
|
2283
2190
|
},
|
|
2284
2191
|
// --- next ---
|
|
2285
2192
|
{
|
|
@@ -2376,7 +2283,7 @@ var init_workspace = __esm({
|
|
|
2376
2283
|
// --- obligations (pure read) ---
|
|
2377
2284
|
{
|
|
2378
2285
|
name: "obligations",
|
|
2379
|
-
description: "List obligations with urgency tiers",
|
|
2286
|
+
description: "List compliance obligations with urgency tiers",
|
|
2380
2287
|
route: { method: "GET", path: "/v1/obligations/summary" },
|
|
2381
2288
|
display: {
|
|
2382
2289
|
title: "Obligations",
|
|
@@ -2390,13 +2297,13 @@ var init_workspace = __esm({
|
|
|
2390
2297
|
]
|
|
2391
2298
|
},
|
|
2392
2299
|
optQP: ["tier"],
|
|
2393
|
-
options: [{ flags: "--tier <tier>", description: "Filter by urgency tier" }],
|
|
2394
|
-
examples: ["corp obligations"]
|
|
2300
|
+
options: [{ flags: "--tier <tier>", description: "Filter by urgency tier", choices: ["critical", "high", "medium", "low"] }],
|
|
2301
|
+
examples: ["corp obligations", "corp obligations --tier critical --json"]
|
|
2395
2302
|
},
|
|
2396
2303
|
// --- digest ---
|
|
2397
2304
|
{
|
|
2398
2305
|
name: "digest",
|
|
2399
|
-
description: "View or trigger
|
|
2306
|
+
description: "View digest history or trigger a new digest",
|
|
2400
2307
|
route: { method: "GET", path: "/v1/digests" },
|
|
2401
2308
|
display: { title: "Digests" },
|
|
2402
2309
|
options: [
|
|
@@ -2413,15 +2320,23 @@ var init_workspace = __esm({
|
|
|
2413
2320
|
const value = result.message;
|
|
2414
2321
|
return typeof value === "string" && value.trim() ? value : null;
|
|
2415
2322
|
})();
|
|
2416
|
-
if (
|
|
2417
|
-
ctx.writer.
|
|
2323
|
+
if (opts.json) {
|
|
2324
|
+
ctx.writer.json(result);
|
|
2325
|
+
return;
|
|
2418
2326
|
}
|
|
2419
|
-
|
|
2327
|
+
ctx.writer.success(result.digest_count > 0 ? "Digest triggered." : "Digest trigger accepted.");
|
|
2328
|
+
if (message) {
|
|
2420
2329
|
ctx.writer.warning(message);
|
|
2421
2330
|
}
|
|
2422
|
-
|
|
2331
|
+
if (result.digest_count != null) {
|
|
2332
|
+
ctx.writer.writeln(` Digest count: ${result.digest_count}`);
|
|
2333
|
+
}
|
|
2423
2334
|
} else if (opts.key) {
|
|
2424
2335
|
const result = await ctx.client.getDigest(opts.key);
|
|
2336
|
+
if (opts.json) {
|
|
2337
|
+
ctx.writer.json(result);
|
|
2338
|
+
return;
|
|
2339
|
+
}
|
|
2425
2340
|
ctx.writer.json(result);
|
|
2426
2341
|
} else {
|
|
2427
2342
|
const digests = await ctx.client.listDigests();
|
|
@@ -2432,6 +2347,10 @@ var init_workspace = __esm({
|
|
|
2432
2347
|
ctx.writer.writeln("No digest history found.");
|
|
2433
2348
|
}
|
|
2434
2349
|
} else {
|
|
2350
|
+
if (opts.json) {
|
|
2351
|
+
ctx.writer.json(digests);
|
|
2352
|
+
return;
|
|
2353
|
+
}
|
|
2435
2354
|
ctx.writer.json(digests);
|
|
2436
2355
|
}
|
|
2437
2356
|
}
|
|
@@ -2439,7 +2358,7 @@ var init_workspace = __esm({
|
|
|
2439
2358
|
throw new Error(`Failed: ${err}`);
|
|
2440
2359
|
}
|
|
2441
2360
|
},
|
|
2442
|
-
examples: ["corp digest"]
|
|
2361
|
+
examples: ["corp digest", "corp digest --trigger", "corp digest --key daily_2026-03-22 --json"]
|
|
2443
2362
|
},
|
|
2444
2363
|
// --- billing ---
|
|
2445
2364
|
{
|
|
@@ -2511,7 +2430,7 @@ var init_workspace = __esm({
|
|
|
2511
2430
|
throw new Error(`Failed to create checkout session: ${err}`);
|
|
2512
2431
|
}
|
|
2513
2432
|
},
|
|
2514
|
-
examples: ["corp billing upgrade"]
|
|
2433
|
+
examples: ["corp billing upgrade", "corp billing upgrade --plan pro", "corp billing upgrade --plan enterprise --json"]
|
|
2515
2434
|
},
|
|
2516
2435
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
2517
2436
|
{
|
|
@@ -2767,10 +2686,10 @@ var init_entities = __esm({
|
|
|
2767
2686
|
},
|
|
2768
2687
|
{
|
|
2769
2688
|
name: "entities show",
|
|
2770
|
-
description: "Show entity
|
|
2771
|
-
args: [{ name: "entity-ref", required: true }],
|
|
2689
|
+
description: "Show detail for a specific entity",
|
|
2690
|
+
args: [{ name: "entity-ref", required: true, description: "Entity name, short ID, or reference" }],
|
|
2772
2691
|
handler: entitiesShowHandler,
|
|
2773
|
-
examples: ["corp entities show"]
|
|
2692
|
+
examples: ["corp entities show acme", "corp entities show ent_abc123 --json"]
|
|
2774
2693
|
},
|
|
2775
2694
|
{
|
|
2776
2695
|
name: "entities convert",
|
|
@@ -2778,11 +2697,11 @@ var init_entities = __esm({
|
|
|
2778
2697
|
route: { method: "POST", path: "/v1/entities/{pos}/convert" },
|
|
2779
2698
|
args: [{ name: "entity-ref", required: true }],
|
|
2780
2699
|
options: [
|
|
2781
|
-
{ flags: "--to <type>", description: "Target entity type
|
|
2782
|
-
{ flags: "--jurisdiction <jurisdiction>", description: "New jurisdiction" }
|
|
2700
|
+
{ flags: "--to <type>", description: "Target entity type", required: true, choices: ["llc", "c_corp"] },
|
|
2701
|
+
{ flags: "--jurisdiction <jurisdiction>", description: "New jurisdiction (e.g. DE, CA)" }
|
|
2783
2702
|
],
|
|
2784
2703
|
handler: entitiesConvertHandler,
|
|
2785
|
-
examples: ["corp entities convert
|
|
2704
|
+
examples: ["corp entities convert acme --to c_corp", "corp entities convert ent_abc123 --to llc --jurisdiction DE --json"]
|
|
2786
2705
|
},
|
|
2787
2706
|
{
|
|
2788
2707
|
name: "entities dissolve",
|
|
@@ -2795,7 +2714,10 @@ var init_entities = __esm({
|
|
|
2795
2714
|
{ flags: "--yes -y", description: "Skip confirmation prompt" }
|
|
2796
2715
|
],
|
|
2797
2716
|
handler: entitiesDissolveHandler,
|
|
2798
|
-
examples: [
|
|
2717
|
+
examples: [
|
|
2718
|
+
"corp entities dissolve acme --reason 'Business wind-down'",
|
|
2719
|
+
"corp entities dissolve ent_abc123 --reason 'Voluntary dissolution' --effective-date 2026-06-01 --yes"
|
|
2720
|
+
]
|
|
2799
2721
|
},
|
|
2800
2722
|
// ── contacts ──
|
|
2801
2723
|
{
|
|
@@ -2818,7 +2740,7 @@ var init_entities = __esm({
|
|
|
2818
2740
|
display: { title: "Contact Profile" },
|
|
2819
2741
|
args: [{ name: "contact-ref", required: true }],
|
|
2820
2742
|
handler: contactsShowHandler,
|
|
2821
|
-
examples: ["corp contacts show", "corp contacts show --json"]
|
|
2743
|
+
examples: ["corp contacts show alice", "corp contacts show con_abc123 --json"]
|
|
2822
2744
|
},
|
|
2823
2745
|
{
|
|
2824
2746
|
name: "contacts add",
|
|
@@ -2828,9 +2750,9 @@ var init_entities = __esm({
|
|
|
2828
2750
|
options: [
|
|
2829
2751
|
{ flags: "--name <name>", description: "Contact name", required: true },
|
|
2830
2752
|
{ flags: "--email <email>", description: "Contact email", required: true },
|
|
2831
|
-
{ flags: "--type <type>", description: "Contact type
|
|
2832
|
-
{ flags: "--category <category>", description: "
|
|
2833
|
-
{ flags: "--cap-table-access <level>", description: "Cap table
|
|
2753
|
+
{ flags: "--type <type>", description: "Contact type", default: "individual", choices: ["individual", "organization"] },
|
|
2754
|
+
{ flags: "--category <category>", description: "Contact role category", choices: ["employee", "contractor", "board_member", "investor", "law_firm", "valuation_firm", "accounting_firm", "officer", "founder", "member", "other"] },
|
|
2755
|
+
{ flags: "--cap-table-access <level>", description: "Cap table visibility level", choices: ["none", "summary", "detailed"] },
|
|
2834
2756
|
{ flags: "--address <address>", description: "Mailing address" },
|
|
2835
2757
|
{ flags: "--mailing-address <address>", description: "Alias for --address" },
|
|
2836
2758
|
{ flags: "--phone <phone>", description: "Phone number" },
|
|
@@ -2839,7 +2761,10 @@ var init_entities = __esm({
|
|
|
2839
2761
|
handler: contactsAddHandler,
|
|
2840
2762
|
produces: { kind: "contact" },
|
|
2841
2763
|
successTemplate: "Contact created: {name}",
|
|
2842
|
-
examples: [
|
|
2764
|
+
examples: [
|
|
2765
|
+
"corp contacts add --name 'Alice Smith' --email alice@example.com --category founder",
|
|
2766
|
+
"corp contacts add --name 'Bob Jones' --email bob@example.com --category employee --type individual --json"
|
|
2767
|
+
]
|
|
2843
2768
|
},
|
|
2844
2769
|
{
|
|
2845
2770
|
name: "contacts edit",
|
|
@@ -2850,15 +2775,18 @@ var init_entities = __esm({
|
|
|
2850
2775
|
options: [
|
|
2851
2776
|
{ flags: "--name <name>", description: "Contact name" },
|
|
2852
2777
|
{ flags: "--email <email>", description: "Contact email" },
|
|
2853
|
-
{ flags: "--category <category>", description: "Contact category" },
|
|
2854
|
-
{ flags: "--cap-table-access <level>", description: "Cap table
|
|
2778
|
+
{ flags: "--category <category>", description: "Contact role category", choices: ["employee", "contractor", "board_member", "investor", "law_firm", "valuation_firm", "accounting_firm", "officer", "founder", "member", "other"] },
|
|
2779
|
+
{ flags: "--cap-table-access <level>", description: "Cap table visibility level", choices: ["none", "summary", "detailed"] },
|
|
2855
2780
|
{ flags: "--address <address>", description: "Mailing address" },
|
|
2856
2781
|
{ flags: "--mailing-address <address>", description: "Alias for --address" },
|
|
2857
2782
|
{ flags: "--phone <phone>", description: "Phone number" },
|
|
2858
2783
|
{ flags: "--notes <notes>", description: "Additional notes" }
|
|
2859
2784
|
],
|
|
2860
2785
|
handler: contactsEditHandler,
|
|
2861
|
-
examples: [
|
|
2786
|
+
examples: [
|
|
2787
|
+
"corp contacts edit alice --email newemail@example.com",
|
|
2788
|
+
"corp contacts edit con_abc123 --category board_member --cap-table-access detailed --json"
|
|
2789
|
+
]
|
|
2862
2790
|
},
|
|
2863
2791
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
2864
2792
|
{
|
|
@@ -2866,21 +2794,24 @@ var init_entities = __esm({
|
|
|
2866
2794
|
description: "View notification preferences for a contact",
|
|
2867
2795
|
route: { method: "GET", path: "/v1/contacts/{pos}/notification-prefs" },
|
|
2868
2796
|
args: [{ name: "contact-id", required: true, description: "Contact ID", posKind: "contact" }],
|
|
2869
|
-
display: { title: "
|
|
2870
|
-
examples: ["corp contacts notification-prefs"]
|
|
2797
|
+
display: { title: "Contact Notification Preferences", cols: ["#contact_id>Contact ID", "email_enabled>Email", "sms_enabled>SMS", "webhook_enabled>Webhook", "@updated_at>Updated"] },
|
|
2798
|
+
examples: ["corp contacts notification-prefs con_abc123", "corp contacts notification-prefs con_abc123 --json"]
|
|
2871
2799
|
},
|
|
2872
2800
|
{
|
|
2873
2801
|
name: "contacts update-notification-prefs",
|
|
2874
|
-
description: "
|
|
2802
|
+
description: "Update notification preferences for a contact",
|
|
2875
2803
|
route: { method: "PATCH", path: "/v1/contacts/{pos}/notification-prefs" },
|
|
2876
2804
|
args: [{ name: "contact-id", required: true, description: "Contact ID", posKind: "contact" }],
|
|
2877
2805
|
options: [
|
|
2878
|
-
{ flags: "--email-enabled <email-enabled>", description: "
|
|
2879
|
-
{ flags: "--sms-enabled <sms-enabled>", description: "
|
|
2880
|
-
{ flags: "--webhook-enabled <webhook-enabled>", description: "
|
|
2806
|
+
{ flags: "--email-enabled <email-enabled>", description: "Enable email notifications (true/false)" },
|
|
2807
|
+
{ flags: "--sms-enabled <sms-enabled>", description: "Enable SMS notifications (true/false)" },
|
|
2808
|
+
{ flags: "--webhook-enabled <webhook-enabled>", description: "Enable webhook notifications (true/false)" }
|
|
2881
2809
|
],
|
|
2882
|
-
examples: [
|
|
2883
|
-
|
|
2810
|
+
examples: [
|
|
2811
|
+
"corp contacts update-notification-prefs con_abc123 --email-enabled true",
|
|
2812
|
+
"corp contacts update-notification-prefs con_abc123 --sms-enabled false --webhook-enabled true --json"
|
|
2813
|
+
],
|
|
2814
|
+
successTemplate: "Notification preferences updated"
|
|
2884
2815
|
}
|
|
2885
2816
|
];
|
|
2886
2817
|
}
|
|
@@ -4268,8 +4199,8 @@ var init_formation = __esm({
|
|
|
4268
4199
|
produces: { kind: "entity", trackEntity: true },
|
|
4269
4200
|
successTemplate: "Pending entity created: {legal_name}",
|
|
4270
4201
|
examples: [
|
|
4271
|
-
'corp form create --type c_corp --name "Acme Inc" --jurisdiction US-DE --address "123 Main,
|
|
4272
|
-
'corp form create --type llc --name "My LLC" --jurisdiction US-WY
|
|
4202
|
+
'corp form create --type c_corp --name "Acme Inc" --jurisdiction US-DE --address "123 Main St,Wilmington,DE,19801"',
|
|
4203
|
+
'corp form create --type llc --name "My LLC" --jurisdiction US-WY'
|
|
4273
4204
|
]
|
|
4274
4205
|
},
|
|
4275
4206
|
{
|
|
@@ -4315,7 +4246,11 @@ var init_formation = __esm({
|
|
|
4315
4246
|
{ flags: "--incorporator-address <address>", description: "Incorporator mailing address (overrides founder)" }
|
|
4316
4247
|
],
|
|
4317
4248
|
handler: formFinalizeHandler,
|
|
4318
|
-
examples: [
|
|
4249
|
+
examples: [
|
|
4250
|
+
"corp form finalize @last:entity",
|
|
4251
|
+
"corp form finalize @last:entity --authorized-shares 10000000 --par-value 0.0001",
|
|
4252
|
+
'corp form finalize @last:entity --company-address "123 Main St,Wilmington,DE,19801" --incorporator-name "Alice Smith"'
|
|
4253
|
+
]
|
|
4319
4254
|
},
|
|
4320
4255
|
{
|
|
4321
4256
|
name: "form activate",
|
|
@@ -4330,21 +4265,28 @@ var init_formation = __esm({
|
|
|
4330
4265
|
{ flags: "--ein <ein>", description: "EIN to confirm (defaults to a deterministic simulated EIN)" }
|
|
4331
4266
|
],
|
|
4332
4267
|
handler: formActivateHandler,
|
|
4333
|
-
examples: [
|
|
4268
|
+
examples: [
|
|
4269
|
+
"corp form activate @last:entity",
|
|
4270
|
+
"corp form activate @last:entity --ein 84-1234567",
|
|
4271
|
+
"corp form activate @last:entity --filing-id DE-2026-0042 --receipt-reference RECEIPT-001"
|
|
4272
|
+
]
|
|
4334
4273
|
},
|
|
4335
4274
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
4336
4275
|
{
|
|
4337
4276
|
name: "contracts",
|
|
4338
|
-
description: "
|
|
4277
|
+
description: "Create a contract document for the active entity",
|
|
4339
4278
|
route: { method: "POST", path: "/v1/contracts" },
|
|
4340
4279
|
options: [
|
|
4341
|
-
{ flags: "--counterparty-name <counterparty-name>", description: "
|
|
4342
|
-
{ flags: "--effective-date <effective-date>", description: "
|
|
4343
|
-
{ flags: "--parameters <parameters>", description: "
|
|
4344
|
-
{ flags: "--template-type <template-type>", description: "
|
|
4280
|
+
{ flags: "--counterparty-name <counterparty-name>", description: "Full legal name of the counterparty", required: true },
|
|
4281
|
+
{ flags: "--effective-date <effective-date>", description: "Contract effective date (YYYY-MM-DD)", required: true },
|
|
4282
|
+
{ flags: "--parameters <parameters>", description: "Additional contract parameters as a JSON object" },
|
|
4283
|
+
{ flags: "--template-type <template-type>", description: "Contract template to use", required: true, choices: ["consulting_agreement", "employment_offer", "contractor_agreement", "nda", "safe_agreement", "custom"] }
|
|
4345
4284
|
],
|
|
4346
|
-
examples: [
|
|
4347
|
-
|
|
4285
|
+
examples: [
|
|
4286
|
+
'corp contracts --template-type consulting_agreement --counterparty-name "Acme Consulting LLC" --effective-date 2026-04-01',
|
|
4287
|
+
'corp contracts --template-type nda --counterparty-name "Partner Corp" --effective-date 2026-04-01 --json'
|
|
4288
|
+
],
|
|
4289
|
+
successTemplate: "Contract created: {contract_id}"
|
|
4348
4290
|
},
|
|
4349
4291
|
{
|
|
4350
4292
|
name: "documents show",
|
|
@@ -4353,7 +4295,7 @@ var init_formation = __esm({
|
|
|
4353
4295
|
entity: true,
|
|
4354
4296
|
args: [{ name: "document-id", required: true, description: "Document ID", posKind: "document" }],
|
|
4355
4297
|
display: { title: "Document", cols: ["document_type>Type", "status>Status", "title>Title", "signature_count>Signatures", "@created_at>Created", "#document_id>ID"] },
|
|
4356
|
-
examples: ["corp documents show
|
|
4298
|
+
examples: ["corp documents show @last", "corp documents show doc-abc123 --json"]
|
|
4357
4299
|
},
|
|
4358
4300
|
{
|
|
4359
4301
|
name: "documents amendment-history",
|
|
@@ -4362,26 +4304,29 @@ var init_formation = __esm({
|
|
|
4362
4304
|
entity: true,
|
|
4363
4305
|
args: [{ name: "document-id", required: true, description: "Document ID", posKind: "document" }],
|
|
4364
4306
|
display: { title: "Documents Amendment History", cols: ["amended_at>Amended At", "description>Description", "version>Version"] },
|
|
4365
|
-
examples: ["corp documents amendment-history", "corp documents amendment-history --json"]
|
|
4307
|
+
examples: ["corp documents amendment-history @last", "corp documents amendment-history doc-abc123 --json"]
|
|
4366
4308
|
},
|
|
4367
4309
|
{
|
|
4368
4310
|
name: "documents pdf",
|
|
4369
4311
|
description: "Download a document as PDF",
|
|
4370
4312
|
route: { method: "GET", path: "/v1/documents/{pos}/pdf" },
|
|
4371
4313
|
entity: true,
|
|
4372
|
-
args: [{ name: "document-id", required: true, description: "Document ID", posKind: "document" }],
|
|
4373
|
-
examples: ["corp documents pdf", "corp documents pdf
|
|
4314
|
+
args: [{ name: "document-id", required: true, description: "Document ID or @last reference", posKind: "document" }],
|
|
4315
|
+
examples: ["corp documents pdf @last", "corp documents pdf doc-abc123"]
|
|
4374
4316
|
},
|
|
4375
4317
|
{
|
|
4376
4318
|
name: "documents request-copy",
|
|
4377
4319
|
description: "Request a certified copy of a document",
|
|
4378
4320
|
route: { method: "POST", path: "/v1/documents/{pos}/request-copy" },
|
|
4379
|
-
args: [{ name: "document-id", required: true, description: "Document ID", posKind: "document" }],
|
|
4321
|
+
args: [{ name: "document-id", required: true, description: "Document ID or @last reference", posKind: "document" }],
|
|
4380
4322
|
options: [
|
|
4381
|
-
{ flags: "--recipient-email <recipient-email>", description: "
|
|
4323
|
+
{ flags: "--recipient-email <recipient-email>", description: "Email address to send the certified copy to" }
|
|
4382
4324
|
],
|
|
4383
|
-
examples: [
|
|
4384
|
-
|
|
4325
|
+
examples: [
|
|
4326
|
+
"corp documents request-copy @last",
|
|
4327
|
+
"corp documents request-copy doc-abc123 --recipient-email alice@acme.com"
|
|
4328
|
+
],
|
|
4329
|
+
successTemplate: "Certified copy requested for document {document_id}"
|
|
4385
4330
|
},
|
|
4386
4331
|
{
|
|
4387
4332
|
name: "entities list",
|
|
@@ -4408,69 +4353,78 @@ var init_formation = __esm({
|
|
|
4408
4353
|
},
|
|
4409
4354
|
{
|
|
4410
4355
|
name: "formations create",
|
|
4411
|
-
description: "
|
|
4356
|
+
description: "Create a new formation with founders and cap table in one step",
|
|
4412
4357
|
route: { method: "POST", path: "/v1/formations" },
|
|
4413
4358
|
options: [
|
|
4414
|
-
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares" },
|
|
4415
|
-
{ flags: "--company-address <company-address>", description: "Company mailing address" },
|
|
4416
|
-
{ flags: "--entity-type <entity-type>", description: "
|
|
4417
|
-
{ flags: "--fiscal-year-end <fiscal-year-end>", description:
|
|
4418
|
-
{ flags: "--formation-date <formation-date>", description: "
|
|
4419
|
-
{ flags: "--jurisdiction <jurisdiction>", description: "
|
|
4359
|
+
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares (e.g. 10000000)" },
|
|
4360
|
+
{ flags: "--company-address <company-address>", description: "Company mailing address as 'street,city,state,zip'" },
|
|
4361
|
+
{ flags: "--entity-type <entity-type>", description: "Legal structure of the entity", required: true, choices: ["c_corp", "llc"] },
|
|
4362
|
+
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (MM-DD, e.g. 12-31). Defaults to 12-31." },
|
|
4363
|
+
{ flags: "--formation-date <formation-date>", description: "Formation date for importing a pre-formed entity (ISO 8601)" },
|
|
4364
|
+
{ flags: "--jurisdiction <jurisdiction>", description: "Incorporation jurisdiction (e.g. US-DE, US-WY)", required: true },
|
|
4420
4365
|
{ flags: "--legal-name <legal-name>", description: "Legal name of the entity", required: true },
|
|
4421
|
-
{ flags: "--members <members>", description: "
|
|
4422
|
-
{ flags: "--par-value <par-value>", description: "Par value per share" },
|
|
4366
|
+
{ flags: "--members <members>", description: "Member/founder entries (repeatable)", required: true, type: "array" },
|
|
4367
|
+
{ flags: "--par-value <par-value>", description: "Par value per share (e.g. 0.0001)" },
|
|
4423
4368
|
{ flags: "--registered-agent-address <registered-agent-address>", description: "Registered agent mailing address" },
|
|
4424
|
-
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent name" },
|
|
4425
|
-
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include right of first refusal in bylaws (corp
|
|
4426
|
-
{ flags: "--s-corp-election <s-corp-election>", description: "
|
|
4427
|
-
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (corp
|
|
4369
|
+
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent legal name" },
|
|
4370
|
+
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include right of first refusal in bylaws (true/false, corp only, default true)" },
|
|
4371
|
+
{ flags: "--s-corp-election <s-corp-election>", description: "Elect S-Corp tax treatment (true/false)" },
|
|
4372
|
+
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (true/false, corp only, default true)" }
|
|
4373
|
+
],
|
|
4374
|
+
examples: [
|
|
4375
|
+
`corp formations create --entity-type c_corp --jurisdiction US-DE --legal-name "Acme Inc" --members '{"name":"Alice","email":"alice@acme.com","role":"director","ownership_pct":100}'`,
|
|
4376
|
+
`corp formations create --entity-type llc --jurisdiction US-WY --legal-name "My LLC" --members '{"name":"Bob","email":"bob@co.com","role":"member","ownership_pct":100}' --json`
|
|
4428
4377
|
],
|
|
4429
|
-
|
|
4430
|
-
successTemplate: "Formations created"
|
|
4378
|
+
successTemplate: "Formation created: {entity_id}"
|
|
4431
4379
|
},
|
|
4432
4380
|
{
|
|
4433
4381
|
name: "formations pending",
|
|
4434
|
-
description: "Create a pending formation",
|
|
4382
|
+
description: "Create a pending (draft) formation record without founders",
|
|
4435
4383
|
route: { method: "POST", path: "/v1/formations/pending" },
|
|
4436
4384
|
options: [
|
|
4437
|
-
{ flags: "--company-address <company-address>", description: "Company mailing address" },
|
|
4438
|
-
{ flags: "--entity-type <entity-type>", description: "
|
|
4439
|
-
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (e.g. 12-31)" },
|
|
4440
|
-
{ flags: "--formation-date <formation-date>", description: "
|
|
4441
|
-
{ flags: "--jurisdiction <jurisdiction>", description: "
|
|
4385
|
+
{ flags: "--company-address <company-address>", description: "Company mailing address as 'street,city,state,zip'" },
|
|
4386
|
+
{ flags: "--entity-type <entity-type>", description: "Legal structure of the entity", required: true, choices: ["c_corp", "llc"] },
|
|
4387
|
+
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (MM-DD, e.g. 12-31)" },
|
|
4388
|
+
{ flags: "--formation-date <formation-date>", description: "Formation date for pre-formed entity import (ISO 8601)" },
|
|
4389
|
+
{ flags: "--jurisdiction <jurisdiction>", description: "Incorporation jurisdiction (e.g. US-DE, US-WY)" },
|
|
4442
4390
|
{ flags: "--legal-name <legal-name>", description: "Legal name of the entity", required: true },
|
|
4443
4391
|
{ flags: "--registered-agent-address <registered-agent-address>", description: "Registered agent mailing address" },
|
|
4444
|
-
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent name" },
|
|
4445
|
-
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include ROFR in bylaws (true/false)" },
|
|
4446
|
-
{ flags: "--s-corp-election <s-corp-election>", description: "S
|
|
4447
|
-
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "
|
|
4392
|
+
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent legal name" },
|
|
4393
|
+
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include ROFR in bylaws (true/false, corp only)" },
|
|
4394
|
+
{ flags: "--s-corp-election <s-corp-election>", description: "Elect S-Corp tax treatment (true/false)" },
|
|
4395
|
+
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (true/false, corp only)" }
|
|
4396
|
+
],
|
|
4397
|
+
examples: [
|
|
4398
|
+
'corp formations pending --entity-type c_corp --legal-name "Acme Inc" --jurisdiction US-DE',
|
|
4399
|
+
'corp formations pending --entity-type llc --legal-name "My LLC" --jurisdiction US-WY --json'
|
|
4448
4400
|
],
|
|
4449
|
-
|
|
4450
|
-
successTemplate: "Pending formation created"
|
|
4401
|
+
successTemplate: "Pending formation created: {entity_id}"
|
|
4451
4402
|
},
|
|
4452
4403
|
{
|
|
4453
4404
|
name: "formations with-cap-table",
|
|
4454
|
-
description: "Create
|
|
4405
|
+
description: "Create a formation together with an initial cap table in one request",
|
|
4455
4406
|
route: { method: "POST", path: "/v1/formations/with-cap-table" },
|
|
4456
4407
|
options: [
|
|
4457
|
-
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares" },
|
|
4458
|
-
{ flags: "--company-address <company-address>", description: "Company mailing address" },
|
|
4459
|
-
{ flags: "--entity-type <entity-type>", description: "
|
|
4460
|
-
{ flags: "--fiscal-year-end <fiscal-year-end>", description:
|
|
4461
|
-
{ flags: "--formation-date <formation-date>", description: "
|
|
4462
|
-
{ flags: "--jurisdiction <jurisdiction>", description: "
|
|
4408
|
+
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares (e.g. 10000000)" },
|
|
4409
|
+
{ flags: "--company-address <company-address>", description: "Company mailing address as 'street,city,state,zip'" },
|
|
4410
|
+
{ flags: "--entity-type <entity-type>", description: "Legal structure of the entity", required: true, choices: ["c_corp", "llc"] },
|
|
4411
|
+
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (MM-DD, e.g. 12-31). Defaults to 12-31." },
|
|
4412
|
+
{ flags: "--formation-date <formation-date>", description: "Formation date for pre-formed entity import (ISO 8601)" },
|
|
4413
|
+
{ flags: "--jurisdiction <jurisdiction>", description: "Incorporation jurisdiction (e.g. US-DE, US-WY)", required: true },
|
|
4463
4414
|
{ flags: "--legal-name <legal-name>", description: "Legal name of the entity", required: true },
|
|
4464
|
-
{ flags: "--members <members>", description: "
|
|
4465
|
-
{ flags: "--par-value <par-value>", description: "Par value per share" },
|
|
4415
|
+
{ flags: "--members <members>", description: "Member/founder entries (repeatable)", required: true, type: "array" },
|
|
4416
|
+
{ flags: "--par-value <par-value>", description: "Par value per share (e.g. 0.0001)" },
|
|
4466
4417
|
{ flags: "--registered-agent-address <registered-agent-address>", description: "Registered agent mailing address" },
|
|
4467
|
-
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent name" },
|
|
4468
|
-
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include right of first refusal in bylaws (corp
|
|
4469
|
-
{ flags: "--s-corp-election <s-corp-election>", description: "
|
|
4470
|
-
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (corp
|
|
4418
|
+
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent legal name" },
|
|
4419
|
+
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include right of first refusal in bylaws (true/false, corp only, default true)" },
|
|
4420
|
+
{ flags: "--s-corp-election <s-corp-election>", description: "Elect S-Corp tax treatment (true/false)" },
|
|
4421
|
+
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (true/false, corp only, default true)" }
|
|
4422
|
+
],
|
|
4423
|
+
examples: [
|
|
4424
|
+
`corp formations with-cap-table --entity-type c_corp --jurisdiction US-DE --legal-name "Acme Inc" --members '{"name":"Alice","email":"alice@acme.com","role":"director","ownership_pct":100}' --authorized-shares 10000000`,
|
|
4425
|
+
`corp formations with-cap-table --entity-type llc --jurisdiction US-WY --legal-name "My LLC" --members '{"name":"Bob","email":"bob@co.com","role":"member","ownership_pct":100}' --json`
|
|
4471
4426
|
],
|
|
4472
|
-
|
|
4473
|
-
successTemplate: "With Cap Table created"
|
|
4427
|
+
successTemplate: "Formation with cap table created: {entity_id}"
|
|
4474
4428
|
},
|
|
4475
4429
|
{
|
|
4476
4430
|
name: "formations",
|
|
@@ -4485,87 +4439,99 @@ var init_formation = __esm({
|
|
|
4485
4439
|
description: "Submit EIN application",
|
|
4486
4440
|
route: { method: "POST", path: "/v1/formations/{eid}/apply-ein" },
|
|
4487
4441
|
entity: true,
|
|
4488
|
-
examples: ["corp formations apply-ein"],
|
|
4489
|
-
successTemplate: "
|
|
4442
|
+
examples: ["corp formations apply-ein", "corp formations apply-ein --json"],
|
|
4443
|
+
successTemplate: "EIN application submitted for {entity_id}"
|
|
4490
4444
|
},
|
|
4491
4445
|
{
|
|
4492
4446
|
name: "formations ein-confirmation",
|
|
4493
|
-
description: "Confirm EIN received from IRS",
|
|
4447
|
+
description: "Confirm the EIN received from the IRS for the active entity",
|
|
4494
4448
|
route: { method: "POST", path: "/v1/formations/{eid}/ein-confirmation" },
|
|
4495
4449
|
entity: true,
|
|
4496
4450
|
options: [
|
|
4497
|
-
{ flags: "--ein <ein>", description: "Employer Identification Number", required: true }
|
|
4451
|
+
{ flags: "--ein <ein>", description: "Employer Identification Number issued by the IRS (e.g. 84-1234567)", required: true }
|
|
4498
4452
|
],
|
|
4499
|
-
examples: ["corp formations ein-confirmation --ein
|
|
4500
|
-
successTemplate: "
|
|
4453
|
+
examples: ["corp formations ein-confirmation --ein 84-1234567", "corp formations ein-confirmation --ein 84-1234567 --json"],
|
|
4454
|
+
successTemplate: "EIN confirmed: {ein}"
|
|
4501
4455
|
},
|
|
4502
4456
|
{
|
|
4503
4457
|
name: "formations filing-attestation",
|
|
4504
|
-
description: "
|
|
4458
|
+
description: "Record a filing accuracy attestation signed by an authorized person",
|
|
4505
4459
|
route: { method: "POST", path: "/v1/formations/{eid}/filing-attestation" },
|
|
4506
4460
|
entity: true,
|
|
4507
4461
|
options: [
|
|
4508
|
-
{ flags: "--consent-text <consent-text>", description: "
|
|
4509
|
-
{ flags: "--notes <notes>", description: "Additional notes" },
|
|
4510
|
-
{ flags: "--signer-email <signer-email>", description: "
|
|
4511
|
-
{ flags: "--signer-name <signer-name>", description: "
|
|
4512
|
-
{ flags: "--signer-role <signer-role>", description: "
|
|
4462
|
+
{ flags: "--consent-text <consent-text>", description: "Custom consent statement text (uses default if omitted)" },
|
|
4463
|
+
{ flags: "--notes <notes>", description: "Additional notes to attach to the attestation record" },
|
|
4464
|
+
{ flags: "--signer-email <signer-email>", description: "Email address of the person attesting", required: true },
|
|
4465
|
+
{ flags: "--signer-name <signer-name>", description: "Full legal name of the person attesting", required: true },
|
|
4466
|
+
{ flags: "--signer-role <signer-role>", description: "Role of the signer (e.g. CEO, Incorporator)", required: true }
|
|
4467
|
+
],
|
|
4468
|
+
examples: [
|
|
4469
|
+
'corp formations filing-attestation --signer-email alice@acme.com --signer-name "Alice Smith" --signer-role Incorporator',
|
|
4470
|
+
'corp formations filing-attestation --signer-email alice@acme.com --signer-name "Alice Smith" --signer-role CEO --json'
|
|
4513
4471
|
],
|
|
4514
|
-
|
|
4515
|
-
successTemplate: "Filing Attestation created"
|
|
4472
|
+
successTemplate: "Filing attestation recorded for {entity_id}"
|
|
4516
4473
|
},
|
|
4517
4474
|
{
|
|
4518
4475
|
name: "formations filing-confirmation",
|
|
4519
|
-
description: "
|
|
4476
|
+
description: "Record confirmation that the state filing has been received and processed",
|
|
4520
4477
|
route: { method: "POST", path: "/v1/formations/{eid}/filing-confirmation" },
|
|
4521
4478
|
entity: true,
|
|
4522
4479
|
options: [
|
|
4523
|
-
{ flags: "--external-filing-id <external-filing-id>", description: "
|
|
4524
|
-
{ flags: "--receipt-reference <receipt-reference>", description: "
|
|
4480
|
+
{ flags: "--external-filing-id <external-filing-id>", description: "State-issued filing identifier (e.g. DE-2026-0042)", required: true },
|
|
4481
|
+
{ flags: "--receipt-reference <receipt-reference>", description: "Payment or receipt reference number for the filing fee" }
|
|
4525
4482
|
],
|
|
4526
|
-
examples: [
|
|
4527
|
-
|
|
4483
|
+
examples: [
|
|
4484
|
+
"corp formations filing-confirmation --external-filing-id DE-2026-0042",
|
|
4485
|
+
"corp formations filing-confirmation --external-filing-id DE-2026-0042 --receipt-reference RECEIPT-001 --json"
|
|
4486
|
+
],
|
|
4487
|
+
successTemplate: "Filing confirmation recorded: {external_filing_id}"
|
|
4528
4488
|
},
|
|
4529
4489
|
{
|
|
4530
4490
|
name: "formations finalize",
|
|
4531
|
-
description: "Finalize a formation
|
|
4491
|
+
description: "Finalize a formation, locking documents and generating the cap table",
|
|
4532
4492
|
route: { method: "POST", path: "/v1/formations/{eid}/finalize" },
|
|
4533
4493
|
entity: true,
|
|
4534
4494
|
options: [
|
|
4535
|
-
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares" },
|
|
4536
|
-
{ flags: "--board-size <board-size>", description: "
|
|
4537
|
-
{ flags: "--company-address <company-address>", description: "Company mailing address" },
|
|
4538
|
-
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (e.g. 12-31)" },
|
|
4539
|
-
{ flags: "--formation-date <formation-date>", description: "
|
|
4540
|
-
{ flags: "--incorporator-address <incorporator-address>", description: "Incorporator
|
|
4541
|
-
{ flags: "--incorporator-name <incorporator-name>", description: "Incorporator
|
|
4542
|
-
{ flags: "--par-value <par-value>", description: "Par value per share" },
|
|
4543
|
-
{ flags: "--principal-name <principal-name>", description: "Principal
|
|
4495
|
+
{ flags: "--authorized-shares <authorized-shares>", description: "Number of authorized shares (e.g. 10000000)" },
|
|
4496
|
+
{ flags: "--board-size <board-size>", description: "Number of board seats (corporations only)" },
|
|
4497
|
+
{ flags: "--company-address <company-address>", description: "Company mailing address as 'street,city,state,zip'" },
|
|
4498
|
+
{ flags: "--fiscal-year-end <fiscal-year-end>", description: "Fiscal year end (MM-DD, e.g. 12-31)" },
|
|
4499
|
+
{ flags: "--formation-date <formation-date>", description: "Formation date for pre-formed entity import (ISO 8601)" },
|
|
4500
|
+
{ flags: "--incorporator-address <incorporator-address>", description: "Incorporator mailing address (overrides founder address)" },
|
|
4501
|
+
{ flags: "--incorporator-name <incorporator-name>", description: "Incorporator full legal name (overrides founder name)" },
|
|
4502
|
+
{ flags: "--par-value <par-value>", description: "Par value per share (e.g. 0.0001)" },
|
|
4503
|
+
{ flags: "--principal-name <principal-name>", description: "Principal or managing member name for LLCs" },
|
|
4544
4504
|
{ flags: "--registered-agent-address <registered-agent-address>", description: "Registered agent mailing address" },
|
|
4545
|
-
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent name" },
|
|
4546
|
-
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include ROFR in bylaws (true/false)" },
|
|
4547
|
-
{ flags: "--s-corp-election <s-corp-election>", description: "S
|
|
4548
|
-
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "
|
|
4505
|
+
{ flags: "--registered-agent-name <registered-agent-name>", description: "Registered agent legal name" },
|
|
4506
|
+
{ flags: "--right-of-first-refusal <right-of-first-refusal>", description: "Include ROFR in bylaws (true/false, corp only)" },
|
|
4507
|
+
{ flags: "--s-corp-election <s-corp-election>", description: "Elect S-Corp tax treatment (true/false)" },
|
|
4508
|
+
{ flags: "--transfer-restrictions <transfer-restrictions>", description: "Include transfer restrictions in bylaws (true/false, corp only)" }
|
|
4509
|
+
],
|
|
4510
|
+
examples: [
|
|
4511
|
+
"corp formations finalize",
|
|
4512
|
+
"corp formations finalize --authorized-shares 10000000 --par-value 0.0001 --json"
|
|
4549
4513
|
],
|
|
4550
|
-
|
|
4551
|
-
successTemplate: "Finalize created"
|
|
4514
|
+
successTemplate: "Formation finalized: {entity_id}"
|
|
4552
4515
|
},
|
|
4553
4516
|
{
|
|
4554
4517
|
name: "formations founders",
|
|
4555
|
-
description: "Add
|
|
4518
|
+
description: "Add a founder to an existing formation record",
|
|
4556
4519
|
route: { method: "POST", path: "/v1/formations/{eid}/founders" },
|
|
4557
4520
|
entity: true,
|
|
4558
4521
|
options: [
|
|
4559
|
-
{ flags: "--address <address>", description: "
|
|
4560
|
-
{ flags: "--email <email>", description: "
|
|
4561
|
-
{ flags: "--is-incorporator <is-incorporator>", description: "
|
|
4562
|
-
{ flags: "--name <name>", description: "
|
|
4563
|
-
{ flags: "--officer-title <officer-title>", description: "Officer
|
|
4564
|
-
{ flags: "--ownership-pct <ownership-pct>", description: "Ownership
|
|
4565
|
-
{ flags: "--role <role>", description: "
|
|
4522
|
+
{ flags: "--address <address>", description: "Founder mailing address as 'street,city,state,zip'" },
|
|
4523
|
+
{ flags: "--email <email>", description: "Founder email address" },
|
|
4524
|
+
{ flags: "--is-incorporator <is-incorporator>", description: "Mark as the sole incorporator (true/false, corporations only)" },
|
|
4525
|
+
{ flags: "--name <name>", description: "Founder full legal name", required: true },
|
|
4526
|
+
{ flags: "--officer-title <officer-title>", description: "Officer title for the founder (corporations only)", choices: ["ceo", "cfo", "cto", "coo", "secretary", "treasurer", "president", "vp", "other"] },
|
|
4527
|
+
{ flags: "--ownership-pct <ownership-pct>", description: "Ownership percentage (e.g. 60 for 60%)" },
|
|
4528
|
+
{ flags: "--role <role>", description: "Founder role in the entity", choices: ["director", "officer", "manager", "member", "chair"] }
|
|
4529
|
+
],
|
|
4530
|
+
examples: [
|
|
4531
|
+
'corp formations founders --name "Alice Smith" --email alice@acme.com --role director --ownership-pct 60 --officer-title ceo --is-incorporator true',
|
|
4532
|
+
'corp formations founders --name "Bob Jones" --email bob@acme.com --role director --ownership-pct 40 --json'
|
|
4566
4533
|
],
|
|
4567
|
-
|
|
4568
|
-
successTemplate: "Founders created"
|
|
4534
|
+
successTemplate: "Founder added to {entity_id}"
|
|
4569
4535
|
},
|
|
4570
4536
|
{
|
|
4571
4537
|
name: "formations gates",
|
|
@@ -4580,42 +4546,48 @@ var init_formation = __esm({
|
|
|
4580
4546
|
description: "Mark formation documents as signed",
|
|
4581
4547
|
route: { method: "POST", path: "/v1/formations/{eid}/mark-documents-signed" },
|
|
4582
4548
|
entity: true,
|
|
4583
|
-
examples: ["corp formations mark-documents-signed"],
|
|
4584
|
-
successTemplate: "
|
|
4549
|
+
examples: ["corp formations mark-documents-signed", "corp formations mark-documents-signed --json"],
|
|
4550
|
+
successTemplate: "Formation documents marked as signed for {entity_id}"
|
|
4585
4551
|
},
|
|
4586
4552
|
{
|
|
4587
4553
|
name: "formations registered-agent-consent-evidence",
|
|
4588
|
-
description: "
|
|
4554
|
+
description: "Record registered agent consent evidence for the active formation",
|
|
4589
4555
|
route: { method: "POST", path: "/v1/formations/{eid}/registered-agent-consent-evidence" },
|
|
4590
4556
|
entity: true,
|
|
4591
4557
|
options: [
|
|
4592
|
-
{ flags: "--evidence-type <evidence-type>", description: "
|
|
4593
|
-
{ flags: "--evidence-uri <evidence-uri>", description: "
|
|
4594
|
-
{ flags: "--notes <notes>", description: "Additional notes" }
|
|
4558
|
+
{ flags: "--evidence-type <evidence-type>", description: "Type of consent evidence (e.g. generated, signed_pdf)" },
|
|
4559
|
+
{ flags: "--evidence-uri <evidence-uri>", description: "URI or path to the consent evidence document", required: true },
|
|
4560
|
+
{ flags: "--notes <notes>", description: "Additional notes about the consent evidence" }
|
|
4561
|
+
],
|
|
4562
|
+
examples: [
|
|
4563
|
+
"corp formations registered-agent-consent-evidence --evidence-uri https://files.example.com/consent.pdf",
|
|
4564
|
+
"corp formations registered-agent-consent-evidence --evidence-uri https://files.example.com/consent.pdf --evidence-type signed_pdf --json"
|
|
4595
4565
|
],
|
|
4596
|
-
|
|
4597
|
-
successTemplate: "Registered Agent Consent Evidence created"
|
|
4566
|
+
successTemplate: "Registered agent consent evidence recorded for {entity_id}"
|
|
4598
4567
|
},
|
|
4599
4568
|
{
|
|
4600
4569
|
name: "formations service-agreement-execute",
|
|
4601
|
-
description: "
|
|
4570
|
+
description: "Mark the formation service agreement as executed",
|
|
4602
4571
|
route: { method: "POST", path: "/v1/formations/{eid}/service-agreement/execute" },
|
|
4603
4572
|
entity: true,
|
|
4604
4573
|
options: [
|
|
4605
|
-
{ flags: "--contract-id <contract-id>", description: "Contract
|
|
4606
|
-
{ flags: "--document-id <document-id>", description: "Document ID" },
|
|
4607
|
-
{ flags: "--notes <notes>", description: "Additional notes" }
|
|
4574
|
+
{ flags: "--contract-id <contract-id>", description: "Contract ID of the service agreement to execute" },
|
|
4575
|
+
{ flags: "--document-id <document-id>", description: "Document ID of the executed service agreement" },
|
|
4576
|
+
{ flags: "--notes <notes>", description: "Additional notes about the execution" }
|
|
4577
|
+
],
|
|
4578
|
+
examples: [
|
|
4579
|
+
"corp formations service-agreement-execute",
|
|
4580
|
+
"corp formations service-agreement-execute --contract-id contract-abc123 --json"
|
|
4608
4581
|
],
|
|
4609
|
-
|
|
4610
|
-
successTemplate: "Service Agreement Execute created"
|
|
4582
|
+
successTemplate: "Service agreement executed for {entity_id}"
|
|
4611
4583
|
},
|
|
4612
4584
|
{
|
|
4613
4585
|
name: "formations submit-filing",
|
|
4614
4586
|
description: "Submit state filing for a formation",
|
|
4615
4587
|
route: { method: "POST", path: "/v1/formations/{eid}/submit-filing" },
|
|
4616
4588
|
entity: true,
|
|
4617
|
-
examples: ["corp formations submit-filing"],
|
|
4618
|
-
successTemplate: "
|
|
4589
|
+
examples: ["corp formations submit-filing", "corp formations submit-filing --json"],
|
|
4590
|
+
successTemplate: "State filing submitted for {entity_id}"
|
|
4619
4591
|
},
|
|
4620
4592
|
{
|
|
4621
4593
|
name: "governance catalog",
|
|
@@ -4630,7 +4602,7 @@ var init_formation = __esm({
|
|
|
4630
4602
|
route: { method: "GET", path: "/v1/governance/catalog/{pos}/markdown" },
|
|
4631
4603
|
args: [{ name: "document-id", required: true, description: "Document ID" }],
|
|
4632
4604
|
display: { title: "Governance Catalog Markdown", cols: ["category>Category", "entity_scope>Entity Scope", "id>Id", "markdown>Markdown", "title>Title", "variants>Variants"] },
|
|
4633
|
-
examples: ["corp governance catalog-markdown"]
|
|
4605
|
+
examples: ["corp governance catalog-markdown bylaws", "corp governance catalog-markdown articles_of_incorporation"]
|
|
4634
4606
|
}
|
|
4635
4607
|
];
|
|
4636
4608
|
}
|
|
@@ -4738,7 +4710,7 @@ var init_cap_table = __esm({
|
|
|
4738
4710
|
// --- cap-table transfers ---
|
|
4739
4711
|
{
|
|
4740
4712
|
name: "cap-table transfers",
|
|
4741
|
-
description: "
|
|
4713
|
+
description: "List share transfers for this entity",
|
|
4742
4714
|
route: { method: "GET", path: "/v1/entities/{eid}/share-transfers" },
|
|
4743
4715
|
entity: true,
|
|
4744
4716
|
display: {
|
|
@@ -4764,7 +4736,7 @@ var init_cap_table = __esm({
|
|
|
4764
4736
|
// --- cap-table instruments ---
|
|
4765
4737
|
{
|
|
4766
4738
|
name: "cap-table instruments",
|
|
4767
|
-
description: "
|
|
4739
|
+
description: "List equity instruments (share classes, option pools, SAFEs) on the cap table",
|
|
4768
4740
|
route: { method: "GET", path: "/v1/entities/{eid}/cap-table" },
|
|
4769
4741
|
entity: true,
|
|
4770
4742
|
display: {
|
|
@@ -4820,7 +4792,7 @@ var init_cap_table = __esm({
|
|
|
4820
4792
|
// --- cap-table rounds ---
|
|
4821
4793
|
{
|
|
4822
4794
|
name: "cap-table rounds",
|
|
4823
|
-
description: "
|
|
4795
|
+
description: "List equity rounds (staged and closed) for this entity",
|
|
4824
4796
|
route: { method: "GET", path: "/v1/entities/{eid}/equity-rounds" },
|
|
4825
4797
|
entity: true,
|
|
4826
4798
|
display: {
|
|
@@ -4846,7 +4818,7 @@ var init_cap_table = __esm({
|
|
|
4846
4818
|
// --- cap-table valuations ---
|
|
4847
4819
|
{
|
|
4848
4820
|
name: "cap-table valuations",
|
|
4849
|
-
description: "
|
|
4821
|
+
description: "List valuation history (409A, FMV, and other valuations)",
|
|
4850
4822
|
route: { method: "GET", path: "/v1/entities/{eid}/valuations" },
|
|
4851
4823
|
entity: true,
|
|
4852
4824
|
display: {
|
|
@@ -4986,7 +4958,10 @@ var init_cap_table = __esm({
|
|
|
4986
4958
|
}
|
|
4987
4959
|
ctx.writer.json(result);
|
|
4988
4960
|
},
|
|
4989
|
-
examples: [
|
|
4961
|
+
examples: [
|
|
4962
|
+
"corp cap-table dilution --round-id @last:round",
|
|
4963
|
+
"corp cap-table dilution --round-id a1b2c3d4 --json"
|
|
4964
|
+
]
|
|
4990
4965
|
},
|
|
4991
4966
|
// --- cap-table create-instrument ---
|
|
4992
4967
|
{
|
|
@@ -4996,7 +4971,7 @@ var init_cap_table = __esm({
|
|
|
4996
4971
|
entity: true,
|
|
4997
4972
|
dryRun: true,
|
|
4998
4973
|
options: [
|
|
4999
|
-
{ flags: "--kind <kind>", description: "Instrument kind
|
|
4974
|
+
{ flags: "--kind <kind>", description: "Instrument kind", required: true, choices: ["common_equity", "preferred_equity", "membership_unit", "option_grant", "safe", "convertible_note", "warrant"] },
|
|
5000
4975
|
{ flags: "--symbol <symbol>", description: "Instrument symbol", required: true },
|
|
5001
4976
|
{ flags: "--issuer-legal-entity-id <ref>", description: "Issuer legal entity reference (ID, short ID, @last, or unique name)" },
|
|
5002
4977
|
{ flags: "--authorized-units <n>", description: "Authorized units", type: "int" },
|
|
@@ -5040,7 +5015,10 @@ var init_cap_table = __esm({
|
|
|
5040
5015
|
},
|
|
5041
5016
|
produces: { kind: "instrument" },
|
|
5042
5017
|
successTemplate: "Instrument created: {symbol}",
|
|
5043
|
-
examples: [
|
|
5018
|
+
examples: [
|
|
5019
|
+
"corp cap-table create-instrument --kind common_equity --symbol COMMON",
|
|
5020
|
+
"corp cap-table create-instrument --kind option_grant --symbol OPTIONS --authorized-units 10000000"
|
|
5021
|
+
]
|
|
5044
5022
|
},
|
|
5045
5023
|
// --- cap-table issue-equity ---
|
|
5046
5024
|
{
|
|
@@ -5120,10 +5098,11 @@ var init_cap_table = __esm({
|
|
|
5120
5098
|
}
|
|
5121
5099
|
},
|
|
5122
5100
|
produces: { kind: "round" },
|
|
5123
|
-
successTemplate: "Equity issued
|
|
5101
|
+
successTemplate: "Equity issued to {recipient_name}",
|
|
5124
5102
|
examples: [
|
|
5125
|
-
'corp cap-table issue-equity --grant-type common --shares
|
|
5126
|
-
'corp cap-table issue-equity --grant-type iso --shares
|
|
5103
|
+
'corp cap-table issue-equity --grant-type common --shares 1000000 --recipient "Alice Smith"',
|
|
5104
|
+
'corp cap-table issue-equity --grant-type iso --shares 50000 --recipient "Bob Jones" --email "bob@acme.com"',
|
|
5105
|
+
'corp cap-table issue-equity --grant-type preferred --shares 500000 --recipient "Acme Ventures" --meeting-id @last:meeting --resolution-id @last:resolution'
|
|
5127
5106
|
]
|
|
5128
5107
|
},
|
|
5129
5108
|
// --- cap-table issue-safe ---
|
|
@@ -5207,10 +5186,11 @@ var init_cap_table = __esm({
|
|
|
5207
5186
|
printReferenceSummary("safe_note", result.data, { showReuseHint: true });
|
|
5208
5187
|
},
|
|
5209
5188
|
produces: { kind: "safe_note" },
|
|
5210
|
-
successTemplate: "SAFE
|
|
5189
|
+
successTemplate: "SAFE issued to {investor_name}",
|
|
5211
5190
|
examples: [
|
|
5212
|
-
'corp cap-table issue-safe --investor "
|
|
5213
|
-
'corp cap-table issue-safe --investor "Angel" --amount-
|
|
5191
|
+
'corp cap-table issue-safe --investor "Sequoia Capital" --amount-dollars 500000 --valuation-cap-dollars 10000000',
|
|
5192
|
+
'corp cap-table issue-safe --investor "Angel Investor" --amount-dollars 250000 --valuation-cap-dollars 8000000 --safe-type pre_money',
|
|
5193
|
+
'corp cap-table issue-safe --investor "YC" --amount-cents 12500000 --valuation-cap-cents 1500000000 --meeting-id @last:meeting --resolution-id @last:resolution'
|
|
5214
5194
|
]
|
|
5215
5195
|
},
|
|
5216
5196
|
// --- cap-table transfer ---
|
|
@@ -5225,10 +5205,10 @@ var init_cap_table = __esm({
|
|
|
5225
5205
|
{ flags: "--to <ref>", description: "Destination contact reference (to_contact_id)", required: true },
|
|
5226
5206
|
{ flags: "--shares <n>", description: "Number of shares to transfer", required: true, type: "int" },
|
|
5227
5207
|
{ flags: "--share-class-id <ref>", description: "Share class reference (auto-resolved if only one exists)" },
|
|
5228
|
-
{ flags: "--governing-doc-type <type>", description: "Governing
|
|
5229
|
-
{ flags: "--transferee-rights <rights>", description: "
|
|
5208
|
+
{ flags: "--governing-doc-type <type>", description: "Governing document that authorizes this transfer", default: "bylaws", choices: ["bylaws", "operating_agreement", "shareholder_agreement", "other"] },
|
|
5209
|
+
{ flags: "--transferee-rights <rights>", description: "Rights granted to the transferee", default: "full_member", choices: ["full_member", "economic_only", "limited"] },
|
|
5230
5210
|
{ flags: "--prepare-intent-id <id>", description: "Prepare intent ID (auto-created if omitted)" },
|
|
5231
|
-
{ flags: "--type <type>", description: "
|
|
5211
|
+
{ flags: "--type <type>", description: "Type of transfer", default: "secondary_sale", choices: ["gift", "trust_transfer", "secondary_sale", "estate", "other"] },
|
|
5232
5212
|
{ flags: "--price-per-share-cents <n>", description: "Price per share in cents", type: "int" },
|
|
5233
5213
|
{ flags: "--relationship <rel>", description: "Relationship to holder" }
|
|
5234
5214
|
],
|
|
@@ -5313,8 +5293,11 @@ var init_cap_table = __esm({
|
|
|
5313
5293
|
printReferenceSummary("share_transfer", result, { label: "Transfer Ref:", showReuseHint: true });
|
|
5314
5294
|
},
|
|
5315
5295
|
produces: { kind: "share_transfer" },
|
|
5316
|
-
successTemplate: "
|
|
5317
|
-
examples: [
|
|
5296
|
+
successTemplate: "Share transfer created: {transfer_workflow_id}",
|
|
5297
|
+
examples: [
|
|
5298
|
+
"corp cap-table transfer --from alice-johnson --to bob-smith --shares 50000 --type secondary_sale",
|
|
5299
|
+
"corp cap-table transfer --from a1b2c3d4 --to e5f6a7b8 --shares 10000 --share-class-id COMMON --type gift --transferee-rights full_member"
|
|
5300
|
+
]
|
|
5318
5301
|
},
|
|
5319
5302
|
// --- cap-table distribute ---
|
|
5320
5303
|
{
|
|
@@ -5326,7 +5309,7 @@ var init_cap_table = __esm({
|
|
|
5326
5309
|
options: [
|
|
5327
5310
|
{ flags: "--amount-cents <n>", description: "Total distribution amount in cents (e.g. 100000 = $1,000.00)", required: true, type: "int" },
|
|
5328
5311
|
{ flags: "--amount-dollars <n>", description: "Total distribution amount in dollars (e.g. 1000 = $1,000.00)", type: "int" },
|
|
5329
|
-
{ flags: "--type <type>", description: "Distribution type
|
|
5312
|
+
{ flags: "--type <type>", description: "Distribution type", default: "dividend", choices: ["dividend", "return", "liquidation"] },
|
|
5330
5313
|
{ flags: "--description <desc>", description: "Distribution description", required: true }
|
|
5331
5314
|
],
|
|
5332
5315
|
handler: async (ctx) => {
|
|
@@ -5360,7 +5343,10 @@ var init_cap_table = __esm({
|
|
|
5360
5343
|
ctx.writer.success(`Distribution calculated: ${result.distribution_id ?? "OK"}`);
|
|
5361
5344
|
printReferenceSummary("distribution", result, { showReuseHint: true });
|
|
5362
5345
|
},
|
|
5363
|
-
examples: [
|
|
5346
|
+
examples: [
|
|
5347
|
+
'corp cap-table distribute --amount-dollars 250000 --description "Q1 2026 dividend distribution"',
|
|
5348
|
+
'corp cap-table distribute --amount-cents 50000000 --type liquidation --description "Liquidation proceeds distribution"'
|
|
5349
|
+
]
|
|
5364
5350
|
},
|
|
5365
5351
|
// --- cap-table start-round ---
|
|
5366
5352
|
{
|
|
@@ -5404,8 +5390,11 @@ var init_cap_table = __esm({
|
|
|
5404
5390
|
printReferenceSummary("round", result, { showReuseHint: true });
|
|
5405
5391
|
},
|
|
5406
5392
|
produces: { kind: "round" },
|
|
5407
|
-
successTemplate: "Round started: {
|
|
5408
|
-
examples: [
|
|
5393
|
+
successTemplate: "Round started: {name}",
|
|
5394
|
+
examples: [
|
|
5395
|
+
'corp cap-table start-round --name "Series A"',
|
|
5396
|
+
'corp cap-table start-round --name "Seed Round" --issuer-legal-entity-id a1b2c3d4e5f6'
|
|
5397
|
+
]
|
|
5409
5398
|
},
|
|
5410
5399
|
// --- cap-table add-security ---
|
|
5411
5400
|
{
|
|
@@ -5422,7 +5411,7 @@ var init_cap_table = __esm({
|
|
|
5422
5411
|
{ flags: "--holder-id <ref>", description: "Existing holder reference" },
|
|
5423
5412
|
{ flags: "--email <email>", description: "Recipient email (to find or create holder)" },
|
|
5424
5413
|
{ flags: "--principal-cents <n>", description: "Principal amount in cents", type: "int" },
|
|
5425
|
-
{ flags: "--grant-type <type>", description: "Grant type" }
|
|
5414
|
+
{ flags: "--grant-type <type>", description: "Grant type (common, preferred, iso, nso, rsa, membership_unit)", choices: ["common", "common_stock", "preferred", "preferred_stock", "membership_unit", "stock_option", "iso", "nso", "rsa", "svu"] }
|
|
5426
5415
|
],
|
|
5427
5416
|
handler: async (ctx) => {
|
|
5428
5417
|
const eid = await ctx.resolver.resolveEntity(ctx.opts.entityId);
|
|
@@ -5449,7 +5438,10 @@ var init_cap_table = __esm({
|
|
|
5449
5438
|
}
|
|
5450
5439
|
ctx.writer.success(`Security added for ${ctx.opts.recipientName}`);
|
|
5451
5440
|
},
|
|
5452
|
-
examples: [
|
|
5441
|
+
examples: [
|
|
5442
|
+
'corp cap-table add-security --round-id @last:round --instrument-id @last:instrument --quantity 500000 --recipient-name "Alice Smith"',
|
|
5443
|
+
'corp cap-table add-security --round-id a1b2c3d4 --instrument-id COMMON --quantity 1000000 --recipient-name "Acme Ventures" --email "invest@acme.com" --grant-type preferred'
|
|
5444
|
+
]
|
|
5453
5445
|
},
|
|
5454
5446
|
// --- cap-table issue-round ---
|
|
5455
5447
|
{
|
|
@@ -5498,7 +5490,10 @@ var init_cap_table = __esm({
|
|
|
5498
5490
|
printReferenceSummary("round", roundMatch.raw, { showReuseHint: true });
|
|
5499
5491
|
}
|
|
5500
5492
|
},
|
|
5501
|
-
examples: [
|
|
5493
|
+
examples: [
|
|
5494
|
+
"corp cap-table issue-round --round-id @last:round",
|
|
5495
|
+
"corp cap-table issue-round --round-id a1b2c3d4 --meeting-id @last:meeting --resolution-id @last:resolution"
|
|
5496
|
+
]
|
|
5502
5497
|
},
|
|
5503
5498
|
// --- cap-table create-valuation ---
|
|
5504
5499
|
{
|
|
@@ -5508,7 +5503,7 @@ var init_cap_table = __esm({
|
|
|
5508
5503
|
entity: true,
|
|
5509
5504
|
dryRun: true,
|
|
5510
5505
|
options: [
|
|
5511
|
-
{ flags: "--type <type>", description: "Valuation type
|
|
5506
|
+
{ flags: "--type <type>", description: "Valuation type", required: true, choices: ["four_oh_nine_a", "llc_profits_interest", "fair_market_value", "gift", "estate", "other"] },
|
|
5512
5507
|
{ flags: "--date <date>", description: "Effective date (ISO 8601)", required: true },
|
|
5513
5508
|
{ flags: "--methodology <method>", description: "Methodology", required: true, choices: ["income", "market", "asset", "backsolve", "hybrid", "other"] },
|
|
5514
5509
|
{ flags: "--fmv <cents>", description: "FMV per share in cents", type: "int" },
|
|
@@ -5559,8 +5554,11 @@ var init_cap_table = __esm({
|
|
|
5559
5554
|
printReferenceSummary("valuation", result, { showReuseHint: true });
|
|
5560
5555
|
},
|
|
5561
5556
|
produces: { kind: "valuation" },
|
|
5562
|
-
successTemplate: "Valuation created",
|
|
5563
|
-
examples: [
|
|
5557
|
+
successTemplate: "Valuation created: {valuation_id}",
|
|
5558
|
+
examples: [
|
|
5559
|
+
"corp cap-table create-valuation --type four_oh_nine_a --date 2026-01-01 --methodology backsolve",
|
|
5560
|
+
"corp cap-table create-valuation --type four_oh_nine_a --date 2026-01-01 --methodology market --fmv 125 --enterprise-value 50000000 --auto-approve"
|
|
5561
|
+
]
|
|
5564
5562
|
},
|
|
5565
5563
|
// --- cap-table submit-valuation <valuation-ref> ---
|
|
5566
5564
|
{
|
|
@@ -5618,7 +5616,10 @@ var init_cap_table = __esm({
|
|
|
5618
5616
|
}
|
|
5619
5617
|
}
|
|
5620
5618
|
},
|
|
5621
|
-
examples: [
|
|
5619
|
+
examples: [
|
|
5620
|
+
"corp cap-table submit-valuation @last:valuation",
|
|
5621
|
+
"corp cap-table submit-valuation a1b2c3d4 --json"
|
|
5622
|
+
]
|
|
5622
5623
|
},
|
|
5623
5624
|
// --- cap-table approve-valuation <valuation-ref> ---
|
|
5624
5625
|
{
|
|
@@ -5662,7 +5663,11 @@ var init_cap_table = __esm({
|
|
|
5662
5663
|
}
|
|
5663
5664
|
}
|
|
5664
5665
|
},
|
|
5665
|
-
|
|
5666
|
+
successTemplate: "Valuation approved: {valuation_id}",
|
|
5667
|
+
examples: [
|
|
5668
|
+
"corp cap-table approve-valuation @last:valuation",
|
|
5669
|
+
"corp cap-table approve-valuation a1b2c3d4 --resolution-id @last:resolution"
|
|
5670
|
+
]
|
|
5666
5671
|
},
|
|
5667
5672
|
// --- cap-table preview-conversion ---
|
|
5668
5673
|
{
|
|
@@ -5692,7 +5697,10 @@ var init_cap_table = __esm({
|
|
|
5692
5697
|
if (result.ownership_pct) console.log(` Post-conversion ownership: ${result.ownership_pct}%`);
|
|
5693
5698
|
ctx.writer.json(result);
|
|
5694
5699
|
},
|
|
5695
|
-
examples: [
|
|
5700
|
+
examples: [
|
|
5701
|
+
"corp cap-table preview-conversion --safe-id @last:safe_note --price-per-share-cents 125",
|
|
5702
|
+
"corp cap-table preview-conversion --safe-id a1b2c3d4 --price-per-share-cents 200 --json"
|
|
5703
|
+
]
|
|
5696
5704
|
},
|
|
5697
5705
|
// --- cap-table convert ---
|
|
5698
5706
|
{
|
|
@@ -5726,7 +5734,10 @@ var init_cap_table = __esm({
|
|
|
5726
5734
|
}
|
|
5727
5735
|
ctx.writer.success(`Conversion executed for SAFE ${safeId}`);
|
|
5728
5736
|
},
|
|
5729
|
-
examples: [
|
|
5737
|
+
examples: [
|
|
5738
|
+
"corp cap-table convert --safe-id @last:safe_note --price-per-share-cents 125",
|
|
5739
|
+
"corp cap-table convert --safe-id a1b2c3d4 --price-per-share-cents 200 --dry-run"
|
|
5740
|
+
]
|
|
5730
5741
|
},
|
|
5731
5742
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
5732
5743
|
{
|
|
@@ -5741,8 +5752,11 @@ var init_cap_table = __esm({
|
|
|
5741
5752
|
{ flags: "--parent-legal-entity-id <parent-legal-entity-id>", description: "Parent entity in the control relationship", required: true },
|
|
5742
5753
|
{ flags: "--voting-power-bps <voting-power-bps>", description: "Voting power in basis points (0-10000)" }
|
|
5743
5754
|
],
|
|
5744
|
-
examples: [
|
|
5745
|
-
|
|
5755
|
+
examples: [
|
|
5756
|
+
"corp equity control-links --child-legal-entity-id a1b2c3d4 --control-type voting --parent-legal-entity-id e5f6a7b8",
|
|
5757
|
+
"corp equity control-links --child-legal-entity-id a1b2c3d4 --control-type board --parent-legal-entity-id e5f6a7b8 --voting-power-bps 5100"
|
|
5758
|
+
],
|
|
5759
|
+
successTemplate: "Control link created"
|
|
5746
5760
|
},
|
|
5747
5761
|
{
|
|
5748
5762
|
name: "equity control-map",
|
|
@@ -5761,8 +5775,11 @@ var init_cap_table = __esm({
|
|
|
5761
5775
|
{ flags: "--round-id <round-id>", description: "Equity round ID", required: true },
|
|
5762
5776
|
{ flags: "--source-reference <source-reference>", description: "Source reference for the conversion" }
|
|
5763
5777
|
],
|
|
5764
|
-
examples: [
|
|
5765
|
-
|
|
5778
|
+
examples: [
|
|
5779
|
+
"corp equity conversions-execute --intent-id a1b2c3d4 --round-id e5f6a7b8",
|
|
5780
|
+
"corp equity conversions-execute --intent-id a1b2c3d4 --round-id e5f6a7b8 --source-reference safe-note:f9g0h1i2"
|
|
5781
|
+
],
|
|
5782
|
+
successTemplate: "Conversion executed"
|
|
5766
5783
|
},
|
|
5767
5784
|
{
|
|
5768
5785
|
name: "equity conversions-preview",
|
|
@@ -5773,8 +5790,11 @@ var init_cap_table = __esm({
|
|
|
5773
5790
|
{ flags: "--round-id <round-id>", description: "Equity round ID", required: true },
|
|
5774
5791
|
{ flags: "--source-reference <source-reference>", description: "Source reference for the conversion" }
|
|
5775
5792
|
],
|
|
5776
|
-
examples: [
|
|
5777
|
-
|
|
5793
|
+
examples: [
|
|
5794
|
+
"corp equity conversions-preview --round-id a1b2c3d4",
|
|
5795
|
+
"corp equity conversions-preview --round-id a1b2c3d4 --source-reference safe-note:b2c3d4e5 --json"
|
|
5796
|
+
],
|
|
5797
|
+
successTemplate: "Conversion preview calculated"
|
|
5778
5798
|
},
|
|
5779
5799
|
{
|
|
5780
5800
|
name: "equity dilution-preview",
|
|
@@ -5794,8 +5814,11 @@ var init_cap_table = __esm({
|
|
|
5794
5814
|
{ flags: "--name <name>", description: "Display name", required: true },
|
|
5795
5815
|
{ flags: "--role <role>", description: "Role this legal entity plays in the ownership/control graph.", required: true, choices: ["operating", "control", "investment", "nonprofit", "spv", "other"] }
|
|
5796
5816
|
],
|
|
5797
|
-
examples: [
|
|
5798
|
-
|
|
5817
|
+
examples: [
|
|
5818
|
+
'corp equity entities --name "Acme Corp" --role operating',
|
|
5819
|
+
'corp equity entities --name "Acme Holdings LLC" --role control --linked-entity-id a1b2c3d4'
|
|
5820
|
+
],
|
|
5821
|
+
successTemplate: "Legal entity registered"
|
|
5799
5822
|
},
|
|
5800
5823
|
{
|
|
5801
5824
|
name: "equity create-fundraising-workflow",
|
|
@@ -5811,8 +5834,11 @@ var init_cap_table = __esm({
|
|
|
5811
5834
|
{ flags: "--round-price-cents <round-price-cents>", description: "Round share price in cents" },
|
|
5812
5835
|
{ flags: "--target-raise-cents <target-raise-cents>", description: "Target fundraising amount in cents" }
|
|
5813
5836
|
],
|
|
5814
|
-
examples: [
|
|
5815
|
-
|
|
5837
|
+
examples: [
|
|
5838
|
+
'corp equity create-fundraising-workflow --name "Series A" --issuer-legal-entity-id a1b2c3d4 --prepare-intent-id e5f6a7b8',
|
|
5839
|
+
'corp equity create-fundraising-workflow --name "Seed Round" --issuer-legal-entity-id a1b2c3d4 --prepare-intent-id e5f6a7b8 --target-raise-cents 200000000'
|
|
5840
|
+
],
|
|
5841
|
+
successTemplate: "Fundraising workflow created"
|
|
5816
5842
|
},
|
|
5817
5843
|
{
|
|
5818
5844
|
name: "equity fundraising-workflows",
|
|
@@ -5821,7 +5847,7 @@ var init_cap_table = __esm({
|
|
|
5821
5847
|
entity: true,
|
|
5822
5848
|
args: [{ name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
5823
5849
|
display: { title: "Equity Fundraising Workflows", cols: ["board_packet_documents>Board Packet Documents", "closing_packet_documents>Closing Packet Documents", "@created_at>Created At", "#accept_intent_id>ID"] },
|
|
5824
|
-
examples: ["corp equity fundraising-workflows", "corp equity fundraising-workflows --json"]
|
|
5850
|
+
examples: ["corp equity fundraising-workflows a1b2c3d4", "corp equity fundraising-workflows a1b2c3d4 --json"]
|
|
5825
5851
|
},
|
|
5826
5852
|
{
|
|
5827
5853
|
name: "equity fundraising-workflows-apply-terms",
|
|
@@ -5833,8 +5859,11 @@ var init_cap_table = __esm({
|
|
|
5833
5859
|
{ flags: "--conversion-precedence <conversion-precedence>", description: "Conversion priority ordering", type: "array" },
|
|
5834
5860
|
{ flags: "--protective-provisions <protective-provisions>", description: "Protective provision terms" }
|
|
5835
5861
|
],
|
|
5836
|
-
examples: [
|
|
5837
|
-
|
|
5862
|
+
examples: [
|
|
5863
|
+
"corp equity fundraising-workflows-apply-terms a1b2c3d4 --anti-dilution-method broad_based_weighted_average",
|
|
5864
|
+
"corp equity fundraising-workflows-apply-terms a1b2c3d4 --anti-dilution-method none --protective-provisions 'standard Series A provisions'"
|
|
5865
|
+
],
|
|
5866
|
+
successTemplate: "Term sheet applied to fundraising workflow"
|
|
5838
5867
|
},
|
|
5839
5868
|
{
|
|
5840
5869
|
name: "equity fundraising-workflows-compile-packet",
|
|
@@ -5845,8 +5874,11 @@ var init_cap_table = __esm({
|
|
|
5845
5874
|
{ flags: "--phase <phase>", description: "Workflow phase" },
|
|
5846
5875
|
{ flags: "--required-signers <required-signers>", description: "List of required signers", type: "array" }
|
|
5847
5876
|
],
|
|
5848
|
-
examples: [
|
|
5849
|
-
|
|
5877
|
+
examples: [
|
|
5878
|
+
"corp equity fundraising-workflows-compile-packet a1b2c3d4",
|
|
5879
|
+
"corp equity fundraising-workflows-compile-packet a1b2c3d4 --phase closing"
|
|
5880
|
+
],
|
|
5881
|
+
successTemplate: "Document packet compiled"
|
|
5850
5882
|
},
|
|
5851
5883
|
{
|
|
5852
5884
|
name: "equity fundraising-workflows-finalize",
|
|
@@ -5856,8 +5888,11 @@ var init_cap_table = __esm({
|
|
|
5856
5888
|
options: [
|
|
5857
5889
|
{ flags: "--phase <phase>", description: "Workflow phase" }
|
|
5858
5890
|
],
|
|
5859
|
-
examples: [
|
|
5860
|
-
|
|
5891
|
+
examples: [
|
|
5892
|
+
"corp equity fundraising-workflows-finalize a1b2c3d4",
|
|
5893
|
+
"corp equity fundraising-workflows-finalize a1b2c3d4 --json"
|
|
5894
|
+
],
|
|
5895
|
+
successTemplate: "Fundraising workflow finalized"
|
|
5861
5896
|
},
|
|
5862
5897
|
{
|
|
5863
5898
|
name: "equity fundraising-workflows-generate-board-packet",
|
|
@@ -5867,8 +5902,11 @@ var init_cap_table = __esm({
|
|
|
5867
5902
|
options: [
|
|
5868
5903
|
{ flags: "--documents <documents>", description: "Document references or content", type: "array" }
|
|
5869
5904
|
],
|
|
5870
|
-
examples: [
|
|
5871
|
-
|
|
5905
|
+
examples: [
|
|
5906
|
+
"corp equity fundraising-workflows-generate-board-packet a1b2c3d4",
|
|
5907
|
+
"corp equity fundraising-workflows-generate-board-packet a1b2c3d4 --json"
|
|
5908
|
+
],
|
|
5909
|
+
successTemplate: "Board approval packet generated"
|
|
5872
5910
|
},
|
|
5873
5911
|
{
|
|
5874
5912
|
name: "equity fundraising-workflows-generate-closing-packet",
|
|
@@ -5878,8 +5916,11 @@ var init_cap_table = __esm({
|
|
|
5878
5916
|
options: [
|
|
5879
5917
|
{ flags: "--documents <documents>", description: "Document references or content", type: "array" }
|
|
5880
5918
|
],
|
|
5881
|
-
examples: [
|
|
5882
|
-
|
|
5919
|
+
examples: [
|
|
5920
|
+
"corp equity fundraising-workflows-generate-closing-packet a1b2c3d4",
|
|
5921
|
+
"corp equity fundraising-workflows-generate-closing-packet a1b2c3d4 --json"
|
|
5922
|
+
],
|
|
5923
|
+
successTemplate: "Closing packet generated"
|
|
5883
5924
|
},
|
|
5884
5925
|
{
|
|
5885
5926
|
name: "equity fundraising-workflows-prepare-execution",
|
|
@@ -5892,8 +5933,11 @@ var init_cap_table = __esm({
|
|
|
5892
5933
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true },
|
|
5893
5934
|
{ flags: "--phase <phase>", description: "Workflow phase" }
|
|
5894
5935
|
],
|
|
5895
|
-
examples: [
|
|
5896
|
-
|
|
5936
|
+
examples: [
|
|
5937
|
+
"corp equity fundraising-workflows-prepare-execution a1b2c3d4 --approval-artifact-id b2c3d4e5 --intent-id f6g7h8i9",
|
|
5938
|
+
"corp equity fundraising-workflows-prepare-execution a1b2c3d4 --approval-artifact-id b2c3d4e5 --intent-id f6g7h8i9 --json"
|
|
5939
|
+
],
|
|
5940
|
+
successTemplate: "Fundraising workflow prepared for execution"
|
|
5897
5941
|
},
|
|
5898
5942
|
{
|
|
5899
5943
|
name: "equity fundraising-workflows-record-board-approval",
|
|
@@ -5904,8 +5948,11 @@ var init_cap_table = __esm({
|
|
|
5904
5948
|
{ flags: "--meeting-id <meeting-id>", description: "Meeting ID", required: true },
|
|
5905
5949
|
{ flags: "--resolution-id <resolution-id>", description: "Resolution ID", required: true }
|
|
5906
5950
|
],
|
|
5907
|
-
examples: [
|
|
5908
|
-
|
|
5951
|
+
examples: [
|
|
5952
|
+
"corp equity fundraising-workflows-record-board-approval a1b2c3d4 --meeting-id @last:meeting --resolution-id @last:resolution",
|
|
5953
|
+
"corp equity fundraising-workflows-record-board-approval a1b2c3d4 --meeting-id b2c3d4e5 --resolution-id f6g7h8i9"
|
|
5954
|
+
],
|
|
5955
|
+
successTemplate: "Board approval recorded"
|
|
5909
5956
|
},
|
|
5910
5957
|
{
|
|
5911
5958
|
name: "equity fundraising-workflows-record-close",
|
|
@@ -5915,8 +5962,10 @@ var init_cap_table = __esm({
|
|
|
5915
5962
|
options: [
|
|
5916
5963
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true }
|
|
5917
5964
|
],
|
|
5918
|
-
examples: [
|
|
5919
|
-
|
|
5965
|
+
examples: [
|
|
5966
|
+
"corp equity fundraising-workflows-record-close a1b2c3d4 --intent-id b2c3d4e5"
|
|
5967
|
+
],
|
|
5968
|
+
successTemplate: "Fundraising round closed"
|
|
5920
5969
|
},
|
|
5921
5970
|
{
|
|
5922
5971
|
name: "equity fundraising-workflows-record-investor-acceptance",
|
|
@@ -5927,8 +5976,11 @@ var init_cap_table = __esm({
|
|
|
5927
5976
|
{ flags: "--accepted-by-contact-id <accepted-by-contact-id>", description: "Contact ID of the accepting party" },
|
|
5928
5977
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true }
|
|
5929
5978
|
],
|
|
5930
|
-
examples: [
|
|
5931
|
-
|
|
5979
|
+
examples: [
|
|
5980
|
+
"corp equity fundraising-workflows-record-investor-acceptance a1b2c3d4 --intent-id b2c3d4e5",
|
|
5981
|
+
"corp equity fundraising-workflows-record-investor-acceptance a1b2c3d4 --intent-id b2c3d4e5 --accepted-by-contact-id c3d4e5f6"
|
|
5982
|
+
],
|
|
5983
|
+
successTemplate: "Investor acceptance recorded"
|
|
5932
5984
|
},
|
|
5933
5985
|
{
|
|
5934
5986
|
name: "equity fundraising-workflows-record-signature",
|
|
@@ -5939,16 +5991,21 @@ var init_cap_table = __esm({
|
|
|
5939
5991
|
{ flags: "--channel <channel>", description: "Approval channel (board_vote, written_consent, etc.)" },
|
|
5940
5992
|
{ flags: "--signer-identity <signer-identity>", description: "Identity of the signer", required: true }
|
|
5941
5993
|
],
|
|
5942
|
-
examples: [
|
|
5943
|
-
|
|
5994
|
+
examples: [
|
|
5995
|
+
'corp equity fundraising-workflows-record-signature a1b2c3d4 --signer-identity "alice@acme.com"',
|
|
5996
|
+
'corp equity fundraising-workflows-record-signature a1b2c3d4 --signer-identity "alice@acme.com" --channel written_consent'
|
|
5997
|
+
],
|
|
5998
|
+
successTemplate: "Signature recorded"
|
|
5944
5999
|
},
|
|
5945
6000
|
{
|
|
5946
6001
|
name: "equity fundraising-workflows-start-signatures",
|
|
5947
6002
|
description: "Start the signature collection process",
|
|
5948
6003
|
route: { method: "POST", path: "/v1/equity/fundraising-workflows/{pos}/start-signatures" },
|
|
5949
6004
|
args: [{ name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
5950
|
-
examples: [
|
|
5951
|
-
|
|
6005
|
+
examples: [
|
|
6006
|
+
"corp equity fundraising-workflows-start-signatures a1b2c3d4"
|
|
6007
|
+
],
|
|
6008
|
+
successTemplate: "Signature collection started"
|
|
5952
6009
|
},
|
|
5953
6010
|
{
|
|
5954
6011
|
name: "equity grants",
|
|
@@ -5960,8 +6017,11 @@ var init_cap_table = __esm({
|
|
|
5960
6017
|
{ flags: "--recipient-name <recipient-name>", description: "Payment recipient name", required: true },
|
|
5961
6018
|
{ flags: "--shares <shares>", description: "Shares", required: true, type: "int" }
|
|
5962
6019
|
],
|
|
5963
|
-
examples: [
|
|
5964
|
-
|
|
6020
|
+
examples: [
|
|
6021
|
+
'corp equity grants --grant-type common_stock --recipient-name "Alice Smith" --shares 500000',
|
|
6022
|
+
'corp equity grants --grant-type iso --recipient-name "Bob Jones" --shares 25000'
|
|
6023
|
+
],
|
|
6024
|
+
successTemplate: "Equity grant issued"
|
|
5965
6025
|
},
|
|
5966
6026
|
{
|
|
5967
6027
|
name: "equity holders",
|
|
@@ -5975,8 +6035,11 @@ var init_cap_table = __esm({
|
|
|
5975
6035
|
{ flags: "--linked-entity-id <linked-entity-id>", description: "ID of the entity to link" },
|
|
5976
6036
|
{ flags: "--name <name>", description: "Display name", required: true }
|
|
5977
6037
|
],
|
|
5978
|
-
examples: [
|
|
5979
|
-
|
|
6038
|
+
examples: [
|
|
6039
|
+
'corp equity holders --contact-id a1b2c3d4 --holder-type individual --name "Alice Smith"',
|
|
6040
|
+
'corp equity holders --contact-id e5f6a7b8 --holder-type fund --name "Acme Ventures Fund I"'
|
|
6041
|
+
],
|
|
6042
|
+
successTemplate: "Equity holder registered"
|
|
5980
6043
|
},
|
|
5981
6044
|
{
|
|
5982
6045
|
name: "equity instruments",
|
|
@@ -5991,8 +6054,11 @@ var init_cap_table = __esm({
|
|
|
5991
6054
|
{ flags: "--symbol <symbol>", description: "Symbol", required: true },
|
|
5992
6055
|
{ flags: "--terms <terms>", description: "Terms" }
|
|
5993
6056
|
],
|
|
5994
|
-
examples: [
|
|
5995
|
-
|
|
6057
|
+
examples: [
|
|
6058
|
+
"corp equity instruments --issuer-legal-entity-id a1b2c3d4 --kind common_equity --symbol COMMON",
|
|
6059
|
+
"corp equity instruments --issuer-legal-entity-id a1b2c3d4 --kind option_grant --symbol OPTIONS --authorized-units 10000000"
|
|
6060
|
+
],
|
|
6061
|
+
successTemplate: "Instrument created"
|
|
5996
6062
|
},
|
|
5997
6063
|
{
|
|
5998
6064
|
name: "equity positions-adjust",
|
|
@@ -6007,8 +6073,11 @@ var init_cap_table = __esm({
|
|
|
6007
6073
|
{ flags: "--quantity-delta <quantity-delta>", description: "Quantity Delta", required: true, type: "int" },
|
|
6008
6074
|
{ flags: "--source-reference <source-reference>", description: "Source reference for the conversion" }
|
|
6009
6075
|
],
|
|
6010
|
-
examples: [
|
|
6011
|
-
|
|
6076
|
+
examples: [
|
|
6077
|
+
"corp equity positions-adjust --holder-id a1b2c3d4 --instrument-id b2c3d4e5 --issuer-legal-entity-id c3d4e5f6 --quantity-delta 10000",
|
|
6078
|
+
"corp equity positions-adjust --holder-id a1b2c3d4 --instrument-id b2c3d4e5 --issuer-legal-entity-id c3d4e5f6 --quantity-delta -5000 --source-reference correction:2026-01"
|
|
6079
|
+
],
|
|
6080
|
+
successTemplate: "Equity position adjusted"
|
|
6012
6081
|
},
|
|
6013
6082
|
{
|
|
6014
6083
|
name: "equity rounds",
|
|
@@ -6024,8 +6093,11 @@ var init_cap_table = __esm({
|
|
|
6024
6093
|
{ flags: "--round-price-cents <round-price-cents>", description: "Round share price in cents" },
|
|
6025
6094
|
{ flags: "--target-raise-cents <target-raise-cents>", description: "Target fundraising amount in cents" }
|
|
6026
6095
|
],
|
|
6027
|
-
examples: [
|
|
6028
|
-
|
|
6096
|
+
examples: [
|
|
6097
|
+
'corp equity rounds --issuer-legal-entity-id a1b2c3d4 --name "Series A"',
|
|
6098
|
+
'corp equity rounds --issuer-legal-entity-id a1b2c3d4 --name "Seed Round" --target-raise-cents 150000000 --pre-money-cents 800000000'
|
|
6099
|
+
],
|
|
6100
|
+
successTemplate: "Equity round created"
|
|
6029
6101
|
},
|
|
6030
6102
|
{
|
|
6031
6103
|
name: "equity rounds-staged",
|
|
@@ -6040,8 +6112,11 @@ var init_cap_table = __esm({
|
|
|
6040
6112
|
{ flags: "--round-price-cents <round-price-cents>", description: "Round share price in cents" },
|
|
6041
6113
|
{ flags: "--target-raise-cents <target-raise-cents>", description: "Target fundraising amount in cents" }
|
|
6042
6114
|
],
|
|
6043
|
-
examples: [
|
|
6044
|
-
|
|
6115
|
+
examples: [
|
|
6116
|
+
'corp equity rounds-staged --issuer-legal-entity-id a1b2c3d4 --name "Series A"',
|
|
6117
|
+
'corp equity rounds-staged --issuer-legal-entity-id a1b2c3d4 --name "Seed Round" --target-raise-cents 150000000'
|
|
6118
|
+
],
|
|
6119
|
+
successTemplate: "Staged equity round created"
|
|
6045
6120
|
},
|
|
6046
6121
|
{
|
|
6047
6122
|
name: "equity rounds-accept",
|
|
@@ -6053,8 +6128,11 @@ var init_cap_table = __esm({
|
|
|
6053
6128
|
{ flags: "--accepted-by-contact-id <accepted-by-contact-id>", description: "Contact ID of the accepting party" },
|
|
6054
6129
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true }
|
|
6055
6130
|
],
|
|
6056
|
-
examples: [
|
|
6057
|
-
|
|
6131
|
+
examples: [
|
|
6132
|
+
"corp equity rounds-accept a1b2c3d4 --intent-id b2c3d4e5",
|
|
6133
|
+
"corp equity rounds-accept a1b2c3d4 --intent-id b2c3d4e5 --accepted-by-contact-id c3d4e5f6"
|
|
6134
|
+
],
|
|
6135
|
+
successTemplate: "Round terms accepted"
|
|
6058
6136
|
},
|
|
6059
6137
|
{
|
|
6060
6138
|
name: "equity rounds-apply-terms",
|
|
@@ -6067,8 +6145,11 @@ var init_cap_table = __esm({
|
|
|
6067
6145
|
{ flags: "--conversion-precedence <conversion-precedence>", description: "Conversion priority ordering", type: "array" },
|
|
6068
6146
|
{ flags: "--protective-provisions <protective-provisions>", description: "Protective provision terms" }
|
|
6069
6147
|
],
|
|
6070
|
-
examples: [
|
|
6071
|
-
|
|
6148
|
+
examples: [
|
|
6149
|
+
"corp equity rounds-apply-terms a1b2c3d4 --anti-dilution-method broad_based_weighted_average",
|
|
6150
|
+
"corp equity rounds-apply-terms a1b2c3d4 --anti-dilution-method none --protective-provisions 'standard Series A'"
|
|
6151
|
+
],
|
|
6152
|
+
successTemplate: "Term sheet applied to round"
|
|
6072
6153
|
},
|
|
6073
6154
|
{
|
|
6074
6155
|
name: "equity rounds-board-approve",
|
|
@@ -6080,8 +6161,11 @@ var init_cap_table = __esm({
|
|
|
6080
6161
|
{ flags: "--meeting-id <meeting-id>", description: "Meeting ID", required: true },
|
|
6081
6162
|
{ flags: "--resolution-id <resolution-id>", description: "Resolution ID", required: true }
|
|
6082
6163
|
],
|
|
6083
|
-
examples: [
|
|
6084
|
-
|
|
6164
|
+
examples: [
|
|
6165
|
+
"corp equity rounds-board-approve a1b2c3d4 --meeting-id @last:meeting --resolution-id @last:resolution",
|
|
6166
|
+
"corp equity rounds-board-approve a1b2c3d4 --meeting-id b2c3d4e5 --resolution-id f6g7h8i9"
|
|
6167
|
+
],
|
|
6168
|
+
successTemplate: "Board approval recorded for round"
|
|
6085
6169
|
},
|
|
6086
6170
|
{
|
|
6087
6171
|
name: "equity rounds-issue",
|
|
@@ -6093,8 +6177,11 @@ var init_cap_table = __esm({
|
|
|
6093
6177
|
{ flags: "--meeting-id <meeting-id>", description: "Meeting ID" },
|
|
6094
6178
|
{ flags: "--resolution-id <resolution-id>", description: "Resolution ID" }
|
|
6095
6179
|
],
|
|
6096
|
-
examples: [
|
|
6097
|
-
|
|
6180
|
+
examples: [
|
|
6181
|
+
"corp equity rounds-issue a1b2c3d4",
|
|
6182
|
+
"corp equity rounds-issue a1b2c3d4 --meeting-id @last:meeting --resolution-id @last:resolution"
|
|
6183
|
+
],
|
|
6184
|
+
successTemplate: "Round issued"
|
|
6098
6185
|
},
|
|
6099
6186
|
{
|
|
6100
6187
|
name: "equity rounds-securities",
|
|
@@ -6111,8 +6198,11 @@ var init_cap_table = __esm({
|
|
|
6111
6198
|
{ flags: "--quantity <quantity>", description: "Quantity", required: true, type: "int" },
|
|
6112
6199
|
{ flags: "--recipient-name <recipient-name>", description: "Payment recipient name", required: true }
|
|
6113
6200
|
],
|
|
6114
|
-
examples: [
|
|
6115
|
-
|
|
6201
|
+
examples: [
|
|
6202
|
+
'corp equity rounds-securities a1b2c3d4 --instrument-id COMMON --quantity 500000 --recipient-name "Alice Smith"',
|
|
6203
|
+
'corp equity rounds-securities a1b2c3d4 --instrument-id SERIES-A --quantity 1000000 --recipient-name "Acme Ventures" --email "invest@acme.com"'
|
|
6204
|
+
],
|
|
6205
|
+
successTemplate: "Security added to round"
|
|
6116
6206
|
},
|
|
6117
6207
|
{
|
|
6118
6208
|
name: "equity create-transfer-workflow",
|
|
@@ -6130,8 +6220,11 @@ var init_cap_table = __esm({
|
|
|
6130
6220
|
{ flags: "--transfer-type <transfer-type>", description: "Type of share transfer.", required: true, choices: ["gift", "trust_transfer", "secondary_sale", "estate", "other"] },
|
|
6131
6221
|
{ flags: "--transferee-rights <transferee-rights>", description: "Rights granted to the transferee.", required: true, choices: ["full_member", "economic_only", "limited"] }
|
|
6132
6222
|
],
|
|
6133
|
-
examples: [
|
|
6134
|
-
|
|
6223
|
+
examples: [
|
|
6224
|
+
"corp equity create-transfer-workflow --from-contact-id a1b2c3d4 --to-contact-id e5f6a7b8 --share-class-id COMMON --share-count 10000 --transfer-type secondary_sale --governing-doc-type bylaws --transferee-rights full_member --prepare-intent-id f9g0h1i2",
|
|
6225
|
+
"corp equity create-transfer-workflow --from-contact-id a1b2c3d4 --to-contact-id e5f6a7b8 --share-class-id COMMON --share-count 5000 --transfer-type gift --governing-doc-type bylaws --transferee-rights full_member --prepare-intent-id f9g0h1i2"
|
|
6226
|
+
],
|
|
6227
|
+
successTemplate: "Transfer workflow created"
|
|
6135
6228
|
},
|
|
6136
6229
|
{
|
|
6137
6230
|
name: "equity transfer-workflows",
|
|
@@ -6140,7 +6233,7 @@ var init_cap_table = __esm({
|
|
|
6140
6233
|
entity: true,
|
|
6141
6234
|
args: [{ name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
6142
6235
|
display: { title: "Equity Transfer Workflows", cols: ["execution_status>Execution Status", "generated_documents>Generated Documents", "last_packet_hash>Last Packet Hash", "@created_at>Created At", "#active_packet_id>ID"] },
|
|
6143
|
-
examples: ["corp equity transfer-workflows", "corp equity transfer-workflows --json"]
|
|
6236
|
+
examples: ["corp equity transfer-workflows a1b2c3d4", "corp equity transfer-workflows a1b2c3d4 --json"]
|
|
6144
6237
|
},
|
|
6145
6238
|
{
|
|
6146
6239
|
name: "equity transfer-workflows-compile-packet",
|
|
@@ -6151,8 +6244,11 @@ var init_cap_table = __esm({
|
|
|
6151
6244
|
{ flags: "--phase <phase>", description: "Workflow phase" },
|
|
6152
6245
|
{ flags: "--required-signers <required-signers>", description: "List of required signers", type: "array" }
|
|
6153
6246
|
],
|
|
6154
|
-
examples: [
|
|
6155
|
-
|
|
6247
|
+
examples: [
|
|
6248
|
+
"corp equity transfer-workflows-compile-packet a1b2c3d4",
|
|
6249
|
+
"corp equity transfer-workflows-compile-packet a1b2c3d4 --phase execution"
|
|
6250
|
+
],
|
|
6251
|
+
successTemplate: "Transfer document packet compiled"
|
|
6156
6252
|
},
|
|
6157
6253
|
{
|
|
6158
6254
|
name: "equity transfer-workflows-finalize",
|
|
@@ -6162,8 +6258,11 @@ var init_cap_table = __esm({
|
|
|
6162
6258
|
options: [
|
|
6163
6259
|
{ flags: "--phase <phase>", description: "Workflow phase" }
|
|
6164
6260
|
],
|
|
6165
|
-
examples: [
|
|
6166
|
-
|
|
6261
|
+
examples: [
|
|
6262
|
+
"corp equity transfer-workflows-finalize a1b2c3d4",
|
|
6263
|
+
"corp equity transfer-workflows-finalize a1b2c3d4 --json"
|
|
6264
|
+
],
|
|
6265
|
+
successTemplate: "Transfer workflow finalized"
|
|
6167
6266
|
},
|
|
6168
6267
|
{
|
|
6169
6268
|
name: "equity transfer-workflows-generate-docs",
|
|
@@ -6173,8 +6272,11 @@ var init_cap_table = __esm({
|
|
|
6173
6272
|
options: [
|
|
6174
6273
|
{ flags: "--documents <documents>", description: "Document references or content", type: "array" }
|
|
6175
6274
|
],
|
|
6176
|
-
examples: [
|
|
6177
|
-
|
|
6275
|
+
examples: [
|
|
6276
|
+
"corp equity transfer-workflows-generate-docs a1b2c3d4",
|
|
6277
|
+
"corp equity transfer-workflows-generate-docs a1b2c3d4 --json"
|
|
6278
|
+
],
|
|
6279
|
+
successTemplate: "Transfer documents generated"
|
|
6178
6280
|
},
|
|
6179
6281
|
{
|
|
6180
6282
|
name: "equity transfer-workflows-prepare-execution",
|
|
@@ -6187,8 +6289,11 @@ var init_cap_table = __esm({
|
|
|
6187
6289
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true },
|
|
6188
6290
|
{ flags: "--phase <phase>", description: "Workflow phase" }
|
|
6189
6291
|
],
|
|
6190
|
-
examples: [
|
|
6191
|
-
|
|
6292
|
+
examples: [
|
|
6293
|
+
"corp equity transfer-workflows-prepare-execution a1b2c3d4 --approval-artifact-id b2c3d4e5 --intent-id f6g7h8i9",
|
|
6294
|
+
"corp equity transfer-workflows-prepare-execution a1b2c3d4 --approval-artifact-id b2c3d4e5 --intent-id f6g7h8i9 --json"
|
|
6295
|
+
],
|
|
6296
|
+
successTemplate: "Transfer workflow prepared for execution"
|
|
6192
6297
|
},
|
|
6193
6298
|
{
|
|
6194
6299
|
name: "equity transfer-workflows-record-board-approval",
|
|
@@ -6199,8 +6304,11 @@ var init_cap_table = __esm({
|
|
|
6199
6304
|
{ flags: "--meeting-id <meeting-id>", description: "Meeting ID", required: true },
|
|
6200
6305
|
{ flags: "--resolution-id <resolution-id>", description: "Resolution ID", required: true }
|
|
6201
6306
|
],
|
|
6202
|
-
examples: [
|
|
6203
|
-
|
|
6307
|
+
examples: [
|
|
6308
|
+
"corp equity transfer-workflows-record-board-approval a1b2c3d4 --meeting-id @last:meeting --resolution-id @last:resolution",
|
|
6309
|
+
"corp equity transfer-workflows-record-board-approval a1b2c3d4 --meeting-id b2c3d4e5 --resolution-id f6g7h8i9"
|
|
6310
|
+
],
|
|
6311
|
+
successTemplate: "Board approval recorded for transfer"
|
|
6204
6312
|
},
|
|
6205
6313
|
{
|
|
6206
6314
|
name: "equity transfer-workflows-record-execution",
|
|
@@ -6210,8 +6318,10 @@ var init_cap_table = __esm({
|
|
|
6210
6318
|
options: [
|
|
6211
6319
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID", required: true }
|
|
6212
6320
|
],
|
|
6213
|
-
examples: [
|
|
6214
|
-
|
|
6321
|
+
examples: [
|
|
6322
|
+
"corp equity transfer-workflows-record-execution a1b2c3d4 --intent-id b2c3d4e5"
|
|
6323
|
+
],
|
|
6324
|
+
successTemplate: "Transfer execution recorded"
|
|
6215
6325
|
},
|
|
6216
6326
|
{
|
|
6217
6327
|
name: "equity transfer-workflows-record-review",
|
|
@@ -6223,8 +6333,11 @@ var init_cap_table = __esm({
|
|
|
6223
6333
|
{ flags: "--notes <notes>", description: "Additional notes", required: true },
|
|
6224
6334
|
{ flags: "--reviewer <reviewer>", description: "Reviewer", required: true }
|
|
6225
6335
|
],
|
|
6226
|
-
examples: [
|
|
6227
|
-
|
|
6336
|
+
examples: [
|
|
6337
|
+
'corp equity transfer-workflows-record-review a1b2c3d4 --approved --notes "Transfer complies with ROFR provisions" --reviewer alice-johnson',
|
|
6338
|
+
'corp equity transfer-workflows-record-review a1b2c3d4 --notes "Missing consent form" --reviewer alice-johnson'
|
|
6339
|
+
],
|
|
6340
|
+
successTemplate: "Transfer review recorded"
|
|
6228
6341
|
},
|
|
6229
6342
|
{
|
|
6230
6343
|
name: "equity transfer-workflows-record-rofr",
|
|
@@ -6235,8 +6348,11 @@ var init_cap_table = __esm({
|
|
|
6235
6348
|
{ flags: "--offered", description: "Offered", required: true },
|
|
6236
6349
|
{ flags: "--waived", description: "Waived", required: true }
|
|
6237
6350
|
],
|
|
6238
|
-
examples: [
|
|
6239
|
-
|
|
6351
|
+
examples: [
|
|
6352
|
+
"corp equity transfer-workflows-record-rofr a1b2c3d4 --offered --waived",
|
|
6353
|
+
"corp equity transfer-workflows-record-rofr a1b2c3d4 --offered"
|
|
6354
|
+
],
|
|
6355
|
+
successTemplate: "ROFR recorded"
|
|
6240
6356
|
},
|
|
6241
6357
|
{
|
|
6242
6358
|
name: "equity transfer-workflows-record-signature",
|
|
@@ -6247,24 +6363,31 @@ var init_cap_table = __esm({
|
|
|
6247
6363
|
{ flags: "--channel <channel>", description: "Approval channel (board_vote, written_consent, etc.)" },
|
|
6248
6364
|
{ flags: "--signer-identity <signer-identity>", description: "Identity of the signer", required: true }
|
|
6249
6365
|
],
|
|
6250
|
-
examples: [
|
|
6251
|
-
|
|
6366
|
+
examples: [
|
|
6367
|
+
'corp equity transfer-workflows-record-signature a1b2c3d4 --signer-identity "alice@acme.com"',
|
|
6368
|
+
'corp equity transfer-workflows-record-signature a1b2c3d4 --signer-identity "bob@acme.com" --channel written_consent'
|
|
6369
|
+
],
|
|
6370
|
+
successTemplate: "Signature recorded on transfer"
|
|
6252
6371
|
},
|
|
6253
6372
|
{
|
|
6254
6373
|
name: "equity transfer-workflows-start-signatures",
|
|
6255
6374
|
description: "Start signature collection for transfer",
|
|
6256
6375
|
route: { method: "POST", path: "/v1/equity/transfer-workflows/{pos}/start-signatures" },
|
|
6257
6376
|
args: [{ name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
6258
|
-
examples: [
|
|
6259
|
-
|
|
6377
|
+
examples: [
|
|
6378
|
+
"corp equity transfer-workflows-start-signatures a1b2c3d4"
|
|
6379
|
+
],
|
|
6380
|
+
successTemplate: "Transfer signature collection started"
|
|
6260
6381
|
},
|
|
6261
6382
|
{
|
|
6262
6383
|
name: "equity transfer-workflows-submit-review",
|
|
6263
6384
|
description: "Submit a share transfer for review",
|
|
6264
6385
|
route: { method: "POST", path: "/v1/equity/transfer-workflows/{pos}/submit-review" },
|
|
6265
6386
|
args: [{ name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
6266
|
-
examples: [
|
|
6267
|
-
|
|
6387
|
+
examples: [
|
|
6388
|
+
"corp equity transfer-workflows-submit-review a1b2c3d4"
|
|
6389
|
+
],
|
|
6390
|
+
successTemplate: "Transfer submitted for review"
|
|
6268
6391
|
},
|
|
6269
6392
|
{
|
|
6270
6393
|
name: "equity workflows-status",
|
|
@@ -6273,7 +6396,10 @@ var init_cap_table = __esm({
|
|
|
6273
6396
|
entity: true,
|
|
6274
6397
|
args: [{ name: "workflow-type", required: true, description: "Workflow Type" }, { name: "workflow-id", required: true, description: "Workflow ID" }],
|
|
6275
6398
|
display: { title: "Equity Workflows Status", cols: ["execution_status>Execution Status", "fundraising_workflow>Fundraising Workflow", "packet>Packet", "transfer_workflow>Transfer Workflow", "#active_packet_id>ID"] },
|
|
6276
|
-
examples: [
|
|
6399
|
+
examples: [
|
|
6400
|
+
"corp equity workflows-status transfer a1b2c3d4",
|
|
6401
|
+
"corp equity workflows-status fundraising a1b2c3d4 --json"
|
|
6402
|
+
]
|
|
6277
6403
|
},
|
|
6278
6404
|
{
|
|
6279
6405
|
name: "safe-notes",
|
|
@@ -6293,8 +6419,11 @@ var init_cap_table = __esm({
|
|
|
6293
6419
|
{ flags: "--safe-type <safe-type>", description: "Safe Type", choices: ["post_money", "pre_money", "mfn"] },
|
|
6294
6420
|
{ flags: "--valuation-cap-cents <valuation-cap-cents>", description: "Valuation Cap Cents" }
|
|
6295
6421
|
],
|
|
6296
|
-
examples: [
|
|
6297
|
-
|
|
6422
|
+
examples: [
|
|
6423
|
+
'corp safe-notes --investor-name "Sequoia Capital" --principal-amount-cents 50000000 --valuation-cap-cents 1000000000',
|
|
6424
|
+
'corp safe-notes --investor-name "Angel Investor" --principal-amount-cents 25000000 --safe-type pre_money --discount-rate 20'
|
|
6425
|
+
],
|
|
6426
|
+
successTemplate: "SAFE note issued"
|
|
6298
6427
|
},
|
|
6299
6428
|
{
|
|
6300
6429
|
name: "share-transfers",
|
|
@@ -6309,8 +6438,11 @@ var init_cap_table = __esm({
|
|
|
6309
6438
|
{ flags: "--transfer-type <transfer-type>", description: "Type of share transfer.", required: true, choices: ["gift", "trust_transfer", "secondary_sale", "estate", "other"] },
|
|
6310
6439
|
{ flags: "--transferee-rights <transferee-rights>", description: "Transferee Rights", choices: ["full_member", "economic_only", "limited"] }
|
|
6311
6440
|
],
|
|
6312
|
-
examples: [
|
|
6313
|
-
|
|
6441
|
+
examples: [
|
|
6442
|
+
"corp share-transfers --from-holder a1b2c3d4 --to-holder e5f6a7b8 --share-class-id COMMON --shares 10000 --transfer-type secondary_sale",
|
|
6443
|
+
"corp share-transfers --from-holder a1b2c3d4 --to-holder e5f6a7b8 --share-class-id COMMON --shares 5000 --transfer-type gift --governing-doc-type bylaws --transferee-rights full_member"
|
|
6444
|
+
],
|
|
6445
|
+
successTemplate: "Share transfer recorded"
|
|
6314
6446
|
},
|
|
6315
6447
|
{
|
|
6316
6448
|
name: "valuations",
|
|
@@ -6328,16 +6460,21 @@ var init_cap_table = __esm({
|
|
|
6328
6460
|
{ flags: "--report-document-id <report-document-id>", description: "Report Document Id" },
|
|
6329
6461
|
{ flags: "--valuation-type <valuation-type>", description: "Type of 409A or equivalent valuation.", required: true, choices: ["four_oh_nine_a", "llc_profits_interest", "fair_market_value", "gift", "estate", "other"] }
|
|
6330
6462
|
],
|
|
6331
|
-
examples: [
|
|
6332
|
-
|
|
6463
|
+
examples: [
|
|
6464
|
+
"corp valuations --effective-date 2026-01-01 --methodology backsolve --valuation-type four_oh_nine_a",
|
|
6465
|
+
"corp valuations --effective-date 2026-01-01 --methodology market --valuation-type fair_market_value --fmv-per-share-cents 125 --enterprise-value-cents 50000000"
|
|
6466
|
+
],
|
|
6467
|
+
successTemplate: "Valuation created"
|
|
6333
6468
|
},
|
|
6334
6469
|
{
|
|
6335
6470
|
name: "valuations submit-for-approval",
|
|
6336
6471
|
description: "Submit a valuation for board approval",
|
|
6337
6472
|
route: { method: "POST", path: "/v1/valuations/{pos}/submit-for-approval" },
|
|
6338
6473
|
args: [{ name: "valuation-id", required: true, description: "Valuation ID" }],
|
|
6339
|
-
examples: [
|
|
6340
|
-
|
|
6474
|
+
examples: [
|
|
6475
|
+
"corp valuations submit-for-approval a1b2c3d4"
|
|
6476
|
+
],
|
|
6477
|
+
successTemplate: "Valuation submitted for approval"
|
|
6341
6478
|
}
|
|
6342
6479
|
];
|
|
6343
6480
|
}
|
|
@@ -6991,7 +7128,10 @@ var init_governance = __esm({
|
|
|
6991
7128
|
}
|
|
6992
7129
|
printSeatsTable(seats);
|
|
6993
7130
|
},
|
|
6994
|
-
examples: [
|
|
7131
|
+
examples: [
|
|
7132
|
+
"corp governance seats @last:body",
|
|
7133
|
+
"corp governance seats a1b2c3d4 --json"
|
|
7134
|
+
]
|
|
6995
7135
|
},
|
|
6996
7136
|
// --- governance meetings <body-ref> ---
|
|
6997
7137
|
{
|
|
@@ -7023,7 +7163,10 @@ var init_governance = __esm({
|
|
|
7023
7163
|
}
|
|
7024
7164
|
printMeetingsTable(meetings);
|
|
7025
7165
|
},
|
|
7026
|
-
examples: [
|
|
7166
|
+
examples: [
|
|
7167
|
+
"corp governance meetings @last:body",
|
|
7168
|
+
"corp governance meetings a1b2c3d4 --json"
|
|
7169
|
+
]
|
|
7027
7170
|
},
|
|
7028
7171
|
// --- governance resolutions <meeting-ref> ---
|
|
7029
7172
|
{
|
|
@@ -7055,7 +7198,10 @@ var init_governance = __esm({
|
|
|
7055
7198
|
}
|
|
7056
7199
|
printResolutionsTable(resolutions);
|
|
7057
7200
|
},
|
|
7058
|
-
examples: [
|
|
7201
|
+
examples: [
|
|
7202
|
+
"corp governance resolutions @last:meeting",
|
|
7203
|
+
"corp governance resolutions a1b2c3d4 --json"
|
|
7204
|
+
]
|
|
7059
7205
|
},
|
|
7060
7206
|
// --- governance agenda-items <meeting-ref> ---
|
|
7061
7207
|
{
|
|
@@ -7087,12 +7233,15 @@ var init_governance = __esm({
|
|
|
7087
7233
|
}
|
|
7088
7234
|
printAgendaItemsTable(items);
|
|
7089
7235
|
},
|
|
7090
|
-
examples: [
|
|
7091
|
-
|
|
7236
|
+
examples: [
|
|
7237
|
+
"corp governance agenda-items @last:meeting",
|
|
7238
|
+
"corp governance agenda-items a1b2c3d4 --json"
|
|
7239
|
+
]
|
|
7240
|
+
},
|
|
7092
7241
|
// --- governance incidents ---
|
|
7093
7242
|
{
|
|
7094
7243
|
name: "governance incidents",
|
|
7095
|
-
description: "
|
|
7244
|
+
description: "List governance incidents for this entity",
|
|
7096
7245
|
route: { method: "GET", path: "/v1/entities/{eid}/governance/incidents" },
|
|
7097
7246
|
entity: true,
|
|
7098
7247
|
display: { title: "Governance Incidents" },
|
|
@@ -7175,7 +7324,11 @@ var init_governance = __esm({
|
|
|
7175
7324
|
if (result.reason) console.log(` ${chalk8.bold("Reason:")} ${result.reason}`);
|
|
7176
7325
|
}
|
|
7177
7326
|
},
|
|
7178
|
-
examples: [
|
|
7327
|
+
examples: [
|
|
7328
|
+
"corp governance mode",
|
|
7329
|
+
"corp governance mode --set board",
|
|
7330
|
+
"corp governance mode --set founder"
|
|
7331
|
+
]
|
|
7179
7332
|
},
|
|
7180
7333
|
// --- governance create-body ---
|
|
7181
7334
|
{
|
|
@@ -7219,7 +7372,10 @@ var init_governance = __esm({
|
|
|
7219
7372
|
},
|
|
7220
7373
|
produces: { kind: "body" },
|
|
7221
7374
|
successTemplate: "Governance body created: {name}",
|
|
7222
|
-
examples: [
|
|
7375
|
+
examples: [
|
|
7376
|
+
'corp governance create-body --name "Board of Directors" --body-type board_of_directors',
|
|
7377
|
+
'corp governance create-body --name "Member Vote" --body-type llc_member_vote --quorum unanimous --voting per_unit'
|
|
7378
|
+
]
|
|
7223
7379
|
},
|
|
7224
7380
|
// --- governance add-seat <body-ref> ---
|
|
7225
7381
|
{
|
|
@@ -7231,7 +7387,7 @@ var init_governance = __esm({
|
|
|
7231
7387
|
args: [{ name: "body-ref", required: true, description: "Governance body reference" }],
|
|
7232
7388
|
options: [
|
|
7233
7389
|
{ flags: "--holder <contact-ref>", description: "Contact reference for the seat holder", required: true },
|
|
7234
|
-
{ flags: "--role <role>", description: "Seat role
|
|
7390
|
+
{ flags: "--role <role>", description: "Seat role", default: "member", choices: ["chair", "member", "officer", "observer"] }
|
|
7235
7391
|
],
|
|
7236
7392
|
handler: async (ctx) => {
|
|
7237
7393
|
const bodyRef = ctx.positional[0];
|
|
@@ -7254,8 +7410,11 @@ var init_governance = __esm({
|
|
|
7254
7410
|
printReferenceSummary("seat", result, { showReuseHint: true });
|
|
7255
7411
|
},
|
|
7256
7412
|
produces: { kind: "seat" },
|
|
7257
|
-
successTemplate: "Seat added
|
|
7258
|
-
examples: [
|
|
7413
|
+
successTemplate: "Seat added: {seat_id}",
|
|
7414
|
+
examples: [
|
|
7415
|
+
"corp governance add-seat @last:body --holder alice-johnson",
|
|
7416
|
+
"corp governance add-seat @last:body --holder bob-smith --role chair"
|
|
7417
|
+
]
|
|
7259
7418
|
},
|
|
7260
7419
|
// --- governance convene ---
|
|
7261
7420
|
{
|
|
@@ -7266,7 +7425,7 @@ var init_governance = __esm({
|
|
|
7266
7425
|
dryRun: true,
|
|
7267
7426
|
options: [
|
|
7268
7427
|
{ flags: "--body <ref>", description: "Governance body reference", required: true },
|
|
7269
|
-
{ flags: "--type <type>", description: "Meeting type
|
|
7428
|
+
{ flags: "--type <type>", description: "Meeting type", required: true, choices: ["board_meeting", "shareholder_meeting", "member_meeting", "written_consent"] },
|
|
7270
7429
|
{ flags: "--title <title>", description: "Meeting title", required: true },
|
|
7271
7430
|
{ flags: "--date <date>", description: "Meeting date (ISO 8601)" },
|
|
7272
7431
|
{ flags: "--agenda <item>", description: "Agenda item (repeatable)", type: "array" }
|
|
@@ -7303,7 +7462,10 @@ var init_governance = __esm({
|
|
|
7303
7462
|
},
|
|
7304
7463
|
produces: { kind: "meeting" },
|
|
7305
7464
|
successTemplate: "Meeting scheduled: {title}",
|
|
7306
|
-
examples: [
|
|
7465
|
+
examples: [
|
|
7466
|
+
'corp governance convene --body @last:body --type board_meeting --title "Q1 2026 Board Meeting" --date 2026-03-31',
|
|
7467
|
+
'corp governance convene --body @last:body --type board_meeting --title "Special Meeting" --agenda "Approve option plan" --agenda "Approve SAFE issuance"'
|
|
7468
|
+
]
|
|
7307
7469
|
},
|
|
7308
7470
|
// --- governance open <meeting-ref> ---
|
|
7309
7471
|
{
|
|
@@ -7345,7 +7507,10 @@ var init_governance = __esm({
|
|
|
7345
7507
|
}
|
|
7346
7508
|
ctx.writer.success(`Meeting opened: ${resolvedMeetingId}`);
|
|
7347
7509
|
},
|
|
7348
|
-
examples: [
|
|
7510
|
+
examples: [
|
|
7511
|
+
"corp governance open @last:meeting --present-seat @last:seat",
|
|
7512
|
+
"corp governance open a1b2c3d4 --present-seat seat-alice --present-seat seat-bob"
|
|
7513
|
+
]
|
|
7349
7514
|
},
|
|
7350
7515
|
// --- governance vote <meeting-ref> <item-ref> ---
|
|
7351
7516
|
{
|
|
@@ -7399,7 +7564,11 @@ var init_governance = __esm({
|
|
|
7399
7564
|
}
|
|
7400
7565
|
}
|
|
7401
7566
|
},
|
|
7402
|
-
|
|
7567
|
+
successTemplate: "Vote recorded: {vote_id}",
|
|
7568
|
+
examples: [
|
|
7569
|
+
"corp governance vote @last:meeting @last:agenda_item --voter alice-johnson --vote for",
|
|
7570
|
+
"corp governance vote a1b2c3d4 b2c3d4e5 --voter bob-smith --vote against"
|
|
7571
|
+
]
|
|
7403
7572
|
},
|
|
7404
7573
|
// --- governance notice <meeting-ref> ---
|
|
7405
7574
|
{
|
|
@@ -7424,7 +7593,11 @@ var init_governance = __esm({
|
|
|
7424
7593
|
}
|
|
7425
7594
|
ctx.writer.success(`Notice sent for meeting ${resolvedMeetingId}`);
|
|
7426
7595
|
},
|
|
7427
|
-
|
|
7596
|
+
successTemplate: "Meeting notice sent",
|
|
7597
|
+
examples: [
|
|
7598
|
+
"corp governance notice @last:meeting",
|
|
7599
|
+
"corp governance notice a1b2c3d4"
|
|
7600
|
+
]
|
|
7428
7601
|
},
|
|
7429
7602
|
// --- governance adjourn <meeting-ref> ---
|
|
7430
7603
|
{
|
|
@@ -7449,7 +7622,11 @@ var init_governance = __esm({
|
|
|
7449
7622
|
}
|
|
7450
7623
|
ctx.writer.success(`Meeting ${resolvedMeetingId} adjourned`);
|
|
7451
7624
|
},
|
|
7452
|
-
|
|
7625
|
+
successTemplate: "Meeting adjourned",
|
|
7626
|
+
examples: [
|
|
7627
|
+
"corp governance adjourn @last:meeting",
|
|
7628
|
+
"corp governance adjourn a1b2c3d4"
|
|
7629
|
+
]
|
|
7453
7630
|
},
|
|
7454
7631
|
// --- governance reopen <meeting-ref> ---
|
|
7455
7632
|
{
|
|
@@ -7474,7 +7651,11 @@ var init_governance = __esm({
|
|
|
7474
7651
|
}
|
|
7475
7652
|
ctx.writer.success(`Meeting ${resolvedMeetingId} re-opened`);
|
|
7476
7653
|
},
|
|
7477
|
-
|
|
7654
|
+
successTemplate: "Meeting re-opened",
|
|
7655
|
+
examples: [
|
|
7656
|
+
"corp governance reopen @last:meeting",
|
|
7657
|
+
"corp governance reopen a1b2c3d4"
|
|
7658
|
+
]
|
|
7478
7659
|
},
|
|
7479
7660
|
// --- governance cancel <meeting-ref> ---
|
|
7480
7661
|
{
|
|
@@ -7512,7 +7693,11 @@ var init_governance = __esm({
|
|
|
7512
7693
|
}
|
|
7513
7694
|
ctx.writer.success(`Meeting ${resolvedMeetingId} cancelled`);
|
|
7514
7695
|
},
|
|
7515
|
-
|
|
7696
|
+
successTemplate: "Meeting cancelled",
|
|
7697
|
+
examples: [
|
|
7698
|
+
"corp governance cancel @last:meeting",
|
|
7699
|
+
"corp governance cancel a1b2c3d4 --yes"
|
|
7700
|
+
]
|
|
7516
7701
|
},
|
|
7517
7702
|
// --- governance finalize-item <meeting-ref> <item-ref> ---
|
|
7518
7703
|
{
|
|
@@ -7551,7 +7736,11 @@ var init_governance = __esm({
|
|
|
7551
7736
|
}
|
|
7552
7737
|
ctx.writer.success(`Agenda item ${resolvedItemId} finalized as ${ctx.opts.status}`);
|
|
7553
7738
|
},
|
|
7554
|
-
|
|
7739
|
+
successTemplate: "Agenda item finalized",
|
|
7740
|
+
examples: [
|
|
7741
|
+
"corp governance finalize-item @last:meeting @last:agenda_item --status voted",
|
|
7742
|
+
"corp governance finalize-item a1b2c3d4 b2c3d4e5 --status tabled"
|
|
7743
|
+
]
|
|
7555
7744
|
},
|
|
7556
7745
|
// --- governance resolve <meeting-ref> <item-ref> ---
|
|
7557
7746
|
{
|
|
@@ -7594,8 +7783,11 @@ var init_governance = __esm({
|
|
|
7594
7783
|
printReferenceSummary("resolution", result, { showReuseHint: true });
|
|
7595
7784
|
},
|
|
7596
7785
|
produces: { kind: "resolution" },
|
|
7597
|
-
successTemplate: "Resolution computed",
|
|
7598
|
-
examples: [
|
|
7786
|
+
successTemplate: "Resolution computed: {resolution_id}",
|
|
7787
|
+
examples: [
|
|
7788
|
+
'corp governance resolve @last:meeting @last:agenda_item --text "RESOLVED: The board approves the 2026 option plan."',
|
|
7789
|
+
'corp governance resolve a1b2c3d4 b2c3d4e5 --text "RESOLVED: The board authorizes issuance of Series A preferred stock."'
|
|
7790
|
+
]
|
|
7599
7791
|
},
|
|
7600
7792
|
// --- governance written-consent ---
|
|
7601
7793
|
{
|
|
@@ -7647,7 +7839,10 @@ var init_governance = __esm({
|
|
|
7647
7839
|
},
|
|
7648
7840
|
produces: { kind: "meeting" },
|
|
7649
7841
|
successTemplate: "Written consent created: {title}",
|
|
7650
|
-
examples: [
|
|
7842
|
+
examples: [
|
|
7843
|
+
'corp governance written-consent --body @last:body --title "Approve 2026 Option Plan" --description "The board approves adoption of the 2026 Equity Incentive Plan."',
|
|
7844
|
+
'corp governance written-consent --body @last:body --title "Authorize SAFE Issuance" --description "The board authorizes issuance of a SAFE to Sequoia Capital for $500,000."'
|
|
7845
|
+
]
|
|
7651
7846
|
},
|
|
7652
7847
|
// --- governance quick-approve ---
|
|
7653
7848
|
{
|
|
@@ -7762,6 +7957,10 @@ var init_governance = __esm({
|
|
|
7762
7957
|
const seatRef = ctx.positional[0];
|
|
7763
7958
|
const eid = await ctx.resolver.resolveEntity(ctx.opts.entityId);
|
|
7764
7959
|
const seatId = await ctx.resolver.resolveSeat(eid, seatRef, ctx.opts.bodyId);
|
|
7960
|
+
if (ctx.dryRun) {
|
|
7961
|
+
ctx.writer.dryRun("governance.resign_seat", { entity_id: eid, seat_id: seatId });
|
|
7962
|
+
return;
|
|
7963
|
+
}
|
|
7765
7964
|
const result = await ctx.client.resignSeat(seatId, eid);
|
|
7766
7965
|
if (ctx.opts.json) {
|
|
7767
7966
|
ctx.writer.json(result);
|
|
@@ -7769,7 +7968,11 @@ var init_governance = __esm({
|
|
|
7769
7968
|
}
|
|
7770
7969
|
ctx.writer.success(`Seat ${seatId} resigned.`);
|
|
7771
7970
|
},
|
|
7772
|
-
|
|
7971
|
+
successTemplate: "Seat resigned",
|
|
7972
|
+
examples: [
|
|
7973
|
+
"corp governance resign @last:seat",
|
|
7974
|
+
"corp governance resign a1b2c3d4"
|
|
7975
|
+
]
|
|
7773
7976
|
},
|
|
7774
7977
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
7775
7978
|
{
|
|
@@ -7820,17 +8023,20 @@ var init_governance = __esm({
|
|
|
7820
8023
|
options: [
|
|
7821
8024
|
{ flags: "--template-version <template-version>", description: "Template Version" }
|
|
7822
8025
|
],
|
|
7823
|
-
examples: [
|
|
7824
|
-
|
|
8026
|
+
examples: [
|
|
8027
|
+
"corp entities governance-doc-bundles-generate",
|
|
8028
|
+
"corp entities governance-doc-bundles-generate --template-version v2 --json"
|
|
8029
|
+
],
|
|
8030
|
+
successTemplate: "Governance document bundle generated"
|
|
7825
8031
|
},
|
|
7826
8032
|
{
|
|
7827
8033
|
name: "entities governance-doc-bundle",
|
|
7828
|
-
description: "
|
|
8034
|
+
description: "View a specific governance document bundle by ID",
|
|
7829
8035
|
route: { method: "GET", path: "/v1/entities/{eid}/governance/doc-bundles/{pos}" },
|
|
7830
8036
|
entity: true,
|
|
7831
8037
|
args: [{ name: "bundle-id", required: true, description: "Document bundle ID" }],
|
|
7832
8038
|
display: { title: "Entities Governance Doc Bundles", cols: ["documents>Documents", "entity_type>Entity Type", "generated_at>Generated At", "profile_version>Profile Version", "#bundle_id>ID"] },
|
|
7833
|
-
examples: ["corp entities governance-doc-
|
|
8039
|
+
examples: ["corp entities governance-doc-bundle a1b2c3d4", "corp entities governance-doc-bundle a1b2c3d4 --json"]
|
|
7834
8040
|
},
|
|
7835
8041
|
{
|
|
7836
8042
|
name: "entities governance-mode-history",
|
|
@@ -7866,7 +8072,10 @@ var init_governance = __esm({
|
|
|
7866
8072
|
{ flags: "--quorum-rule <quorum-rule>", description: "The threshold required for a vote to pass.", required: true, choices: ["majority", "supermajority", "unanimous"] },
|
|
7867
8073
|
{ flags: "--voting-method <voting-method>", description: "How votes are counted.", required: true, choices: ["per_capita", "per_unit"] }
|
|
7868
8074
|
],
|
|
7869
|
-
examples: [
|
|
8075
|
+
examples: [
|
|
8076
|
+
'corp governance-bodies create --name "Board of Directors" --body-type board_of_directors --quorum-rule majority --voting-method per_capita',
|
|
8077
|
+
'corp governance-bodies create --name "LLC Member Vote" --body-type llc_member_vote --quorum-rule unanimous --voting-method per_unit'
|
|
8078
|
+
],
|
|
7870
8079
|
successTemplate: "Governance body created"
|
|
7871
8080
|
},
|
|
7872
8081
|
{
|
|
@@ -7874,8 +8083,10 @@ var init_governance = __esm({
|
|
|
7874
8083
|
description: "Scan for and flag expired governance seats",
|
|
7875
8084
|
route: { method: "POST", path: "/v1/governance-seats/scan-expired" },
|
|
7876
8085
|
entity: true,
|
|
7877
|
-
examples: [
|
|
7878
|
-
|
|
8086
|
+
examples: [
|
|
8087
|
+
"corp governance-seats scan-expired"
|
|
8088
|
+
],
|
|
8089
|
+
successTemplate: "Expired seats scanned and flagged"
|
|
7879
8090
|
},
|
|
7880
8091
|
{
|
|
7881
8092
|
name: "governance-seats resign",
|
|
@@ -7883,7 +8094,9 @@ var init_governance = __esm({
|
|
|
7883
8094
|
route: { method: "POST", path: "/v1/governance-seats/{pos}/resign" },
|
|
7884
8095
|
entity: true,
|
|
7885
8096
|
args: [{ name: "seat-id", required: true, description: "Governance seat ID" }],
|
|
7886
|
-
examples: [
|
|
8097
|
+
examples: [
|
|
8098
|
+
"corp governance-seats resign a1b2c3d4"
|
|
8099
|
+
],
|
|
7887
8100
|
successTemplate: "Seat resigned"
|
|
7888
8101
|
},
|
|
7889
8102
|
{
|
|
@@ -7892,7 +8105,7 @@ var init_governance = __esm({
|
|
|
7892
8105
|
route: { method: "POST", path: "/v1/governance/audit/checkpoints" },
|
|
7893
8106
|
entity: true,
|
|
7894
8107
|
examples: ["corp governance audit-checkpoints"],
|
|
7895
|
-
successTemplate: "Audit
|
|
8108
|
+
successTemplate: "Audit checkpoint created"
|
|
7896
8109
|
},
|
|
7897
8110
|
{
|
|
7898
8111
|
name: "governance audit-events",
|
|
@@ -7909,8 +8122,11 @@ var init_governance = __esm({
|
|
|
7909
8122
|
{ flags: "--linked-mode-event-id <linked-mode-event-id>", description: "Linked Mode Event Id" },
|
|
7910
8123
|
{ flags: "--linked-trigger-id <linked-trigger-id>", description: "Linked Trigger Id" }
|
|
7911
8124
|
],
|
|
7912
|
-
examples: [
|
|
7913
|
-
|
|
8125
|
+
examples: [
|
|
8126
|
+
'corp governance audit-events --action "Mode changed to board" --event-type mode_changed',
|
|
8127
|
+
'corp governance audit-events --action "Manual review completed" --event-type manual_event --details "Reviewed by legal team"'
|
|
8128
|
+
],
|
|
8129
|
+
successTemplate: "Audit event recorded"
|
|
7914
8130
|
},
|
|
7915
8131
|
{
|
|
7916
8132
|
name: "governance audit-verify",
|
|
@@ -7918,7 +8134,7 @@ var init_governance = __esm({
|
|
|
7918
8134
|
route: { method: "POST", path: "/v1/governance/audit/verify" },
|
|
7919
8135
|
entity: true,
|
|
7920
8136
|
examples: ["corp governance audit-verify"],
|
|
7921
|
-
successTemplate: "
|
|
8137
|
+
successTemplate: "Governance audit verified"
|
|
7922
8138
|
},
|
|
7923
8139
|
{
|
|
7924
8140
|
name: "governance delegation-schedule",
|
|
@@ -7941,8 +8157,11 @@ var init_governance = __esm({
|
|
|
7941
8157
|
{ flags: "--rationale <rationale>", description: "Rationale" },
|
|
7942
8158
|
{ flags: "--tier1-max-amount-cents <tier1-max-amount-cents>", description: "Tier1 Max Amount Cents" }
|
|
7943
8159
|
],
|
|
7944
|
-
examples: [
|
|
7945
|
-
|
|
8160
|
+
examples: [
|
|
8161
|
+
'corp governance delegation-schedule-amend --rationale "Expanding Tier 1 authority for routine operations"',
|
|
8162
|
+
"corp governance delegation-schedule-amend --meeting-id @last:meeting --adopted-resolution-id @last:resolution --tier1-max-amount-cents 500000"
|
|
8163
|
+
],
|
|
8164
|
+
successTemplate: "Delegation schedule amended"
|
|
7946
8165
|
},
|
|
7947
8166
|
{
|
|
7948
8167
|
name: "governance delegation-schedule-history",
|
|
@@ -7962,8 +8181,11 @@ var init_governance = __esm({
|
|
|
7962
8181
|
{ flags: "--meeting-id <meeting-id>", description: "Meeting ID", required: true },
|
|
7963
8182
|
{ flags: "--rationale <rationale>", description: "Rationale" }
|
|
7964
8183
|
],
|
|
7965
|
-
examples: [
|
|
7966
|
-
|
|
8184
|
+
examples: [
|
|
8185
|
+
"corp governance delegation-schedule-reauthorize --adopted-resolution-id @last:resolution --meeting-id @last:meeting",
|
|
8186
|
+
'corp governance delegation-schedule-reauthorize --adopted-resolution-id a1b2c3d4 --meeting-id b2c3d4e5 --rationale "Annual reauthorization of delegation schedule"'
|
|
8187
|
+
],
|
|
8188
|
+
successTemplate: "Delegation schedule reauthorized"
|
|
7967
8189
|
},
|
|
7968
8190
|
{
|
|
7969
8191
|
name: "governance evaluate",
|
|
@@ -7974,8 +8196,11 @@ var init_governance = __esm({
|
|
|
7974
8196
|
{ flags: "--intent-type <intent-type>", description: "Type of intent", required: true },
|
|
7975
8197
|
{ flags: "--metadata <metadata>", description: "Additional metadata (JSON)" }
|
|
7976
8198
|
],
|
|
7977
|
-
examples: [
|
|
7978
|
-
|
|
8199
|
+
examples: [
|
|
8200
|
+
"corp governance evaluate --intent-type equity.issuance.execute",
|
|
8201
|
+
`corp governance evaluate --intent-type equity.transfer.prepare --metadata '{"amount_cents": 50000000}'`
|
|
8202
|
+
],
|
|
8203
|
+
successTemplate: "Governance evaluation complete"
|
|
7979
8204
|
},
|
|
7980
8205
|
{
|
|
7981
8206
|
name: "governance report-incident",
|
|
@@ -7987,8 +8212,11 @@ var init_governance = __esm({
|
|
|
7987
8212
|
{ flags: "--severity <severity>", description: "Severity level", required: true, choices: ["low", "medium", "high", "critical"] },
|
|
7988
8213
|
{ flags: "--title <title>", description: "Title", required: true }
|
|
7989
8214
|
],
|
|
7990
|
-
examples: [
|
|
7991
|
-
|
|
8215
|
+
examples: [
|
|
8216
|
+
'corp governance report-incident --title "Unauthorized access attempt" --description "Board portal accessed from unknown IP" --severity medium',
|
|
8217
|
+
'corp governance report-incident --title "Quorum breach" --description "Meeting held without required quorum" --severity high'
|
|
8218
|
+
],
|
|
8219
|
+
successTemplate: "Incident reported"
|
|
7992
8220
|
},
|
|
7993
8221
|
{
|
|
7994
8222
|
name: "governance incidents-resolve",
|
|
@@ -7996,8 +8224,10 @@ var init_governance = __esm({
|
|
|
7996
8224
|
route: { method: "POST", path: "/v1/governance/incidents/{pos}/resolve" },
|
|
7997
8225
|
entity: true,
|
|
7998
8226
|
args: [{ name: "incident-id", required: true, description: "Incident ID" }],
|
|
7999
|
-
examples: [
|
|
8000
|
-
|
|
8227
|
+
examples: [
|
|
8228
|
+
"corp governance incidents-resolve a1b2c3d4"
|
|
8229
|
+
],
|
|
8230
|
+
successTemplate: "Incident resolved"
|
|
8001
8231
|
},
|
|
8002
8232
|
{
|
|
8003
8233
|
name: "meetings written-consent",
|
|
@@ -8008,8 +8238,11 @@ var init_governance = __esm({
|
|
|
8008
8238
|
{ flags: "--description <description>", description: "Description text", required: true },
|
|
8009
8239
|
{ flags: "--title <title>", description: "Title", required: true }
|
|
8010
8240
|
],
|
|
8011
|
-
examples: [
|
|
8012
|
-
|
|
8241
|
+
examples: [
|
|
8242
|
+
'corp meetings written-consent --body-id a1b2c3d4 --title "Approve Budget" --description "The board approves the 2026 operating budget."',
|
|
8243
|
+
'corp meetings written-consent --body-id a1b2c3d4 --title "Authorize Officer" --description "The board authorizes Alice Smith as CFO."'
|
|
8244
|
+
],
|
|
8245
|
+
successTemplate: "Written consent created"
|
|
8013
8246
|
},
|
|
8014
8247
|
{
|
|
8015
8248
|
name: "meetings agenda-items-vote",
|
|
@@ -8021,8 +8254,11 @@ var init_governance = __esm({
|
|
|
8021
8254
|
{ flags: "--vote-value <vote-value>", description: "How a participant voted.", required: true, choices: ["for", "against", "abstain", "recusal"] },
|
|
8022
8255
|
{ flags: "--voter-id <voter-id>", description: "Voter Id", required: true }
|
|
8023
8256
|
],
|
|
8024
|
-
examples: [
|
|
8025
|
-
|
|
8257
|
+
examples: [
|
|
8258
|
+
"corp meetings agenda-items-vote a1b2c3d4 b2c3d4e5 --vote-value for --voter-id c3d4e5f6",
|
|
8259
|
+
"corp meetings agenda-items-vote a1b2c3d4 b2c3d4e5 --vote-value abstain --voter-id c3d4e5f6"
|
|
8260
|
+
],
|
|
8261
|
+
successTemplate: "Vote recorded"
|
|
8026
8262
|
},
|
|
8027
8263
|
{
|
|
8028
8264
|
name: "meetings convene",
|
|
@@ -8033,8 +8269,10 @@ var init_governance = __esm({
|
|
|
8033
8269
|
options: [
|
|
8034
8270
|
{ flags: "--present-seat-ids <present-seat-ids>", description: "Present Seat Ids", required: true, type: "array" }
|
|
8035
8271
|
],
|
|
8036
|
-
examples: [
|
|
8037
|
-
|
|
8272
|
+
examples: [
|
|
8273
|
+
"corp meetings convene a1b2c3d4 --present-seat-ids seat-alice seat-bob"
|
|
8274
|
+
],
|
|
8275
|
+
successTemplate: "Meeting convened"
|
|
8038
8276
|
},
|
|
8039
8277
|
{
|
|
8040
8278
|
name: "meetings resolutions-attach-document",
|
|
@@ -8044,8 +8282,10 @@ var init_governance = __esm({
|
|
|
8044
8282
|
options: [
|
|
8045
8283
|
{ flags: "--document-id <document-id>", description: "Document ID", required: true }
|
|
8046
8284
|
],
|
|
8047
|
-
examples: [
|
|
8048
|
-
|
|
8285
|
+
examples: [
|
|
8286
|
+
"corp meetings resolutions-attach-document a1b2c3d4 b2c3d4e5 --document-id c3d4e5f6"
|
|
8287
|
+
],
|
|
8288
|
+
successTemplate: "Document attached to resolution"
|
|
8049
8289
|
}
|
|
8050
8290
|
];
|
|
8051
8291
|
}
|
|
@@ -8141,7 +8381,7 @@ var init_documents = __esm({
|
|
|
8141
8381
|
}
|
|
8142
8382
|
console.log(shareUrl);
|
|
8143
8383
|
},
|
|
8144
|
-
examples: ["corp documents signing-link", "corp documents signing-link
|
|
8384
|
+
examples: ["corp documents signing-link @last", "corp documents signing-link doc-abc123"]
|
|
8145
8385
|
},
|
|
8146
8386
|
// --- documents sign <doc-ref> ---
|
|
8147
8387
|
{
|
|
@@ -8195,7 +8435,10 @@ var init_documents = __esm({
|
|
|
8195
8435
|
printReferenceSummary("document", result.document, { showReuseHint: true });
|
|
8196
8436
|
printJson(result.document);
|
|
8197
8437
|
},
|
|
8198
|
-
examples: [
|
|
8438
|
+
examples: [
|
|
8439
|
+
"corp documents sign @last",
|
|
8440
|
+
'corp documents sign doc-abc123 --signer-name "Alice Smith" --signer-role CEO --signer-email alice@acme.com'
|
|
8441
|
+
]
|
|
8199
8442
|
},
|
|
8200
8443
|
// --- documents sign-all ---
|
|
8201
8444
|
{
|
|
@@ -8220,7 +8463,7 @@ var init_documents = __esm({
|
|
|
8220
8463
|
signatures: Array.isArray(document.signatures) ? document.signatures.length : document.signatures
|
|
8221
8464
|
})));
|
|
8222
8465
|
},
|
|
8223
|
-
examples: ["corp documents sign-all"]
|
|
8466
|
+
examples: ["corp documents sign-all", "corp documents sign-all --json"]
|
|
8224
8467
|
},
|
|
8225
8468
|
// --- documents generate ---
|
|
8226
8469
|
{
|
|
@@ -8229,7 +8472,7 @@ var init_documents = __esm({
|
|
|
8229
8472
|
route: { method: "POST", path: "/v1/contracts/generate" },
|
|
8230
8473
|
entity: true,
|
|
8231
8474
|
options: [
|
|
8232
|
-
{ flags: "--template <type>", description: "
|
|
8475
|
+
{ flags: "--template <type>", description: "Contract template type", required: true, choices: ["consulting_agreement", "employment_offer", "contractor_agreement", "nda", "safe_agreement", "custom"] },
|
|
8233
8476
|
{ flags: "--counterparty <name>", description: "Counterparty name", required: true },
|
|
8234
8477
|
{ flags: "--effective-date <date>", description: "Effective date (ISO 8601, defaults to today)" },
|
|
8235
8478
|
{ flags: "--base-salary <amount>", description: "Employment offer base salary (for employment_offer)" },
|
|
@@ -8298,8 +8541,13 @@ var init_documents = __esm({
|
|
|
8298
8541
|
}
|
|
8299
8542
|
},
|
|
8300
8543
|
produces: { kind: "document" },
|
|
8301
|
-
successTemplate: "
|
|
8302
|
-
examples: [
|
|
8544
|
+
successTemplate: "Contract generated: {document_id} \u2014 {title}",
|
|
8545
|
+
examples: [
|
|
8546
|
+
'corp documents generate --template consulting_agreement --counterparty "Acme Consulting LLC"',
|
|
8547
|
+
'corp documents generate --template employment_offer --counterparty "Jane Doe" --base-salary 150000',
|
|
8548
|
+
'corp documents generate --template nda --counterparty "Partner Corp" --effective-date 2026-04-01',
|
|
8549
|
+
'corp documents generate --template safe_agreement --counterparty "Seed Investor" --param purchase_amount=500000 --param valuation_cap=10000000'
|
|
8550
|
+
]
|
|
8303
8551
|
},
|
|
8304
8552
|
// --- documents preview-pdf ---
|
|
8305
8553
|
{
|
|
@@ -8322,7 +8570,10 @@ var init_documents = __esm({
|
|
|
8322
8570
|
ctx.writer.success(`Preview PDF URL: ${url}`);
|
|
8323
8571
|
console.log("The document definition was validated successfully. Use your API key to download the PDF.");
|
|
8324
8572
|
},
|
|
8325
|
-
examples: [
|
|
8573
|
+
examples: [
|
|
8574
|
+
"corp documents preview-pdf --definition-id bylaws",
|
|
8575
|
+
"corp documents preview-pdf --definition-id articles_of_incorporation"
|
|
8576
|
+
]
|
|
8326
8577
|
}
|
|
8327
8578
|
];
|
|
8328
8579
|
}
|
|
@@ -8455,7 +8706,10 @@ var init_compliance = __esm({
|
|
|
8455
8706
|
},
|
|
8456
8707
|
produces: { kind: "tax_filing" },
|
|
8457
8708
|
successTemplate: "Tax filing created",
|
|
8458
|
-
examples: [
|
|
8709
|
+
examples: [
|
|
8710
|
+
"corp tax file --type 1120 --year 2025",
|
|
8711
|
+
"corp tax file --type 83b --year 2025 --filer-contact-id @last:contact"
|
|
8712
|
+
]
|
|
8459
8713
|
},
|
|
8460
8714
|
// --- tax deadlines ---
|
|
8461
8715
|
{
|
|
@@ -8519,48 +8773,60 @@ var init_compliance = __esm({
|
|
|
8519
8773
|
},
|
|
8520
8774
|
produces: { kind: "deadline" },
|
|
8521
8775
|
successTemplate: "Deadline tracked",
|
|
8522
|
-
examples: [
|
|
8776
|
+
examples: [
|
|
8777
|
+
'corp tax deadline --type annual_report --due-date 2026-03-31 --description "Delaware annual report due"',
|
|
8778
|
+
'corp tax deadline --type annual_report --due-date 2026-03-31 --description "Delaware annual report" --recurrence annual'
|
|
8779
|
+
]
|
|
8523
8780
|
},
|
|
8524
8781
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
8525
8782
|
{
|
|
8526
8783
|
name: "compliance escalations-scan",
|
|
8527
8784
|
description: "Scan for compliance issues and create escalations",
|
|
8528
8785
|
route: { method: "POST", path: "/v1/compliance/escalations/scan" },
|
|
8529
|
-
examples: [
|
|
8786
|
+
examples: [
|
|
8787
|
+
"corp compliance escalations-scan",
|
|
8788
|
+
"corp compliance escalations-scan --json"
|
|
8789
|
+
],
|
|
8530
8790
|
successTemplate: "Escalation scan complete"
|
|
8531
8791
|
},
|
|
8532
8792
|
{
|
|
8533
8793
|
name: "compliance escalations-resolve-with-evidence",
|
|
8534
|
-
description: "Resolve a compliance escalation
|
|
8794
|
+
description: "Resolve a compliance escalation by submitting supporting evidence",
|
|
8535
8795
|
route: { method: "POST", path: "/v1/compliance/escalations/{pos}/resolve-with-evidence" },
|
|
8536
8796
|
args: [{ name: "escalation-id", required: true, description: "Escalation ID" }],
|
|
8537
8797
|
options: [
|
|
8538
|
-
{ flags: "--evidence-type <evidence-type>", description: "
|
|
8539
|
-
{ flags: "--filing-reference <filing-reference>", description: "
|
|
8540
|
-
{ flags: "--notes <notes>", description: "Additional notes" },
|
|
8541
|
-
{ flags: "--packet-id <packet-id>", description: "Document packet ID" },
|
|
8542
|
-
{ flags: "--resolve-incident", description: "
|
|
8543
|
-
{ flags: "--resolve-obligation", description: "
|
|
8798
|
+
{ flags: "--evidence-type <evidence-type>", description: "Type of evidence provided", choices: ["filing", "payment", "document", "correspondence", "other"] },
|
|
8799
|
+
{ flags: "--filing-reference <filing-reference>", description: "Reference number or identifier of the associated filing" },
|
|
8800
|
+
{ flags: "--notes <notes>", description: "Additional notes about the resolution" },
|
|
8801
|
+
{ flags: "--packet-id <packet-id>", description: "Document packet ID containing evidence" },
|
|
8802
|
+
{ flags: "--resolve-incident", description: "Also mark the associated incident as resolved" },
|
|
8803
|
+
{ flags: "--resolve-obligation", description: "Also mark the associated obligation as resolved" }
|
|
8804
|
+
],
|
|
8805
|
+
examples: [
|
|
8806
|
+
"corp compliance escalations-resolve-with-evidence esc_01hx9k3n2p4q7r8s9t0uvwxyz --evidence-type filing --filing-reference DE-2026-0042",
|
|
8807
|
+
'corp compliance escalations-resolve-with-evidence esc_01hx9k3n2p4q7r8s9t0uvwxyz --resolve-incident --notes "Filed on time"'
|
|
8544
8808
|
],
|
|
8545
|
-
|
|
8546
|
-
successTemplate: "Escalations Resolve With Evidence created"
|
|
8809
|
+
successTemplate: "Escalation resolved with evidence"
|
|
8547
8810
|
},
|
|
8548
8811
|
{
|
|
8549
8812
|
name: "contractors classify",
|
|
8550
|
-
description: "Classify a worker as employee or contractor",
|
|
8813
|
+
description: "Classify a worker as an employee or independent contractor",
|
|
8551
8814
|
route: { method: "POST", path: "/v1/contractors/classify" },
|
|
8552
8815
|
entity: true,
|
|
8553
8816
|
options: [
|
|
8554
|
-
{ flags: "--contractor-name <contractor-name>", description: "
|
|
8555
|
-
{ flags: "--duration-months <duration-months>", description: "
|
|
8556
|
-
{ flags: "--exclusive-client <exclusive-client>", description: "
|
|
8557
|
-
{ flags: "--factors <factors>", description: "
|
|
8558
|
-
{ flags: "--hours-per-week <hours-per-week>", description: "
|
|
8559
|
-
{ flags: "--provides-tools <provides-tools>", description: "
|
|
8560
|
-
{ flags: "--state <state>", description: "State" }
|
|
8817
|
+
{ flags: "--contractor-name <contractor-name>", description: "Full name or company name of the worker", required: true },
|
|
8818
|
+
{ flags: "--duration-months <duration-months>", description: "Expected or actual engagement duration in months" },
|
|
8819
|
+
{ flags: "--exclusive-client <exclusive-client>", description: "Whether the worker works exclusively for this entity (true/false)" },
|
|
8820
|
+
{ flags: "--factors <factors>", description: "Additional classification factors (JSON)" },
|
|
8821
|
+
{ flags: "--hours-per-week <hours-per-week>", description: "Average hours worked per week" },
|
|
8822
|
+
{ flags: "--provides-tools <provides-tools>", description: "Whether the worker provides their own tools and equipment (true/false)" },
|
|
8823
|
+
{ flags: "--state <state>", description: "State whose labor law governs the classification (e.g. CA, DE)" }
|
|
8824
|
+
],
|
|
8825
|
+
examples: [
|
|
8826
|
+
'corp contractors classify --contractor-name "Jane Doe" --state CA --hours-per-week 20',
|
|
8827
|
+
'corp contractors classify --contractor-name "Acme Services LLC" --duration-months 6 --exclusive-client false --provides-tools true'
|
|
8561
8828
|
],
|
|
8562
|
-
|
|
8563
|
-
successTemplate: "Classify created"
|
|
8829
|
+
successTemplate: "Worker classification complete"
|
|
8564
8830
|
},
|
|
8565
8831
|
{
|
|
8566
8832
|
name: "deadlines",
|
|
@@ -8573,8 +8839,11 @@ var init_compliance = __esm({
|
|
|
8573
8839
|
{ flags: "--recurrence <recurrence>", description: "Recurrence pattern for a deadline.", choices: ["one_time", "monthly", "quarterly", "annual"] },
|
|
8574
8840
|
{ flags: "--severity <severity>", description: "Risk severity of missing a deadline.", choices: ["low", "medium", "high", "critical"] }
|
|
8575
8841
|
],
|
|
8576
|
-
examples: [
|
|
8577
|
-
|
|
8842
|
+
examples: [
|
|
8843
|
+
'corp deadlines --deadline-type annual_report --description "Delaware annual report" --due-date 2026-03-31 --recurrence annual',
|
|
8844
|
+
'corp deadlines --deadline-type tax_filing --description "Q1 estimated taxes" --due-date 2026-04-15 --severity high'
|
|
8845
|
+
],
|
|
8846
|
+
successTemplate: "Deadline tracked"
|
|
8578
8847
|
},
|
|
8579
8848
|
{
|
|
8580
8849
|
name: "entities compliance-escalations",
|
|
@@ -8590,11 +8859,14 @@ var init_compliance = __esm({
|
|
|
8590
8859
|
route: { method: "POST", path: "/v1/tax/filings" },
|
|
8591
8860
|
entity: true,
|
|
8592
8861
|
options: [
|
|
8593
|
-
{ flags: "--document-type <document-type>", description: "Type of document
|
|
8594
|
-
{ flags: "--tax-year <tax-year>", description: "Tax
|
|
8862
|
+
{ flags: "--document-type <document-type>", description: "Type of tax document to file", required: true, choices: ["1120", "1120s", "1065", "franchise_tax", "annual_report", "83b", "1099_nec", "k1", "941", "w2"] },
|
|
8863
|
+
{ flags: "--tax-year <tax-year>", description: "Tax year the filing covers (e.g. 2025)", required: true, type: "int" }
|
|
8864
|
+
],
|
|
8865
|
+
examples: [
|
|
8866
|
+
"corp tax create-filing --document-type 1120 --tax-year 2025",
|
|
8867
|
+
"corp tax create-filing --document-type 1065 --tax-year 2025"
|
|
8595
8868
|
],
|
|
8596
|
-
|
|
8597
|
-
successTemplate: "Filings created"
|
|
8869
|
+
successTemplate: "Tax filing created"
|
|
8598
8870
|
}
|
|
8599
8871
|
];
|
|
8600
8872
|
}
|
|
@@ -8697,7 +8969,10 @@ var init_agents = __esm({
|
|
|
8697
8969
|
}
|
|
8698
8970
|
console.log(chalk9.magenta("\u2500".repeat(40)));
|
|
8699
8971
|
},
|
|
8700
|
-
examples: [
|
|
8972
|
+
examples: [
|
|
8973
|
+
"corp agents show @last:agent",
|
|
8974
|
+
"corp agents show agt_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
8975
|
+
]
|
|
8701
8976
|
},
|
|
8702
8977
|
// --- agents create ---
|
|
8703
8978
|
{
|
|
@@ -8738,7 +9013,10 @@ var init_agents = __esm({
|
|
|
8738
9013
|
},
|
|
8739
9014
|
produces: { kind: "agent" },
|
|
8740
9015
|
successTemplate: "Agent created: {name}",
|
|
8741
|
-
examples: [
|
|
9016
|
+
examples: [
|
|
9017
|
+
'corp agents create --name "bookkeeper" --prompt "You manage accounts payable for the company"',
|
|
9018
|
+
'corp agents create --name "compliance-monitor" --prompt "You monitor regulatory deadlines" --model gpt-4o'
|
|
9019
|
+
]
|
|
8742
9020
|
},
|
|
8743
9021
|
// --- agents pause <agent-ref> ---
|
|
8744
9022
|
{
|
|
@@ -8752,7 +9030,10 @@ var init_agents = __esm({
|
|
|
8752
9030
|
const result = await ctx.client.updateAgent(resolvedAgentId, { status: "paused" });
|
|
8753
9031
|
ctx.writer.writeResult(result, `Agent ${resolvedAgentId} paused.`, { jsonOnly: ctx.opts.json });
|
|
8754
9032
|
},
|
|
8755
|
-
examples: [
|
|
9033
|
+
examples: [
|
|
9034
|
+
"corp agents pause @last:agent",
|
|
9035
|
+
"corp agents pause agt_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
9036
|
+
]
|
|
8756
9037
|
},
|
|
8757
9038
|
// --- agents resume <agent-ref> ---
|
|
8758
9039
|
{
|
|
@@ -8779,7 +9060,10 @@ var init_agents = __esm({
|
|
|
8779
9060
|
}
|
|
8780
9061
|
}
|
|
8781
9062
|
},
|
|
8782
|
-
examples: [
|
|
9063
|
+
examples: [
|
|
9064
|
+
"corp agents resume @last:agent",
|
|
9065
|
+
"corp agents resume agt_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
9066
|
+
]
|
|
8783
9067
|
},
|
|
8784
9068
|
// --- agents delete <agent-ref> ---
|
|
8785
9069
|
{
|
|
@@ -8806,7 +9090,10 @@ var init_agents = __esm({
|
|
|
8806
9090
|
const result = await ctx.client.deleteAgent(resolvedAgentId);
|
|
8807
9091
|
ctx.writer.writeResult(result, `Agent ${resolvedAgentId} deleted.`, { jsonOnly: ctx.opts.json });
|
|
8808
9092
|
},
|
|
8809
|
-
examples: [
|
|
9093
|
+
examples: [
|
|
9094
|
+
"corp agents delete @last:agent",
|
|
9095
|
+
"corp agents delete agt_01hx9k3n2p4q7r8s9t0uvwxyz --yes"
|
|
9096
|
+
]
|
|
8810
9097
|
},
|
|
8811
9098
|
// --- agents message <agent-ref> ---
|
|
8812
9099
|
{
|
|
@@ -8837,7 +9124,10 @@ var init_agents = __esm({
|
|
|
8837
9124
|
}
|
|
8838
9125
|
}
|
|
8839
9126
|
},
|
|
8840
|
-
examples: [
|
|
9127
|
+
examples: [
|
|
9128
|
+
`corp agents message @last:agent --body "Process this month's invoices"`,
|
|
9129
|
+
"corp agents message agt_01hx9k3n2p4q7r8s9t0uvwxyz --body-file ./task.txt"
|
|
9130
|
+
]
|
|
8841
9131
|
},
|
|
8842
9132
|
// --- agents skill <agent-ref> ---
|
|
8843
9133
|
{
|
|
@@ -8866,7 +9156,10 @@ var init_agents = __esm({
|
|
|
8866
9156
|
});
|
|
8867
9157
|
ctx.writer.writeResult(result, `Skill '${ctx.opts.name}' added to agent ${resolvedAgentId}.`, { jsonOnly: ctx.opts.json });
|
|
8868
9158
|
},
|
|
8869
|
-
examples: [
|
|
9159
|
+
examples: [
|
|
9160
|
+
'corp agents skill @last:agent --name invoice-processing --description "Process AP invoices from email"',
|
|
9161
|
+
'corp agents skill agt_01hx9k3n2p4q7r8s9t0uvwxyz --name bookkeeping --description "Reconcile ledger entries" --instructions-file ./skills/bookkeeping.txt'
|
|
9162
|
+
]
|
|
8870
9163
|
},
|
|
8871
9164
|
// --- agents execution <agent-ref> <execution-id> ---
|
|
8872
9165
|
{
|
|
@@ -8897,7 +9190,10 @@ var init_agents = __esm({
|
|
|
8897
9190
|
if (result.completed_at) console.log(` ${chalk9.bold("Completed:")} ${result.completed_at}`);
|
|
8898
9191
|
console.log(chalk9.magenta("\u2500".repeat(40)));
|
|
8899
9192
|
},
|
|
8900
|
-
examples: [
|
|
9193
|
+
examples: [
|
|
9194
|
+
"corp agents execution @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9195
|
+
"corp agents execution agt_01hx9k3n2p4q7r8s9t0uvwxyz exc_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
9196
|
+
]
|
|
8901
9197
|
},
|
|
8902
9198
|
// --- agents execution-result <agent-ref> <execution-id> ---
|
|
8903
9199
|
{
|
|
@@ -8921,7 +9217,10 @@ var init_agents = __esm({
|
|
|
8921
9217
|
ctx.writer.success(`Result for execution ${executionId}:`);
|
|
8922
9218
|
printJson(result);
|
|
8923
9219
|
},
|
|
8924
|
-
examples: [
|
|
9220
|
+
examples: [
|
|
9221
|
+
"corp agents execution-result @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9222
|
+
"corp agents execution-result @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
9223
|
+
]
|
|
8925
9224
|
},
|
|
8926
9225
|
// --- agents kill <agent-ref> <execution-id> ---
|
|
8927
9226
|
{
|
|
@@ -8949,7 +9248,10 @@ var init_agents = __esm({
|
|
|
8949
9248
|
const result = await ctx.client.killAgentExecution(resolvedAgentId, executionId);
|
|
8950
9249
|
ctx.writer.writeResult(result, `Execution ${executionId} killed.`, { jsonOnly: ctx.opts.json });
|
|
8951
9250
|
},
|
|
8952
|
-
examples: [
|
|
9251
|
+
examples: [
|
|
9252
|
+
"corp agents kill @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9253
|
+
"corp agents kill @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz --yes"
|
|
9254
|
+
]
|
|
8953
9255
|
},
|
|
8954
9256
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
8955
9257
|
{
|
|
@@ -8958,7 +9260,10 @@ var init_agents = __esm({
|
|
|
8958
9260
|
route: { method: "GET", path: "/v1/agents/{pos}/executions/{pos2}/logs" },
|
|
8959
9261
|
args: [{ name: "agent-id", required: true, description: "Agent ID", posKind: "agent" }, { name: "execution-id", required: true, description: "Agent execution ID" }],
|
|
8960
9262
|
display: { title: "Execution Logs", cols: ["@timestamp>Time", "level>Level", "message>Message"] },
|
|
8961
|
-
examples: [
|
|
9263
|
+
examples: [
|
|
9264
|
+
"corp agents executions-logs @last:agent exc_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9265
|
+
"corp agents executions-logs agt_01hx9k3n2p4q7r8s9t0uvwxyz exc_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
9266
|
+
]
|
|
8962
9267
|
},
|
|
8963
9268
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
8964
9269
|
{
|
|
@@ -8967,7 +9272,10 @@ var init_agents = __esm({
|
|
|
8967
9272
|
route: { method: "GET", path: "/v1/agents/{pos}/messages/{pos2}" },
|
|
8968
9273
|
args: [{ name: "agent-id", required: true, description: "Agent ID", posKind: "agent" }, { name: "message-id", required: true, description: "Message Id" }],
|
|
8969
9274
|
display: { title: "Agent Message" },
|
|
8970
|
-
examples: [
|
|
9275
|
+
examples: [
|
|
9276
|
+
"corp agents messages @last:agent msg_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9277
|
+
"corp agents messages @last:agent msg_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
9278
|
+
]
|
|
8971
9279
|
}
|
|
8972
9280
|
];
|
|
8973
9281
|
}
|
|
@@ -9074,7 +9382,10 @@ var init_work_items = __esm({
|
|
|
9074
9382
|
console.log(` ${chalk10.bold("Created at:")} ${w.created_at ?? "N/A"}`);
|
|
9075
9383
|
console.log(chalk10.cyan("\u2500".repeat(40)));
|
|
9076
9384
|
},
|
|
9077
|
-
examples: [
|
|
9385
|
+
examples: [
|
|
9386
|
+
"corp work-items show wi_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9387
|
+
"corp work-items show @last:work_item --json"
|
|
9388
|
+
]
|
|
9078
9389
|
},
|
|
9079
9390
|
// --- work-items create ---
|
|
9080
9391
|
{
|
|
@@ -9112,7 +9423,10 @@ var init_work_items = __esm({
|
|
|
9112
9423
|
},
|
|
9113
9424
|
produces: { kind: "work_item" },
|
|
9114
9425
|
successTemplate: "Work item created: {title}",
|
|
9115
|
-
examples: [
|
|
9426
|
+
examples: [
|
|
9427
|
+
'corp work-items create --title "File Q1 taxes" --category compliance --deadline 2026-04-15',
|
|
9428
|
+
'corp work-items create --title "Renew Delaware registered agent" --category legal --asap'
|
|
9429
|
+
]
|
|
9116
9430
|
},
|
|
9117
9431
|
// --- work-items claim <item-ref> ---
|
|
9118
9432
|
{
|
|
@@ -9141,7 +9455,10 @@ var init_work_items = __esm({
|
|
|
9141
9455
|
const result = await ctx.client.claimWorkItem(eid, resolvedWorkItemId, data);
|
|
9142
9456
|
ctx.writer.writeResult(result, `Work item ${resolvedWorkItemId} claimed by ${claimedBy}.`, { jsonOnly: ctx.opts.json });
|
|
9143
9457
|
},
|
|
9144
|
-
examples: [
|
|
9458
|
+
examples: [
|
|
9459
|
+
"corp work-items claim wi_01hx9k3n2p4q7r8s9t0uvwxyz --by bookkeeper-agent",
|
|
9460
|
+
"corp work-items claim @last:work_item --by ops-agent --ttl 3600"
|
|
9461
|
+
]
|
|
9145
9462
|
},
|
|
9146
9463
|
// --- work-items complete <item-ref> ---
|
|
9147
9464
|
{
|
|
@@ -9172,7 +9489,10 @@ var init_work_items = __esm({
|
|
|
9172
9489
|
const result = await ctx.client.completeWorkItem(eid, resolvedWorkItemId, data);
|
|
9173
9490
|
ctx.writer.writeResult(result, `Work item ${resolvedWorkItemId} completed.`, { jsonOnly: ctx.opts.json });
|
|
9174
9491
|
},
|
|
9175
|
-
examples: [
|
|
9492
|
+
examples: [
|
|
9493
|
+
'corp work-items complete wi_01hx9k3n2p4q7r8s9t0uvwxyz --by bookkeeper-agent --result "Filed 1120 for Q1 2025"',
|
|
9494
|
+
'corp work-items complete @last:work_item --by ops-agent --result "Completed and verified"'
|
|
9495
|
+
]
|
|
9176
9496
|
},
|
|
9177
9497
|
// --- work-items release <item-ref> ---
|
|
9178
9498
|
{
|
|
@@ -9188,7 +9508,10 @@ var init_work_items = __esm({
|
|
|
9188
9508
|
const result = await ctx.client.releaseWorkItem(eid, resolvedWorkItemId);
|
|
9189
9509
|
ctx.writer.writeResult(result, `Work item ${resolvedWorkItemId} claim released.`, { jsonOnly: ctx.opts.json });
|
|
9190
9510
|
},
|
|
9191
|
-
examples: [
|
|
9511
|
+
examples: [
|
|
9512
|
+
"corp work-items release wi_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9513
|
+
"corp work-items release @last:work_item"
|
|
9514
|
+
]
|
|
9192
9515
|
},
|
|
9193
9516
|
// --- work-items cancel <item-ref> ---
|
|
9194
9517
|
{
|
|
@@ -9217,7 +9540,10 @@ var init_work_items = __esm({
|
|
|
9217
9540
|
const result = await ctx.client.cancelWorkItem(eid, resolvedWorkItemId);
|
|
9218
9541
|
ctx.writer.writeResult(result, `Work item ${resolvedWorkItemId} cancelled.`, { jsonOnly: ctx.opts.json });
|
|
9219
9542
|
},
|
|
9220
|
-
examples: [
|
|
9543
|
+
examples: [
|
|
9544
|
+
"corp work-items cancel wi_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
9545
|
+
"corp work-items cancel @last:work_item --yes"
|
|
9546
|
+
]
|
|
9221
9547
|
}
|
|
9222
9548
|
];
|
|
9223
9549
|
}
|
|
@@ -9295,7 +9621,7 @@ var init_services = __esm({
|
|
|
9295
9621
|
printReferenceSummary("service_request", result);
|
|
9296
9622
|
printJson(result);
|
|
9297
9623
|
},
|
|
9298
|
-
examples: ["corp services show", "corp services show --json"]
|
|
9624
|
+
examples: ["corp services show req_abc123", "corp services show @last --json"]
|
|
9299
9625
|
},
|
|
9300
9626
|
// --- services buy <slug> ---
|
|
9301
9627
|
{
|
|
@@ -9341,7 +9667,7 @@ var init_services = __esm({
|
|
|
9341
9667
|
},
|
|
9342
9668
|
produces: { kind: "service_request" },
|
|
9343
9669
|
successTemplate: "Service request created",
|
|
9344
|
-
examples: ["corp services buy
|
|
9670
|
+
examples: ["corp services buy registered-agent", "corp services buy annual-report --entity-id ent_abc123"]
|
|
9345
9671
|
},
|
|
9346
9672
|
// --- services fulfill <ref> ---
|
|
9347
9673
|
{
|
|
@@ -9371,7 +9697,7 @@ var init_services = __esm({
|
|
|
9371
9697
|
printReferenceSummary("service_request", result, { showReuseHint: true });
|
|
9372
9698
|
printJson(result);
|
|
9373
9699
|
},
|
|
9374
|
-
examples: ["corp services fulfill
|
|
9700
|
+
examples: ["corp services fulfill req_abc123", "corp services fulfill req_abc123 --note 'Filed with state' --json"]
|
|
9375
9701
|
},
|
|
9376
9702
|
// --- services cancel <ref> ---
|
|
9377
9703
|
{
|
|
@@ -9397,55 +9723,58 @@ var init_services = __esm({
|
|
|
9397
9723
|
printReferenceSummary("service_request", result, { showReuseHint: true });
|
|
9398
9724
|
printJson(result);
|
|
9399
9725
|
},
|
|
9400
|
-
examples: ["corp services cancel
|
|
9726
|
+
examples: ["corp services cancel req_abc123", "corp services cancel @last --json"]
|
|
9401
9727
|
},
|
|
9402
9728
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
9403
9729
|
{
|
|
9404
9730
|
name: "services create-request",
|
|
9405
|
-
description: "Submit a new service request",
|
|
9731
|
+
description: "Submit a new service request by slug",
|
|
9406
9732
|
route: { method: "POST", path: "/v1/services/requests" },
|
|
9407
9733
|
options: [
|
|
9408
|
-
{ flags: "--obligation-id <obligation-id>", description: "Obligation ID" },
|
|
9409
|
-
{ flags: "--service-slug <service-slug>", description: "Service
|
|
9734
|
+
{ flags: "--obligation-id <obligation-id>", description: "Obligation ID to attach this request to" },
|
|
9735
|
+
{ flags: "--service-slug <service-slug>", description: "Service catalog slug", required: true }
|
|
9410
9736
|
],
|
|
9411
|
-
examples: [
|
|
9412
|
-
|
|
9737
|
+
examples: [
|
|
9738
|
+
"corp services create-request --service-slug registered-agent",
|
|
9739
|
+
"corp services create-request --service-slug annual-report --obligation-id obl_abc123 --json"
|
|
9740
|
+
],
|
|
9741
|
+
successTemplate: "Service request created"
|
|
9413
9742
|
},
|
|
9414
9743
|
{
|
|
9415
9744
|
name: "services requests",
|
|
9416
9745
|
description: "View a service request by ID",
|
|
9417
9746
|
route: { method: "GET", path: "/v1/services/requests/{pos}" },
|
|
9418
9747
|
entity: true,
|
|
9419
|
-
args: [{ name: "request-id", required: true, description: "
|
|
9420
|
-
display: { title: "
|
|
9421
|
-
examples: ["corp services requests", "corp services requests --json"]
|
|
9748
|
+
args: [{ name: "request-id", required: true, description: "Service request ID", posKind: "service_request" }],
|
|
9749
|
+
display: { title: "Service Request", cols: ["amount_cents>Amount", "checkout_url>Checkout URL", "failed_at>Failed At", "fulfilled_at>Fulfilled At", "@created_at>Created", "#entity_id>Entity ID"] },
|
|
9750
|
+
examples: ["corp services requests req_abc123", "corp services requests req_abc123 --json"]
|
|
9422
9751
|
},
|
|
9423
9752
|
{
|
|
9424
9753
|
name: "services requests-cancel",
|
|
9425
|
-
description: "Cancel a service request",
|
|
9754
|
+
description: "Cancel a pending service request",
|
|
9426
9755
|
route: { method: "POST", path: "/v1/services/requests/{pos}/cancel" },
|
|
9427
|
-
args: [{ name: "request-id", required: true, description: "
|
|
9428
|
-
examples: ["corp services requests-cancel
|
|
9429
|
-
successTemplate: "
|
|
9756
|
+
args: [{ name: "request-id", required: true, description: "Service request ID", posKind: "service_request" }],
|
|
9757
|
+
examples: ["corp services requests-cancel req_abc123"],
|
|
9758
|
+
successTemplate: "Service request cancelled"
|
|
9430
9759
|
},
|
|
9431
9760
|
{
|
|
9432
9761
|
name: "services requests-checkout",
|
|
9433
|
-
description: "Start checkout for a service request",
|
|
9762
|
+
description: "Start Stripe checkout for a service request",
|
|
9434
9763
|
route: { method: "POST", path: "/v1/services/requests/{pos}/checkout" },
|
|
9435
|
-
args: [{ name: "request-id", required: true, description: "
|
|
9436
|
-
examples: ["corp services requests-checkout
|
|
9437
|
-
successTemplate: "Checkout
|
|
9764
|
+
args: [{ name: "request-id", required: true, description: "Service request ID", posKind: "service_request" }],
|
|
9765
|
+
examples: ["corp services requests-checkout req_abc123", "corp services requests-checkout req_abc123 --json"],
|
|
9766
|
+
successTemplate: "Checkout session created"
|
|
9438
9767
|
},
|
|
9439
9768
|
{
|
|
9440
9769
|
name: "services requests-fulfill",
|
|
9441
|
-
description: "
|
|
9770
|
+
description: "Mark a service request as fulfilled (operator only)",
|
|
9442
9771
|
route: { method: "POST", path: "/v1/services/requests/{pos}/fulfill" },
|
|
9443
|
-
args: [{ name: "request-id", required: true, description: "
|
|
9772
|
+
args: [{ name: "request-id", required: true, description: "Service request ID", posKind: "service_request" }],
|
|
9444
9773
|
options: [
|
|
9445
|
-
{ flags: "--note <note>", description: "
|
|
9774
|
+
{ flags: "--note <note>", description: "Fulfillment note visible to the customer" }
|
|
9446
9775
|
],
|
|
9447
|
-
examples: ["corp services requests-fulfill
|
|
9448
|
-
successTemplate: "
|
|
9776
|
+
examples: ["corp services requests-fulfill req_abc123", "corp services requests-fulfill req_abc123 --note 'Filed with Delaware' --json"],
|
|
9777
|
+
successTemplate: "Service request fulfilled"
|
|
9449
9778
|
}
|
|
9450
9779
|
];
|
|
9451
9780
|
}
|
|
@@ -10875,7 +11204,7 @@ var init_admin = __esm({
|
|
|
10875
11204
|
{ force: ctx.opts.force }
|
|
10876
11205
|
);
|
|
10877
11206
|
},
|
|
10878
|
-
examples: ["corp config set"]
|
|
11207
|
+
examples: ["corp config set api_url https://api.thecorporation.com", "corp config set workspace_id ws_abc123"]
|
|
10879
11208
|
},
|
|
10880
11209
|
{
|
|
10881
11210
|
name: "config get",
|
|
@@ -10888,7 +11217,7 @@ var init_admin = __esm({
|
|
|
10888
11217
|
const { configGetCommand: configGetCommand2 } = await Promise.resolve().then(() => (init_config2(), config_exports));
|
|
10889
11218
|
configGetCommand2(ctx.positional[0]);
|
|
10890
11219
|
},
|
|
10891
|
-
examples: ["corp config get"]
|
|
11220
|
+
examples: ["corp config get api_url", "corp config get workspace_id"]
|
|
10892
11221
|
},
|
|
10893
11222
|
{
|
|
10894
11223
|
name: "config list",
|
|
@@ -10958,7 +11287,7 @@ var init_admin = __esm({
|
|
|
10958
11287
|
local: true,
|
|
10959
11288
|
options: [
|
|
10960
11289
|
{ flags: "--name <name>", description: "Corporation name", required: true },
|
|
10961
|
-
{ flags: "--scenario <scenario>", description: "
|
|
11290
|
+
{ flags: "--scenario <scenario>", description: "Demo scenario to create", default: "startup", choices: ["startup", "llc", "restaurant"] },
|
|
10962
11291
|
{ flags: "--minimal", description: "Use the minimal server-side demo seed instead of the full CLI workflow" },
|
|
10963
11292
|
{ flags: "--json", description: "Output as JSON" }
|
|
10964
11293
|
],
|
|
@@ -10971,7 +11300,7 @@ var init_admin = __esm({
|
|
|
10971
11300
|
json: ctx.opts.json
|
|
10972
11301
|
});
|
|
10973
11302
|
},
|
|
10974
|
-
examples: ["corp demo"]
|
|
11303
|
+
examples: ["corp demo --name 'Acme Corp'", "corp demo --name 'Taco LLC' --scenario restaurant"]
|
|
10975
11304
|
},
|
|
10976
11305
|
// ── chat (local, interactive) ───────────────────────────────────────
|
|
10977
11306
|
{
|
|
@@ -11018,7 +11347,7 @@ var init_admin = __esm({
|
|
|
11018
11347
|
},
|
|
11019
11348
|
produces: { kind: "api_key" },
|
|
11020
11349
|
successTemplate: "API key created",
|
|
11021
|
-
examples: ["corp api-keys create --name '
|
|
11350
|
+
examples: ["corp api-keys create --name 'CI Deploy Key'", "corp api-keys create --name 'Webhook Key' --scopes read:entities --json"]
|
|
11022
11351
|
},
|
|
11023
11352
|
{
|
|
11024
11353
|
name: "api-keys revoke",
|
|
@@ -11038,7 +11367,7 @@ var init_admin = __esm({
|
|
|
11038
11367
|
json: ctx.opts.json
|
|
11039
11368
|
});
|
|
11040
11369
|
},
|
|
11041
|
-
examples: ["corp api-keys revoke
|
|
11370
|
+
examples: ["corp api-keys revoke key_abc123", "corp api-keys revoke key_abc123 --yes"]
|
|
11042
11371
|
},
|
|
11043
11372
|
{
|
|
11044
11373
|
name: "api-keys rotate",
|
|
@@ -11058,7 +11387,7 @@ var init_admin = __esm({
|
|
|
11058
11387
|
},
|
|
11059
11388
|
produces: { kind: "api_key" },
|
|
11060
11389
|
successTemplate: "API key rotated",
|
|
11061
|
-
examples: ["corp api-keys rotate
|
|
11390
|
+
examples: ["corp api-keys rotate key_abc123", "corp api-keys rotate key_abc123 --json"]
|
|
11062
11391
|
},
|
|
11063
11392
|
// ── link (API, write) ───────────────────────────────────────────────
|
|
11064
11393
|
{
|
|
@@ -11076,7 +11405,7 @@ var init_admin = __esm({
|
|
|
11076
11405
|
provider: ctx.opts.provider
|
|
11077
11406
|
});
|
|
11078
11407
|
},
|
|
11079
|
-
examples: ["corp link --external-id
|
|
11408
|
+
examples: ["corp link --external-id cus_abc123 --provider stripe", "corp link --external-id org_xyz --provider github"]
|
|
11080
11409
|
},
|
|
11081
11410
|
// ── claim (API, write) ──────────────────────────────────────────────
|
|
11082
11411
|
{
|
|
@@ -11091,7 +11420,7 @@ var init_admin = __esm({
|
|
|
11091
11420
|
await claimCommand2(ctx.positional[0]);
|
|
11092
11421
|
},
|
|
11093
11422
|
produces: { kind: "entity", trackEntity: true },
|
|
11094
|
-
examples: ["corp claim
|
|
11423
|
+
examples: ["corp claim CLAIM-ABC123", "corp claim ws_invite_xyz789"]
|
|
11095
11424
|
},
|
|
11096
11425
|
// ── feedback (API, write) ───────────────────────────────────────────
|
|
11097
11426
|
{
|
|
@@ -11102,7 +11431,7 @@ var init_admin = __esm({
|
|
|
11102
11431
|
{ name: "message", required: true, description: "Feedback message" }
|
|
11103
11432
|
],
|
|
11104
11433
|
options: [
|
|
11105
|
-
{ flags: "--category <category>", description: "
|
|
11434
|
+
{ flags: "--category <category>", description: "Feedback category", default: "general", choices: ["bug", "feature", "general"] },
|
|
11106
11435
|
{ flags: "--email <email>", description: "Your email address (to receive a copy)" }
|
|
11107
11436
|
],
|
|
11108
11437
|
handler: async (ctx) => {
|
|
@@ -11113,7 +11442,10 @@ var init_admin = __esm({
|
|
|
11113
11442
|
json: ctx.opts.json
|
|
11114
11443
|
});
|
|
11115
11444
|
},
|
|
11116
|
-
examples: [
|
|
11445
|
+
examples: [
|
|
11446
|
+
"corp feedback 'The cap table export is missing share classes'",
|
|
11447
|
+
"corp feedback 'PDF generation fails on long names' --category bug --email me@example.com"
|
|
11448
|
+
]
|
|
11117
11449
|
},
|
|
11118
11450
|
// ── resolve (API, read) ─────────────────────────────────────────────
|
|
11119
11451
|
{
|
|
@@ -11136,7 +11468,7 @@ var init_admin = __esm({
|
|
|
11136
11468
|
meetingId: ctx.opts.meetingId
|
|
11137
11469
|
});
|
|
11138
11470
|
},
|
|
11139
|
-
examples: ["corp resolve"]
|
|
11471
|
+
examples: ["corp resolve entity acme", "corp resolve contact alice --entity-id ent_abc123"]
|
|
11140
11472
|
},
|
|
11141
11473
|
// ── find (API, read) ────────────────────────────────────────────────
|
|
11142
11474
|
{
|
|
@@ -11161,7 +11493,7 @@ var init_admin = __esm({
|
|
|
11161
11493
|
json: ctx.opts.json
|
|
11162
11494
|
});
|
|
11163
11495
|
},
|
|
11164
|
-
examples: ["corp find"]
|
|
11496
|
+
examples: ["corp find entity acme", "corp find contact alice --entity-id ent_abc123 --json"]
|
|
11165
11497
|
},
|
|
11166
11498
|
// ── approvals (informational) ───────────────────────────────────────
|
|
11167
11499
|
{
|
|
@@ -11224,26 +11556,26 @@ var init_admin = __esm({
|
|
|
11224
11556
|
description: "Seed a demo workspace with sample data",
|
|
11225
11557
|
route: { method: "POST", path: "/v1/demo/seed" },
|
|
11226
11558
|
options: [
|
|
11227
|
-
{ flags: "--name <name>", description: "
|
|
11228
|
-
{ flags: "--scenario <scenario>", description: "Demo scenario to
|
|
11559
|
+
{ flags: "--name <name>", description: "Corporation display name" },
|
|
11560
|
+
{ flags: "--scenario <scenario>", description: "Demo scenario to seed", choices: ["startup", "llc", "restaurant"] }
|
|
11229
11561
|
],
|
|
11230
|
-
examples: ["corp demo seed", "corp demo seed --json"],
|
|
11231
|
-
successTemplate: "
|
|
11562
|
+
examples: ["corp demo seed --name 'Acme Corp'", "corp demo seed --name 'Taco LLC' --scenario restaurant --json"],
|
|
11563
|
+
successTemplate: "Demo workspace seeded"
|
|
11232
11564
|
},
|
|
11233
11565
|
{
|
|
11234
11566
|
name: "digests trigger",
|
|
11235
|
-
description: "Trigger digest generation
|
|
11567
|
+
description: "Trigger digest generation immediately",
|
|
11236
11568
|
route: { method: "POST", path: "/v1/digests/trigger" },
|
|
11237
11569
|
examples: ["corp digests trigger"],
|
|
11238
|
-
successTemplate: "
|
|
11570
|
+
successTemplate: "Digest triggered"
|
|
11239
11571
|
},
|
|
11240
11572
|
{
|
|
11241
11573
|
name: "digests",
|
|
11242
11574
|
description: "View a specific digest by key",
|
|
11243
11575
|
route: { method: "GET", path: "/v1/digests/{pos}" },
|
|
11244
|
-
args: [{ name: "digest-key", required: true, description: "Digest key" }],
|
|
11576
|
+
args: [{ name: "digest-key", required: true, description: "Digest key (e.g. daily_2026-03-22)" }],
|
|
11245
11577
|
display: { title: "Digest" },
|
|
11246
|
-
examples: ["corp digests"]
|
|
11578
|
+
examples: ["corp digests daily_2026-03-22", "corp digests weekly_2026-03-22 --json"]
|
|
11247
11579
|
},
|
|
11248
11580
|
{
|
|
11249
11581
|
name: "service-token",
|
|
@@ -11273,14 +11605,14 @@ var init_admin = __esm({
|
|
|
11273
11605
|
options: [
|
|
11274
11606
|
{ flags: "--claim-token <claim-token>", description: "Workspace claim token", required: true }
|
|
11275
11607
|
],
|
|
11276
|
-
examples: ["corp workspaces claim --claim-token
|
|
11277
|
-
successTemplate: "
|
|
11608
|
+
examples: ["corp workspaces claim --claim-token tok_abc123xyz"],
|
|
11609
|
+
successTemplate: "Workspace claimed"
|
|
11278
11610
|
},
|
|
11279
11611
|
{
|
|
11280
11612
|
name: "workspaces contacts",
|
|
11281
11613
|
description: "List contacts across the workspace",
|
|
11282
11614
|
route: { method: "GET", path: "/v1/workspaces/{workspace_id}/contacts" },
|
|
11283
|
-
display: { title: "Workspaces Contacts", cols: ["#contact_id>ID", "#entity_id>ID"] },
|
|
11615
|
+
display: { title: "Workspaces Contacts", cols: ["#contact_id>Contact ID", "#entity_id>Entity ID"] },
|
|
11284
11616
|
examples: ["corp workspaces contacts"]
|
|
11285
11617
|
},
|
|
11286
11618
|
{
|
|
@@ -11299,7 +11631,7 @@ var init_admin = __esm({
|
|
|
11299
11631
|
{ flags: "--api-key <api-key>", description: "API key (starts with sk_)", required: true },
|
|
11300
11632
|
{ flags: "--ttl-seconds <ttl-seconds>", description: "Token TTL in seconds (60-86400)", type: "int" }
|
|
11301
11633
|
],
|
|
11302
|
-
examples: ["corp auth token-exchange --api-key
|
|
11634
|
+
examples: ["corp auth token-exchange --api-key sk_live_abc123", "corp auth token-exchange --api-key sk_live_abc123 --ttl-seconds 3600 --json"],
|
|
11303
11635
|
successTemplate: "Token exchanged"
|
|
11304
11636
|
},
|
|
11305
11637
|
{
|
|
@@ -11328,7 +11660,7 @@ var init_admin = __esm({
|
|
|
11328
11660
|
description: "Revoke an SSH public key",
|
|
11329
11661
|
route: { method: "DELETE", path: "/v1/ssh-keys/{pos}" },
|
|
11330
11662
|
args: [{ name: "key-id", required: true, description: "SSH key ID to revoke" }],
|
|
11331
|
-
examples: ["corp ssh-keys revoke
|
|
11663
|
+
examples: ["corp ssh-keys revoke key_abc123"],
|
|
11332
11664
|
successTemplate: "SSH key revoked"
|
|
11333
11665
|
},
|
|
11334
11666
|
{
|
|
@@ -11339,8 +11671,8 @@ var init_admin = __esm({
|
|
|
11339
11671
|
{ flags: "--name <name>", description: "Display name", required: true },
|
|
11340
11672
|
{ flags: "--owner-email <owner-email>", description: "Workspace owner email address" }
|
|
11341
11673
|
],
|
|
11342
|
-
examples: ["corp workspaces provision --name '
|
|
11343
|
-
successTemplate: "
|
|
11674
|
+
examples: ["corp workspaces provision --name 'Acme Corp'", "corp workspaces provision --name 'Taco LLC' --owner-email founder@taco.com --json"],
|
|
11675
|
+
successTemplate: "Workspace provisioned"
|
|
11344
11676
|
},
|
|
11345
11677
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
11346
11678
|
{
|
|
@@ -11351,7 +11683,10 @@ var init_admin = __esm({
|
|
|
11351
11683
|
{ flags: "--items <items>", description: "Items to sync (JSON array)", required: true, type: "array" },
|
|
11352
11684
|
{ flags: "--kind <kind>", description: "Resource kind", required: true, choices: ["entity", "contact", "share_transfer", "invoice", "bank_account", "payment", "payroll_run", "distribution", "reconciliation", "tax_filing", "deadline", "classification", "body", "meeting", "seat", "agenda_item", "resolution", "document", "work_item", "agent", "valuation", "safe_note", "instrument", "share_class", "round"] }
|
|
11353
11685
|
],
|
|
11354
|
-
examples: [
|
|
11686
|
+
examples: [
|
|
11687
|
+
`corp references sync --kind entity --items '[{"id":"ent_abc123","name":"Acme"}]'`,
|
|
11688
|
+
`corp references sync --kind contact --items '[{"id":"con_xyz","name":"Alice"}]' --json`
|
|
11689
|
+
],
|
|
11355
11690
|
successTemplate: "References synced"
|
|
11356
11691
|
},
|
|
11357
11692
|
// ── Auto-generated from OpenAPI ──────────────────────────────
|
|
@@ -11363,26 +11698,29 @@ var init_admin = __esm({
|
|
|
11363
11698
|
{ flags: "--execution-id <execution-id>", description: "Agent execution ID", required: true },
|
|
11364
11699
|
{ flags: "--template <template>", description: "Template string with {{secret}} placeholders", required: true }
|
|
11365
11700
|
],
|
|
11366
|
-
examples: [
|
|
11367
|
-
|
|
11701
|
+
examples: [
|
|
11702
|
+
"corp secrets interpolate --execution-id exec_abc123 --template 'Bearer {{MY_API_KEY}}'",
|
|
11703
|
+
"corp secrets interpolate --execution-id exec_abc123 --template '{{DB_HOST}}:5432' --json"
|
|
11704
|
+
],
|
|
11705
|
+
successTemplate: "Template interpolated"
|
|
11368
11706
|
},
|
|
11369
11707
|
{
|
|
11370
11708
|
name: "secrets resolve",
|
|
11371
|
-
description: "Resolve a secrets token to its values",
|
|
11709
|
+
description: "Resolve a secrets access token to its plaintext values",
|
|
11372
11710
|
route: { method: "POST", path: "/v1/secrets/resolve" },
|
|
11373
11711
|
options: [
|
|
11374
11712
|
{ flags: "--token <token>", description: "Secrets access token", required: true }
|
|
11375
11713
|
],
|
|
11376
|
-
examples: ["corp secrets resolve --token
|
|
11377
|
-
successTemplate: "
|
|
11714
|
+
examples: ["corp secrets resolve --token stok_abc123xyz", "corp secrets resolve --token stok_abc123xyz --json"],
|
|
11715
|
+
successTemplate: "Secrets resolved"
|
|
11378
11716
|
},
|
|
11379
11717
|
{
|
|
11380
11718
|
name: "documents validate-preview",
|
|
11381
|
-
description: "Validate
|
|
11719
|
+
description: "Validate the document preview AST without generating a PDF",
|
|
11382
11720
|
route: { method: "GET", path: "/v1/documents/preview/pdf/validate" },
|
|
11383
11721
|
entity: true,
|
|
11384
11722
|
display: { title: "Document Preview Validation" },
|
|
11385
|
-
examples: ["corp documents validate-preview", "corp documents validate-preview --json"]
|
|
11723
|
+
examples: ["corp documents validate-preview --entity-id ent_abc123", "corp documents validate-preview --entity-id ent_abc123 --json"]
|
|
11386
11724
|
}
|
|
11387
11725
|
];
|
|
11388
11726
|
}
|
|
@@ -11400,8 +11738,8 @@ var init_execution = __esm({
|
|
|
11400
11738
|
route: { method: "PATCH", path: "/v1/document-requests/{pos}/fulfill" },
|
|
11401
11739
|
entity: true,
|
|
11402
11740
|
args: [{ name: "request-id", required: true, description: "Document request ID" }],
|
|
11403
|
-
examples: ["corp document-requests fulfill
|
|
11404
|
-
successTemplate: "
|
|
11741
|
+
examples: ["corp document-requests fulfill req_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11742
|
+
successTemplate: "Document request fulfilled"
|
|
11405
11743
|
},
|
|
11406
11744
|
{
|
|
11407
11745
|
name: "document-requests not-applicable",
|
|
@@ -11409,8 +11747,8 @@ var init_execution = __esm({
|
|
|
11409
11747
|
route: { method: "PATCH", path: "/v1/document-requests/{pos}/not-applicable" },
|
|
11410
11748
|
entity: true,
|
|
11411
11749
|
args: [{ name: "request-id", required: true, description: "Document request ID" }],
|
|
11412
|
-
examples: ["corp document-requests not-applicable
|
|
11413
|
-
successTemplate: "
|
|
11750
|
+
examples: ["corp document-requests not-applicable req_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11751
|
+
successTemplate: "Document request marked not applicable"
|
|
11414
11752
|
},
|
|
11415
11753
|
{
|
|
11416
11754
|
name: "entities approval-artifacts",
|
|
@@ -11475,8 +11813,11 @@ var init_execution = __esm({
|
|
|
11475
11813
|
{ flags: "--max-amount-cents <max-amount-cents>", description: "Maximum authorized amount in cents" },
|
|
11476
11814
|
{ flags: "--scope <scope>", description: "Authorization scope", required: true }
|
|
11477
11815
|
],
|
|
11478
|
-
examples: [
|
|
11479
|
-
|
|
11816
|
+
examples: [
|
|
11817
|
+
'corp execution approval-artifacts --approver-identity "alice@acme.com" --channel board_vote --intent-type equity_grant --scope entity',
|
|
11818
|
+
'corp execution approval-artifacts --approver-identity "alice@acme.com" --channel written_consent --intent-type equity_grant --scope entity --approved-at 2026-03-01T00:00:00Z'
|
|
11819
|
+
],
|
|
11820
|
+
successTemplate: "Approval artifact recorded"
|
|
11480
11821
|
},
|
|
11481
11822
|
{
|
|
11482
11823
|
name: "execution intents",
|
|
@@ -11489,8 +11830,11 @@ var init_execution = __esm({
|
|
|
11489
11830
|
{ flags: "--intent-type <intent-type>", description: "Type of intent", required: true },
|
|
11490
11831
|
{ flags: "--metadata <metadata>", description: "Additional metadata (JSON)" }
|
|
11491
11832
|
],
|
|
11492
|
-
examples: [
|
|
11493
|
-
|
|
11833
|
+
examples: [
|
|
11834
|
+
'corp execution intents --description "Issue 10,000 options to Alice" --intent-type equity_grant --authority-tier tier_2',
|
|
11835
|
+
'corp execution intents --description "Wire $50,000 to vendor" --intent-type payment --authority-tier tier_1'
|
|
11836
|
+
],
|
|
11837
|
+
successTemplate: "Execution intent created"
|
|
11494
11838
|
},
|
|
11495
11839
|
{
|
|
11496
11840
|
name: "execution obligations",
|
|
@@ -11505,8 +11849,11 @@ var init_execution = __esm({
|
|
|
11505
11849
|
{ flags: "--intent-id <intent-id>", description: "Execution intent ID" },
|
|
11506
11850
|
{ flags: "--obligation-type <obligation-type>", description: "Type of obligation", required: true }
|
|
11507
11851
|
],
|
|
11508
|
-
examples: [
|
|
11509
|
-
|
|
11852
|
+
examples: [
|
|
11853
|
+
'corp execution obligations --assignee-type human --description "Sign equity grant agreement" --obligation-type signature',
|
|
11854
|
+
'corp execution obligations --assignee-type internal --description "File 83(b) election" --obligation-type document --due-date 2026-04-15'
|
|
11855
|
+
],
|
|
11856
|
+
successTemplate: "Obligation created"
|
|
11510
11857
|
},
|
|
11511
11858
|
{
|
|
11512
11859
|
name: "execution packets",
|
|
@@ -11515,7 +11862,10 @@ var init_execution = __esm({
|
|
|
11515
11862
|
entity: true,
|
|
11516
11863
|
args: [{ name: "packet-id", required: true, description: "Document packet ID" }],
|
|
11517
11864
|
display: { title: "Execution Packets", cols: ["finalized_at>Finalized At", "items>Items", "manifest_hash>Manifest Hash", "required_signers>Required Signers", "@created_at>Created At", "#entity_id>ID"] },
|
|
11518
|
-
examples: [
|
|
11865
|
+
examples: [
|
|
11866
|
+
"corp execution packets pkt_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11867
|
+
"corp execution packets pkt_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
11868
|
+
]
|
|
11519
11869
|
},
|
|
11520
11870
|
{
|
|
11521
11871
|
name: "intents authorize",
|
|
@@ -11523,7 +11873,10 @@ var init_execution = __esm({
|
|
|
11523
11873
|
route: { method: "POST", path: "/v1/intents/{pos}/authorize" },
|
|
11524
11874
|
entity: true,
|
|
11525
11875
|
args: [{ name: "intent-id", required: true, description: "Execution intent ID" }],
|
|
11526
|
-
examples: [
|
|
11876
|
+
examples: [
|
|
11877
|
+
"corp intents authorize int_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11878
|
+
"corp intents authorize @last:intent"
|
|
11879
|
+
],
|
|
11527
11880
|
successTemplate: "Intent authorized"
|
|
11528
11881
|
},
|
|
11529
11882
|
{
|
|
@@ -11534,8 +11887,10 @@ var init_execution = __esm({
|
|
|
11534
11887
|
options: [
|
|
11535
11888
|
{ flags: "--approval-artifact-id <approval-artifact-id>", description: "Approval artifact ID to bind", required: true }
|
|
11536
11889
|
],
|
|
11537
|
-
examples: [
|
|
11538
|
-
|
|
11890
|
+
examples: [
|
|
11891
|
+
"corp intents bind-approval-artifact @last:intent --approval-artifact-id art_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
11892
|
+
],
|
|
11893
|
+
successTemplate: "Approval artifact bound to intent"
|
|
11539
11894
|
},
|
|
11540
11895
|
{
|
|
11541
11896
|
name: "intents bind-document-request",
|
|
@@ -11545,8 +11900,10 @@ var init_execution = __esm({
|
|
|
11545
11900
|
options: [
|
|
11546
11901
|
{ flags: "--request-id <request-id>", description: "Document request ID", required: true }
|
|
11547
11902
|
],
|
|
11548
|
-
examples: [
|
|
11549
|
-
|
|
11903
|
+
examples: [
|
|
11904
|
+
"corp intents bind-document-request @last:intent --request-id req_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
11905
|
+
],
|
|
11906
|
+
successTemplate: "Document request bound to intent"
|
|
11550
11907
|
},
|
|
11551
11908
|
{
|
|
11552
11909
|
name: "intents cancel",
|
|
@@ -11554,7 +11911,10 @@ var init_execution = __esm({
|
|
|
11554
11911
|
route: { method: "POST", path: "/v1/intents/{pos}/cancel" },
|
|
11555
11912
|
entity: true,
|
|
11556
11913
|
args: [{ name: "intent-id", required: true, description: "Execution intent ID" }],
|
|
11557
|
-
examples: [
|
|
11914
|
+
examples: [
|
|
11915
|
+
"corp intents cancel int_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11916
|
+
"corp intents cancel @last:intent"
|
|
11917
|
+
],
|
|
11558
11918
|
successTemplate: "Intent cancelled"
|
|
11559
11919
|
},
|
|
11560
11920
|
{
|
|
@@ -11563,7 +11923,10 @@ var init_execution = __esm({
|
|
|
11563
11923
|
route: { method: "POST", path: "/v1/intents/{pos}/evaluate" },
|
|
11564
11924
|
entity: true,
|
|
11565
11925
|
args: [{ name: "intent-id", required: true, description: "Execution intent ID" }],
|
|
11566
|
-
examples: [
|
|
11926
|
+
examples: [
|
|
11927
|
+
"corp intents evaluate int_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11928
|
+
"corp intents evaluate @last:intent"
|
|
11929
|
+
],
|
|
11567
11930
|
successTemplate: "Intent evaluated"
|
|
11568
11931
|
},
|
|
11569
11932
|
{
|
|
@@ -11572,7 +11935,10 @@ var init_execution = __esm({
|
|
|
11572
11935
|
route: { method: "POST", path: "/v1/intents/{pos}/execute" },
|
|
11573
11936
|
entity: true,
|
|
11574
11937
|
args: [{ name: "intent-id", required: true, description: "Execution intent ID" }],
|
|
11575
|
-
examples: [
|
|
11938
|
+
examples: [
|
|
11939
|
+
"corp intents execute int_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11940
|
+
"corp intents execute @last:intent"
|
|
11941
|
+
],
|
|
11576
11942
|
successTemplate: "Intent executed"
|
|
11577
11943
|
},
|
|
11578
11944
|
{
|
|
@@ -11582,7 +11948,10 @@ var init_execution = __esm({
|
|
|
11582
11948
|
entity: true,
|
|
11583
11949
|
args: [{ name: "intent-id", required: true, description: "Execution intent ID" }],
|
|
11584
11950
|
display: { title: "Intents Receipts", cols: ["executed_at>Executed At", "idempotency_key>Idempotency Key", "request_hash>Request Hash", "response_hash>Response Hash", "@created_at>Created At", "#intent_id>ID"] },
|
|
11585
|
-
examples: [
|
|
11951
|
+
examples: [
|
|
11952
|
+
"corp intents receipts int_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11953
|
+
"corp intents receipts @last:intent --json"
|
|
11954
|
+
]
|
|
11586
11955
|
},
|
|
11587
11956
|
{
|
|
11588
11957
|
name: "obligations assign",
|
|
@@ -11593,8 +11962,10 @@ var init_execution = __esm({
|
|
|
11593
11962
|
options: [
|
|
11594
11963
|
{ flags: "--assignee-id <assignee-id>", description: "ID of the party to assign to", required: true }
|
|
11595
11964
|
],
|
|
11596
|
-
examples: [
|
|
11597
|
-
|
|
11965
|
+
examples: [
|
|
11966
|
+
"corp obligations assign obl_01hx9k3n2p4q7r8s9t0uvwxyz --assignee-id usr_01hx9k3n2p4q7r8s9t0uvwxyz"
|
|
11967
|
+
],
|
|
11968
|
+
successTemplate: "Obligation assigned"
|
|
11598
11969
|
},
|
|
11599
11970
|
{
|
|
11600
11971
|
name: "obligations document-requests",
|
|
@@ -11603,7 +11974,10 @@ var init_execution = __esm({
|
|
|
11603
11974
|
entity: true,
|
|
11604
11975
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11605
11976
|
display: { title: "Obligations Document Requests", cols: ["description>Description", "document_type>Document Type", "fulfilled_at>Fulfilled At", "not_applicable_at>Not Applicable At", "@created_at>Created At", "#entity_id>ID"] },
|
|
11606
|
-
examples: [
|
|
11977
|
+
examples: [
|
|
11978
|
+
"corp obligations document-requests obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
11979
|
+
"corp obligations document-requests obl_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
11980
|
+
]
|
|
11607
11981
|
},
|
|
11608
11982
|
{
|
|
11609
11983
|
name: "obligations create-document-request",
|
|
@@ -11615,8 +11989,10 @@ var init_execution = __esm({
|
|
|
11615
11989
|
{ flags: "--description <description>", description: "Description text", required: true },
|
|
11616
11990
|
{ flags: "--document-type <document-type>", description: "Type of document required", required: true }
|
|
11617
11991
|
],
|
|
11618
|
-
examples: [
|
|
11619
|
-
|
|
11992
|
+
examples: [
|
|
11993
|
+
'corp obligations create-document-request obl_01hx9k3n2p4q7r8s9t0uvwxyz --description "Signed equity grant agreement" --document-type equity_grant'
|
|
11994
|
+
],
|
|
11995
|
+
successTemplate: "Document request created"
|
|
11620
11996
|
},
|
|
11621
11997
|
{
|
|
11622
11998
|
name: "obligations expire",
|
|
@@ -11624,7 +12000,10 @@ var init_execution = __esm({
|
|
|
11624
12000
|
route: { method: "POST", path: "/v1/obligations/{pos}/expire" },
|
|
11625
12001
|
entity: true,
|
|
11626
12002
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11627
|
-
examples: [
|
|
12003
|
+
examples: [
|
|
12004
|
+
"corp obligations expire obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12005
|
+
"corp obligations expire @last:obligation"
|
|
12006
|
+
],
|
|
11628
12007
|
successTemplate: "Obligation expired"
|
|
11629
12008
|
},
|
|
11630
12009
|
{
|
|
@@ -11633,7 +12012,10 @@ var init_execution = __esm({
|
|
|
11633
12012
|
route: { method: "POST", path: "/v1/obligations/{pos}/fulfill" },
|
|
11634
12013
|
entity: true,
|
|
11635
12014
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11636
|
-
examples: [
|
|
12015
|
+
examples: [
|
|
12016
|
+
"corp obligations fulfill obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12017
|
+
"corp obligations fulfill @last:obligation"
|
|
12018
|
+
],
|
|
11637
12019
|
successTemplate: "Obligation fulfilled"
|
|
11638
12020
|
},
|
|
11639
12021
|
{
|
|
@@ -11642,7 +12024,10 @@ var init_execution = __esm({
|
|
|
11642
12024
|
route: { method: "POST", path: "/v1/obligations/{pos}/waive" },
|
|
11643
12025
|
entity: true,
|
|
11644
12026
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11645
|
-
examples: [
|
|
12027
|
+
examples: [
|
|
12028
|
+
"corp obligations waive obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12029
|
+
"corp obligations waive @last:obligation"
|
|
12030
|
+
],
|
|
11646
12031
|
successTemplate: "Obligation waived"
|
|
11647
12032
|
},
|
|
11648
12033
|
{
|
|
@@ -11652,7 +12037,10 @@ var init_execution = __esm({
|
|
|
11652
12037
|
entity: true,
|
|
11653
12038
|
args: [{ name: "receipt-id", required: true, description: "Execution receipt ID" }],
|
|
11654
12039
|
display: { title: "Receipts", cols: ["executed_at>Executed At", "idempotency_key>Idempotency Key", "request_hash>Request Hash", "response_hash>Response Hash", "@created_at>Created At", "#intent_id>ID"] },
|
|
11655
|
-
examples: [
|
|
12040
|
+
examples: [
|
|
12041
|
+
"corp receipts rcp_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12042
|
+
"corp receipts rcp_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
12043
|
+
]
|
|
11656
12044
|
},
|
|
11657
12045
|
// ── Human obligations ───────────────────────────────────────────────
|
|
11658
12046
|
{
|
|
@@ -11671,7 +12059,10 @@ var init_execution = __esm({
|
|
|
11671
12059
|
route: { method: "POST", path: "/v1/human-obligations/{pos}/fulfill" },
|
|
11672
12060
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11673
12061
|
successTemplate: "Obligation fulfilled",
|
|
11674
|
-
examples: [
|
|
12062
|
+
examples: [
|
|
12063
|
+
"corp human-obligations fulfill obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12064
|
+
"corp human-obligations fulfill @last:obligation"
|
|
12065
|
+
]
|
|
11675
12066
|
},
|
|
11676
12067
|
{
|
|
11677
12068
|
name: "human-obligations signer-token",
|
|
@@ -11679,7 +12070,10 @@ var init_execution = __esm({
|
|
|
11679
12070
|
route: { method: "POST", path: "/v1/human-obligations/{pos}/signer-token" },
|
|
11680
12071
|
args: [{ name: "obligation-id", required: true, description: "Obligation ID" }],
|
|
11681
12072
|
successTemplate: "Signer token issued",
|
|
11682
|
-
examples: [
|
|
12073
|
+
examples: [
|
|
12074
|
+
"corp human-obligations signer-token obl_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12075
|
+
"corp human-obligations signer-token @last:obligation"
|
|
12076
|
+
]
|
|
11683
12077
|
}
|
|
11684
12078
|
];
|
|
11685
12079
|
}
|
|
@@ -11711,7 +12105,10 @@ var init_secret_proxies = __esm({
|
|
|
11711
12105
|
{ flags: "--description <desc>", description: "Description text" }
|
|
11712
12106
|
],
|
|
11713
12107
|
successTemplate: "Secret proxy {name} created",
|
|
11714
|
-
examples: [
|
|
12108
|
+
examples: [
|
|
12109
|
+
"corp secret-proxies create --name stripe-keys --url https://secrets.example.com/proxy",
|
|
12110
|
+
"corp secret-proxies create --name local-secrets --url self --description 'Locally encrypted secrets' --json"
|
|
12111
|
+
]
|
|
11715
12112
|
},
|
|
11716
12113
|
{
|
|
11717
12114
|
name: "secret-proxies show",
|
|
@@ -11722,7 +12119,7 @@ var init_secret_proxies = __esm({
|
|
|
11722
12119
|
title: "Secret Proxy",
|
|
11723
12120
|
cols: ["name>Name", "url>URL", "description>Description", "secret_count>Secrets", "@created_at>Created"]
|
|
11724
12121
|
},
|
|
11725
|
-
examples: ["corp secret-proxies show"]
|
|
12122
|
+
examples: ["corp secret-proxies show my-proxy", "corp secret-proxies show my-proxy --json"]
|
|
11726
12123
|
},
|
|
11727
12124
|
{
|
|
11728
12125
|
name: "secret-proxies secrets",
|
|
@@ -11733,7 +12130,7 @@ var init_secret_proxies = __esm({
|
|
|
11733
12130
|
title: "Secrets",
|
|
11734
12131
|
cols: ["names>Secret Names", "proxy_name>Proxy"]
|
|
11735
12132
|
},
|
|
11736
|
-
examples: ["corp secret-proxies secrets"]
|
|
12133
|
+
examples: ["corp secret-proxies secrets my-proxy", "corp secret-proxies secrets my-proxy --json"]
|
|
11737
12134
|
},
|
|
11738
12135
|
{
|
|
11739
12136
|
name: "secret-proxies set-secrets",
|
|
@@ -11744,7 +12141,10 @@ var init_secret_proxies = __esm({
|
|
|
11744
12141
|
{ flags: "--secrets <json>", description: "JSON object of key-value secret pairs", required: true }
|
|
11745
12142
|
],
|
|
11746
12143
|
successTemplate: "Secrets updated for {proxy_name}",
|
|
11747
|
-
examples: [
|
|
12144
|
+
examples: [
|
|
12145
|
+
`corp secret-proxies set-secrets my-proxy --secrets '{"API_KEY":"sk-live-abc","DB_PASS":"hunter2"}'`,
|
|
12146
|
+
`corp secret-proxies set-secrets my-proxy --secrets '{"STRIPE_KEY":"sk_live_xyz"}' --json`
|
|
12147
|
+
]
|
|
11748
12148
|
}
|
|
11749
12149
|
];
|
|
11750
12150
|
}
|
|
@@ -11762,20 +12162,23 @@ var init_treasury = __esm({
|
|
|
11762
12162
|
route: { method: "POST", path: "/v1/bank-accounts/{pos}/close" },
|
|
11763
12163
|
entity: true,
|
|
11764
12164
|
args: [{ name: "bank-account-id", required: true, description: "Bank account ID", posKind: "bank_account" }],
|
|
11765
|
-
examples: ["corp bank-accounts close
|
|
11766
|
-
successTemplate: "
|
|
12165
|
+
examples: ["corp bank-accounts close ba_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
12166
|
+
successTemplate: "Bank account closed"
|
|
11767
12167
|
},
|
|
11768
12168
|
{
|
|
11769
12169
|
name: "distributions",
|
|
11770
|
-
description: "Record a distribution (dividend, member draw)",
|
|
12170
|
+
description: "Record a distribution (dividend, member draw, or liquidation)",
|
|
11771
12171
|
route: { method: "POST", path: "/v1/distributions" },
|
|
11772
12172
|
options: [
|
|
11773
12173
|
{ flags: "--description <description>", description: "Description text", required: true },
|
|
11774
|
-
{ flags: "--distribution-type <distribution-type>", description: "Type of distribution
|
|
11775
|
-
{ flags: "--total-amount-cents <total-amount-cents>", description: "Total
|
|
12174
|
+
{ flags: "--distribution-type <distribution-type>", description: "Type of distribution", choices: ["dividend", "return", "liquidation"] },
|
|
12175
|
+
{ flags: "--total-amount-cents <total-amount-cents>", description: "Total amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" }
|
|
11776
12176
|
],
|
|
11777
|
-
examples: [
|
|
11778
|
-
|
|
12177
|
+
examples: [
|
|
12178
|
+
'corp distributions --description "Q1 dividend" --distribution-type dividend --total-amount-cents 500000',
|
|
12179
|
+
'corp distributions --description "Founder draw" --distribution-type return --total-amount-cents 1000000'
|
|
12180
|
+
],
|
|
12181
|
+
successTemplate: "Distribution recorded"
|
|
11779
12182
|
},
|
|
11780
12183
|
{
|
|
11781
12184
|
name: "entities accounts",
|
|
@@ -11803,7 +12206,7 @@ var init_treasury = __esm({
|
|
|
11803
12206
|
},
|
|
11804
12207
|
{
|
|
11805
12208
|
name: "entities stripe-account",
|
|
11806
|
-
description: "View Stripe account for an entity",
|
|
12209
|
+
description: "View Stripe account details for an entity",
|
|
11807
12210
|
route: { method: "GET", path: "/v1/entities/{eid}/stripe-account" },
|
|
11808
12211
|
entity: true,
|
|
11809
12212
|
display: { title: "Entities Stripe Account", cols: ["@created_at>Created At", "#entity_id>ID", "status>Status", "#stripe_account_id>ID"] },
|
|
@@ -11815,13 +12218,15 @@ var init_treasury = __esm({
|
|
|
11815
12218
|
route: { method: "POST", path: "/v1/invoices/from-agent-request" },
|
|
11816
12219
|
entity: true,
|
|
11817
12220
|
options: [
|
|
11818
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
12221
|
+
{ flags: "--amount-cents <amount-cents>", description: "Invoice amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
11819
12222
|
{ flags: "--customer-name <customer-name>", description: "Customer name for the invoice", required: true },
|
|
11820
|
-
{ flags: "--description <description>", description: "Description
|
|
11821
|
-
{ flags: "--due-date <due-date>", description: "
|
|
12223
|
+
{ flags: "--description <description>", description: "Description of the services or goods invoiced", required: true },
|
|
12224
|
+
{ flags: "--due-date <due-date>", description: "Payment due date (ISO 8601, e.g. 2026-06-30)", required: true }
|
|
11822
12225
|
],
|
|
11823
|
-
examples: [
|
|
11824
|
-
|
|
12226
|
+
examples: [
|
|
12227
|
+
'corp invoices from-agent-request --amount-cents 500000 --customer-name "Acme Corp" --description "Consulting services Q1" --due-date 2026-06-30'
|
|
12228
|
+
],
|
|
12229
|
+
successTemplate: "Invoice created from agent request"
|
|
11825
12230
|
},
|
|
11826
12231
|
{
|
|
11827
12232
|
name: "invoices",
|
|
@@ -11830,7 +12235,10 @@ var init_treasury = __esm({
|
|
|
11830
12235
|
entity: true,
|
|
11831
12236
|
args: [{ name: "invoice-id", required: true, description: "Invoice ID", posKind: "invoice" }],
|
|
11832
12237
|
display: { title: "Invoices", cols: ["amount_cents>Amount Cents", "customer_name>Customer Name", "description>Description", "status>Status", "@created_at>Created At", "#entity_id>ID"] },
|
|
11833
|
-
examples: [
|
|
12238
|
+
examples: [
|
|
12239
|
+
"corp invoices inv_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12240
|
+
"corp invoices inv_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
12241
|
+
]
|
|
11834
12242
|
},
|
|
11835
12243
|
{
|
|
11836
12244
|
name: "invoices mark-paid",
|
|
@@ -11838,7 +12246,7 @@ var init_treasury = __esm({
|
|
|
11838
12246
|
route: { method: "POST", path: "/v1/invoices/{pos}/mark-paid" },
|
|
11839
12247
|
entity: true,
|
|
11840
12248
|
args: [{ name: "invoice-id", required: true, description: "Invoice ID", posKind: "invoice" }],
|
|
11841
|
-
examples: ["corp invoices mark-paid
|
|
12249
|
+
examples: ["corp invoices mark-paid inv_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11842
12250
|
successTemplate: "Invoice marked as paid"
|
|
11843
12251
|
},
|
|
11844
12252
|
{
|
|
@@ -11848,7 +12256,10 @@ var init_treasury = __esm({
|
|
|
11848
12256
|
entity: true,
|
|
11849
12257
|
args: [{ name: "invoice-id", required: true, description: "Invoice ID", posKind: "invoice" }],
|
|
11850
12258
|
display: { title: "Invoices Pay Instructions", cols: ["amount_cents>Amount Cents", "currency>Currency", "instructions>Instructions", "#invoice_id>ID", "payment_method>Payment Method"] },
|
|
11851
|
-
examples: [
|
|
12259
|
+
examples: [
|
|
12260
|
+
"corp invoices pay-instructions inv_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12261
|
+
"corp invoices pay-instructions inv_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
12262
|
+
]
|
|
11852
12263
|
},
|
|
11853
12264
|
{
|
|
11854
12265
|
name: "invoices send",
|
|
@@ -11856,17 +12267,20 @@ var init_treasury = __esm({
|
|
|
11856
12267
|
route: { method: "POST", path: "/v1/invoices/{pos}/send" },
|
|
11857
12268
|
entity: true,
|
|
11858
12269
|
args: [{ name: "invoice-id", required: true, description: "Invoice ID", posKind: "invoice" }],
|
|
11859
|
-
examples: ["corp invoices send
|
|
12270
|
+
examples: ["corp invoices send inv_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11860
12271
|
successTemplate: "Invoice sent"
|
|
11861
12272
|
},
|
|
11862
12273
|
{
|
|
11863
12274
|
name: "invoices status",
|
|
11864
|
-
description: "Check
|
|
12275
|
+
description: "Check payment status of an invoice",
|
|
11865
12276
|
route: { method: "GET", path: "/v1/invoices/{pos}/status" },
|
|
11866
12277
|
entity: true,
|
|
11867
12278
|
args: [{ name: "invoice-id", required: true, description: "Invoice ID", posKind: "invoice" }],
|
|
11868
12279
|
display: { title: "Invoices Status", cols: ["amount_cents>Amount Cents", "customer_name>Customer Name", "description>Description", "status>Status", "@created_at>Created At", "#entity_id>ID"] },
|
|
11869
|
-
examples: [
|
|
12280
|
+
examples: [
|
|
12281
|
+
"corp invoices status inv_01hx9k3n2p4q7r8s9t0uvwxyz",
|
|
12282
|
+
"corp invoices status inv_01hx9k3n2p4q7r8s9t0uvwxyz --json"
|
|
12283
|
+
]
|
|
11870
12284
|
},
|
|
11871
12285
|
{
|
|
11872
12286
|
name: "journal-entries post",
|
|
@@ -11874,7 +12288,7 @@ var init_treasury = __esm({
|
|
|
11874
12288
|
route: { method: "POST", path: "/v1/journal-entries/{pos}/post" },
|
|
11875
12289
|
entity: true,
|
|
11876
12290
|
args: [{ name: "entry-id", required: true, description: "Journal entry ID" }],
|
|
11877
|
-
examples: ["corp journal-entries post
|
|
12291
|
+
examples: ["corp journal-entries post jrn_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11878
12292
|
successTemplate: "Journal entry posted"
|
|
11879
12293
|
},
|
|
11880
12294
|
{
|
|
@@ -11883,21 +12297,24 @@ var init_treasury = __esm({
|
|
|
11883
12297
|
route: { method: "POST", path: "/v1/journal-entries/{pos}/void" },
|
|
11884
12298
|
entity: true,
|
|
11885
12299
|
args: [{ name: "entry-id", required: true, description: "Journal entry ID" }],
|
|
11886
|
-
examples: ["corp journal-entries void
|
|
12300
|
+
examples: ["corp journal-entries void jrn_01hx9k3n2p4q7r8s9t0uvwxyz"],
|
|
11887
12301
|
successTemplate: "Journal entry voided"
|
|
11888
12302
|
},
|
|
11889
12303
|
{
|
|
11890
12304
|
name: "ledger reconcile",
|
|
11891
|
-
description: "
|
|
12305
|
+
description: "Run a ledger reconciliation for an entity",
|
|
11892
12306
|
route: { method: "POST", path: "/v1/ledger/reconcile" },
|
|
11893
12307
|
entity: true,
|
|
11894
12308
|
options: [
|
|
11895
|
-
{ flags: "--as-of-date <as-of-date>", description: "
|
|
11896
|
-
{ flags: "--end-date <end-date>", description: "End
|
|
11897
|
-
{ flags: "--start-date <start-date>", description: "Start
|
|
12309
|
+
{ flags: "--as-of-date <as-of-date>", description: "Reconcile as of this date (ISO 8601, e.g. 2026-03-31)" },
|
|
12310
|
+
{ flags: "--end-date <end-date>", description: "End of reconciliation period (ISO 8601)" },
|
|
12311
|
+
{ flags: "--start-date <start-date>", description: "Start of reconciliation period (ISO 8601)" }
|
|
11898
12312
|
],
|
|
11899
|
-
examples: [
|
|
11900
|
-
|
|
12313
|
+
examples: [
|
|
12314
|
+
"corp ledger reconcile --as-of-date 2026-03-31",
|
|
12315
|
+
"corp ledger reconcile --start-date 2026-01-01 --end-date 2026-03-31"
|
|
12316
|
+
],
|
|
12317
|
+
successTemplate: "Ledger reconciliation complete"
|
|
11901
12318
|
},
|
|
11902
12319
|
{
|
|
11903
12320
|
name: "payments",
|
|
@@ -11905,79 +12322,95 @@ var init_treasury = __esm({
|
|
|
11905
12322
|
route: { method: "POST", path: "/v1/payments" },
|
|
11906
12323
|
entity: true,
|
|
11907
12324
|
options: [
|
|
11908
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
11909
|
-
{ flags: "--description <description>", description: "Description
|
|
11910
|
-
{ flags: "--payment-method <payment-method>", description: "How
|
|
11911
|
-
{ flags: "--recipient <recipient>", description: "Recipient", required: true }
|
|
12325
|
+
{ flags: "--amount-cents <amount-cents>", description: "Payment amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
12326
|
+
{ flags: "--description <description>", description: "Description of the payment", required: true },
|
|
12327
|
+
{ flags: "--payment-method <payment-method>", description: "How the payment is made or received", choices: ["bank_transfer", "card", "check", "wire", "ach"] },
|
|
12328
|
+
{ flags: "--recipient <recipient>", description: "Recipient name or ID", required: true }
|
|
12329
|
+
],
|
|
12330
|
+
examples: [
|
|
12331
|
+
'corp payments --amount-cents 250000 --description "Software subscription" --payment-method ach --recipient "Acme Vendors LLC"',
|
|
12332
|
+
'corp payments --amount-cents 1000000 --description "Consulting invoice #42" --payment-method wire --recipient "Jane Doe"'
|
|
11912
12333
|
],
|
|
11913
|
-
|
|
11914
|
-
successTemplate: "Payments created"
|
|
12334
|
+
successTemplate: "Payment recorded"
|
|
11915
12335
|
},
|
|
11916
12336
|
{
|
|
11917
12337
|
name: "payments execute",
|
|
11918
|
-
description: "Execute a pending payment",
|
|
12338
|
+
description: "Execute a pending payment immediately",
|
|
11919
12339
|
route: { method: "POST", path: "/v1/payments/execute" },
|
|
11920
12340
|
entity: true,
|
|
11921
12341
|
options: [
|
|
11922
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
11923
|
-
{ flags: "--description <description>", description: "Description
|
|
11924
|
-
{ flags: "--payment-method <payment-method>", description: "How
|
|
11925
|
-
{ flags: "--recipient <recipient>", description: "Recipient", required: true }
|
|
12342
|
+
{ flags: "--amount-cents <amount-cents>", description: "Payment amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
12343
|
+
{ flags: "--description <description>", description: "Description of the payment", required: true },
|
|
12344
|
+
{ flags: "--payment-method <payment-method>", description: "How the payment is made or received", choices: ["bank_transfer", "card", "check", "wire", "ach"] },
|
|
12345
|
+
{ flags: "--recipient <recipient>", description: "Recipient name or ID", required: true }
|
|
12346
|
+
],
|
|
12347
|
+
examples: [
|
|
12348
|
+
'corp payments execute --amount-cents 250000 --description "Vendor invoice" --payment-method wire --recipient "Acme Vendors LLC"'
|
|
11926
12349
|
],
|
|
11927
|
-
examples: ["corp payments execute --amount-cents 'amount-cents' --description bank_transfer --recipient 'recipient'", "corp payments execute --json"],
|
|
11928
12350
|
successTemplate: "Payment executed"
|
|
11929
12351
|
},
|
|
11930
12352
|
{
|
|
11931
12353
|
name: "payroll runs",
|
|
11932
|
-
description: "Create a payroll run",
|
|
12354
|
+
description: "Create a payroll run for a pay period",
|
|
11933
12355
|
route: { method: "POST", path: "/v1/payroll/runs" },
|
|
11934
12356
|
entity: true,
|
|
11935
12357
|
options: [
|
|
11936
|
-
{ flags: "--pay-period-end <pay-period-end>", description: "
|
|
11937
|
-
{ flags: "--pay-period-start <pay-period-start>", description: "
|
|
12358
|
+
{ flags: "--pay-period-end <pay-period-end>", description: "Last day of the pay period (ISO 8601, e.g. 2026-03-31)", required: true },
|
|
12359
|
+
{ flags: "--pay-period-start <pay-period-start>", description: "First day of the pay period (ISO 8601, e.g. 2026-03-01)", required: true }
|
|
12360
|
+
],
|
|
12361
|
+
examples: [
|
|
12362
|
+
"corp payroll runs --pay-period-start 2026-03-01 --pay-period-end 2026-03-31"
|
|
11938
12363
|
],
|
|
11939
|
-
examples: ["corp payroll runs --pay-period-end 'pay-period-end' --pay-period-start 'pay-period-start'"],
|
|
11940
12364
|
successTemplate: "Payroll run created"
|
|
11941
12365
|
},
|
|
11942
12366
|
{
|
|
11943
12367
|
name: "spending-limits",
|
|
11944
|
-
description: "Set a spending limit",
|
|
12368
|
+
description: "Set a spending limit for a category and period",
|
|
11945
12369
|
route: { method: "POST", path: "/v1/spending-limits" },
|
|
11946
12370
|
entity: true,
|
|
11947
12371
|
options: [
|
|
11948
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
11949
|
-
{ flags: "--category <category>", description: "
|
|
11950
|
-
{ flags: "--period <period>", description: "
|
|
12372
|
+
{ flags: "--amount-cents <amount-cents>", description: "Limit amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
12373
|
+
{ flags: "--category <category>", description: "Spending category (e.g. software, travel, marketing)", required: true },
|
|
12374
|
+
{ flags: "--period <period>", description: "Limit period (e.g. monthly, quarterly, annual)", required: true }
|
|
11951
12375
|
],
|
|
11952
|
-
examples: [
|
|
11953
|
-
|
|
12376
|
+
examples: [
|
|
12377
|
+
"corp spending-limits --amount-cents 500000 --category software --period monthly",
|
|
12378
|
+
"corp spending-limits --amount-cents 2000000 --category travel --period quarterly"
|
|
12379
|
+
],
|
|
12380
|
+
successTemplate: "Spending limit set"
|
|
11954
12381
|
},
|
|
11955
12382
|
{
|
|
11956
12383
|
name: "treasury accounts",
|
|
11957
|
-
description: "Create a new ledger account",
|
|
12384
|
+
description: "Create a new ledger account for an entity",
|
|
11958
12385
|
route: { method: "POST", path: "/v1/treasury/accounts" },
|
|
11959
12386
|
entity: true,
|
|
11960
12387
|
options: [
|
|
11961
|
-
{ flags: "--account-code <account-code>", description: "Standard GL account
|
|
12388
|
+
{ flags: "--account-code <account-code>", description: "Standard GL account code to create", required: true, choices: ["Cash", "AccountsReceivable", "AccountsPayable", "AccruedExpenses", "FounderCapital", "Revenue", "OperatingExpenses", "Cogs"] }
|
|
12389
|
+
],
|
|
12390
|
+
examples: [
|
|
12391
|
+
"corp treasury accounts --account-code Cash",
|
|
12392
|
+
"corp treasury accounts --account-code Revenue"
|
|
11962
12393
|
],
|
|
11963
|
-
|
|
11964
|
-
successTemplate: "Accounts created"
|
|
12394
|
+
successTemplate: "Ledger account created"
|
|
11965
12395
|
},
|
|
11966
12396
|
{
|
|
11967
12397
|
name: "treasury bank-accounts",
|
|
11968
|
-
description: "Register a new bank account",
|
|
12398
|
+
description: "Register a new bank account for an entity",
|
|
11969
12399
|
route: { method: "POST", path: "/v1/treasury/bank-accounts" },
|
|
11970
12400
|
entity: true,
|
|
11971
12401
|
options: [
|
|
11972
|
-
{ flags: "--account-type <account-type>", description: "
|
|
11973
|
-
{ flags: "--bank-name <bank-name>", description: "
|
|
12402
|
+
{ flags: "--account-type <account-type>", description: "Type of bank account", choices: ["checking", "savings"] },
|
|
12403
|
+
{ flags: "--bank-name <bank-name>", description: "Name of the bank (e.g. Mercury, Chase)", required: true }
|
|
11974
12404
|
],
|
|
11975
|
-
examples: [
|
|
11976
|
-
|
|
12405
|
+
examples: [
|
|
12406
|
+
"corp treasury bank-accounts --bank-name Mercury --account-type checking",
|
|
12407
|
+
"corp treasury bank-accounts --bank-name Chase --account-type savings"
|
|
12408
|
+
],
|
|
12409
|
+
successTemplate: "Bank account registered"
|
|
11977
12410
|
},
|
|
11978
12411
|
{
|
|
11979
12412
|
name: "treasury chart-of-accounts",
|
|
11980
|
-
description: "View chart of accounts for an entity",
|
|
12413
|
+
description: "View the chart of accounts for an entity",
|
|
11981
12414
|
route: { method: "GET", path: "/v1/treasury/chart-of-accounts/{eid}" },
|
|
11982
12415
|
entity: true,
|
|
11983
12416
|
display: { title: "Treasury Chart Of Accounts", cols: ["accounts>Accounts", "#entity_id>ID"] },
|
|
@@ -11989,13 +12422,15 @@ var init_treasury = __esm({
|
|
|
11989
12422
|
route: { method: "POST", path: "/v1/treasury/invoices" },
|
|
11990
12423
|
entity: true,
|
|
11991
12424
|
options: [
|
|
11992
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
12425
|
+
{ flags: "--amount-cents <amount-cents>", description: "Invoice amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
11993
12426
|
{ flags: "--customer-name <customer-name>", description: "Customer name for the invoice", required: true },
|
|
11994
|
-
{ flags: "--description <description>", description: "Description
|
|
11995
|
-
{ flags: "--due-date <due-date>", description: "
|
|
12427
|
+
{ flags: "--description <description>", description: "Description of services or goods invoiced", required: true },
|
|
12428
|
+
{ flags: "--due-date <due-date>", description: "Payment due date (ISO 8601, e.g. 2026-06-30)", required: true }
|
|
12429
|
+
],
|
|
12430
|
+
examples: [
|
|
12431
|
+
'corp treasury invoices --amount-cents 500000 --customer-name "Acme Corp" --description "Consulting services Q1" --due-date 2026-06-30'
|
|
11996
12432
|
],
|
|
11997
|
-
|
|
11998
|
-
successTemplate: "Invoices created"
|
|
12433
|
+
successTemplate: "Invoice created"
|
|
11999
12434
|
},
|
|
12000
12435
|
{
|
|
12001
12436
|
name: "treasury journal-entries",
|
|
@@ -12003,12 +12438,14 @@ var init_treasury = __esm({
|
|
|
12003
12438
|
route: { method: "POST", path: "/v1/treasury/journal-entries" },
|
|
12004
12439
|
entity: true,
|
|
12005
12440
|
options: [
|
|
12006
|
-
{ flags: "--description <description>", description: "Description
|
|
12007
|
-
{ flags: "--effective-date <effective-date>", description: "
|
|
12008
|
-
{ flags: "--lines <lines>", description: "
|
|
12441
|
+
{ flags: "--description <description>", description: "Description of the journal entry", required: true },
|
|
12442
|
+
{ flags: "--effective-date <effective-date>", description: "Date the entry takes effect (ISO 8601, e.g. 2026-03-31)", required: true },
|
|
12443
|
+
{ flags: "--lines <lines>", description: "JSON array of debit/credit line items", required: true, type: "array" }
|
|
12444
|
+
],
|
|
12445
|
+
examples: [
|
|
12446
|
+
`corp treasury journal-entries --description "Prepaid software expense" --effective-date 2026-03-31 --lines '[{"account_code":"OperatingExpenses","amount_cents":50000,"type":"debit"},{"account_code":"Cash","amount_cents":50000,"type":"credit"}]'`
|
|
12009
12447
|
],
|
|
12010
|
-
|
|
12011
|
-
successTemplate: "Journal Entries created"
|
|
12448
|
+
successTemplate: "Journal entry created"
|
|
12012
12449
|
},
|
|
12013
12450
|
{
|
|
12014
12451
|
name: "treasury payment-intents",
|
|
@@ -12016,44 +12453,51 @@ var init_treasury = __esm({
|
|
|
12016
12453
|
route: { method: "POST", path: "/v1/treasury/payment-intents" },
|
|
12017
12454
|
entity: true,
|
|
12018
12455
|
options: [
|
|
12019
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
12020
|
-
{ flags: "--currency <currency>", description: "
|
|
12021
|
-
{ flags: "--description <description>", description: "Description
|
|
12456
|
+
{ flags: "--amount-cents <amount-cents>", description: "Payment amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
12457
|
+
{ flags: "--currency <currency>", description: "ISO 4217 currency code (e.g. USD)" },
|
|
12458
|
+
{ flags: "--description <description>", description: "Description of the payment" }
|
|
12459
|
+
],
|
|
12460
|
+
examples: [
|
|
12461
|
+
'corp treasury payment-intents --amount-cents 500000 --currency USD --description "Vendor payment"'
|
|
12022
12462
|
],
|
|
12023
|
-
|
|
12024
|
-
successTemplate: "Payment Intents created"
|
|
12463
|
+
successTemplate: "Payment intent created"
|
|
12025
12464
|
},
|
|
12026
12465
|
{
|
|
12027
12466
|
name: "treasury payouts",
|
|
12028
|
-
description: "Create a payout",
|
|
12467
|
+
description: "Create a payout to a destination",
|
|
12029
12468
|
route: { method: "POST", path: "/v1/treasury/payouts" },
|
|
12030
12469
|
entity: true,
|
|
12031
12470
|
options: [
|
|
12032
|
-
{ flags: "--amount-cents <amount-cents>", description: "
|
|
12033
|
-
{ flags: "--description <description>", description: "Description
|
|
12034
|
-
{ flags: "--destination <destination>", description: "Destination", required: true }
|
|
12471
|
+
{ flags: "--amount-cents <amount-cents>", description: "Payout amount in cents (e.g. 500000 for $5,000)", required: true, type: "int" },
|
|
12472
|
+
{ flags: "--description <description>", description: "Description of the payout" },
|
|
12473
|
+
{ flags: "--destination <destination>", description: "Destination account or recipient ID", required: true }
|
|
12474
|
+
],
|
|
12475
|
+
examples: [
|
|
12476
|
+
'corp treasury payouts --amount-cents 500000 --destination ba_01hx9k3n2p4q7r8s9t0uvwxyz --description "Founder distribution"'
|
|
12035
12477
|
],
|
|
12036
|
-
|
|
12037
|
-
successTemplate: "Payouts created"
|
|
12478
|
+
successTemplate: "Payout created"
|
|
12038
12479
|
},
|
|
12039
12480
|
{
|
|
12040
12481
|
name: "treasury seed-chart-of-accounts",
|
|
12041
|
-
description: "Initialize chart of accounts for an entity",
|
|
12482
|
+
description: "Initialize the chart of accounts for an entity from a template",
|
|
12042
12483
|
route: { method: "POST", path: "/v1/treasury/seed-chart-of-accounts" },
|
|
12043
12484
|
entity: true,
|
|
12044
12485
|
options: [
|
|
12045
|
-
{ flags: "--template <template>", description: "Chart of accounts template
|
|
12486
|
+
{ flags: "--template <template>", description: "Chart of accounts template to seed from (e.g. standard, startup)" }
|
|
12046
12487
|
],
|
|
12047
|
-
examples: [
|
|
12048
|
-
|
|
12488
|
+
examples: [
|
|
12489
|
+
"corp treasury seed-chart-of-accounts",
|
|
12490
|
+
"corp treasury seed-chart-of-accounts --template startup"
|
|
12491
|
+
],
|
|
12492
|
+
successTemplate: "Chart of accounts initialized"
|
|
12049
12493
|
},
|
|
12050
12494
|
{
|
|
12051
12495
|
name: "treasury stripe-accounts",
|
|
12052
|
-
description: "Register a Stripe account",
|
|
12496
|
+
description: "Register a Stripe account for an entity",
|
|
12053
12497
|
route: { method: "POST", path: "/v1/treasury/stripe-accounts" },
|
|
12054
12498
|
entity: true,
|
|
12055
12499
|
examples: ["corp treasury stripe-accounts"],
|
|
12056
|
-
successTemplate: "Stripe
|
|
12500
|
+
successTemplate: "Stripe account registered"
|
|
12057
12501
|
}
|
|
12058
12502
|
];
|
|
12059
12503
|
}
|
|
@@ -12086,7 +12530,7 @@ var init_branches = __esm({
|
|
|
12086
12530
|
{ flags: "--from <branch>", description: "Base branch (default: main)", default: "main" }
|
|
12087
12531
|
],
|
|
12088
12532
|
successTemplate: "Branch {branch} created at {base_commit}",
|
|
12089
|
-
examples: ["corp branches create --name
|
|
12533
|
+
examples: ["corp branches create --name feature/my-change", "corp branches create --name hotfix/fix-ein --from main --json"]
|
|
12090
12534
|
},
|
|
12091
12535
|
{
|
|
12092
12536
|
name: "branches merge",
|
|
@@ -12099,7 +12543,7 @@ var init_branches = __esm({
|
|
|
12099
12543
|
{ flags: "--squash", description: "Squash merge (default: true)" }
|
|
12100
12544
|
],
|
|
12101
12545
|
successTemplate: "Merge {strategy}: {commit}",
|
|
12102
|
-
examples: ["corp branches merge
|
|
12546
|
+
examples: ["corp branches merge feature/my-change", "corp branches merge feature/my-change --into main --squash --json"]
|
|
12103
12547
|
},
|
|
12104
12548
|
{
|
|
12105
12549
|
name: "branches delete",
|
|
@@ -12108,7 +12552,7 @@ var init_branches = __esm({
|
|
|
12108
12552
|
entity: "query",
|
|
12109
12553
|
args: [{ name: "branch", required: true, description: "Branch to delete" }],
|
|
12110
12554
|
successTemplate: "Branch deleted",
|
|
12111
|
-
examples: ["corp branches delete
|
|
12555
|
+
examples: ["corp branches delete feature/my-change"]
|
|
12112
12556
|
},
|
|
12113
12557
|
{
|
|
12114
12558
|
name: "branches prune",
|
|
@@ -12117,12 +12561,281 @@ var init_branches = __esm({
|
|
|
12117
12561
|
entity: "query",
|
|
12118
12562
|
args: [{ name: "branch", required: true, description: "Branch to prune" }],
|
|
12119
12563
|
successTemplate: "Branch pruned",
|
|
12120
|
-
examples: ["corp branches prune
|
|
12564
|
+
examples: ["corp branches prune feature/my-change"]
|
|
12121
12565
|
}
|
|
12122
12566
|
];
|
|
12123
12567
|
}
|
|
12124
12568
|
});
|
|
12125
12569
|
|
|
12570
|
+
// src/registry/completions.ts
|
|
12571
|
+
function buildTree(commands) {
|
|
12572
|
+
const topLevelMap = /* @__PURE__ */ new Map();
|
|
12573
|
+
const topLevel = [];
|
|
12574
|
+
for (const cmd of commands) {
|
|
12575
|
+
if (cmd.hidden) continue;
|
|
12576
|
+
const parts = cmd.name.split(" ");
|
|
12577
|
+
const opts = ["--json"];
|
|
12578
|
+
if (cmd.entity) opts.push("--entity-id");
|
|
12579
|
+
if (cmd.dryRun) opts.push("--dry-run");
|
|
12580
|
+
for (const o of cmd.options ?? []) {
|
|
12581
|
+
if (o.hidden) continue;
|
|
12582
|
+
const longFlag = o.flags.split(/\s+/).find((f) => f.startsWith("--"));
|
|
12583
|
+
if (longFlag) {
|
|
12584
|
+
opts.push(longFlag.replace(/<[^>]*>|\[[^\]]*\]/, "").trim());
|
|
12585
|
+
}
|
|
12586
|
+
}
|
|
12587
|
+
const node = {
|
|
12588
|
+
name: parts[parts.length - 1],
|
|
12589
|
+
description: cmd.description,
|
|
12590
|
+
options: opts,
|
|
12591
|
+
subcmds: []
|
|
12592
|
+
};
|
|
12593
|
+
if (parts.length === 1) {
|
|
12594
|
+
topLevelMap.set(parts[0], node);
|
|
12595
|
+
topLevel.push(node);
|
|
12596
|
+
} else {
|
|
12597
|
+
const parentName = parts[0];
|
|
12598
|
+
let parent = topLevelMap.get(parentName);
|
|
12599
|
+
if (!parent) {
|
|
12600
|
+
parent = { name: parentName, description: "", options: [], subcmds: [] };
|
|
12601
|
+
topLevelMap.set(parentName, parent);
|
|
12602
|
+
topLevel.push(parent);
|
|
12603
|
+
}
|
|
12604
|
+
parent.subcmds.push(node);
|
|
12605
|
+
}
|
|
12606
|
+
}
|
|
12607
|
+
return topLevel;
|
|
12608
|
+
}
|
|
12609
|
+
function generateBash(commands) {
|
|
12610
|
+
const tree = buildTree(commands);
|
|
12611
|
+
const lines = [
|
|
12612
|
+
"# corp bash completion",
|
|
12613
|
+
"# Source this file or add to ~/.bash_completion.d/",
|
|
12614
|
+
"# source <(corp completions --shell bash)",
|
|
12615
|
+
"",
|
|
12616
|
+
"_corp_completions() {",
|
|
12617
|
+
" local cur prev words cword",
|
|
12618
|
+
" _init_completion 2>/dev/null || {",
|
|
12619
|
+
" COMPREPLY=()",
|
|
12620
|
+
' cur="${COMP_WORDS[COMP_CWORD]}"',
|
|
12621
|
+
' prev="${COMP_WORDS[COMP_CWORD-1]}"',
|
|
12622
|
+
' words=("${COMP_WORDS[@]}")',
|
|
12623
|
+
" cword=$COMP_CWORD",
|
|
12624
|
+
" }",
|
|
12625
|
+
"",
|
|
12626
|
+
' local subcommand=""',
|
|
12627
|
+
' local subsubcommand=""',
|
|
12628
|
+
' if [[ ${#words[@]} -ge 2 ]]; then subcommand="${words[1]}"; fi',
|
|
12629
|
+
' if [[ ${#words[@]} -ge 3 ]]; then subsubcommand="${words[2]}"; fi',
|
|
12630
|
+
""
|
|
12631
|
+
];
|
|
12632
|
+
const topNames = tree.map((n) => n.name).join(" ");
|
|
12633
|
+
lines.push(` local top_commands="${topNames}"`);
|
|
12634
|
+
lines.push("");
|
|
12635
|
+
lines.push(' case "$subcommand" in');
|
|
12636
|
+
for (const parent of tree) {
|
|
12637
|
+
if (parent.subcmds.length > 0) {
|
|
12638
|
+
const subNames = parent.subcmds.map((s3) => s3.name).join(" ");
|
|
12639
|
+
lines.push(` ${parent.name})`);
|
|
12640
|
+
lines.push(` local ${parent.name}_subcmds="${subNames}"`);
|
|
12641
|
+
lines.push(` case "$subsubcommand" in`);
|
|
12642
|
+
for (const child of parent.subcmds) {
|
|
12643
|
+
const childFlags = child.options.join(" ");
|
|
12644
|
+
lines.push(` ${child.name})`);
|
|
12645
|
+
lines.push(` COMPREPLY=( $(compgen -W "${childFlags}" -- "$cur") )`);
|
|
12646
|
+
lines.push(" return 0 ;;");
|
|
12647
|
+
}
|
|
12648
|
+
const parentFlags = parent.options.join(" ");
|
|
12649
|
+
lines.push(" *)");
|
|
12650
|
+
if (parent.options.length > 0) {
|
|
12651
|
+
lines.push(` COMPREPLY=( $(compgen -W "${parent.subcmds.map((s3) => s3.name).join(" ")} ${parentFlags}" -- "$cur") )`);
|
|
12652
|
+
} else {
|
|
12653
|
+
lines.push(` COMPREPLY=( $(compgen -W "$${parent.name}_subcmds" -- "$cur") )`);
|
|
12654
|
+
}
|
|
12655
|
+
lines.push(" return 0 ;;");
|
|
12656
|
+
lines.push(" esac ;;");
|
|
12657
|
+
} else {
|
|
12658
|
+
const flags = parent.options.join(" ");
|
|
12659
|
+
lines.push(` ${parent.name})`);
|
|
12660
|
+
lines.push(` COMPREPLY=( $(compgen -W "${flags}" -- "$cur") )`);
|
|
12661
|
+
lines.push(" return 0 ;;");
|
|
12662
|
+
}
|
|
12663
|
+
}
|
|
12664
|
+
lines.push(" *)");
|
|
12665
|
+
lines.push(' COMPREPLY=( $(compgen -W "$top_commands" -- "$cur") )');
|
|
12666
|
+
lines.push(" return 0 ;;");
|
|
12667
|
+
lines.push(" esac");
|
|
12668
|
+
lines.push("}");
|
|
12669
|
+
lines.push("");
|
|
12670
|
+
lines.push("complete -F _corp_completions corp");
|
|
12671
|
+
lines.push("complete -F _corp_completions npx corp");
|
|
12672
|
+
return lines.join("\n");
|
|
12673
|
+
}
|
|
12674
|
+
function escapeZshDesc(s3) {
|
|
12675
|
+
return s3.replace(/'/g, "'\\''").replace(/:/g, "\\:");
|
|
12676
|
+
}
|
|
12677
|
+
function generateZsh(commands) {
|
|
12678
|
+
const tree = buildTree(commands);
|
|
12679
|
+
const lines = [
|
|
12680
|
+
"#compdef corp",
|
|
12681
|
+
"# corp zsh completion",
|
|
12682
|
+
"# Add to your fpath and run: compdef _corp corp",
|
|
12683
|
+
'# eval "$(corp completions --shell zsh)"',
|
|
12684
|
+
"",
|
|
12685
|
+
"_corp() {",
|
|
12686
|
+
" local state",
|
|
12687
|
+
" local -a top_commands",
|
|
12688
|
+
""
|
|
12689
|
+
];
|
|
12690
|
+
lines.push(" top_commands=(");
|
|
12691
|
+
for (const node of tree) {
|
|
12692
|
+
lines.push(` '${node.name}:${escapeZshDesc(node.description)}'`);
|
|
12693
|
+
}
|
|
12694
|
+
lines.push(" )");
|
|
12695
|
+
lines.push("");
|
|
12696
|
+
lines.push(" _arguments -C \\");
|
|
12697
|
+
lines.push(" '(-h --help)'{-h,--help}'[Show help]' \\");
|
|
12698
|
+
lines.push(" '(-V --version)'{-V,--version}'[Show version]' \\");
|
|
12699
|
+
lines.push(" '(-q --quiet)'{-q,--quiet}'[Quiet output]' \\");
|
|
12700
|
+
lines.push(" '1: :->cmd' \\");
|
|
12701
|
+
lines.push(" '*: :->args'");
|
|
12702
|
+
lines.push("");
|
|
12703
|
+
lines.push(" case $state in");
|
|
12704
|
+
lines.push(" cmd)");
|
|
12705
|
+
lines.push(" _describe 'command' top_commands ;;");
|
|
12706
|
+
lines.push(" args)");
|
|
12707
|
+
lines.push(" case $words[2] in");
|
|
12708
|
+
for (const parent of tree) {
|
|
12709
|
+
lines.push(` ${parent.name})`);
|
|
12710
|
+
if (parent.subcmds.length > 0) {
|
|
12711
|
+
lines.push(" local -a subcmds");
|
|
12712
|
+
lines.push(" subcmds=(");
|
|
12713
|
+
for (const child of parent.subcmds) {
|
|
12714
|
+
lines.push(` '${child.name}:${escapeZshDesc(child.description)}'`);
|
|
12715
|
+
}
|
|
12716
|
+
lines.push(" )");
|
|
12717
|
+
lines.push(" if (( CURRENT == 3 )); then");
|
|
12718
|
+
lines.push(" _describe 'subcommand' subcmds");
|
|
12719
|
+
lines.push(" else");
|
|
12720
|
+
lines.push(" case $words[3] in");
|
|
12721
|
+
for (const child of parent.subcmds) {
|
|
12722
|
+
const argSpec = child.options.map((f) => `'${f}[option]'`).join(" \\\n ");
|
|
12723
|
+
lines.push(` ${child.name})`);
|
|
12724
|
+
lines.push(` _arguments ${argSpec} ;;`);
|
|
12725
|
+
}
|
|
12726
|
+
lines.push(" esac");
|
|
12727
|
+
lines.push(" fi ;;");
|
|
12728
|
+
} else {
|
|
12729
|
+
const argSpec = parent.options.map((f) => `'${f}[option]'`).join(" \\\n ");
|
|
12730
|
+
if (argSpec) {
|
|
12731
|
+
lines.push(` _arguments ${argSpec} ;;`);
|
|
12732
|
+
} else {
|
|
12733
|
+
lines.push(" ;; # no options");
|
|
12734
|
+
}
|
|
12735
|
+
}
|
|
12736
|
+
}
|
|
12737
|
+
lines.push(" esac ;;");
|
|
12738
|
+
lines.push(" esac");
|
|
12739
|
+
lines.push("}");
|
|
12740
|
+
lines.push("");
|
|
12741
|
+
lines.push("_corp");
|
|
12742
|
+
return lines.join("\n");
|
|
12743
|
+
}
|
|
12744
|
+
function generateFish(commands) {
|
|
12745
|
+
const tree = buildTree(commands);
|
|
12746
|
+
const lines = [
|
|
12747
|
+
"# corp fish completion",
|
|
12748
|
+
"# Save to ~/.config/fish/completions/corp.fish",
|
|
12749
|
+
"# corp completions --shell fish > ~/.config/fish/completions/corp.fish",
|
|
12750
|
+
""
|
|
12751
|
+
];
|
|
12752
|
+
lines.push("complete -c corp -f");
|
|
12753
|
+
lines.push("");
|
|
12754
|
+
for (const node of tree) {
|
|
12755
|
+
const desc = node.description.replace(/'/g, "\\'");
|
|
12756
|
+
lines.push(`complete -c corp -n '__fish_use_subcommand' -a '${node.name}' -d '${desc}'`);
|
|
12757
|
+
}
|
|
12758
|
+
lines.push("");
|
|
12759
|
+
for (const parent of tree) {
|
|
12760
|
+
const parentName = parent.name;
|
|
12761
|
+
if (parent.subcmds.length > 0) {
|
|
12762
|
+
for (const child of parent.subcmds) {
|
|
12763
|
+
const desc = child.description.replace(/'/g, "\\'");
|
|
12764
|
+
lines.push(
|
|
12765
|
+
`complete -c corp -n "__fish_seen_subcommand_from ${parentName}; and not __fish_seen_subcommand_from ${parent.subcmds.map((s3) => s3.name).join(" ")}" -a '${child.name}' -d '${desc}'`
|
|
12766
|
+
);
|
|
12767
|
+
}
|
|
12768
|
+
lines.push("");
|
|
12769
|
+
for (const child of parent.subcmds) {
|
|
12770
|
+
for (const flag of child.options) {
|
|
12771
|
+
const long = flag.replace(/^--/, "");
|
|
12772
|
+
lines.push(
|
|
12773
|
+
`complete -c corp -n "__fish_seen_subcommand_from ${parentName}; and __fish_seen_subcommand_from ${child.name}" -l '${long}'`
|
|
12774
|
+
);
|
|
12775
|
+
}
|
|
12776
|
+
if (child.options.length > 0) lines.push("");
|
|
12777
|
+
}
|
|
12778
|
+
} else {
|
|
12779
|
+
for (const flag of parent.options) {
|
|
12780
|
+
const long = flag.replace(/^--/, "");
|
|
12781
|
+
lines.push(
|
|
12782
|
+
`complete -c corp -n "__fish_seen_subcommand_from ${parentName}" -l '${long}'`
|
|
12783
|
+
);
|
|
12784
|
+
}
|
|
12785
|
+
if (parent.options.length > 0) lines.push("");
|
|
12786
|
+
}
|
|
12787
|
+
}
|
|
12788
|
+
return lines.join("\n");
|
|
12789
|
+
}
|
|
12790
|
+
function makeCompletionsCommand(allCommands) {
|
|
12791
|
+
return {
|
|
12792
|
+
name: "completions",
|
|
12793
|
+
description: "Generate shell completion scripts",
|
|
12794
|
+
local: true,
|
|
12795
|
+
options: [
|
|
12796
|
+
{
|
|
12797
|
+
flags: "--shell <shell>",
|
|
12798
|
+
description: "Shell type (bash, zsh, fish)",
|
|
12799
|
+
choices: ["bash", "zsh", "fish"],
|
|
12800
|
+
required: true
|
|
12801
|
+
}
|
|
12802
|
+
],
|
|
12803
|
+
examples: [
|
|
12804
|
+
"corp completions --shell bash",
|
|
12805
|
+
"corp completions --shell zsh",
|
|
12806
|
+
"corp completions --shell fish",
|
|
12807
|
+
"source <(corp completions --shell bash)",
|
|
12808
|
+
'eval "$(corp completions --shell zsh)"',
|
|
12809
|
+
"corp completions --shell fish > ~/.config/fish/completions/corp.fish"
|
|
12810
|
+
],
|
|
12811
|
+
handler: async (ctx) => {
|
|
12812
|
+
const shell = ctx.opts.shell;
|
|
12813
|
+
const cmds = allCommands.filter((c) => c.name !== "completions");
|
|
12814
|
+
let script;
|
|
12815
|
+
switch (shell) {
|
|
12816
|
+
case "bash":
|
|
12817
|
+
script = generateBash(cmds);
|
|
12818
|
+
break;
|
|
12819
|
+
case "zsh":
|
|
12820
|
+
script = generateZsh(cmds);
|
|
12821
|
+
break;
|
|
12822
|
+
case "fish":
|
|
12823
|
+
script = generateFish(cmds);
|
|
12824
|
+
break;
|
|
12825
|
+
default:
|
|
12826
|
+
ctx.writer.error(`Unknown shell: ${shell}. Choose bash, zsh, or fish.`);
|
|
12827
|
+
process.exit(1);
|
|
12828
|
+
}
|
|
12829
|
+
process.stdout.write(script + "\n");
|
|
12830
|
+
}
|
|
12831
|
+
};
|
|
12832
|
+
}
|
|
12833
|
+
var init_completions = __esm({
|
|
12834
|
+
"src/registry/completions.ts"() {
|
|
12835
|
+
"use strict";
|
|
12836
|
+
}
|
|
12837
|
+
});
|
|
12838
|
+
|
|
12126
12839
|
// src/registry/index.ts
|
|
12127
12840
|
var registry_exports = {};
|
|
12128
12841
|
__export(registry_exports, {
|
|
@@ -12254,7 +12967,7 @@ function generateSchema(commands, programName, version) {
|
|
|
12254
12967
|
commands: topLevel
|
|
12255
12968
|
};
|
|
12256
12969
|
}
|
|
12257
|
-
var registry;
|
|
12970
|
+
var baseRegistry, registry;
|
|
12258
12971
|
var init_registry = __esm({
|
|
12259
12972
|
"src/registry/index.ts"() {
|
|
12260
12973
|
"use strict";
|
|
@@ -12274,7 +12987,8 @@ var init_registry = __esm({
|
|
|
12274
12987
|
init_secret_proxies();
|
|
12275
12988
|
init_treasury();
|
|
12276
12989
|
init_branches();
|
|
12277
|
-
|
|
12990
|
+
init_completions();
|
|
12991
|
+
baseRegistry = [
|
|
12278
12992
|
...workspaceCommands,
|
|
12279
12993
|
...entityCommands,
|
|
12280
12994
|
...formationCommands,
|
|
@@ -12292,6 +13006,10 @@ var init_registry = __esm({
|
|
|
12292
13006
|
...treasuryCommands,
|
|
12293
13007
|
...branchCommands
|
|
12294
13008
|
];
|
|
13009
|
+
registry = [
|
|
13010
|
+
...baseRegistry,
|
|
13011
|
+
makeCompletionsCommand(baseRegistry)
|
|
13012
|
+
];
|
|
12295
13013
|
}
|
|
12296
13014
|
});
|
|
12297
13015
|
|
|
@@ -12617,7 +13335,9 @@ init_api_client();
|
|
|
12617
13335
|
init_references();
|
|
12618
13336
|
function buildCLI(commands, version) {
|
|
12619
13337
|
const program2 = new Command();
|
|
12620
|
-
program2.name("corp").description(
|
|
13338
|
+
program2.name("corp").description(
|
|
13339
|
+
'The Corporation CLI \u2014 form entities, manage cap tables, govern, and operate.\n\nQuick start:\n corp form --type llc --name "My LLC" --member "Alice,a@co.com,member,100"\n corp cap-table\n corp next\n\nDocs: https://docs.thecorporation.ai'
|
|
13340
|
+
).version(version).enablePositionalOptions();
|
|
12621
13341
|
program2.option("-q, --quiet", "Only output the resource ID (for scripting)");
|
|
12622
13342
|
program2.action(() => {
|
|
12623
13343
|
program2.outputHelp();
|
|
@@ -12638,6 +13358,61 @@ function buildCLI(commands, version) {
|
|
|
12638
13358
|
children.get(parent).push(def);
|
|
12639
13359
|
}
|
|
12640
13360
|
}
|
|
13361
|
+
const commandGroupOrder = {
|
|
13362
|
+
// Core workflow — formation & entity management
|
|
13363
|
+
form: 0,
|
|
13364
|
+
entities: 1,
|
|
13365
|
+
contacts: 2,
|
|
13366
|
+
// Cap table
|
|
13367
|
+
"cap-table": 10,
|
|
13368
|
+
"safe-notes": 11,
|
|
13369
|
+
"share-transfers": 12,
|
|
13370
|
+
valuations: 13,
|
|
13371
|
+
// Governance
|
|
13372
|
+
governance: 20,
|
|
13373
|
+
// Finance
|
|
13374
|
+
finance: 30,
|
|
13375
|
+
// Compliance & tax
|
|
13376
|
+
tax: 40,
|
|
13377
|
+
deadlines: 41,
|
|
13378
|
+
// Status / context / actions
|
|
13379
|
+
status: 50,
|
|
13380
|
+
context: 51,
|
|
13381
|
+
use: 52,
|
|
13382
|
+
next: 53,
|
|
13383
|
+
obligations: 54,
|
|
13384
|
+
"human-obligations": 55,
|
|
13385
|
+
digest: 56,
|
|
13386
|
+
// Services & work items
|
|
13387
|
+
services: 60,
|
|
13388
|
+
"work-items": 61,
|
|
13389
|
+
contracts: 62,
|
|
13390
|
+
// Agents
|
|
13391
|
+
agents: 70,
|
|
13392
|
+
// Admin / config / setup (last)
|
|
13393
|
+
billing: 80,
|
|
13394
|
+
"api-keys": 81,
|
|
13395
|
+
link: 82,
|
|
13396
|
+
claim: 83,
|
|
13397
|
+
feedback: 84,
|
|
13398
|
+
resolve: 85,
|
|
13399
|
+
find: 86,
|
|
13400
|
+
approvals: 87,
|
|
13401
|
+
receipts: 88,
|
|
13402
|
+
config: 90,
|
|
13403
|
+
setup: 91,
|
|
13404
|
+
schema: 92,
|
|
13405
|
+
serve: 93,
|
|
13406
|
+
demo: 94,
|
|
13407
|
+
chat: 95,
|
|
13408
|
+
completions: 96
|
|
13409
|
+
};
|
|
13410
|
+
topLevel.sort((a, b) => {
|
|
13411
|
+
const ga = commandGroupOrder[a.name] ?? 75;
|
|
13412
|
+
const gb = commandGroupOrder[b.name] ?? 75;
|
|
13413
|
+
if (ga !== gb) return ga - gb;
|
|
13414
|
+
return a.name.localeCompare(b.name);
|
|
13415
|
+
});
|
|
12641
13416
|
const parentCmds = /* @__PURE__ */ new Map();
|
|
12642
13417
|
for (const def of topLevel) {
|
|
12643
13418
|
const cmd = wireCommand(program2, def);
|