@robosystems/client 2.38.1 → 2.39.1

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.
Files changed (59) hide show
  1. package/artifacts/InvestorClient.d.ts +4 -2
  2. package/artifacts/InvestorClient.js +4 -2
  3. package/artifacts/InvestorClient.ts +4 -2
  4. package/artifacts/LedgerClient.d.ts +31 -23
  5. package/artifacts/LedgerClient.js +27 -19
  6. package/artifacts/LedgerClient.ts +34 -26
  7. package/artifacts/LibraryClient.d.ts +4 -4
  8. package/artifacts/LibraryClient.js +4 -4
  9. package/artifacts/LibraryClient.ts +5 -5
  10. package/artifacts/OperatorClient.d.ts +2 -2
  11. package/artifacts/OperatorClient.js +2 -2
  12. package/artifacts/OperatorClient.ts +2 -2
  13. package/artifacts/graphql/queries/ledger/flowCandidates.d.ts +1 -1
  14. package/artifacts/graphql/queries/ledger/flowCandidates.js +1 -1
  15. package/artifacts/graphql/queries/ledger/flowCandidates.ts +1 -1
  16. package/artifacts/graphql/queries/ledger/informationBlock.d.ts +3 -5
  17. package/artifacts/graphql/queries/ledger/informationBlock.js +3 -5
  18. package/artifacts/graphql/queries/ledger/informationBlock.ts +3 -5
  19. package/artifacts/graphql/queries/ledger/mappedTrialBalance.d.ts +1 -1
  20. package/artifacts/graphql/queries/ledger/mappedTrialBalance.js +1 -1
  21. package/artifacts/graphql/queries/ledger/mappedTrialBalance.ts +1 -1
  22. package/artifacts/graphql/queries/ledger/mappingCoverage.d.ts +1 -1
  23. package/artifacts/graphql/queries/ledger/mappingCoverage.js +1 -1
  24. package/artifacts/graphql/queries/ledger/mappingCoverage.ts +1 -1
  25. package/artifacts/graphql/queries/ledger/reportDownloadUrl.d.ts +3 -2
  26. package/artifacts/graphql/queries/ledger/reportDownloadUrl.js +3 -2
  27. package/artifacts/graphql/queries/ledger/reportDownloadUrl.ts +3 -2
  28. package/artifacts/graphql/queries/ledger/reportingTaxonomy.d.ts +3 -3
  29. package/artifacts/graphql/queries/ledger/reportingTaxonomy.js +3 -3
  30. package/artifacts/graphql/queries/ledger/reportingTaxonomy.ts +3 -3
  31. package/artifacts/graphql/queries/ledger/statement.d.ts +5 -4
  32. package/artifacts/graphql/queries/ledger/statement.js +5 -4
  33. package/artifacts/graphql/queries/ledger/statement.ts +5 -4
  34. package/artifacts/graphql/queries/ledger/structures.d.ts +1 -1
  35. package/artifacts/graphql/queries/ledger/structures.js +1 -1
  36. package/artifacts/graphql/queries/ledger/structures.ts +1 -1
  37. package/artifacts/graphql/queries/ledger/unmappedElements.d.ts +1 -1
  38. package/artifacts/graphql/queries/ledger/unmappedElements.js +1 -1
  39. package/artifacts/graphql/queries/ledger/unmappedElements.ts +1 -1
  40. package/artifacts/graphql/queries/library/arcs.d.ts +1 -1
  41. package/artifacts/graphql/queries/library/arcs.js +1 -1
  42. package/artifacts/graphql/queries/library/arcs.ts +1 -1
  43. package/artifacts/graphql/queries/library/elements.d.ts +1 -1
  44. package/artifacts/graphql/queries/library/elements.js +1 -1
  45. package/artifacts/graphql/queries/library/elements.ts +1 -1
  46. package/artifacts/hooks.d.ts +8 -8
  47. package/artifacts/hooks.js +8 -8
  48. package/artifacts/hooks.ts +8 -8
  49. package/package.json +1 -1
  50. package/sdk/sdk.gen.d.ts +15 -15
  51. package/sdk/sdk.gen.js +15 -15
  52. package/sdk/sdk.gen.ts +15 -15
  53. package/sdk/types.gen.d.ts +77 -68
  54. package/sdk/types.gen.ts +77 -68
  55. package/sdk.gen.d.ts +15 -15
  56. package/sdk.gen.js +15 -15
  57. package/sdk.gen.ts +15 -15
  58. package/types.gen.d.ts +77 -68
  59. package/types.gen.ts +77 -68
@@ -6,7 +6,7 @@ const graphql_request_1 = require("graphql-request");
6
6
  * Trial balance rolled up to reporting concepts via a mapping structure.
7
7
  *
8
8
  * Unlike `trialBalance`, which groups by raw CoA account, this query
9
- * groups by the US GAAP reporting concept each account maps to. Used
9
+ * groups by the reporting concept (rs-gaap) each account maps to. Used
10
10
  * by the report builder to preview what a generated statement will
11
11
  * look like before materializing it.
12
12
  */
@@ -4,7 +4,7 @@ import { gql } from 'graphql-request'
4
4
  * Trial balance rolled up to reporting concepts via a mapping structure.
5
5
  *
6
6
  * Unlike `trialBalance`, which groups by raw CoA account, this query
7
- * groups by the US GAAP reporting concept each account maps to. Used
7
+ * groups by the reporting concept (rs-gaap) each account maps to. Used
8
8
  * by the report builder to preview what a generated statement will
9
9
  * look like before materializing it.
10
10
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
- * CoA → GAAP mapping coverage stats. Used by the MappingAgent to
2
+ * CoA → GAAP mapping coverage stats. Used by the mapping operator to
3
3
  * decide "am I done yet?" and by the close screen to show progress.
4
4
  */
5
5
  export declare const GET_MAPPING_COVERAGE: string;
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GET_MAPPING_COVERAGE = void 0;
4
4
  const graphql_request_1 = require("graphql-request");
5
5
  /**
6
- * CoA → GAAP mapping coverage stats. Used by the MappingAgent to
6
+ * CoA → GAAP mapping coverage stats. Used by the mapping operator to
7
7
  * decide "am I done yet?" and by the close screen to show progress.
8
8
  */
9
9
  exports.GET_MAPPING_COVERAGE = (0, graphql_request_1.gql) `
@@ -1,7 +1,7 @@
1
1
  import { gql } from 'graphql-request'
2
2
 
3
3
  /**
4
- * CoA → GAAP mapping coverage stats. Used by the MappingAgent to
4
+ * CoA → GAAP mapping coverage stats. Used by the mapping operator to
5
5
  * decide "am I done yet?" and by the close screen to show progress.
6
6
  */
7
7
  export const GET_MAPPING_COVERAGE = gql`
@@ -4,8 +4,9 @@
4
4
  * Replaces the retired `GET .../reports/{id}/download` REST resource — a
5
5
  * download is a read of stored state, so it lives on the read surface.
6
6
  * Every flavor resolves to a short-lived presigned S3 URL the client
7
- * follows directly (the Tavi compiled model is stamped at publish time;
8
- * the holon and XBRL are materialized + cached on first request).
7
+ * follows directly (the holon is stamped at publish time; the Tavi
8
+ * compiled model, the XBRL and the holon with lineage are materialized +
9
+ * cached on first request).
9
10
  * `format` accepts the `ReportDownloadFormat` enum (`TAVI`,
10
11
  * `HOLON_JSONLD`, `HOLON_JSONLD_LINEAGE`, `XBRL_2_1`).
11
12
  */
@@ -8,8 +8,9 @@ const graphql_request_1 = require("graphql-request");
8
8
  * Replaces the retired `GET .../reports/{id}/download` REST resource — a
9
9
  * download is a read of stored state, so it lives on the read surface.
10
10
  * Every flavor resolves to a short-lived presigned S3 URL the client
11
- * follows directly (the Tavi compiled model is stamped at publish time;
12
- * the holon and XBRL are materialized + cached on first request).
11
+ * follows directly (the holon is stamped at publish time; the Tavi
12
+ * compiled model, the XBRL and the holon with lineage are materialized +
13
+ * cached on first request).
13
14
  * `format` accepts the `ReportDownloadFormat` enum (`TAVI`,
14
15
  * `HOLON_JSONLD`, `HOLON_JSONLD_LINEAGE`, `XBRL_2_1`).
15
16
  */
@@ -6,8 +6,9 @@ import { gql } from 'graphql-request'
6
6
  * Replaces the retired `GET .../reports/{id}/download` REST resource — a
7
7
  * download is a read of stored state, so it lives on the read surface.
8
8
  * Every flavor resolves to a short-lived presigned S3 URL the client
9
- * follows directly (the Tavi compiled model is stamped at publish time;
10
- * the holon and XBRL are materialized + cached on first request).
9
+ * follows directly (the holon is stamped at publish time; the Tavi
10
+ * compiled model, the XBRL and the holon with lineage are materialized +
11
+ * cached on first request).
11
12
  * `format` accepts the `ReportDownloadFormat` enum (`TAVI`,
12
13
  * `HOLON_JSONLD`, `HOLON_JSONLD_LINEAGE`, `XBRL_2_1`).
13
14
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
- * The locked US GAAP reporting taxonomy for this graph (or null if
3
- * not loaded yet). This is the shared SFAC 6 → us-gaap hierarchy that
4
- * all reporting statements roll up through.
2
+ * The locked US GAAP (`us-gaap`) reporting taxonomy for this graph, or
3
+ * null when the graph carries none. Statements render through rs-gaap,
4
+ * the canonical reporting framework, not through this taxonomy.
5
5
  */
6
6
  export declare const GET_REPORTING_TAXONOMY: string;
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.GET_REPORTING_TAXONOMY = void 0;
4
4
  const graphql_request_1 = require("graphql-request");
5
5
  /**
6
- * The locked US GAAP reporting taxonomy for this graph (or null if
7
- * not loaded yet). This is the shared SFAC 6 → us-gaap hierarchy that
8
- * all reporting statements roll up through.
6
+ * The locked US GAAP (`us-gaap`) reporting taxonomy for this graph, or
7
+ * null when the graph carries none. Statements render through rs-gaap,
8
+ * the canonical reporting framework, not through this taxonomy.
9
9
  */
10
10
  exports.GET_REPORTING_TAXONOMY = (0, graphql_request_1.gql) `
11
11
  query GetLedgerReportingTaxonomy {
@@ -1,9 +1,9 @@
1
1
  import { gql } from 'graphql-request'
2
2
 
3
3
  /**
4
- * The locked US GAAP reporting taxonomy for this graph (or null if
5
- * not loaded yet). This is the shared SFAC 6 → us-gaap hierarchy that
6
- * all reporting statements roll up through.
4
+ * The locked US GAAP (`us-gaap`) reporting taxonomy for this graph, or
5
+ * null when the graph carries none. Statements render through rs-gaap,
6
+ * the canonical reporting framework, not through this taxonomy.
7
7
  */
8
8
  export const GET_REPORTING_TAXONOMY = gql`
9
9
  query GetLedgerReportingTaxonomy {
@@ -1,9 +1,10 @@
1
1
  /**
2
2
  * Render a financial statement for a report + block_type.
3
3
  *
4
- * Structure types: `income_statement`, `balance_sheet`,
5
- * `equity_statement`, `custom`. Returns hierarchically-ordered rows
6
- * (with depth + subtotal flags) plus the guardrail validation result.
7
- * The caller usually renders `rows` directly as a nested tree.
4
+ * Block types: `income_statement`, `balance_sheet`,
5
+ * `cash_flow_statement`, `equity_statement`; null when the report has no
6
+ * structure of that type. Returns hierarchically-ordered rows (with depth
7
+ * + subtotal flags) plus the guardrail validation result. The caller
8
+ * usually renders `rows` directly as a nested tree.
8
9
  */
9
10
  export declare const GET_STATEMENT: string;
@@ -5,10 +5,11 @@ const graphql_request_1 = require("graphql-request");
5
5
  /**
6
6
  * Render a financial statement for a report + block_type.
7
7
  *
8
- * Structure types: `income_statement`, `balance_sheet`,
9
- * `equity_statement`, `custom`. Returns hierarchically-ordered rows
10
- * (with depth + subtotal flags) plus the guardrail validation result.
11
- * The caller usually renders `rows` directly as a nested tree.
8
+ * Block types: `income_statement`, `balance_sheet`,
9
+ * `cash_flow_statement`, `equity_statement`; null when the report has no
10
+ * structure of that type. Returns hierarchically-ordered rows (with depth
11
+ * + subtotal flags) plus the guardrail validation result. The caller
12
+ * usually renders `rows` directly as a nested tree.
12
13
  */
13
14
  exports.GET_STATEMENT = (0, graphql_request_1.gql) `
14
15
  query GetLedgerStatement($reportId: String!, $blockType: String!) {
@@ -3,10 +3,11 @@ import { gql } from 'graphql-request'
3
3
  /**
4
4
  * Render a financial statement for a report + block_type.
5
5
  *
6
- * Structure types: `income_statement`, `balance_sheet`,
7
- * `equity_statement`, `custom`. Returns hierarchically-ordered rows
8
- * (with depth + subtotal flags) plus the guardrail validation result.
9
- * The caller usually renders `rows` directly as a nested tree.
6
+ * Block types: `income_statement`, `balance_sheet`,
7
+ * `cash_flow_statement`, `equity_statement`; null when the report has no
8
+ * structure of that type. Returns hierarchically-ordered rows (with depth
9
+ * + subtotal flags) plus the guardrail validation result. The caller
10
+ * usually renders `rows` directly as a nested tree.
10
11
  */
11
12
  export const GET_STATEMENT = gql`
12
13
  query GetLedgerStatement($reportId: String!, $blockType: String!) {
@@ -1,5 +1,5 @@
1
1
  /**
2
2
  * Structures list. Optional filters narrow by taxonomy or structure type
3
- * (e.g. "coa_mapping", "statement_income", "schedule").
3
+ * (e.g. "coa_mapping", "income_statement", "schedule").
4
4
  */
5
5
  export declare const LIST_STRUCTURES: string;
@@ -4,7 +4,7 @@ exports.LIST_STRUCTURES = void 0;
4
4
  const graphql_request_1 = require("graphql-request");
5
5
  /**
6
6
  * Structures list. Optional filters narrow by taxonomy or structure type
7
- * (e.g. "coa_mapping", "statement_income", "schedule").
7
+ * (e.g. "coa_mapping", "income_statement", "schedule").
8
8
  */
9
9
  exports.LIST_STRUCTURES = (0, graphql_request_1.gql) `
10
10
  query ListLedgerStructures($taxonomyId: String, $blockType: String) {
@@ -2,7 +2,7 @@ import { gql } from 'graphql-request'
2
2
 
3
3
  /**
4
4
  * Structures list. Optional filters narrow by taxonomy or structure type
5
- * (e.g. "coa_mapping", "statement_income", "schedule").
5
+ * (e.g. "coa_mapping", "income_statement", "schedule").
6
6
  */
7
7
  export const LIST_STRUCTURES = gql`
8
8
  query ListLedgerStructures($taxonomyId: String, $blockType: String) {
@@ -3,6 +3,6 @@
3
3
  *
4
4
  * Optional `mappingId` scopes the check to a single mapping structure;
5
5
  * when omitted, checks across all mapping structures. Used by the
6
- * MappingAgent workflow and the manual mapping UI.
6
+ * mapping operator workflow and the manual mapping UI.
7
7
  */
8
8
  export declare const LIST_UNMAPPED_ELEMENTS: string;
@@ -7,7 +7,7 @@ const graphql_request_1 = require("graphql-request");
7
7
  *
8
8
  * Optional `mappingId` scopes the check to a single mapping structure;
9
9
  * when omitted, checks across all mapping structures. Used by the
10
- * MappingAgent workflow and the manual mapping UI.
10
+ * mapping operator workflow and the manual mapping UI.
11
11
  */
12
12
  exports.LIST_UNMAPPED_ELEMENTS = (0, graphql_request_1.gql) `
13
13
  query ListLedgerUnmappedElements($mappingId: String) {
@@ -5,7 +5,7 @@ import { gql } from 'graphql-request'
5
5
  *
6
6
  * Optional `mappingId` scopes the check to a single mapping structure;
7
7
  * when omitted, checks across all mapping structures. Used by the
8
- * MappingAgent workflow and the manual mapping UI.
8
+ * mapping operator workflow and the manual mapping UI.
9
9
  */
10
10
  export const LIST_UNMAPPED_ELEMENTS = gql`
11
11
  query ListLedgerUnmappedElements($mappingId: String) {
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * List every arc contributed by a taxonomy (via its structures) + the
3
3
  * total count in one round-trip. For mapping taxonomies
4
- * (fac-to-rs-gaap, sfac6-to-fac, type-subtype) this is the primary
4
+ * (fac-to-rs-gaap, rs-gaap-type-subtype, rs-gaap-calculations) this is the primary
5
5
  * browse view — the arcs ARE what the taxonomy contributes.
6
6
  */
7
7
  export declare const LIST_LIBRARY_TAXONOMY_ARCS: string;
@@ -5,7 +5,7 @@ const graphql_request_1 = require("graphql-request");
5
5
  /**
6
6
  * List every arc contributed by a taxonomy (via its structures) + the
7
7
  * total count in one round-trip. For mapping taxonomies
8
- * (fac-to-rs-gaap, sfac6-to-fac, type-subtype) this is the primary
8
+ * (fac-to-rs-gaap, rs-gaap-type-subtype, rs-gaap-calculations) this is the primary
9
9
  * browse view — the arcs ARE what the taxonomy contributes.
10
10
  */
11
11
  exports.LIST_LIBRARY_TAXONOMY_ARCS = (0, graphql_request_1.gql) `
@@ -3,7 +3,7 @@ import { gql } from 'graphql-request'
3
3
  /**
4
4
  * List every arc contributed by a taxonomy (via its structures) + the
5
5
  * total count in one round-trip. For mapping taxonomies
6
- * (fac-to-rs-gaap, sfac6-to-fac, type-subtype) this is the primary
6
+ * (fac-to-rs-gaap, rs-gaap-type-subtype, rs-gaap-calculations) this is the primary
7
7
  * browse view — the arcs ARE what the taxonomy contributes.
8
8
  */
9
9
  export const LIST_LIBRARY_TAXONOMY_ARCS = gql`
@@ -18,7 +18,7 @@ export declare const LIST_LIBRARY_ELEMENTS: string;
18
18
  */
19
19
  export declare const SEARCH_LIBRARY_ELEMENTS: string;
20
20
  /**
21
- * Get a single element by id or by qname ('sfac6:Assets', etc).
21
+ * Get a single element by id or by qname ('rs-gaap:Assets', etc).
22
22
  * Returns null when neither identifier resolves.
23
23
  */
24
24
  export declare const GET_LIBRARY_ELEMENT: string;
@@ -100,7 +100,7 @@ exports.SEARCH_LIBRARY_ELEMENTS = (0, graphql_request_1.gql) `
100
100
  }
101
101
  `;
102
102
  /**
103
- * Get a single element by id or by qname ('sfac6:Assets', etc).
103
+ * Get a single element by id or by qname ('rs-gaap:Assets', etc).
104
104
  * Returns null when neither identifier resolves.
105
105
  */
106
106
  exports.GET_LIBRARY_ELEMENT = (0, graphql_request_1.gql) `
@@ -100,7 +100,7 @@ export const SEARCH_LIBRARY_ELEMENTS = gql`
100
100
  `
101
101
 
102
102
  /**
103
- * Get a single element by id or by qname ('sfac6:Assets', etc).
103
+ * Get a single element by id or by qname ('rs-gaap:Assets', etc).
104
104
  * Returns null when neither identifier resolves.
105
105
  */
106
106
  export const GET_LIBRARY_ELEMENT = gql`
@@ -10,7 +10,7 @@ import { QueryClient } from './QueryClient';
10
10
  * const { execute, loading, error, data } = useQuery('graph_123')
11
11
  *
12
12
  * const handleSearch = async () => {
13
- * const result = await execute('MATCH (n:Company) RETURN n LIMIT 10')
13
+ * const result = await execute('MATCH (e:Entity) RETURN e.name LIMIT 10')
14
14
  * console.log(result.data)
15
15
  * }
16
16
  * ```
@@ -50,11 +50,11 @@ export declare function useStreamingQuery(graphId: string): {
50
50
  *
51
51
  * @example
52
52
  * ```tsx
53
- * const { monitor, status, progress, error, result } = useOperation<BackupResult>()
53
+ * const { monitor, status, progress, error, result } = useOperation()
54
54
  *
55
55
  * const handleBackup = async () => {
56
- * const { operation_id } = await createBackup({ ... })
57
- * const result = await monitor(operation_id)
56
+ * const { data } = await createBackup({ path: { graph_id: graphId }, body: { ... } })
57
+ * const result = await monitor(data!.operationId)
58
58
  * console.log('Backup completed:', result)
59
59
  * }
60
60
  * ```
@@ -75,12 +75,12 @@ export declare function useOperation<T = any>(operationId?: string): {
75
75
  * const { monitorAll, results, allCompleted, hasErrors } = useMultipleOperations()
76
76
  *
77
77
  * const handleMultiple = async () => {
78
- * const operations = await Promise.all([
79
- * createBackup(...),
80
- * createExport(...),
78
+ * const responses = await Promise.all([
79
+ * createBackup({ path: { graph_id: graphA }, body: { ... } }),
80
+ * materialize({ path: { graph_id: graphB }, body: {} }),
81
81
  * ])
82
82
  *
83
- * const results = await monitorAll(operations.map(op => op.operation_id))
83
+ * const results = await monitorAll(responses.map(({ data }) => data!.operationId))
84
84
  * }
85
85
  * ```
86
86
  */
@@ -23,7 +23,7 @@ const QueryClient_1 = require("./QueryClient");
23
23
  * const { execute, loading, error, data } = useQuery('graph_123')
24
24
  *
25
25
  * const handleSearch = async () => {
26
- * const result = await execute('MATCH (n:Company) RETURN n LIMIT 10')
26
+ * const result = await execute('MATCH (e:Entity) RETURN e.name LIMIT 10')
27
27
  * console.log(result.data)
28
28
  * }
29
29
  * ```
@@ -179,11 +179,11 @@ function useStreamingQuery(graphId) {
179
179
  *
180
180
  * @example
181
181
  * ```tsx
182
- * const { monitor, status, progress, error, result } = useOperation<BackupResult>()
182
+ * const { monitor, status, progress, error, result } = useOperation()
183
183
  *
184
184
  * const handleBackup = async () => {
185
- * const { operation_id } = await createBackup({ ... })
186
- * const result = await monitor(operation_id)
185
+ * const { data } = await createBackup({ path: { graph_id: graphId }, body: { ... } })
186
+ * const result = await monitor(data!.operationId)
187
187
  * console.log('Backup completed:', result)
188
188
  * }
189
189
  * ```
@@ -280,12 +280,12 @@ function useOperation(operationId) {
280
280
  * const { monitorAll, results, allCompleted, hasErrors } = useMultipleOperations()
281
281
  *
282
282
  * const handleMultiple = async () => {
283
- * const operations = await Promise.all([
284
- * createBackup(...),
285
- * createExport(...),
283
+ * const responses = await Promise.all([
284
+ * createBackup({ path: { graph_id: graphA }, body: { ... } }),
285
+ * materialize({ path: { graph_id: graphB }, body: {} }),
286
286
  * ])
287
287
  *
288
- * const results = await monitorAll(operations.map(op => op.operation_id))
288
+ * const results = await monitorAll(responses.map(({ data }) => data!.operationId))
289
289
  * }
290
290
  * ```
291
291
  */
@@ -21,7 +21,7 @@ import { QueryClient } from './QueryClient'
21
21
  * const { execute, loading, error, data } = useQuery('graph_123')
22
22
  *
23
23
  * const handleSearch = async () => {
24
- * const result = await execute('MATCH (n:Company) RETURN n LIMIT 10')
24
+ * const result = await execute('MATCH (e:Entity) RETURN e.name LIMIT 10')
25
25
  * console.log(result.data)
26
26
  * }
27
27
  * ```
@@ -215,11 +215,11 @@ export function useStreamingQuery(graphId: string) {
215
215
  *
216
216
  * @example
217
217
  * ```tsx
218
- * const { monitor, status, progress, error, result } = useOperation<BackupResult>()
218
+ * const { monitor, status, progress, error, result } = useOperation()
219
219
  *
220
220
  * const handleBackup = async () => {
221
- * const { operation_id } = await createBackup({ ... })
222
- * const result = await monitor(operation_id)
221
+ * const { data } = await createBackup({ path: { graph_id: graphId }, body: { ... } })
222
+ * const result = await monitor(data!.operationId)
223
223
  * console.log('Backup completed:', result)
224
224
  * }
225
225
  * ```
@@ -330,12 +330,12 @@ export function useOperation<T = any>(operationId?: string) {
330
330
  * const { monitorAll, results, allCompleted, hasErrors } = useMultipleOperations()
331
331
  *
332
332
  * const handleMultiple = async () => {
333
- * const operations = await Promise.all([
334
- * createBackup(...),
335
- * createExport(...),
333
+ * const responses = await Promise.all([
334
+ * createBackup({ path: { graph_id: graphA }, body: { ... } }),
335
+ * materialize({ path: { graph_id: graphB }, body: {} }),
336
336
  * ])
337
337
  *
338
- * const results = await monitorAll(operations.map(op => op.operation_id))
338
+ * const results = await monitorAll(responses.map(({ data }) => data!.operationId))
339
339
  * }
340
340
  * ```
341
341
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robosystems/client",
3
- "version": "2.38.1",
3
+ "version": "2.39.1",
4
4
  "description": "TypeScript SDK for RoboSystems, the open-source knowledge graph for finance",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
package/sdk/sdk.gen.d.ts CHANGED
@@ -364,7 +364,7 @@ export declare const listOperators: <ThrowOnError extends boolean = false>(optio
364
364
  /**
365
365
  * Auto-select Operator for Query
366
366
  *
367
- * Routes to the best operator for your query. Operators: `analyst` (answers natural-language questions over the graph — curated financial reads, documents, memory, and read-only Cypher; supports `quick`, `standard`, `extended`; `cypher` is accepted as its former name) and `mapping` (autonomous Chart of Accounts → rs-gaap mapping; roboledger graphs only, `extended` only). `GET /v1/graphs/{graph_id}/operator` lists what is registered. Credits are consumed by actual token usage, not a fixed price per mode. The run executes on the background worker: the default answer is 202 with the operation's `_links` (stream, status, cancel); `?mode=sync` waits up to 50s and answers 200 with the result.
367
+ * Routes to the best operator for your query. Operators: `analyst` (answers natural-language questions over the graph — curated financial reads, documents, memory, and read-only Cypher; supports `quick`, `standard`, `extended`; `cypher` is accepted as its former name) and `mapping` (automatic Chart of Accounts → rs-gaap mapping; roboledger graphs only, `extended` only). `author` makes writes, so it is never chosen here: call it by name. `GET /v1/graphs/{graph_id}/operator` lists what is registered. Credits are consumed by actual token usage, not a fixed price per mode. The run executes on the background worker: the default answer is 202 with the operation's `_links` (stream, status, cancel); `?mode=sync` waits up to 50s and answers 200 with the result.
368
368
  */
369
369
  export declare const autoSelectOperator: <ThrowOnError extends boolean = false>(options: Options<AutoSelectOperatorData, ThrowOnError>) => RequestResult<AutoSelectOperatorResponses, AutoSelectOperatorErrors, ThrowOnError>;
370
370
  /**
@@ -374,7 +374,7 @@ export declare const getOperatorMetadata: <ThrowOnError extends boolean = false>
374
374
  /**
375
375
  * Execute Specific Operator
376
376
  *
377
- * Available: `analyst` (natural-language questions over the graph — curated financial reads, documents, memory, and read-only Cypher; RAG retrieval is one of its capabilities, not a separate operator; `cypher` is accepted as its former name) and `mapping` (Chart of Accounts → rs-gaap mapping, roboledger graphs only). `GET /v1/graphs/{graph_id}/operator` lists what is registered. The run executes on the background worker: the default answer is 202 with the operation's `_links` (stream, status, cancel); `?mode=sync` waits up to 50s and answers 200 with the result.
377
+ * Available: `analyst` (natural-language questions over the graph — curated financial reads, documents, memory, and read-only Cypher; RAG retrieval is one of its capabilities, not a separate operator; `cypher` is accepted as its former name), `mapping` (Chart of Accounts → rs-gaap mapping, roboledger graphs only) and `author` (makes the change a request asks for, such as metric and forecast blocks, counterparties, memories, draft reports and inbox classifications, through writes that are reversible or wait on a person's step; needs write access to the graph). `GET /v1/graphs/{graph_id}/operator` lists what is registered. The run executes on the background worker: the default answer is 202 with the operation's `_links` (stream, status, cancel); `?mode=sync` waits up to 50s and answers 200 with the result.
378
378
  */
379
379
  export declare const executeSpecificOperator: <ThrowOnError extends boolean = false>(options: Options<ExecuteSpecificOperatorData, ThrowOnError>) => RequestResult<ExecuteSpecificOperatorResponses, ExecuteSpecificOperatorErrors, ThrowOnError>;
380
380
  /**
@@ -526,7 +526,7 @@ export declare const createRepositorySubscription: <ThrowOnError extends boolean
526
526
  /**
527
527
  * End Repository Trial
528
528
  *
529
- * End your free trial of a shared repository now and start the paid plan. The first period is charged to the payment method on file; raw queries, the AI analyst and the plan's credits open once the payment clears, usually within a minute. Returns 400 when the subscription is not on a trial.
529
+ * End your free trial of a shared repository now and start the paid plan. The first period is charged to the payment method on file; raw queries, the AI analyst and the plan's credits open once the payment clears, usually within a minute. Returns 400 when the subscription is not on a trial, or when no payment method is on file yet.
530
530
  */
531
531
  export declare const endRepositorySubscriptionTrial: <ThrowOnError extends boolean = false>(options: Options<EndRepositorySubscriptionTrialData, ThrowOnError>) => RequestResult<EndRepositorySubscriptionTrialResponses, EndRepositorySubscriptionTrialErrors, ThrowOnError>;
532
532
  /**
@@ -828,7 +828,7 @@ export declare const getOrgUpcomingInvoice: <ThrowOnError extends boolean = fals
828
828
  /**
829
829
  * Create Payment Checkout Session
830
830
  *
831
- * Initiates a Stripe checkout session for payment collection. Creates a pending subscription; the webhook activates it and provisions the resource after payment completes. Returns billing_disabled=true with no URL when billing is off. Requires org owner role.
831
+ * Initiates a Stripe checkout session for payment collection. Creates a pending subscription; the webhook activates it and provisions the resource after payment completes. Returns billing_disabled=true with no URL when billing is off. Requires org owner role. A repository's free trial asks for no card but needs a verified email: an unverified account starting one gets 403.
832
832
  */
833
833
  export declare const createCheckoutSession: <ThrowOnError extends boolean = false>(options: Options<CreateCheckoutSessionData, ThrowOnError>) => RequestResult<CreateCheckoutSessionResponses, CreateCheckoutSessionErrors, ThrowOnError>;
834
834
  /**
@@ -886,7 +886,7 @@ export declare const changeCalendarStart: <ThrowOnError extends boolean = false>
886
886
  /**
887
887
  * Initialize Chart of Accounts
888
888
  *
889
- * Create the graph's chart of accounts from a shipped template — the fresh-company path to native books. Use when the graph has NO chart (a QuickBooks-synced tenant never needs this: its chart arrives with the sync and stays after a sever) and before connecting a bank feed, which needs a chart to resolve against. Templates: `saas` (subscription software), `services` (professional services), `product` (inventory and COGS) — the `chartTemplates` GraphQL field lists them with names and account counts. Creates the chart, its `coa_mapping` structure and the template's CoA → rs-gaap mapping associations in one transaction, with the equity rows mapped by the entity's legal form (`entity_type`, defaulting to the entity's). Each entity of the group keeps its own chart: `entity_id` names a subsidiary, omitted means the group parent. One-time per entity: 409 once that entity has a chart — a chart is never replaced. Customize afterwards with update-taxonomy-block; accounts that carry activity are never deleted.
889
+ * Create the graph's chart of accounts from a shipped template — the fresh-company path to native books. Use when the graph has NO chart (a QuickBooks-synced tenant never needs this: its chart arrives with the sync and stays after a sever) and before connecting a bank feed, which needs a chart to resolve against. Templates: `saas` (subscription software), `services` (professional services), `product` (inventory and COGS), `consolidation` (a group's consolidation entity — the adjustments column, never an operating company's chart). Creates the chart, its `coa_mapping` structure and the template's CoA → rs-gaap mapping associations in one transaction, with the equity rows mapped by the entity's legal form (`entity_type`, defaulting to the entity's). Each entity of the group keeps its own chart: `entity_id` names a subsidiary, omitted means the group parent. One-time per entity: 409 once that entity has a chart — a chart is never replaced. Customize afterwards with update-taxonomy-block; accounts that carry activity are never deleted.
890
890
  *
891
891
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
892
892
  */
@@ -918,7 +918,7 @@ export declare const changeReportingStyle: <ThrowOnError extends boolean = false
918
918
  /**
919
919
  * Link Bank Account
920
920
  *
921
- * Point a bank feed's account at a chart account. Name `element_id` for an existing active account, or `entity_id` alone to create one in that entity's chart. The chart the account is in decides whose books the feed's lines go into, so this is also how a feed account is bound to a subsidiary. Lines still in the inbox move with it (across an entity change their suggestion is resolved again on the new chart, and a classification that named the old entity's account is dropped); posted entries stay where they were posted. An account another connection already feeds is refused, as is an entity whose books QuickBooks keeps (the group parent, while QuickBooks is connected). An account the feed created and then left stays on its chart as an ordinary account. A sync already in flight when the link moves can still land a line or two on the old account; running this again moves them. Read the group's accounts with the `bankAccounts` GraphQL field.
921
+ * Point a bank feed's account at a chart account. Name `element_id` for an existing active account, or `entity_id` alone to create one in that entity's chart. The chart the account is in decides whose books the feed's lines go into, so this is also how a feed account is bound to a subsidiary. Lines still in the inbox move with it (across an entity change their suggestion is resolved again on the new chart, and a classification that named the old entity's account is dropped); posted entries stay where they were posted. An account another connection already feeds is refused, as is an entity whose books QuickBooks keeps (the group parent, while QuickBooks is connected). An account the feed created and then left stays on its chart as an ordinary account. A sync already in flight when the link moves can still land a line or two on the old account; running this again moves them. The group's accounts are `list-bank-accounts` over MCP and the `bankAccounts` GraphQL field.
922
922
  *
923
923
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
924
924
  */
@@ -966,7 +966,7 @@ export declare const createMappingAssociation: <ThrowOnError extends boolean = f
966
966
  /**
967
967
  * Delete Mapping Association
968
968
  *
969
- * Remove a single CoA → reporting-concept mapping edge by id. The mapping structure itself remains; only the association row is dropped. Use this to correct a wrong mapping — delete the bad edge, then `create-mapping-association` the right one. Find the association id via the `library_element_arcs` GraphQL field. Library-seeded rows cannot be deleted (403). An edge for an account with landed history in a closed month cannot be removed on its own (422): move the account with `create-mapping-association` and `replaces_association_id` instead.
969
+ * Remove a single CoA → reporting-concept mapping edge by id. The mapping structure itself remains; only the association row is dropped. Use this to correct a wrong mapping — delete the bad edge, then `create-mapping-association` the right one. The association id is `list-element-arcs` over MCP and the `libraryElementArcs` GraphQL field. Library-seeded rows cannot be deleted (403). An edge for an account with landed history in a closed month cannot be removed on its own (422): move the account with `create-mapping-association` and `replaces_association_id` instead.
970
970
  *
971
971
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
972
972
  */
@@ -982,7 +982,7 @@ export declare const autoMapElements: <ThrowOnError extends boolean = false>(opt
982
982
  /**
983
983
  * Create Information Block
984
984
  *
985
- * Generic Information Block construction entry. `block_type` selects the registered block type; `payload` is validated against that type's creation schema at dispatch. Schedule dispatches to the existing Schedule machinery; statement block types raise 501 (use create-report instead). Authoring schedules for a close? Call `get-close-playbook` (mode='initiate') first — one schedule is a single debit/credit element pair, so multi-line entries become multiple schedules, and element ids must be real (discover via get-graph-schema / get-unmapped-elements / suggest-mapping).
985
+ * Generic Information Block construction entry. `block_type` selects the registered block type; `payload` is validated against that type's creation schema at dispatch. Only schedule and forecast are constructed here; the other block types raise 501 with a hint naming their own operation (statements: create-report; disclosure and metric structures: create-taxonomy-block). Authoring schedules for a close? Call `get-close-playbook` (mode='initiate') first — one schedule is a single debit/credit element pair, so multi-line entries become multiple schedules, and element ids must be real (discover via get-graph-schema / get-unmapped-elements / suggest-mapping).
986
986
  *
987
987
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
988
988
  */
@@ -990,7 +990,7 @@ export declare const createInformationBlock: <ThrowOnError extends boolean = fal
990
990
  /**
991
991
  * Update Information Block
992
992
  *
993
- * Generic Information Block update entry. Dispatches by `block_type` to the registered mutation handler. Block types whose Structures are library-seeded and immutable (statement family) surface 501.
993
+ * Generic Information Block update entry. Dispatches by `block_type` to the registered mutation handler. Only schedule and forecast blocks update here; the statement family (library-seeded and immutable), disclosure, metric and reconciliation blocks surface 501 with a hint naming the operation that changes them.
994
994
  *
995
995
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
996
996
  */
@@ -998,7 +998,7 @@ export declare const updateInformationBlock: <ThrowOnError extends boolean = fal
998
998
  /**
999
999
  * Delete Information Block
1000
1000
  *
1001
- * Generic Information Block deletion entry. Returns a thin confirmation (deleted / structure_id / block_type / name). Block types whose Structures are library-seeded cannot be deleted per tenant and surface 501.
1001
+ * Generic Information Block deletion entry. Returns a thin confirmation (deleted / structure_id / block_type / name). Only schedule and forecast blocks delete here; statement, disclosure, metric and reconciliation blocks surface 501 with a hint naming the operation that manages them.
1002
1002
  *
1003
1003
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1004
1004
  */
@@ -1030,7 +1030,7 @@ export declare const assertMetrics: <ThrowOnError extends boolean = false>(optio
1030
1030
  /**
1031
1031
  * Compute Forecast for a Forecast Block
1032
1032
  *
1033
- * Walks a forecast block's driver cascade month-by-month forward from its base period: lever-driven rs-driver Derive rules in dependency order, carry-forward for unmodeled income-statement lines, calc-DAG subtotals — upserting one scenario income-statement FactSet (plus a working-capital balance-sheet set) per forward month, all keyed by the block's scenario_id (NULL = actuals; scenario reads pass it as a filter). Re-running replaces each month's values. Rules with missing lever months or unbound operands are skipped with a reason (their targets fall back to carry-forward), never errored. Deterministic and non-AI — no credits consumed.
1033
+ * Walks a forecast block's driver cascade month-by-month forward from its anchor (with base_anchor='seam', the default, the newest closed month inside the horizon; with 'fixed', the block's base_period): lever-driven rs-driver Derive rules in dependency order, carry-forward for unmodeled income-statement lines, calc-DAG subtotals — upserting per forward month a scenario income-statement FactSet, a balance-sheet set (the full roll when the anchor month has an actual balance sheet, else only the rule-driven working-capital instants) and a derived cash-flow set when an actual one exists, all keyed by the block's scenario_id (NULL = actuals; scenario reads pass it as a filter). Re-running replaces each month's values. Rules with missing lever months or unbound operands are skipped with a reason (their targets fall back to carry-forward). Each month's sets are verified; a month that fails halts the walk there (halted_at), since every later month would be derived from it. Deterministic and non-AI — no credits consumed.
1034
1034
  *
1035
1035
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1036
1036
  */
@@ -1110,7 +1110,7 @@ export declare const updateEventBlock: <ThrowOnError extends boolean = false>(op
1110
1110
  /**
1111
1111
  * Execute Event Block
1112
1112
  *
1113
- * For events on a connection with write_policy='qb_authoritative' or 'hybrid', publish the event's draft GL entries to the source-of-truth system (QuickBooks), each as its own JournalEntry. Records the QuickBooks ids per entry on event.metadata.qb_entry_ids and promotes the published entries to 'posted'; the event goes 'fulfilled' once no draft remains, or 'pending' on rejection (what landed is kept). Native-policy events fast-path through with no QB write — RoboSystems is the system of record. Only the group parent's books are QuickBooks': an event on a subsidiary's books is refused.
1113
+ * For events on a connection with write_policy='qb_authoritative' or 'hybrid', publish the event's draft GL entries to the source-of-truth system (QuickBooks), each as its own JournalEntry. Records the QuickBooks ids per entry on event.metadata.qb_entry_ids and promotes the published entries to 'posted'; the event goes 'fulfilled' once no draft remains. On rejection what landed is kept, the status is unchanged and the error is stamped on event.metadata.last_outbound_error (and returned as qb_error). Events on 'native' or 'shadow' books pass through with no QB write. Only the group parent's books are QuickBooks': an event on a subsidiary's books is refused.
1114
1114
  *
1115
1115
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1116
1116
  */
@@ -1302,7 +1302,7 @@ export declare const promoteObligations: <ThrowOnError extends boolean = false>(
1302
1302
  /**
1303
1303
  * Preview Schedule
1304
1304
  *
1305
- * Generate a schedule from a definition without keeping it: the same generator and guards as creating one (block_type='schedule' on create-information-block), run and rolled back. Returns the envelope create would leave (its ids provisional) and the period-by-period roll-forward: the balance the schedule carries on the account it credits (a loan's: the note), opening, the period's amount, closing, and for a loan the interest, payment, principal and current portion. Show it to the person before asking to create. A definition create would refuse (a roll-forward that climbs where it should fall, legs that do not balance) is refused here with the period that breaks. `warnings` names any active schedule already posting the same accounts in the same months. With `replaces_structure_id`, `replaces` says what the schedule being edited or recreated has posted, by month, and the path the change takes: `rebuild` (rebuild-schedule with the new definition) while nothing has posted, `terminate_and_succeed` after.
1305
+ * Generate a schedule from a definition without keeping it: the same generator and guards as creating one (block_type='schedule' on create-information-block), run and rolled back. Returns the envelope create would leave (its ids provisional) and the period-by-period roll-forward: the balance the schedule carries on the account it credits (a loan's: the note), opening, the period's amount, closing, and for a loan the interest, payment, principal and current portion. Show it to the person before asking to create. A definition create would refuse (a roll-forward that climbs where it should fall, legs that do not balance) is refused here with the period that breaks. `warnings` names any active schedule already posting the same accounts in the same months. With `replaces_structure_id`, `replaces` says what the schedule being edited or recreated has posted, by month, and the path the change takes: `rebuild` (the schedule regenerated in place from the new definition) while nothing has posted, `terminate_and_succeed` after.
1306
1306
  *
1307
1307
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1308
1308
  */
@@ -1406,7 +1406,7 @@ export declare const deletePublishList: <ThrowOnError extends boolean = false>(o
1406
1406
  /**
1407
1407
  * Add Members to Publish List
1408
1408
  *
1409
- * Add one or more recipient graphs to a publish list. Targets must exist and have the same extension enabled (e.g. roboledger). Self-graph rejected (422); already-member rejected (409).
1409
+ * Add one or more recipient graphs to a publish list. Targets must exist and carry the roboledger or roboinvestor extension. Self-graph rejected (422); already-member rejected (409).
1410
1410
  *
1411
1411
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1412
1412
  */
@@ -1542,7 +1542,7 @@ export declare const deletePortfolioBlock: <ThrowOnError extends boolean = false
1542
1542
  /**
1543
1543
  * Create Security
1544
1544
  *
1545
- * Register a security (common stock, preferred stock, warrant, convertible note, etc.) owned by this graph's entity. Optionally cross-links to an issuing entity in another graph via `source_graph_id` for mutual-handshake attribution.
1545
+ * Register a security (common stock, preferred stock, warrant, convertible note, etc.) in this graph's registry. Its `entity_id` is the issuer, not the holder; a portfolio's `entity_id` is the owner. Optionally cross-links to the issuer's own graph via `source_graph_id` for mutual-handshake attribution.
1546
1546
  *
1547
1547
  * **Idempotency**: supply an `Idempotency-Key` header to make safe retries; replays within 24 hours return the same envelope. Reusing the key with a different body returns HTTP 409 Conflict.
1548
1548
  */