@open-captable-protocol/canton 0.0.29 → 0.0.31

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.
@@ -1,11 +1,12 @@
1
1
  import { ClientConfig } from '@fairmint/canton-node-sdk';
2
- import { AuthorizeIssuerParams, AuthorizeIssuerResult, CreateIssuerParams, CreateIssuerResult, UpdateIssuerDataParams, UpdateIssuerDataResult, CreateCompanyValuationReportParams, CreateCompanyValuationReportResult, UpdateCompanyValuationParams, UpdateCompanyValuationResult, AddObserversToCompanyValuationReportParams, AddObserversToCompanyValuationReportResult } from './functions';
2
+ import { AuthorizeIssuerParams, AuthorizeIssuerResult, CreateIssuerParams, CreateIssuerResult, UpdateIssuerDataParams, UpdateIssuerDataResult, GetIssuerAsOcfParams, GetIssuerAsOcfResult, CreateCompanyValuationReportParams, CreateCompanyValuationReportResult, UpdateCompanyValuationParams, UpdateCompanyValuationResult, AddObserversToCompanyValuationReportParams, AddObserversToCompanyValuationReportResult } from './functions';
3
3
  export declare class OcpClient {
4
4
  private client;
5
5
  issuer: {
6
6
  authorizeIssuer: (params: AuthorizeIssuerParams) => Promise<AuthorizeIssuerResult>;
7
7
  createIssuer: (params: CreateIssuerParams) => Promise<CreateIssuerResult>;
8
8
  updateIssuerData: (params: UpdateIssuerDataParams) => Promise<UpdateIssuerDataResult>;
9
+ getIssuerAsOcf: (params: GetIssuerAsOcfParams) => Promise<GetIssuerAsOcfResult>;
9
10
  };
10
11
  companyValuationReport: {
11
12
  createCompanyValuationReport: (params: CreateCompanyValuationReportParams) => Promise<CreateCompanyValuationReportResult>;
@@ -1 +1 @@
1
- {"version":3,"file":"OcpClient.d.ts","sourceRoot":"","sources":["../src/OcpClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAuB,MAAM,2BAA2B,CAAC;AAC9E,OAAO,EAAmB,qBAAqB,EAAE,qBAAqB,EAAe,kBAAkB,EAAE,kBAAkB,EAAoB,sBAAsB,E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,MAAM,EAAE;QACb,eAAe,EAAE,CAAC,MAAM,EAAE,qBAAqB,KAAK,OAAO,CAAC,qBAAqB,CAAC,CAAC;QACnF,YAAY,EAAE,CAAC,MAAM,EAAE,kBAAkB,KAAK,OAAO,CAAC,kBAAkB,CAAC,CAAC;QAC1E,gBAAgB,EAAE,CAAC,MAAM,EAAE,sBAAsB,KAAK,OAAO,CAAC,sBAAsB,CAAC,CAAC;QACtF,cAAc,EAAE,CAAC,MAAM,EAAE,oBAAoB,KAAK,OAAO,CAAC,oBAAoB,CAAC,CAAC;KACjF,CAAC;IAEK,sBAAsB,EAAE;QAC7B,4BAA4B,EAAE,CAC5B,MAAM,EAAE,kCAAkC,KACvC,OAAO,CAAC,kCAAkC,CAAC,CAAC;QACjD,sBAAsB,EAAE,CACtB,MAAM,EAAE,4BAA4B,KACjC,OAAO,CAAC,4BAA4B,CAAC,CAAC;QAC3C,oCAAoC,EAAE,CACpC,MAAM,EAAE,0CAA0C,KAC/C,OAAO,CAAC,0CAA0C,CAAC,CAAC;KAC1D,CAAC;gBAEU,MAAM,CAAC,EAAE,YAAY;CAoBlC"}
package/dist/OcpClient.js CHANGED
@@ -9,7 +9,8 @@ class OcpClient {
9
9
  this.issuer = {
10
10
  authorizeIssuer: (params) => (0, functions_1.authorizeIssuer)(this.client, params),
11
11
  createIssuer: (params) => (0, functions_1.createIssuer)(this.client, params),
12
- updateIssuerData: (params) => (0, functions_1.updateIssuerData)(this.client, params)
12
+ updateIssuerData: (params) => (0, functions_1.updateIssuerData)(this.client, params),
13
+ getIssuerAsOcf: (params) => (0, functions_1.getIssuerAsOcf)(this.client, params)
13
14
  };
14
15
  this.companyValuationReport = {
15
16
  createCompanyValuationReport: (params) => (0, functions_1.createCompanyValuationReport)(this.client, params),
@@ -1 +1 @@
1
- {"version":3,"file":"OcpClient.js","sourceRoot":"","sources":["../src/OcpClient.ts"],"names":[],"mappings":";;;AAAA,+DAA8E;AAC9E,2CAA2gB;AAE3gB,MAAa,SAAS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AE,CAAC,MAA0B,EAAE,EAAE,CAAC,IAAA,wBAAY,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;YAC/E,gBAAgB,EAAE,CAAC,MAA8B,EAAE,EAAE,CAAC,IAAA,4BAAgB,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;YAC3F,cAAc,EAAE,CAAC,MAA4B,EAAE,EAAE,CAAC,IAAA,0BAAc,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;SACtF,CAAC;QAEF,IAAI,CAAC,sBAAsB,GAAG;YAC5B,4BAA4B,EAAE,CAAC,MAA0C,EAAE,EAAE,CAC3E,IAAA,wCAA4B,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;YACnD,sBAAsB,EAAE,CAAC,MAAoC,EAAE,EAAE,CAC/D,IAAA,kCAAsB,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;YAC7C,oCAAoC,EAAE,CACpC,MAAkD,EAClD,EAAE,CAAC,IAAA,gDAAoC,EAAC,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;SAC/D,CAAC;IACJ,CAAC;CACF;AA1CD,8BA0CC"}
@@ -0,0 +1,73 @@
1
+ import { LedgerJsonApiClient } from '@fairmint/canton-node-sdk';
2
+ /**
3
+ * OCF Issuer object according to the Open Cap Table Coalition schema
4
+ * @see https://schema.opencaptablecoalition.com/v/1.2.0/objects/Issuer.schema.json
5
+ */
6
+ export interface OcfIssuer {
7
+ object_type: 'ISSUER';
8
+ legal_name: string;
9
+ dba?: string;
10
+ formation_date?: string;
11
+ country_of_formation: string;
12
+ country_subdivision_of_formation?: string;
13
+ tax_ids?: Array<{
14
+ tax_id_type: string;
15
+ tax_id: string;
16
+ }>;
17
+ email?: {
18
+ email_type: 'PERSONAL' | 'BUSINESS';
19
+ email_address: string;
20
+ };
21
+ phone?: string;
22
+ address?: {
23
+ line1?: string;
24
+ line2?: string;
25
+ city?: string;
26
+ state?: string;
27
+ postal_code?: string;
28
+ country?: string;
29
+ };
30
+ initial_shares_authorized?: string | number;
31
+ id?: string;
32
+ comments?: string[];
33
+ }
34
+ export interface GetIssuerAsOcfParams {
35
+ /** Contract ID of the Issuer contract to retrieve */
36
+ contractId: string;
37
+ }
38
+ export interface GetIssuerAsOcfResult {
39
+ /** The OCF Issuer object */
40
+ issuer: OcfIssuer;
41
+ /** The original contract ID */
42
+ contractId: string;
43
+ }
44
+ /**
45
+ * Retrieve an issuer contract by ID and return it as an OCF JSON object
46
+ *
47
+ * This function fetches the issuer contract data from the ledger and transforms it
48
+ * into the Open Cap Table Coalition (OCF) format according to the official schema.
49
+ *
50
+ * @see https://schema.opencaptablecoalition.com/v/1.2.0/objects/Issuer.schema.json
51
+ *
52
+ * @example
53
+ * ```typescript
54
+ * const result = await getIssuerAsOcf(client, {
55
+ * contractId: "1234567890abcdef"
56
+ * });
57
+ *
58
+ * console.log(result.issuer);
59
+ * // {
60
+ * // object_type: "ISSUER",
61
+ * // legal_name: "My Company Inc.",
62
+ * // country_of_formation: "US",
63
+ * // formation_date: "2020-01-15",
64
+ * // // ... other fields
65
+ * // }
66
+ * ```
67
+ *
68
+ * @param client - The ledger JSON API client
69
+ * @param params - Parameters for retrieving the issuer
70
+ * @returns Promise resolving to the OCF Issuer object
71
+ */
72
+ export declare function getIssuerAsOcf(client: LedgerJsonApiClient, params: GetIssuerAsOcfParams): Promise<GetIssuerAsOcfResult>;
73
+ //# sourceMappingURL=getIssuerAsOcf.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getIssuerAsOcf.d.ts","sourceRoot":"","sources":["../../../src/functions/issuer/getIssuerAsOcf.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAEhE;;;GAGG;AACH,MAAM,WAAW,SAAS;IACxB,WAAW,EAAE,QAAQ,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;IACnB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,gCAAgC,CAAC,EAAE,MAAM,CAAC;IAC1C,OAAO,CAAC,EAAE,KAAK,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;QACpB,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC,CAAC;IACH,KAAK,CAAC,EAAE;QACN,UAAU,EAAE,UAAU,GAAG,UAAU,CAAC;QACpC,aAAa,EAAE,MAAM,CAAC;KACvB,CAAC;IACF,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE;QACR,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB,CAAC;IACF,yBAAyB,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC5C,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;CACrB;AAED,MAAM,WAAW,oBAAoB;IACnC,qDAAqD;IACrD,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,oBAAoB;IACnC,4BAA4B;IAC5B,MAAM,EAAE,SAAS,CAAC;IAClB,+BAA+B;IAC/B,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAsB,cAAc,CAClC,MAAM,EAAE,mBAAmB,EAC3B,MAAM,EAAE,oBAAoB,GAC3B,OAAO,CAAC,oBAAoB,CAAC,CAiF/B"}
@@ -0,0 +1,105 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getIssuerAsOcf = getIssuerAsOcf;
4
+ /**
5
+ * Retrieve an issuer contract by ID and return it as an OCF JSON object
6
+ *
7
+ * This function fetches the issuer contract data from the ledger and transforms it
8
+ * into the Open Cap Table Coalition (OCF) format according to the official schema.
9
+ *
10
+ * @see https://schema.opencaptablecoalition.com/v/1.2.0/objects/Issuer.schema.json
11
+ *
12
+ * @example
13
+ * ```typescript
14
+ * const result = await getIssuerAsOcf(client, {
15
+ * contractId: "1234567890abcdef"
16
+ * });
17
+ *
18
+ * console.log(result.issuer);
19
+ * // {
20
+ * // object_type: "ISSUER",
21
+ * // legal_name: "My Company Inc.",
22
+ * // country_of_formation: "US",
23
+ * // formation_date: "2020-01-15",
24
+ * // // ... other fields
25
+ * // }
26
+ * ```
27
+ *
28
+ * @param client - The ledger JSON API client
29
+ * @param params - Parameters for retrieving the issuer
30
+ * @returns Promise resolving to the OCF Issuer object
31
+ */
32
+ async function getIssuerAsOcf(client, params) {
33
+ // Get the events for the Issuer contract
34
+ const eventsResponse = await client.getEventsByContractId({
35
+ contractId: params.contractId
36
+ });
37
+ if (!eventsResponse.created?.createdEvent?.createArgument) {
38
+ throw new Error('Invalid contract events response: missing created event or create argument');
39
+ }
40
+ const createArgument = eventsResponse.created.createdEvent.createArgument;
41
+ // Type guard to ensure we have the expected issuer data structure
42
+ function hasIssuerData(arg) {
43
+ return typeof arg === 'object' &&
44
+ arg !== null &&
45
+ 'issuer_data' in arg &&
46
+ typeof arg.issuer_data === 'object';
47
+ }
48
+ if (!hasIssuerData(createArgument)) {
49
+ throw new Error('Issuer data not found in contract create argument');
50
+ }
51
+ const issuerData = createArgument.issuer_data;
52
+ // Helper function to convert DAML Optional to JavaScript undefined
53
+ const toUndefined = (value) => value === null ? undefined : value;
54
+ // Helper function to convert DAML email type to OCF schema email type
55
+ const convertEmailType = (damlEmailType) => {
56
+ switch (damlEmailType) {
57
+ case 'OcfEmailTypePersonal':
58
+ return 'PERSONAL';
59
+ case 'OcfEmailTypeBusiness':
60
+ return 'BUSINESS';
61
+ default:
62
+ throw new Error(`Unknown email type: ${damlEmailType}`);
63
+ }
64
+ };
65
+ // Transform DAML issuer data to OCF format
66
+ const ocfIssuer = {
67
+ object_type: 'ISSUER',
68
+ legal_name: issuerData.legal_name || '',
69
+ country_of_formation: issuerData.country_of_formation || '',
70
+ // Optional fields
71
+ ...(issuerData.dba && { dba: issuerData.dba }),
72
+ ...(issuerData.formation_date && { formation_date: issuerData.formation_date }),
73
+ ...(issuerData.country_subdivision_of_formation && {
74
+ country_subdivision_of_formation: issuerData.country_subdivision_of_formation
75
+ }),
76
+ ...(issuerData.tax_ids && { tax_ids: issuerData.tax_ids }),
77
+ ...(issuerData.email && {
78
+ email: {
79
+ email_type: convertEmailType(issuerData.email.email_type),
80
+ email_address: issuerData.email.email_address
81
+ }
82
+ }),
83
+ ...(issuerData.phone && { phone: issuerData.phone }),
84
+ ...(issuerData.address && {
85
+ address: {
86
+ ...(issuerData.address.line1 && { line1: toUndefined(issuerData.address.line1) }),
87
+ ...(issuerData.address.line2 && { line2: toUndefined(issuerData.address.line2) }),
88
+ ...(issuerData.address.city && { city: toUndefined(issuerData.address.city) }),
89
+ ...(issuerData.address.state && { state: toUndefined(issuerData.address.state) }),
90
+ ...(issuerData.address.postal_code && { postal_code: toUndefined(issuerData.address.postal_code) }),
91
+ ...(issuerData.address.country && { country: toUndefined(issuerData.address.country) })
92
+ }
93
+ }),
94
+ ...(issuerData.initial_shares_authorized && {
95
+ initial_shares_authorized: issuerData.initial_shares_authorized
96
+ }),
97
+ // Use contract ID as the OCF object ID
98
+ id: params.contractId
99
+ };
100
+ return {
101
+ issuer: ocfIssuer,
102
+ contractId: params.contractId
103
+ };
104
+ }
105
+ //# sourceMappingURL=getIssuerAsOcf.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getIssuerAsOcf.js","sourceRoot":"","sources":["../../../src/functions/issuer/getIssuerAsOcf.ts"],"names":[],"mappings":";;AA4EA,wCAoFC;AAhHD;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACI,KAAK,UAAU,cAAc,CAClC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AC,UAAU,CAAC,OAAO,CAAC,KAAK,IAAI,EAAE,KAAK,EAAE,WAAW,CAAC,UAAU,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;gBACjF,GAAG,CAAC,UAAU,CAAC,OAAO,CAAC,WAAW,IAAI,EAAE,WAAW,EAAE,WAAW,CAAC,UAAU,CAAC,OAAO,CAAC,WAAW,CAAC,EAAE,CAAC;gBACnG,GAAG,CAAC,UAAU,CAAC,OAAO,CAAC,OAAO,IAAI,EAAE,OAAO,EAAE,WAAW,CAAC,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC;aACxF;SACF,CAAC;QACF,GAAG,CAAC,UAAU,CAAC,yBAAyB,IAAI;YAC1C,yBAAyB,EAAE,UAAU,CAAC,yBAAyB;SAChE,CAAC;QACF,uCAAuC;QACvC,EAAE,EAAE,MAAM,CAAC,UAAU;KACtB,CAAC;IAEF,OAAO;QACL,MAAM,EAAE,SAAS;QACjB,UAAU,EAAE,MAAM,CAAC,UAAU;KAC9B,CAAC;AACJ,CAAC"}
@@ -1,4 +1,5 @@
1
1
  export * from './authorizeIssuer';
2
2
  export * from './createIssuer';
3
3
  export * from './updateIssuerData';
4
+ export * from './getIssuerAsOcf';
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/functions/issuer/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/functions/issuer/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC"}
@@ -17,4 +17,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./authorizeIssuer"), exports);
18
18
  __exportStar(require("./createIssuer"), exports);
19
19
  __exportStar(require("./updateIssuerData"), exports);
20
+ __exportStar(require("./getIssuerAsOcf"), exports);
20
21
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/functions/issuer/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,iDAA+B;AAC/B,qDAAmC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/functions/issuer/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,iDAA+B;AAC/B,qDAAmC;AACnC,mDAAiC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-captable-protocol/canton",
3
- "version": "0.0.29",
3
+ "version": "0.0.31",
4
4
  "description": "A TypeScript SDK for interacting with the Open CapTable Protocol (OCP) Factory contract on Canton blockchain",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -13,13 +13,14 @@
13
13
  "dev": "tsc --watch",
14
14
  "clean": "rm -rf dist",
15
15
  "script:authorize": "ts-node scripts/authorizeIssuer.ts",
16
- "script:create-issuer": "ts-node scripts/createIssuer.ts"
16
+ "script:create-issuer": "ts-node scripts/createIssuer.ts",
17
+ "script:get-issuer-ocf": "ts-node scripts/getIssuerAsOcf.ts"
17
18
  },
18
19
  "dependencies": {
19
20
  "@daml/ledger": "^2.10.2",
20
21
  "@daml/types": "^2.10.2",
21
22
  "@fairmint/canton-node-sdk": "^0.0.85",
22
- "@fairmint/open-captable-protocol-daml-js": "^0.0.35"
23
+ "@fairmint/open-captable-protocol-daml-js": "^0.0.36"
23
24
  },
24
25
 
25
26
  "devDependencies": {