@ixo/editor 6.21.0 → 6.23.0
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/action-manifest.json +613 -11
- package/dist/{chunk-EO2K4IDP.js → chunk-LBFFAKSN.js} +135 -22
- package/dist/chunk-LBFFAKSN.js.map +1 -0
- package/dist/{chunk-I4NSQ7X4.js → chunk-UIZV4YAW.js} +4264 -4043
- package/dist/chunk-UIZV4YAW.js.map +1 -0
- package/dist/{chunk-2WSXLAX5.js → chunk-VFYF2B5E.js} +5581 -2637
- package/dist/chunk-VFYF2B5E.js.map +1 -0
- package/dist/core/index.d.ts +479 -46
- package/dist/core/index.js +241 -3
- package/dist/core/index.js.map +1 -1
- package/dist/{graphql-client-j-P2Llxg.d.ts → graphql-client-DQD1v9Yw.d.ts} +10 -3
- package/dist/{index-BC4ycOwH.d.ts → index-x1R0c9P_.d.ts} +2616 -127
- package/dist/index.d.ts +3 -3
- package/dist/index.js +36 -3
- package/dist/index.js.map +1 -1
- package/dist/mantine/index.d.ts +116 -10
- package/dist/mantine/index.js +158 -37
- package/dist/mantine/index.js.map +1 -1
- package/dist/store-B60v3oba.d.ts +1026 -0
- package/package.json +2 -2
- package/dist/chunk-2WSXLAX5.js.map +0 -1
- package/dist/chunk-EO2K4IDP.js.map +0 -1
- package/dist/chunk-I4NSQ7X4.js.map +0 -1
- package/dist/store-Ba-HGtSG.d.ts +0 -2144
package/dist/core/index.js
CHANGED
|
@@ -1,55 +1,112 @@
|
|
|
1
1
|
import {
|
|
2
|
+
FLOW_PARTICIPANTS_MAP_KEY,
|
|
2
3
|
addFlowNode,
|
|
3
4
|
readFlowDocument,
|
|
5
|
+
readFlowParticipants,
|
|
4
6
|
removeFlowNode,
|
|
7
|
+
removeFlowParticipant,
|
|
5
8
|
reorderFlowNodes,
|
|
6
9
|
resetStepRuntime,
|
|
7
10
|
setBlockProps,
|
|
11
|
+
setFlowParticipantPowerLevel,
|
|
12
|
+
setFlowParticipantRequirements,
|
|
8
13
|
setFormAnswers,
|
|
9
14
|
swapFlowBlocks,
|
|
10
|
-
updateNodeRuntime
|
|
11
|
-
|
|
15
|
+
updateNodeRuntime,
|
|
16
|
+
upsertFlowParticipant
|
|
17
|
+
} from "../chunk-LBFFAKSN.js";
|
|
12
18
|
import {
|
|
19
|
+
ExplicitRunRequiredError,
|
|
20
|
+
FLOW_CONNECTIONS_MAP_KEY,
|
|
21
|
+
FLOW_CONNECTION_BINDINGS_MAP_KEY,
|
|
13
22
|
FlowAgentService,
|
|
23
|
+
FlowNotMigratedError,
|
|
24
|
+
INVOCATIONS_MAP_KEY,
|
|
25
|
+
InvalidConditionConfigError,
|
|
14
26
|
LATEST_VERSION,
|
|
27
|
+
LEGACY_RUN_STORAGE_VERSION,
|
|
28
|
+
MAX_RUN_ACTION_OUTPUT_BYTES,
|
|
29
|
+
MULTI_RUN_STORAGE_VERSION,
|
|
15
30
|
NODE_CONTEXT_MAP_NAME,
|
|
16
31
|
NODE_CONTEXT_OVERRIDES_MAP_NAME,
|
|
17
32
|
PROOF_MISSING_CODE,
|
|
33
|
+
RUNS_TERMINAL_MAP_KEY,
|
|
18
34
|
RUN_RECORD_AUDIT_TYPE,
|
|
35
|
+
RUN_STORAGE_VERSION_KEY,
|
|
36
|
+
RunLifecycleAuthorizationError,
|
|
37
|
+
RunNotMigratedError,
|
|
38
|
+
RunNotReadyError,
|
|
19
39
|
SERVICE_VERBS,
|
|
20
40
|
STEP_COMPLETED_EVENT,
|
|
21
41
|
STEP_COMPLETED_EVENT_NAME,
|
|
42
|
+
TerminalRunExecutionError,
|
|
43
|
+
UnknownRunError,
|
|
22
44
|
VERSION_MANIFEST,
|
|
45
|
+
XERO_TOOLKIT,
|
|
23
46
|
XERO_WORK_ITEMS_MAP_NAME,
|
|
24
47
|
XERO_WORK_TERMINAL_MAP_NAME,
|
|
25
48
|
acquireFlowAgentLease,
|
|
49
|
+
adoptLegacyRuntime,
|
|
26
50
|
appendAgentLedgerEvent,
|
|
27
51
|
appendRunRecord,
|
|
52
|
+
appendRunTimelineEvent,
|
|
53
|
+
appendRunTimelineEvents,
|
|
54
|
+
assertRunActionExecutionAllowed,
|
|
55
|
+
boundRunActionOutput,
|
|
56
|
+
boundRunEventJson,
|
|
57
|
+
buildActionRunInputs,
|
|
28
58
|
buildAuthzFromProps,
|
|
29
59
|
buildBlockConditionsProp,
|
|
30
60
|
buildFlowAgentContext,
|
|
31
61
|
buildFlowNodeFromBlock,
|
|
62
|
+
buildRunDefinitionSnapshot,
|
|
32
63
|
buildServicesFromHandlers,
|
|
33
64
|
buildXeroInvoiceWorkKey,
|
|
34
65
|
buildXeroPaymentWorkKey,
|
|
35
66
|
canMatches,
|
|
36
67
|
canToType,
|
|
68
|
+
cancelRun,
|
|
37
69
|
classifyBlockerCause,
|
|
38
70
|
classifyNodeState,
|
|
39
71
|
cleanupExpiredFlowAgentLeases,
|
|
72
|
+
clearAllActionState,
|
|
40
73
|
clearRuntimeForTemplateClone,
|
|
74
|
+
closeRun,
|
|
75
|
+
collectPhantomLegacyRun,
|
|
41
76
|
compileBaseUcanFlow,
|
|
42
77
|
computeAgentCommandId,
|
|
43
78
|
computePendingInvocationId,
|
|
79
|
+
computeRunDefinitionHash,
|
|
80
|
+
computeRunSummary,
|
|
81
|
+
countPendingInvocations,
|
|
44
82
|
createAgentCommand,
|
|
45
83
|
createInvocationStore,
|
|
46
84
|
createMemoryInvocationStore,
|
|
47
85
|
createMemoryUcanDelegationStore,
|
|
86
|
+
createReference,
|
|
87
|
+
createRunEventIdempotencyKey,
|
|
88
|
+
createRunId,
|
|
89
|
+
createRunRuntimeReader,
|
|
90
|
+
createRunRuntimeReaderWithDoc,
|
|
91
|
+
createRunScopedRuntimeManager,
|
|
92
|
+
createRunUlid,
|
|
48
93
|
createRuntimeStateManager,
|
|
49
94
|
createUcanDelegationStore,
|
|
50
95
|
createUcanService,
|
|
96
|
+
createYDocRuntimeManager,
|
|
51
97
|
decompileToBaseUcanFlow,
|
|
98
|
+
deleteActionState,
|
|
99
|
+
detectRunDefinitionDrift,
|
|
100
|
+
dispatchFlowStartTriggers,
|
|
101
|
+
doneWhenCompleted,
|
|
102
|
+
enableMultiRunStorage,
|
|
103
|
+
ensureRun,
|
|
104
|
+
evaluateBlockConditions,
|
|
105
|
+
evaluateBlockConditionsForRun,
|
|
106
|
+
evaluateBlockExecutionEligibilityForRun,
|
|
107
|
+
evaluateCondition,
|
|
52
108
|
evaluateFlowAgentPolicy,
|
|
109
|
+
executeActionBlock,
|
|
53
110
|
executeFlowAgentCoreCommand,
|
|
54
111
|
executeNode,
|
|
55
112
|
executeQueuedAgentCommands,
|
|
@@ -68,22 +125,37 @@ import {
|
|
|
68
125
|
getEventsForBlock,
|
|
69
126
|
getFlowAgentMaps,
|
|
70
127
|
getMissingActionInputs,
|
|
128
|
+
getNestedValue,
|
|
71
129
|
getOrCreateBlockPendingMap,
|
|
72
130
|
getOutputSchemaForBlock,
|
|
73
131
|
getPendingInvocationsMap,
|
|
132
|
+
getRunActionsMap,
|
|
133
|
+
getRunMeta,
|
|
134
|
+
getRunStorageVersion,
|
|
135
|
+
getRunsMap,
|
|
136
|
+
getRunsTerminalMap,
|
|
74
137
|
getVersionPolicy,
|
|
75
138
|
getXeroWorkItemsMap,
|
|
76
139
|
getXeroWorkTerminalMap,
|
|
77
140
|
hasAction,
|
|
141
|
+
hasLegacyRuntimeHistory,
|
|
142
|
+
hasReferences,
|
|
143
|
+
isActionDone,
|
|
144
|
+
isActionTypeDone,
|
|
78
145
|
isAuthorized,
|
|
146
|
+
isBelowTheLineBlock,
|
|
79
147
|
isBlankInputValue,
|
|
80
148
|
isCapabilityMatch,
|
|
81
149
|
isExternalMutation,
|
|
150
|
+
isLegacyRuntimeAdoptionEnabled,
|
|
82
151
|
isNodeContextRecord,
|
|
152
|
+
isRecordInRun,
|
|
83
153
|
isRuntimeRef,
|
|
84
154
|
isTempUcanEnforcementDisabled,
|
|
85
155
|
isVerifiedCompletion,
|
|
86
156
|
isVersionAtLeast,
|
|
157
|
+
listOpenRuns,
|
|
158
|
+
listRuns,
|
|
87
159
|
markXeroWorkApproved,
|
|
88
160
|
markXeroWorkApprovedForEditor,
|
|
89
161
|
markXeroWorkCompleted,
|
|
@@ -91,50 +163,97 @@ import {
|
|
|
91
163
|
markXeroWorkFailed,
|
|
92
164
|
markXeroWorkFailedForEditor,
|
|
93
165
|
mergeCompiledFlows,
|
|
166
|
+
migrateFlowToSessions,
|
|
167
|
+
neverDone,
|
|
168
|
+
normalizeActionReadBackMetadata,
|
|
169
|
+
normalizeCondition,
|
|
170
|
+
normalizeConditions,
|
|
171
|
+
parseConditionConfig,
|
|
172
|
+
parseConditionConfigStrict,
|
|
173
|
+
parseReferences,
|
|
94
174
|
parseServiceCan,
|
|
95
175
|
planRalphLoopCommands,
|
|
96
176
|
queueAgentCommand,
|
|
97
177
|
queuePendingInvocation,
|
|
178
|
+
readActionState,
|
|
179
|
+
readActionStates,
|
|
180
|
+
readAgentCommands,
|
|
98
181
|
readAgentLedgerEvents,
|
|
99
182
|
readBlocksFromFragment,
|
|
100
183
|
readCompiledFlowFromYDoc,
|
|
101
184
|
readFlow,
|
|
185
|
+
readFlowAgentLeases,
|
|
102
186
|
readFlowAsBaseUcan,
|
|
187
|
+
readFlowConnectionBindings,
|
|
188
|
+
readFlowConnections,
|
|
103
189
|
readFlowFromEditor,
|
|
190
|
+
readFlowXeroBinding,
|
|
191
|
+
readFlowXeroBindingFromEditor,
|
|
192
|
+
readInvocationsForRun,
|
|
104
193
|
readPendingInvocations,
|
|
194
|
+
readPendingRunTimelineEvents,
|
|
105
195
|
readQueuedAgentCommands,
|
|
196
|
+
readRunActionStates,
|
|
106
197
|
readRunRecords,
|
|
198
|
+
reconcileActionReadBack,
|
|
199
|
+
reconcileCompletion,
|
|
107
200
|
reconcilePendingInvocations,
|
|
201
|
+
recordRunDefinitionDrift,
|
|
108
202
|
registerAction,
|
|
109
203
|
releaseFlowAgentLease,
|
|
110
204
|
removeBlockFromFragment,
|
|
205
|
+
removeFlowConnection,
|
|
206
|
+
removeFlowConnectionBinding,
|
|
111
207
|
removePendingInvocation,
|
|
112
208
|
replaceBlockInFragment,
|
|
113
209
|
replayFailedListenerRun,
|
|
114
210
|
requiredCapabilityForCommand,
|
|
211
|
+
resetActionState,
|
|
212
|
+
resolveActiveRunId,
|
|
213
|
+
resolveConditionSourceValue,
|
|
214
|
+
resolveObjectReferences,
|
|
215
|
+
resolveRecordRunId,
|
|
216
|
+
resolveReferences,
|
|
217
|
+
resolveReferencesDetailed,
|
|
218
|
+
resolveRunIdForExecution,
|
|
219
|
+
resolveRunIdForRead,
|
|
115
220
|
resolveRuntimeRefs,
|
|
221
|
+
resolveSingleReference,
|
|
116
222
|
resourceMatches,
|
|
223
|
+
retryPendingRunTimelineEvents,
|
|
224
|
+
seedRunFromLegacyRuntime,
|
|
117
225
|
serviceCan,
|
|
118
226
|
setActiveEditor,
|
|
227
|
+
setAdvisoryActiveRunId,
|
|
228
|
+
setFlowConnectionOptional,
|
|
229
|
+
setFlowConnectionRequires,
|
|
230
|
+
setMultiRunStorage,
|
|
119
231
|
setTempUcanEnforcementDisabled,
|
|
120
232
|
setupFlowFromBaseUcan,
|
|
121
233
|
snapshotInputRefs,
|
|
122
234
|
snapshotNode,
|
|
235
|
+
startRun,
|
|
236
|
+
subscribeToActionState,
|
|
123
237
|
tickFlowAgent,
|
|
124
238
|
toEvaluatorOperator,
|
|
239
|
+
toRunJsonValue,
|
|
125
240
|
typeToCan,
|
|
126
241
|
updateAgentCommand,
|
|
127
242
|
updateXeroWorkReviewPayload,
|
|
128
243
|
updateXeroWorkReviewPayloadForEditor,
|
|
244
|
+
upsertFlowConnection,
|
|
245
|
+
upsertFlowConnectionBinding,
|
|
129
246
|
upsertXeroWorkItem,
|
|
130
247
|
upsertXeroWorkItemForEditor,
|
|
248
|
+
usesLegacyRuntimeCompatibility,
|
|
131
249
|
validateActionProof,
|
|
132
250
|
validateAgentCommand,
|
|
133
251
|
validateFlowAgentLease,
|
|
134
252
|
verifyCompletion,
|
|
253
|
+
writeActionState,
|
|
135
254
|
writeCompiledBlocksToFragment,
|
|
136
255
|
writeRunRecordAndReconcile
|
|
137
|
-
} from "../chunk-
|
|
256
|
+
} from "../chunk-VFYF2B5E.js";
|
|
138
257
|
import {
|
|
139
258
|
computeCID,
|
|
140
259
|
computeJsonCID
|
|
@@ -520,50 +639,102 @@ function createOracleInitFlowTemplate() {
|
|
|
520
639
|
return { metadata, nodes };
|
|
521
640
|
}
|
|
522
641
|
export {
|
|
642
|
+
ExplicitRunRequiredError,
|
|
643
|
+
FLOW_CONNECTIONS_MAP_KEY,
|
|
644
|
+
FLOW_CONNECTION_BINDINGS_MAP_KEY,
|
|
645
|
+
FLOW_PARTICIPANTS_MAP_KEY,
|
|
523
646
|
FlowAgentService,
|
|
647
|
+
FlowNotMigratedError,
|
|
648
|
+
INVOCATIONS_MAP_KEY,
|
|
649
|
+
InvalidConditionConfigError,
|
|
524
650
|
LATEST_VERSION,
|
|
651
|
+
LEGACY_RUN_STORAGE_VERSION,
|
|
652
|
+
MAX_RUN_ACTION_OUTPUT_BYTES,
|
|
653
|
+
MULTI_RUN_STORAGE_VERSION,
|
|
525
654
|
NODE_CONTEXT_MAP_NAME,
|
|
526
655
|
NODE_CONTEXT_OVERRIDES_MAP_NAME,
|
|
527
656
|
PROOF_MISSING_CODE,
|
|
657
|
+
RUNS_TERMINAL_MAP_KEY,
|
|
528
658
|
RUN_RECORD_AUDIT_TYPE,
|
|
659
|
+
RUN_STORAGE_VERSION_KEY,
|
|
660
|
+
RunLifecycleAuthorizationError,
|
|
661
|
+
RunNotMigratedError,
|
|
662
|
+
RunNotReadyError,
|
|
529
663
|
SERVICE_VERBS,
|
|
530
664
|
STEP_COMPLETED_EVENT,
|
|
531
665
|
STEP_COMPLETED_EVENT_NAME,
|
|
666
|
+
TerminalRunExecutionError,
|
|
667
|
+
UnknownRunError,
|
|
532
668
|
VERSION_MANIFEST,
|
|
669
|
+
XERO_TOOLKIT,
|
|
533
670
|
XERO_WORK_ITEMS_MAP_NAME,
|
|
534
671
|
XERO_WORK_TERMINAL_MAP_NAME,
|
|
535
672
|
acquireFlowAgentLease,
|
|
536
673
|
addFlowNode,
|
|
674
|
+
adoptLegacyRuntime,
|
|
537
675
|
appendAgentLedgerEvent,
|
|
538
676
|
appendRunRecord,
|
|
677
|
+
appendRunTimelineEvent,
|
|
678
|
+
appendRunTimelineEvents,
|
|
679
|
+
assertRunActionExecutionAllowed,
|
|
680
|
+
boundRunActionOutput,
|
|
681
|
+
boundRunEventJson,
|
|
682
|
+
buildActionRunInputs,
|
|
539
683
|
buildAuthzFromProps,
|
|
540
684
|
buildBlockConditionsProp,
|
|
541
685
|
buildFlowAgentContext,
|
|
542
686
|
buildFlowNodeFromBlock,
|
|
687
|
+
buildRunDefinitionSnapshot,
|
|
543
688
|
buildServicesFromHandlers,
|
|
544
689
|
buildXeroInvoiceWorkKey,
|
|
545
690
|
buildXeroPaymentWorkKey,
|
|
546
691
|
canMatches,
|
|
547
692
|
canToType,
|
|
693
|
+
cancelRun,
|
|
548
694
|
classifyBlockerCause,
|
|
549
695
|
classifyNodeState,
|
|
550
696
|
cleanupExpiredFlowAgentLeases,
|
|
697
|
+
clearAllActionState,
|
|
551
698
|
clearRuntimeForTemplateClone,
|
|
699
|
+
closeRun,
|
|
700
|
+
collectPhantomLegacyRun,
|
|
552
701
|
compileBaseUcanFlow,
|
|
553
702
|
computeAgentCommandId,
|
|
554
703
|
computeCID,
|
|
555
704
|
computeJsonCID,
|
|
556
705
|
computePendingInvocationId,
|
|
706
|
+
computeRunDefinitionHash,
|
|
707
|
+
computeRunSummary,
|
|
708
|
+
countPendingInvocations,
|
|
557
709
|
createAgentCommand,
|
|
558
710
|
createInvocationStore,
|
|
559
711
|
createMemoryInvocationStore,
|
|
560
712
|
createMemoryUcanDelegationStore,
|
|
561
713
|
createOracleInitFlowTemplate,
|
|
714
|
+
createReference,
|
|
715
|
+
createRunEventIdempotencyKey,
|
|
716
|
+
createRunId,
|
|
717
|
+
createRunRuntimeReader,
|
|
718
|
+
createRunRuntimeReaderWithDoc,
|
|
719
|
+
createRunScopedRuntimeManager,
|
|
720
|
+
createRunUlid,
|
|
562
721
|
createRuntimeStateManager,
|
|
563
722
|
createUcanDelegationStore,
|
|
564
723
|
createUcanService,
|
|
724
|
+
createYDocRuntimeManager,
|
|
565
725
|
decompileToBaseUcanFlow,
|
|
726
|
+
deleteActionState,
|
|
727
|
+
detectRunDefinitionDrift,
|
|
728
|
+
dispatchFlowStartTriggers,
|
|
729
|
+
doneWhenCompleted,
|
|
730
|
+
enableMultiRunStorage,
|
|
731
|
+
ensureRun,
|
|
732
|
+
evaluateBlockConditions,
|
|
733
|
+
evaluateBlockConditionsForRun,
|
|
734
|
+
evaluateBlockExecutionEligibilityForRun,
|
|
735
|
+
evaluateCondition,
|
|
566
736
|
evaluateFlowAgentPolicy,
|
|
737
|
+
executeActionBlock,
|
|
567
738
|
executeFlowAgentCoreCommand,
|
|
568
739
|
executeNode,
|
|
569
740
|
executeQueuedAgentCommands,
|
|
@@ -582,22 +753,37 @@ export {
|
|
|
582
753
|
getEventsForBlock,
|
|
583
754
|
getFlowAgentMaps,
|
|
584
755
|
getMissingActionInputs,
|
|
756
|
+
getNestedValue,
|
|
585
757
|
getOrCreateBlockPendingMap,
|
|
586
758
|
getOutputSchemaForBlock,
|
|
587
759
|
getPendingInvocationsMap,
|
|
760
|
+
getRunActionsMap,
|
|
761
|
+
getRunMeta,
|
|
762
|
+
getRunStorageVersion,
|
|
763
|
+
getRunsMap,
|
|
764
|
+
getRunsTerminalMap,
|
|
588
765
|
getVersionPolicy,
|
|
589
766
|
getXeroWorkItemsMap,
|
|
590
767
|
getXeroWorkTerminalMap,
|
|
591
768
|
hasAction,
|
|
769
|
+
hasLegacyRuntimeHistory,
|
|
770
|
+
hasReferences,
|
|
771
|
+
isActionDone,
|
|
772
|
+
isActionTypeDone,
|
|
592
773
|
isAuthorized,
|
|
774
|
+
isBelowTheLineBlock,
|
|
593
775
|
isBlankInputValue,
|
|
594
776
|
isCapabilityMatch,
|
|
595
777
|
isExternalMutation,
|
|
778
|
+
isLegacyRuntimeAdoptionEnabled,
|
|
596
779
|
isNodeContextRecord,
|
|
780
|
+
isRecordInRun,
|
|
597
781
|
isRuntimeRef,
|
|
598
782
|
isTempUcanEnforcementDisabled,
|
|
599
783
|
isVerifiedCompletion,
|
|
600
784
|
isVersionAtLeast,
|
|
785
|
+
listOpenRuns,
|
|
786
|
+
listRuns,
|
|
601
787
|
markXeroWorkApproved,
|
|
602
788
|
markXeroWorkApprovedForEditor,
|
|
603
789
|
markXeroWorkCompleted,
|
|
@@ -605,56 +791,108 @@ export {
|
|
|
605
791
|
markXeroWorkFailed,
|
|
606
792
|
markXeroWorkFailedForEditor,
|
|
607
793
|
mergeCompiledFlows,
|
|
794
|
+
migrateFlowToSessions,
|
|
795
|
+
neverDone,
|
|
796
|
+
normalizeActionReadBackMetadata,
|
|
797
|
+
normalizeCondition,
|
|
798
|
+
normalizeConditions,
|
|
608
799
|
oracleInitSurveySchema,
|
|
800
|
+
parseConditionConfig,
|
|
801
|
+
parseConditionConfigStrict,
|
|
802
|
+
parseReferences,
|
|
609
803
|
parseServiceCan,
|
|
610
804
|
planRalphLoopCommands,
|
|
611
805
|
queueAgentCommand,
|
|
612
806
|
queuePendingInvocation,
|
|
807
|
+
readActionState,
|
|
808
|
+
readActionStates,
|
|
809
|
+
readAgentCommands,
|
|
613
810
|
readAgentLedgerEvents,
|
|
614
811
|
readBlocksFromFragment,
|
|
615
812
|
readCompiledFlowFromYDoc,
|
|
616
813
|
readFlow,
|
|
814
|
+
readFlowAgentLeases,
|
|
617
815
|
readFlowAsBaseUcan,
|
|
816
|
+
readFlowConnectionBindings,
|
|
817
|
+
readFlowConnections,
|
|
618
818
|
readFlowDocument,
|
|
619
819
|
readFlowFromEditor,
|
|
820
|
+
readFlowParticipants,
|
|
821
|
+
readFlowXeroBinding,
|
|
822
|
+
readFlowXeroBindingFromEditor,
|
|
823
|
+
readInvocationsForRun,
|
|
620
824
|
readPendingInvocations,
|
|
825
|
+
readPendingRunTimelineEvents,
|
|
621
826
|
readQueuedAgentCommands,
|
|
827
|
+
readRunActionStates,
|
|
622
828
|
readRunRecords,
|
|
829
|
+
reconcileActionReadBack,
|
|
830
|
+
reconcileCompletion,
|
|
623
831
|
reconcilePendingInvocations,
|
|
832
|
+
recordRunDefinitionDrift,
|
|
624
833
|
registerAction,
|
|
625
834
|
releaseFlowAgentLease,
|
|
626
835
|
removeBlockFromFragment,
|
|
836
|
+
removeFlowConnection,
|
|
837
|
+
removeFlowConnectionBinding,
|
|
627
838
|
removeFlowNode,
|
|
839
|
+
removeFlowParticipant,
|
|
628
840
|
removePendingInvocation,
|
|
629
841
|
reorderFlowNodes,
|
|
630
842
|
replaceBlockInFragment,
|
|
631
843
|
replayFailedListenerRun,
|
|
632
844
|
requiredCapabilityForCommand,
|
|
845
|
+
resetActionState,
|
|
633
846
|
resetStepRuntime,
|
|
847
|
+
resolveActiveRunId,
|
|
848
|
+
resolveConditionSourceValue,
|
|
849
|
+
resolveObjectReferences,
|
|
850
|
+
resolveRecordRunId,
|
|
851
|
+
resolveReferences,
|
|
852
|
+
resolveReferencesDetailed,
|
|
853
|
+
resolveRunIdForExecution,
|
|
854
|
+
resolveRunIdForRead,
|
|
634
855
|
resolveRuntimeRefs,
|
|
856
|
+
resolveSingleReference,
|
|
635
857
|
resourceMatches,
|
|
858
|
+
retryPendingRunTimelineEvents,
|
|
859
|
+
seedRunFromLegacyRuntime,
|
|
636
860
|
serviceCan,
|
|
637
861
|
setActiveEditor,
|
|
862
|
+
setAdvisoryActiveRunId,
|
|
638
863
|
setBlockProps,
|
|
864
|
+
setFlowConnectionOptional,
|
|
865
|
+
setFlowConnectionRequires,
|
|
866
|
+
setFlowParticipantPowerLevel,
|
|
867
|
+
setFlowParticipantRequirements,
|
|
639
868
|
setFormAnswers,
|
|
869
|
+
setMultiRunStorage,
|
|
640
870
|
setTempUcanEnforcementDisabled,
|
|
641
871
|
setupFlowFromBaseUcan,
|
|
642
872
|
snapshotInputRefs,
|
|
643
873
|
snapshotNode,
|
|
874
|
+
startRun,
|
|
875
|
+
subscribeToActionState,
|
|
644
876
|
swapFlowBlocks,
|
|
645
877
|
tickFlowAgent,
|
|
646
878
|
toEvaluatorOperator,
|
|
879
|
+
toRunJsonValue,
|
|
647
880
|
typeToCan,
|
|
648
881
|
updateAgentCommand,
|
|
649
882
|
updateNodeRuntime,
|
|
650
883
|
updateXeroWorkReviewPayload,
|
|
651
884
|
updateXeroWorkReviewPayloadForEditor,
|
|
885
|
+
upsertFlowConnection,
|
|
886
|
+
upsertFlowConnectionBinding,
|
|
887
|
+
upsertFlowParticipant,
|
|
652
888
|
upsertXeroWorkItem,
|
|
653
889
|
upsertXeroWorkItemForEditor,
|
|
890
|
+
usesLegacyRuntimeCompatibility,
|
|
654
891
|
validateActionProof,
|
|
655
892
|
validateAgentCommand,
|
|
656
893
|
validateFlowAgentLease,
|
|
657
894
|
verifyCompletion,
|
|
895
|
+
writeActionState,
|
|
658
896
|
writeCompiledBlocksToFragment,
|
|
659
897
|
writeRunRecordAndReconcile
|
|
660
898
|
};
|
package/dist/core/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/core/templates/oracleInitFlow.ts"],"sourcesContent":["import type { FlowMetadata } from '../types/editor';\nimport type { FlowNode } from '../types/authorization';\n\n// ---------------------------------------------------------------------------\n// SurveyJS schema for the oracle configuration form\n// ---------------------------------------------------------------------------\n\nexport const oracleInitSurveySchema = {\n title: 'Oracle Configuration',\n description: 'Provide the details needed to initialise a new oracle on the IXO network.',\n logoPosition: 'right',\n pages: [\n {\n name: 'basicInfo',\n title: 'Basic Information',\n elements: [\n {\n type: 'text',\n name: 'projectName',\n title: 'Project Name',\n description: 'Used as the folder name — no spaces or special characters.',\n isRequired: true,\n validators: [\n {\n type: 'regex',\n text: 'Only lowercase letters, numbers, and hyphens are allowed (no spaces or special characters).',\n regex: '^[a-z0-9]+(-[a-z0-9]+)*$',\n },\n ],\n },\n {\n type: 'text',\n name: 'pin',\n title: 'PIN',\n description: 'A 6-digit PIN used to secure wallet operations.',\n isRequired: true,\n inputType: 'password',\n maxLength: 6,\n validators: [\n {\n type: 'regex',\n text: 'PIN must be exactly 6 digits.',\n regex: '^\\\\d{6}$',\n },\n ],\n },\n ],\n },\n {\n name: 'oracleDetails',\n title: 'Oracle Details',\n elements: [\n {\n type: 'text',\n name: 'oracleName',\n title: 'Oracle Name',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'orgName',\n title: 'Organisation Name',\n isRequired: true,\n },\n {\n type: 'comment',\n name: 'description',\n title: 'Description',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'location',\n title: 'Location',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'logoUrl',\n title: 'Logo URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'coverImageUrl',\n title: 'Cover Image URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n ],\n },\n {\n name: 'serviceConfig',\n title: 'Service Configuration',\n elements: [\n {\n type: 'text',\n name: 'apiUrl',\n title: 'API URL',\n isRequired: true,\n inputType: 'url',\n defaultValue: 'http://localhost:4000',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'price',\n title: 'Price',\n description: 'Service price in IXO tokens (minimum 1).',\n isRequired: true,\n inputType: 'number',\n defaultValue: 100,\n validators: [\n {\n type: 'numeric',\n text: 'Price must be at least 1.',\n minValue: 1,\n },\n ],\n },\n {\n type: 'dropdown',\n name: 'llmModel',\n title: 'LLM Model',\n isRequired: true,\n choices: [\n { value: 'kimi-k2.5', text: 'Kimi K2.5' },\n { value: 'claude-sonnet', text: 'Claude Sonnet' },\n { value: 'gpt-4o', text: 'GPT-4o' },\n { value: 'gemini-2.5', text: 'Gemini 2.5' },\n { value: 'llama-4', text: 'Llama 4' },\n { value: 'custom', text: 'Custom' },\n ],\n },\n {\n type: 'comment',\n name: 'opening',\n title: 'Opening Message',\n description: 'The greeting or introduction the agent uses when starting a conversation.',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'communicationStyle',\n title: 'Communication Style',\n description: 'How the agent should communicate (e.g. formal, friendly, concise).',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'capabilities',\n title: 'What can the agent do?',\n description: 'Describe what this agent is capable of doing for users.',\n isRequired: false,\n },\n ],\n },\n ],\n};\n\n// ---------------------------------------------------------------------------\n// Template generator\n// ---------------------------------------------------------------------------\n\nexport function createOracleInitFlowTemplate(): {\n metadata: FlowMetadata;\n nodes: FlowNode[];\n} {\n const metadata: FlowMetadata = {\n '@context': 'https://schema.ixo.world/flow/v1',\n _type: 'flow/oracle-init',\n schema_version: '1.0.0',\n doc_id: '',\n title: 'Oracle Init Flow',\n createdAt: new Date().toISOString(),\n createdBy: '',\n flowOwnerDid: '',\n };\n\n const nodes: FlowNode[] = [\n // ------------------------------------------------------------------\n // [1] Form — collects all oracle configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-form',\n type: 'form',\n props: {\n title: 'Oracle Configuration',\n description: 'Enter the details for your new oracle.',\n icon: 'checklist',\n surveySchema: JSON.stringify(oracleInitSurveySchema),\n },\n },\n\n // ------------------------------------------------------------------\n // [2] Skills — skill/MCP configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-skills',\n type: 'skills',\n props: {\n title: 'Oracle Skills & MCP Servers',\n description: 'Configure skills and MCP servers for the oracle.',\n icon: 'tools',\n skills: '[]',\n entityDid: '',\n mcpServers: '[]',\n status: 'pending',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-form',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [3] Action — Generate & Fund Wallet\n // Generates a new wallet and funds it in one step.\n // ------------------------------------------------------------------\n {\n id: 'oracle-wallet',\n type: 'action',\n props: {\n title: 'Generate & Fund Wallet',\n description: 'Generate a new IXO wallet and fund it with tokens.',\n icon: 'bolt',\n actionType: 'qi/wallet.generateAndFund',\n inputs: JSON.stringify({}),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-skills',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [4] Action — Create Identity (IID + Matrix)\n // Creates the on-chain IID document, then registers the Matrix account.\n // ------------------------------------------------------------------\n {\n id: 'oracle-identity',\n type: 'action',\n props: {\n title: 'Create Identity',\n description: 'Create on-chain DID document and register Matrix account.',\n icon: 'bolt',\n actionType: 'qi/identity.create',\n inputs: JSON.stringify({\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n did: '{{oracle-wallet.output.did}}',\n address: '{{oracle-wallet.output.address}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-wallet',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [5] Action — Create Oracle Entity\n // On-chain entity creation with P-256 encryption key.\n // ------------------------------------------------------------------\n {\n id: 'oracle-entity-create',\n type: 'action',\n props: {\n title: 'Create Oracle Entity',\n description: 'Create the oracle entity on the IXO network.',\n icon: 'bolt',\n actionType: 'qi/entity.createOracle',\n inputs: JSON.stringify({\n // Wallet outputs\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n address: '{{oracle-wallet.output.address}}',\n did: '{{oracle-wallet.output.did}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n // Matrix outputs (from identity block)\n matrixAccessToken: '{{oracle-identity.output.matrixAccessToken}}',\n matrixRoomId: '{{oracle-identity.output.matrixRoomId}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-identity',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [6] Action — Configure Oracle (contract + secrets + config)\n // Creates the user↔oracle DM room, encrypts secrets, stores config.\n // ------------------------------------------------------------------\n {\n id: 'oracle-configure',\n type: 'action',\n props: {\n title: 'Configure Oracle',\n description: 'Contract oracle, encrypt secrets, and store configuration.',\n icon: 'bolt',\n actionType: 'qi/oracle.configureOracle',\n inputs: JSON.stringify({\n // Contract input\n oracleEntityDid: '{{oracle-entity-create.output.entityDid}}',\n // Secrets routing (matrixRoomId comes from contract phase, not inputs)\n publicKeyMultibase: '{{oracle-entity-create.output.encryptionPublicKeyMultibase}}',\n verificationMethodId: '{{oracle-entity-create.output.encryptionVerificationMethodId}}',\n // Fresh mxLogin params\n matrixHomeServerUrl: '{{oracle-identity.output.matrixHomeServerUrl}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n // Sensitive plaintext values\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n // MCP auth secrets (already JWE-encrypted by skills block FlowDetail)\n mcpAuthSecrets: '{{oracle-skills.output.mcpAuthSecrets}}',\n // Skills outputs\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n // Identifiers\n matrixUserId: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n oracleAddress: '{{oracle-wallet.output.address}}',\n oracleDid: '{{oracle-wallet.output.did}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-entity-create',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [7] Action — Deploy Oracle (setup + start)\n // Clones repo, writes config, builds, then starts the process.\n // ------------------------------------------------------------------\n {\n id: 'oracle-deploy',\n type: 'action',\n props: {\n title: 'Deploy Oracle',\n description: 'Set up environment and start the oracle process.',\n icon: 'bolt',\n actionType: 'qi/oracle.deploy',\n inputs: JSON.stringify({\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n roomId: '{{oracle-configure.output.userOracleRoomId}}',\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n freshAccessToken: '{{oracle-configure.output.freshAccessToken}}',\n openRouterApiKey: '{{oracle-configure.output.openRouterApiKeyPlaintext}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-configure',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [8] Secrets — display credentials and download\n // ------------------------------------------------------------------\n {\n id: 'oracle-secrets',\n type: 'secrets',\n props: {\n title: 'Oracle Credentials',\n description: 'Download your oracle credentials after setup is complete.',\n icon: 'key',\n downloadEndpoint: '',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-deploy',\n requiredStatus: 'approved',\n },\n },\n ];\n\n return { metadata, nodes };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAOO,IAAM,yBAAyB;AAAA,EACpC,OAAO;AAAA,EAC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B;AAAA,UACrB,WAAW;AAAA,UACX,eAAe;AAAA,UACf,WAAW;AAAA;AAAA,UAEX,aAAa;AAAA,QACf,CAAC;AAAA,QACD,sBAAsB;AAAA,MACxB;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA;AAAA,MACE,IAAI;AAAA,MACJ,MAAM;AAAA,MACN,OAAO;AAAA,QACL,OAAO;AAAA,QACP,aAAa;AAAA,QACb,MAAM;AAAA,QACN,YAAY;AAAA,QACZ,QAAQ,KAAK,UAAU;AAAA,UACrB,WAAW;AAAA,UACX,QAAQ;AAAA,UACR,QAAQ;AAAA,UACR,YAAY;AAAA,UACZ,UAAU;AAAA,UACV,gBAAgB;AAAA,UAChB,sBAAsB;AAAA,UACtB,gBAAgB;AAAA,UAChB,qBAAqB;AAAA,UACrB,kBAAkB;AAAA,UAClB,kBAAkB;AAAA;AAAA,UAElB,aAAa;AAAA,QACf,CAAC;AAAA,QACD,sBAAsB;AAAA,MACxB;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKA;AAAA,MACE,IAAI;AAAA,MACJ,MAAM;AAAA,MACN,OAAO;AAAA,QACL,OAAO;AAAA,QACP,aAAa;AAAA,QACb,MAAM;AAAA,QACN,kBAAkB;AAAA,QAClB,WAAW;AAAA,MACb;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA,EACF;AAEA,SAAO,EAAE,UAAU,MAAM;AAC3B;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/core/templates/oracleInitFlow.ts"],"sourcesContent":["import type { FlowMetadata } from '../types/editor';\nimport type { FlowNode } from '../types/authorization';\n\n// ---------------------------------------------------------------------------\n// SurveyJS schema for the oracle configuration form\n// ---------------------------------------------------------------------------\n\nexport const oracleInitSurveySchema = {\n title: 'Oracle Configuration',\n description: 'Provide the details needed to initialise a new oracle on the IXO network.',\n logoPosition: 'right',\n pages: [\n {\n name: 'basicInfo',\n title: 'Basic Information',\n elements: [\n {\n type: 'text',\n name: 'projectName',\n title: 'Project Name',\n description: 'Used as the folder name — no spaces or special characters.',\n isRequired: true,\n validators: [\n {\n type: 'regex',\n text: 'Only lowercase letters, numbers, and hyphens are allowed (no spaces or special characters).',\n regex: '^[a-z0-9]+(-[a-z0-9]+)*$',\n },\n ],\n },\n {\n type: 'text',\n name: 'pin',\n title: 'PIN',\n description: 'A 6-digit PIN used to secure wallet operations.',\n isRequired: true,\n inputType: 'password',\n maxLength: 6,\n validators: [\n {\n type: 'regex',\n text: 'PIN must be exactly 6 digits.',\n regex: '^\\\\d{6}$',\n },\n ],\n },\n ],\n },\n {\n name: 'oracleDetails',\n title: 'Oracle Details',\n elements: [\n {\n type: 'text',\n name: 'oracleName',\n title: 'Oracle Name',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'orgName',\n title: 'Organisation Name',\n isRequired: true,\n },\n {\n type: 'comment',\n name: 'description',\n title: 'Description',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'location',\n title: 'Location',\n isRequired: true,\n },\n {\n type: 'text',\n name: 'logoUrl',\n title: 'Logo URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'coverImageUrl',\n title: 'Cover Image URL',\n isRequired: true,\n inputType: 'url',\n validators: [{ type: 'url' }],\n },\n ],\n },\n {\n name: 'serviceConfig',\n title: 'Service Configuration',\n elements: [\n {\n type: 'text',\n name: 'apiUrl',\n title: 'API URL',\n isRequired: true,\n inputType: 'url',\n defaultValue: 'http://localhost:4000',\n validators: [{ type: 'url' }],\n },\n {\n type: 'text',\n name: 'price',\n title: 'Price',\n description: 'Service price in IXO tokens (minimum 1).',\n isRequired: true,\n inputType: 'number',\n defaultValue: 100,\n validators: [\n {\n type: 'numeric',\n text: 'Price must be at least 1.',\n minValue: 1,\n },\n ],\n },\n {\n type: 'dropdown',\n name: 'llmModel',\n title: 'LLM Model',\n isRequired: true,\n choices: [\n { value: 'kimi-k2.5', text: 'Kimi K2.5' },\n { value: 'claude-sonnet', text: 'Claude Sonnet' },\n { value: 'gpt-4o', text: 'GPT-4o' },\n { value: 'gemini-2.5', text: 'Gemini 2.5' },\n { value: 'llama-4', text: 'Llama 4' },\n { value: 'custom', text: 'Custom' },\n ],\n },\n {\n type: 'comment',\n name: 'opening',\n title: 'Opening Message',\n description: 'The greeting or introduction the agent uses when starting a conversation.',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'communicationStyle',\n title: 'Communication Style',\n description: 'How the agent should communicate (e.g. formal, friendly, concise).',\n isRequired: false,\n },\n {\n type: 'comment',\n name: 'capabilities',\n title: 'What can the agent do?',\n description: 'Describe what this agent is capable of doing for users.',\n isRequired: false,\n },\n ],\n },\n ],\n};\n\n// ---------------------------------------------------------------------------\n// Template generator\n// ---------------------------------------------------------------------------\n\nexport function createOracleInitFlowTemplate(): {\n metadata: FlowMetadata;\n nodes: FlowNode[];\n} {\n const metadata: FlowMetadata = {\n '@context': 'https://schema.ixo.world/flow/v1',\n _type: 'flow/oracle-init',\n schema_version: '1.0.0',\n doc_id: '',\n title: 'Oracle Init Flow',\n createdAt: new Date().toISOString(),\n createdBy: '',\n flowOwnerDid: '',\n };\n\n const nodes: FlowNode[] = [\n // ------------------------------------------------------------------\n // [1] Form — collects all oracle configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-form',\n type: 'form',\n props: {\n title: 'Oracle Configuration',\n description: 'Enter the details for your new oracle.',\n icon: 'checklist',\n surveySchema: JSON.stringify(oracleInitSurveySchema),\n },\n },\n\n // ------------------------------------------------------------------\n // [2] Skills — skill/MCP configuration\n // ------------------------------------------------------------------\n {\n id: 'oracle-skills',\n type: 'skills',\n props: {\n title: 'Oracle Skills & MCP Servers',\n description: 'Configure skills and MCP servers for the oracle.',\n icon: 'tools',\n skills: '[]',\n entityDid: '',\n mcpServers: '[]',\n status: 'pending',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-form',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [3] Action — Generate & Fund Wallet\n // Generates a new wallet and funds it in one step.\n // ------------------------------------------------------------------\n {\n id: 'oracle-wallet',\n type: 'action',\n props: {\n title: 'Generate & Fund Wallet',\n description: 'Generate a new IXO wallet and fund it with tokens.',\n icon: 'bolt',\n actionType: 'qi/wallet.generateAndFund',\n inputs: JSON.stringify({}),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-skills',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [4] Action — Create Identity (IID + Matrix)\n // Creates the on-chain IID document, then registers the Matrix account.\n // ------------------------------------------------------------------\n {\n id: 'oracle-identity',\n type: 'action',\n props: {\n title: 'Create Identity',\n description: 'Create on-chain DID document and register Matrix account.',\n icon: 'bolt',\n actionType: 'qi/identity.create',\n inputs: JSON.stringify({\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n did: '{{oracle-wallet.output.did}}',\n address: '{{oracle-wallet.output.address}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-wallet',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [5] Action — Create Oracle Entity\n // On-chain entity creation with P-256 encryption key.\n // ------------------------------------------------------------------\n {\n id: 'oracle-entity-create',\n type: 'action',\n props: {\n title: 'Create Oracle Entity',\n description: 'Create the oracle entity on the IXO network.',\n icon: 'bolt',\n actionType: 'qi/entity.createOracle',\n inputs: JSON.stringify({\n // Wallet outputs\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n address: '{{oracle-wallet.output.address}}',\n did: '{{oracle-wallet.output.did}}',\n pubKey: '{{oracle-wallet.output.pubKey}}',\n // Matrix outputs (from identity block)\n matrixAccessToken: '{{oracle-identity.output.matrixAccessToken}}',\n matrixRoomId: '{{oracle-identity.output.matrixRoomId}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-identity',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [6] Action — Configure Oracle (contract + secrets + config)\n // Creates the user↔oracle DM room, encrypts secrets, stores config.\n // ------------------------------------------------------------------\n {\n id: 'oracle-configure',\n type: 'action',\n props: {\n title: 'Configure Oracle',\n description: 'Contract oracle, encrypt secrets, and store configuration.',\n icon: 'bolt',\n actionType: 'qi/oracle.configureOracle',\n inputs: JSON.stringify({\n // Contract input\n oracleEntityDid: '{{oracle-entity-create.output.entityDid}}',\n // Secrets routing (matrixRoomId comes from contract phase, not inputs)\n publicKeyMultibase: '{{oracle-entity-create.output.encryptionPublicKeyMultibase}}',\n verificationMethodId: '{{oracle-entity-create.output.encryptionVerificationMethodId}}',\n // Fresh mxLogin params\n matrixHomeServerUrl: '{{oracle-identity.output.matrixHomeServerUrl}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n // Sensitive plaintext values\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n // MCP auth secrets (already JWE-encrypted by skills block FlowDetail)\n mcpAuthSecrets: '{{oracle-skills.output.mcpAuthSecrets}}',\n // Skills outputs\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n // Identifiers\n matrixUserId: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n oracleAddress: '{{oracle-wallet.output.address}}',\n oracleDid: '{{oracle-wallet.output.did}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-entity-create',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [7] Action — Deploy Oracle (setup + start)\n // Clones repo, writes config, builds, then starts the process.\n // ------------------------------------------------------------------\n {\n id: 'oracle-deploy',\n type: 'action',\n props: {\n title: 'Deploy Oracle',\n description: 'Set up environment and start the oracle process.',\n icon: 'bolt',\n actionType: 'qi/oracle.deploy',\n inputs: JSON.stringify({\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n roomId: '{{oracle-configure.output.userOracleRoomId}}',\n skills: '{{oracle-skills.output.skills}}',\n mcpServers: '{{oracle-skills.output.mcpServers}}',\n mnemonic: '{{oracle-wallet.output.mnemonic}}',\n matrixPassword: '{{oracle-identity.output.matrixPassword}}',\n matrixRecoveryPhrase: '{{oracle-identity.output.matrixRecoveryPhrase}}',\n matrixUsername: '{{oracle-identity.output.matrixUserId}}',\n matrixAccountRoomId: '{{oracle-identity.output.matrixRoomId}}',\n freshAccessToken: '{{oracle-configure.output.freshAccessToken}}',\n openRouterApiKey: '{{oracle-configure.output.openRouterApiKeyPlaintext}}',\n // Form outputs — whole blob, action parses & destructures\n formAnswers: '{{oracle-form.output.form.answers}}',\n }),\n requiresConfirmation: '',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-configure',\n requiredStatus: 'approved',\n },\n },\n\n // ------------------------------------------------------------------\n // [8] Secrets — display credentials and download\n // ------------------------------------------------------------------\n {\n id: 'oracle-secrets',\n type: 'secrets',\n props: {\n title: 'Oracle Credentials',\n description: 'Download your oracle credentials after setup is complete.',\n icon: 'key',\n downloadEndpoint: '',\n entityDid: '{{oracle-entity-create.output.entityDid}}',\n },\n activationCondition: {\n upstreamNodeId: 'oracle-deploy',\n requiredStatus: 'approved',\n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AA,MACN,OAAO;AAAA,QACL,OAAO;AAAA,QACP,aAAa;AAAA,QACb,MAAM;AAAA,QACN,kBAAkB;AAAA,QAClB,WAAW;AAAA,MACb;AAAA,MACA,qBAAqB;AAAA,QACnB,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,IACF;AAAA,EACF;AAEA,SAAO,EAAE,UAAU,MAAM;AAC3B;","names":[]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _blocknote_core from '@blocknote/core';
|
|
2
|
-
import {
|
|
2
|
+
import { ah as IxoBlockProps, m as IxoEditorOptions, a9 as IxoEditorType, q as IxoCollaborativeEditorOptions, x as BlocknoteHandlers, z as BlockRequirements, ao as UnlMapConfig, ak as DynamicListDataProvider, al as DynamicListPanelRenderer, am as DomainCardRenderer, ad as RunEventAppender, a5 as Translate, l as DelegationGrant } from './index-x1R0c9P_.js';
|
|
3
3
|
import { Text, Doc, Map, Array as Array$1 } from 'yjs';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
import * as _tiptap_core from '@tiptap/core';
|
|
@@ -523,13 +523,17 @@ interface IxoEditorProps {
|
|
|
523
523
|
awarenessInstance?: any;
|
|
524
524
|
/** Slot rendered between the page title and the editor body (e.g. a details strip). */
|
|
525
525
|
belowTitleSlot?: React__default.ReactNode;
|
|
526
|
+
/** Explicit session rendered by this editor surface. */
|
|
527
|
+
sessionRunId?: string;
|
|
528
|
+
/** Matrix-backed timeline used by action transitions in this surface. */
|
|
529
|
+
runEventLog?: RunEventAppender;
|
|
526
530
|
/** Translation function — pass `t` from the host app's i18n setup. Optional. */
|
|
527
531
|
translate?: Translate;
|
|
528
532
|
}
|
|
529
533
|
/**
|
|
530
534
|
* IxoEditor component - A customized BlockNote editor for IXO (Mantine UI)
|
|
531
535
|
*/
|
|
532
|
-
declare function IxoEditor({ editor, editable, className, onChange, onSelectionChange, children, mantineTheme: _mantineTheme, handlers, blockRequirements, isPanelVisible, coverImageUrl, logoUrl, visualizationRenderer, getDynamicListData, dynamicListPanelRenderer, domainCardRenderer, onFlowStepRefClick, onExternalDrop, externalDropType, dropIndicator, isPlacementMode, onPlacementCancel, mapConfig, connectedUsers, awarenessInstance, belowTitleSlot, translate, }: IxoEditorProps): React__default.ReactElement | null;
|
|
536
|
+
declare function IxoEditor({ editor, editable, className, onChange, onSelectionChange, children, mantineTheme: _mantineTheme, handlers, blockRequirements, isPanelVisible, coverImageUrl, logoUrl, visualizationRenderer, getDynamicListData, dynamicListPanelRenderer, domainCardRenderer, onFlowStepRefClick, onExternalDrop, externalDropType, dropIndicator, isPlacementMode, onPlacementCancel, mapConfig, connectedUsers, awarenessInstance, belowTitleSlot, sessionRunId, runEventLog, translate, }: IxoEditorProps): React__default.ReactElement | null;
|
|
533
537
|
|
|
534
538
|
interface CoverImageProps {
|
|
535
539
|
coverImageUrl?: string;
|
|
@@ -537,9 +541,12 @@ interface CoverImageProps {
|
|
|
537
541
|
}
|
|
538
542
|
declare function CoverImage({ coverImageUrl, logoUrl }: CoverImageProps): React__default.ReactElement | null;
|
|
539
543
|
|
|
540
|
-
declare function DevUcanGrantButton({ editor, handlers: propHandlers }: {
|
|
544
|
+
declare function DevUcanGrantButton({ editor, handlers: propHandlers, opened: controlledOpened, onOpenedChange, }: {
|
|
541
545
|
editor: IxoEditorType;
|
|
542
546
|
handlers?: BlocknoteHandlers;
|
|
547
|
+
/** When provided the component is controlled: the caller owns the trigger and this renders the modal only. */
|
|
548
|
+
opened?: boolean;
|
|
549
|
+
onOpenedChange?: (opened: boolean) => void;
|
|
543
550
|
}): React__default.JSX.Element;
|
|
544
551
|
|
|
545
552
|
/** @deprecated The activation gating fields were removed; this type is kept
|