@pikku/addon-graph 0.0.2 → 0.12.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/.pikku/addon/pikku-addon-types.gen.ts +30 -3
- package/.pikku/addon/pikku-package.gen.ts +3 -1
- package/.pikku/agent/pikku-agent-map.gen.d.ts +2 -14
- package/.pikku/agent/pikku-agent-types.gen.ts +13 -7
- package/.pikku/channel/pikku-channel-types.gen.ts +177 -0
- package/.pikku/cli/pikku-cli-types.gen.ts +105 -0
- package/.pikku/console/pikku-addon-meta.gen.json +281 -0
- package/.pikku/console/pikku-node-types.gen.ts +2 -2
- package/.pikku/function/pikku-function-types.gen.ts +70 -34
- package/.pikku/function/pikku-functions-meta-verbose.gen.json +274 -196
- package/.pikku/function/pikku-functions-meta.gen.json +160 -144
- package/.pikku/function/pikku-functions-meta.gen.ts +1 -1
- package/.pikku/function/pikku-functions.gen.ts +4 -2
- package/.pikku/http/pikku-http-types.gen.ts +147 -0
- package/.pikku/mcp/pikku-mcp-types.gen.ts +183 -0
- package/.pikku/pikku-bootstrap.gen.ts +2 -9
- package/.pikku/pikku-meta-service.gen.ts +10 -0
- package/.pikku/pikku-services.gen.ts +10 -3
- package/.pikku/pikku-types.gen.ts +1 -1
- package/.pikku/queue/pikku-queue-types.gen.ts +27 -0
- package/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +212 -194
- package/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +221 -202
- package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +27 -0
- package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +6 -0
- package/.pikku/scheduler/pikku-scheduler-types.gen.ts +25 -0
- package/.pikku/schemas/register.gen.ts +69 -65
- package/.pikku/schemas/schemas/SleepInput.schema.json +1 -0
- package/.pikku/secrets/pikku-secret-types.gen.ts +1 -1
- package/.pikku/secrets/pikku-secrets.gen.ts +1 -1
- package/.pikku/trigger/pikku-trigger-types.gen.ts +1 -1
- package/.pikku/variables/pikku-variable-types.gen.ts +1 -1
- package/.pikku/variables/pikku-variables.gen.ts +1 -1
- package/.pikku/workflow/pikku-workflow-map.gen.d.ts +9 -5
- package/.pikku/workflow/pikku-workflow-types.gen.ts +66 -57
- package/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +1 -1
- package/.pikku/workflow/pikku-workflow-wirings.gen.ts +1 -1
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts +18 -2
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts.map +1 -1
- package/dist/.pikku/addon/pikku-addon-types.gen.js +25 -2
- package/dist/.pikku/addon/pikku-addon-types.gen.js.map +1 -1
- package/dist/.pikku/addon/pikku-addon-types.gen.ts +30 -3
- package/dist/.pikku/addon/pikku-package.gen.js +2 -1
- package/dist/.pikku/addon/pikku-package.gen.js.map +1 -1
- package/dist/.pikku/addon/pikku-package.gen.ts +3 -1
- package/dist/.pikku/agent/pikku-agent-map.gen.d.ts +2 -14
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +6 -6
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts.map +1 -1
- package/dist/.pikku/agent/pikku-agent-types.gen.js.map +1 -1
- package/dist/.pikku/agent/pikku-agent-types.gen.ts +13 -7
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +112 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.d.ts.map +1 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.js +60 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.js.map +1 -0
- package/dist/.pikku/channel/pikku-channel-types.gen.ts +177 -0
- package/dist/.pikku/cli/pikku-cli-types.gen.d.ts +78 -0
- package/dist/.pikku/cli/pikku-cli-types.gen.d.ts.map +1 -0
- package/dist/.pikku/cli/pikku-cli-types.gen.js +61 -0
- package/dist/.pikku/cli/pikku-cli-types.gen.js.map +1 -0
- package/dist/.pikku/cli/pikku-cli-types.gen.ts +105 -0
- package/dist/.pikku/console/pikku-addon-meta.gen.json +281 -0
- package/dist/.pikku/console/pikku-node-types.gen.d.ts +2 -2
- package/dist/.pikku/console/pikku-node-types.gen.d.ts.map +1 -1
- package/dist/.pikku/console/pikku-node-types.gen.ts +2 -2
- package/dist/.pikku/function/pikku-function-types.gen.d.ts +56 -30
- package/dist/.pikku/function/pikku-function-types.gen.d.ts.map +1 -1
- package/dist/.pikku/function/pikku-function-types.gen.js +31 -19
- package/dist/.pikku/function/pikku-function-types.gen.js.map +1 -1
- package/dist/.pikku/function/pikku-function-types.gen.ts +70 -34
- package/dist/.pikku/function/pikku-functions-meta-verbose.gen.json +274 -196
- package/dist/.pikku/function/pikku-functions-meta.gen.js +1 -1
- package/dist/.pikku/function/pikku-functions-meta.gen.json +160 -144
- package/dist/.pikku/function/pikku-functions-meta.gen.ts +1 -1
- package/dist/.pikku/function/pikku-functions.gen.js +4 -2
- package/dist/.pikku/function/pikku-functions.gen.js.map +1 -1
- package/dist/.pikku/function/pikku-functions.gen.ts +4 -2
- package/dist/.pikku/http/pikku-http-types.gen.d.ts +120 -0
- package/dist/.pikku/http/pikku-http-types.gen.d.ts.map +1 -0
- package/dist/.pikku/http/pikku-http-types.gen.js +72 -0
- package/dist/.pikku/http/pikku-http-types.gen.js.map +1 -0
- package/dist/.pikku/http/pikku-http-types.gen.ts +147 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +131 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts.map +1 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js +38 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.js.map +1 -0
- package/dist/.pikku/mcp/pikku-mcp-types.gen.ts +183 -0
- package/dist/.pikku/pikku-bootstrap.gen.d.ts +4 -2
- package/dist/.pikku/pikku-bootstrap.gen.d.ts.map +1 -1
- package/dist/.pikku/pikku-bootstrap.gen.js +2 -10
- package/dist/.pikku/pikku-bootstrap.gen.js.map +1 -1
- package/dist/.pikku/pikku-bootstrap.gen.ts +2 -9
- package/dist/.pikku/pikku-meta-service.gen.d.ts +8 -0
- package/dist/.pikku/pikku-meta-service.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-meta-service.gen.js +10 -0
- package/dist/.pikku/pikku-meta-service.gen.js.map +1 -0
- package/dist/.pikku/pikku-meta-service.gen.ts +10 -0
- package/dist/.pikku/pikku-services.gen.d.ts +8 -3
- package/dist/.pikku/pikku-services.gen.d.ts.map +1 -1
- package/dist/.pikku/pikku-services.gen.js +7 -1
- package/dist/.pikku/pikku-services.gen.js.map +1 -1
- package/dist/.pikku/pikku-services.gen.ts +10 -3
- package/dist/.pikku/pikku-types.gen.d.ts +1 -1
- package/dist/.pikku/pikku-types.gen.js +1 -1
- package/dist/.pikku/pikku-types.gen.ts +1 -1
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +24 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.d.ts.map +1 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.js +17 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.js.map +1 -0
- package/dist/.pikku/queue/pikku-queue-types.gen.ts +27 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +212 -194
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +221 -202
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts +2 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts.map +1 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +7 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js.map +1 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +27 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +6 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +22 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts.map +1 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +17 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js.map +1 -0
- package/dist/.pikku/scheduler/pikku-scheduler-types.gen.ts +25 -0
- package/dist/.pikku/schemas/register.gen.js +35 -33
- package/dist/.pikku/schemas/register.gen.js.map +1 -1
- package/dist/.pikku/schemas/register.gen.ts +69 -65
- package/dist/.pikku/schemas/schemas/SleepInput.schema.json +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +1 -1
- package/dist/.pikku/secrets/pikku-secret-types.gen.js +1 -1
- package/dist/.pikku/secrets/pikku-secret-types.gen.ts +1 -1
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +1 -1
- package/dist/.pikku/secrets/pikku-secrets.gen.js +1 -1
- package/dist/.pikku/secrets/pikku-secrets.gen.ts +1 -1
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +1 -1
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js +1 -1
- package/dist/.pikku/trigger/pikku-trigger-types.gen.ts +1 -1
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +1 -1
- package/dist/.pikku/variables/pikku-variable-types.gen.js +1 -1
- package/dist/.pikku/variables/pikku-variable-types.gen.ts +1 -1
- package/dist/.pikku/variables/pikku-variables.gen.d.ts +1 -1
- package/dist/.pikku/variables/pikku-variables.gen.js +1 -1
- package/dist/.pikku/variables/pikku-variables.gen.ts +1 -1
- package/dist/.pikku/workflow/pikku-workflow-map.gen.d.ts +9 -5
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +36 -27
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts.map +1 -1
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js +5 -18
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js.map +1 -1
- package/dist/.pikku/workflow/pikku-workflow-types.gen.ts +66 -57
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +1 -1
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.ts +1 -1
- package/dist/src/functions/data/jwt.function.d.ts.map +1 -1
- package/dist/src/functions/data/jwt.function.js +3 -2
- package/dist/src/functions/data/jwt.function.js.map +1 -1
- package/dist/src/functions/data/sleep.function.d.ts +16 -0
- package/dist/src/functions/data/sleep.function.d.ts.map +1 -0
- package/dist/src/functions/data/sleep.function.js +18 -0
- package/dist/src/functions/data/sleep.function.js.map +1 -0
- package/package.json +3 -2
- package/.pikku/agent/pikku-agent-wirings-meta.gen.json +0 -3
- package/.pikku/agent/pikku-agent-wirings-meta.gen.ts +0 -7
- package/.pikku/agent/pikku-agent-wirings.gen.ts +0 -3
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts +0 -2
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts.map +0 -1
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js +0 -7
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js.map +0 -1
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.json +0 -3
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.ts +0 -7
- package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts +0 -5
- package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts.map +0 -1
- package/dist/.pikku/agent/pikku-agent-wirings.gen.js +0 -5
- package/dist/.pikku/agent/pikku-agent-wirings.gen.js.map +0 -1
- package/dist/.pikku/agent/pikku-agent-wirings.gen.ts +0 -3
|
@@ -1,72 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { addSchema } from '@pikku/core/schema'
|
|
5
5
|
|
|
6
|
-
import * as CoalesceInput from './schemas/CoalesceInput.schema.json' with { type: 'json' }
|
|
7
|
-
addSchema('CoalesceInput', CoalesceInput, '@pikku/addon-graph')
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
import * as CoalesceOutput from './schemas/CoalesceOutput.schema.json' with { type: 'json' }
|
|
11
|
-
addSchema('CoalesceOutput', CoalesceOutput, '@pikku/addon-graph')
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
import * as CryptoInput from './schemas/CryptoInput.schema.json' with { type: 'json' }
|
|
15
|
-
addSchema('CryptoInput', CryptoInput, '@pikku/addon-graph')
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
import * as CryptoOutput from './schemas/CryptoOutput.schema.json' with { type: 'json' }
|
|
19
|
-
addSchema('CryptoOutput', CryptoOutput, '@pikku/addon-graph')
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
import * as DateTimeInput from './schemas/DateTimeInput.schema.json' with { type: 'json' }
|
|
23
|
-
addSchema('DateTimeInput', DateTimeInput, '@pikku/addon-graph')
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
import * as DateTimeOutput from './schemas/DateTimeOutput.schema.json' with { type: 'json' }
|
|
27
|
-
addSchema('DateTimeOutput', DateTimeOutput, '@pikku/addon-graph')
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
import * as JwtSignInput from './schemas/JwtSignInput.schema.json' with { type: 'json' }
|
|
31
|
-
addSchema('JwtSignInput', JwtSignInput, '@pikku/addon-graph')
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
import * as JwtSignOutput from './schemas/JwtSignOutput.schema.json' with { type: 'json' }
|
|
35
|
-
addSchema('JwtSignOutput', JwtSignOutput, '@pikku/addon-graph')
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
import * as JwtDecodeInput from './schemas/JwtDecodeInput.schema.json' with { type: 'json' }
|
|
39
|
-
addSchema('JwtDecodeInput', JwtDecodeInput, '@pikku/addon-graph')
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
import * as JwtDecodeOutput from './schemas/JwtDecodeOutput.schema.json' with { type: 'json' }
|
|
43
|
-
addSchema('JwtDecodeOutput', JwtDecodeOutput, '@pikku/addon-graph')
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
import * as MathInput from './schemas/MathInput.schema.json' with { type: 'json' }
|
|
47
|
-
addSchema('MathInput', MathInput, '@pikku/addon-graph')
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
import * as MathOutput from './schemas/MathOutput.schema.json' with { type: 'json' }
|
|
51
|
-
addSchema('MathOutput', MathOutput, '@pikku/addon-graph')
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
import * as StringTransformInput from './schemas/StringTransformInput.schema.json' with { type: 'json' }
|
|
55
|
-
addSchema('StringTransformInput', StringTransformInput, '@pikku/addon-graph')
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
import * as StringTransformOutput from './schemas/StringTransformOutput.schema.json' with { type: 'json' }
|
|
59
|
-
addSchema('StringTransformOutput', StringTransformOutput, '@pikku/addon-graph')
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
import * as TypeConvertInput from './schemas/TypeConvertInput.schema.json' with { type: 'json' }
|
|
63
|
-
addSchema('TypeConvertInput', TypeConvertInput, '@pikku/addon-graph')
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
import * as TypeConvertOutput from './schemas/TypeConvertOutput.schema.json' with { type: 'json' }
|
|
67
|
-
addSchema('TypeConvertOutput', TypeConvertOutput, '@pikku/addon-graph')
|
|
68
|
-
|
|
69
|
-
|
|
70
6
|
import * as AggregateInput from './schemas/AggregateInput.schema.json' with { type: 'json' }
|
|
71
7
|
addSchema('AggregateInput', AggregateInput, '@pikku/addon-graph')
|
|
72
8
|
|
|
@@ -155,6 +91,74 @@ import * as UniqueOutput from './schemas/UniqueOutput.schema.json' with { type:
|
|
|
155
91
|
addSchema('UniqueOutput', UniqueOutput, '@pikku/addon-graph')
|
|
156
92
|
|
|
157
93
|
|
|
94
|
+
import * as CoalesceInput from './schemas/CoalesceInput.schema.json' with { type: 'json' }
|
|
95
|
+
addSchema('CoalesceInput', CoalesceInput, '@pikku/addon-graph')
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
import * as CoalesceOutput from './schemas/CoalesceOutput.schema.json' with { type: 'json' }
|
|
99
|
+
addSchema('CoalesceOutput', CoalesceOutput, '@pikku/addon-graph')
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
import * as CryptoInput from './schemas/CryptoInput.schema.json' with { type: 'json' }
|
|
103
|
+
addSchema('CryptoInput', CryptoInput, '@pikku/addon-graph')
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
import * as CryptoOutput from './schemas/CryptoOutput.schema.json' with { type: 'json' }
|
|
107
|
+
addSchema('CryptoOutput', CryptoOutput, '@pikku/addon-graph')
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
import * as DateTimeInput from './schemas/DateTimeInput.schema.json' with { type: 'json' }
|
|
111
|
+
addSchema('DateTimeInput', DateTimeInput, '@pikku/addon-graph')
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
import * as DateTimeOutput from './schemas/DateTimeOutput.schema.json' with { type: 'json' }
|
|
115
|
+
addSchema('DateTimeOutput', DateTimeOutput, '@pikku/addon-graph')
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
import * as JwtSignInput from './schemas/JwtSignInput.schema.json' with { type: 'json' }
|
|
119
|
+
addSchema('JwtSignInput', JwtSignInput, '@pikku/addon-graph')
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
import * as JwtSignOutput from './schemas/JwtSignOutput.schema.json' with { type: 'json' }
|
|
123
|
+
addSchema('JwtSignOutput', JwtSignOutput, '@pikku/addon-graph')
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
import * as JwtDecodeInput from './schemas/JwtDecodeInput.schema.json' with { type: 'json' }
|
|
127
|
+
addSchema('JwtDecodeInput', JwtDecodeInput, '@pikku/addon-graph')
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
import * as JwtDecodeOutput from './schemas/JwtDecodeOutput.schema.json' with { type: 'json' }
|
|
131
|
+
addSchema('JwtDecodeOutput', JwtDecodeOutput, '@pikku/addon-graph')
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
import * as MathInput from './schemas/MathInput.schema.json' with { type: 'json' }
|
|
135
|
+
addSchema('MathInput', MathInput, '@pikku/addon-graph')
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
import * as MathOutput from './schemas/MathOutput.schema.json' with { type: 'json' }
|
|
139
|
+
addSchema('MathOutput', MathOutput, '@pikku/addon-graph')
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
import * as SleepInput from './schemas/SleepInput.schema.json' with { type: 'json' }
|
|
143
|
+
addSchema('SleepInput', SleepInput, '@pikku/addon-graph')
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
import * as StringTransformInput from './schemas/StringTransformInput.schema.json' with { type: 'json' }
|
|
147
|
+
addSchema('StringTransformInput', StringTransformInput, '@pikku/addon-graph')
|
|
148
|
+
|
|
149
|
+
|
|
150
|
+
import * as StringTransformOutput from './schemas/StringTransformOutput.schema.json' with { type: 'json' }
|
|
151
|
+
addSchema('StringTransformOutput', StringTransformOutput, '@pikku/addon-graph')
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
import * as TypeConvertInput from './schemas/TypeConvertInput.schema.json' with { type: 'json' }
|
|
155
|
+
addSchema('TypeConvertInput', TypeConvertInput, '@pikku/addon-graph')
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
import * as TypeConvertOutput from './schemas/TypeConvertOutput.schema.json' with { type: 'json' }
|
|
159
|
+
addSchema('TypeConvertOutput', TypeConvertOutput, '@pikku/addon-graph')
|
|
160
|
+
|
|
161
|
+
|
|
158
162
|
import * as EditFieldsInput from './schemas/EditFieldsInput.schema.json' with { type: 'json' }
|
|
159
163
|
addSchema('EditFieldsInput', EditFieldsInput, '@pikku/addon-graph')
|
|
160
164
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"name":{"type":"string","description":"A unique name for this sleep step"},"ms":{"type":"number","description":"Duration to sleep in milliseconds"}},"required":["name","ms"],"additionalProperties":false}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { TypedSecretService as CoreTypedSecretService, type CredentialMeta } from '@pikku/core/services'
|
|
5
5
|
import type { SecretService } from '@pikku/core/services'
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { TypedVariablesService as CoreTypedVariablesService, type VariableMeta } from '@pikku/core/services'
|
|
5
5
|
import type { VariablesService } from '@pikku/core/services'
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Workflow type map with input/output types for each workflow
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
+
|
|
11
12
|
interface WorkflowHandler<I, O> {
|
|
12
13
|
input: I;
|
|
13
14
|
output: O;
|
|
@@ -23,12 +24,15 @@ export type WorkflowMap = {
|
|
|
23
24
|
export type GraphsMap = {
|
|
24
25
|
};
|
|
25
26
|
|
|
26
|
-
export type
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
export type FlattenedWorkflowMap = WorkflowMap
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
export type WorkflowClient<Name extends keyof FlattenedWorkflowMap> = {
|
|
31
|
+
start: (input: FlattenedWorkflowMap[Name]['input']) => Promise<{ runId: string }>;
|
|
32
|
+
getRun: <output extends keyof FlattenedWorkflowMap[Name]>(runId: string) => Promise<FlattenedWorkflowMap[Name][output]>;
|
|
29
33
|
cancelRun: (runId: string) => Promise<boolean>;
|
|
30
34
|
}
|
|
31
35
|
|
|
32
36
|
export type TypedWorkflowClients = {
|
|
33
|
-
[Name in keyof
|
|
37
|
+
[Name in keyof FlattenedWorkflowMap]: WorkflowClient<Name>;
|
|
34
38
|
}
|
|
@@ -1,13 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { WorkflowCancelledException } from '@pikku/core/workflow'
|
|
5
|
-
import {
|
|
6
|
-
workflow as coreWorkflow,
|
|
7
|
-
workflowStart as coreWorkflowStart,
|
|
8
|
-
workflowStatus as coreWorkflowStatus,
|
|
9
|
-
graphStart as coreGraphStart,
|
|
10
|
-
} from '@pikku/core/workflow'
|
|
11
5
|
import { template } from '@pikku/core/workflow'
|
|
12
6
|
import {
|
|
13
7
|
pikkuWorkflowGraph as corePikkuWorkflowGraph,
|
|
@@ -18,18 +12,25 @@ import type { PikkuWorkflowWire, WorkflowStepOptions } from '@pikku/core/workflo
|
|
|
18
12
|
|
|
19
13
|
export { WorkflowCancelledException }
|
|
20
14
|
import type { PikkuFunctionSessionless, PikkuFunctionConfig } from '../function/pikku-function-types.gen.js'
|
|
21
|
-
import type {
|
|
22
|
-
import type {
|
|
15
|
+
import type { FlattenedRPCMap } from '../rpc/pikku-rpc-wirings-map.internal.gen.d.js'
|
|
16
|
+
import type { FlattenedWorkflowMap } from './pikku-workflow-map.gen.d.js'
|
|
23
17
|
|
|
24
18
|
export { template }
|
|
25
19
|
|
|
26
20
|
export interface TypedWorkflow extends PikkuWorkflowWire {
|
|
27
|
-
do<K extends keyof
|
|
21
|
+
do<K extends keyof FlattenedRPCMap>(
|
|
28
22
|
stepName: string,
|
|
29
23
|
rpcName: K,
|
|
30
|
-
data:
|
|
24
|
+
data: FlattenedRPCMap[K]['input'],
|
|
25
|
+
options?: WorkflowStepOptions
|
|
26
|
+
): Promise<FlattenedRPCMap[K]['output']>
|
|
27
|
+
|
|
28
|
+
do<K extends keyof FlattenedWorkflowMap>(
|
|
29
|
+
stepName: string,
|
|
30
|
+
workflowName: K,
|
|
31
|
+
data: FlattenedWorkflowMap[K]['input'],
|
|
31
32
|
options?: WorkflowStepOptions
|
|
32
|
-
): Promise<
|
|
33
|
+
): Promise<FlattenedWorkflowMap[K]['output']>
|
|
33
34
|
|
|
34
35
|
do<T>(
|
|
35
36
|
stepName: string,
|
|
@@ -38,24 +39,73 @@ export interface TypedWorkflow extends PikkuWorkflowWire {
|
|
|
38
39
|
): Promise<T>
|
|
39
40
|
}
|
|
40
41
|
|
|
42
|
+
import type { StandardSchemaV1 } from '@standard-schema/spec'
|
|
43
|
+
import type { InferSchemaOutput, PikkuPermission, PikkuMiddleware, NodeConfig, PikkuApprovalDescription } from '../function/pikku-function-types.gen.js'
|
|
44
|
+
import { PikkuError } from '@pikku/core/errors'
|
|
45
|
+
import type { CorePermissionGroup } from '@pikku/core'
|
|
46
|
+
|
|
41
47
|
export type PikkuFunctionWorkflow<
|
|
42
48
|
In = unknown,
|
|
43
49
|
Out = never
|
|
44
50
|
> = PikkuFunctionSessionless<In, Out, 'workflow'>
|
|
45
51
|
|
|
46
|
-
export
|
|
52
|
+
export type PikkuWorkflowConfigWithSchema<
|
|
53
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
54
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
55
|
+
> = {
|
|
56
|
+
title?: string
|
|
57
|
+
description?: string
|
|
58
|
+
tags?: string[]
|
|
59
|
+
expose?: boolean
|
|
60
|
+
internal?: boolean
|
|
61
|
+
override?: string
|
|
62
|
+
version?: number
|
|
63
|
+
remote?: boolean
|
|
64
|
+
mcp?: boolean
|
|
65
|
+
readonly?: boolean
|
|
66
|
+
approvalRequired?: boolean
|
|
67
|
+
approvalDescription?: InputSchema extends StandardSchemaV1 ? PikkuApprovalDescription<InferSchemaOutput<InputSchema>> : never
|
|
68
|
+
func: PikkuFunctionWorkflow<
|
|
69
|
+
InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown,
|
|
70
|
+
OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown
|
|
71
|
+
>
|
|
72
|
+
auth?: boolean
|
|
73
|
+
permissions?: InputSchema extends StandardSchemaV1 ? CorePermissionGroup<PikkuPermission<InferSchemaOutput<InputSchema>>> : undefined
|
|
74
|
+
middleware?: PikkuMiddleware[]
|
|
75
|
+
input?: InputSchema
|
|
76
|
+
output?: OutputSchema
|
|
77
|
+
node?: NodeConfig
|
|
78
|
+
errors?: Array<typeof PikkuError>
|
|
79
|
+
inline?: boolean
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export function pikkuWorkflowFunc<
|
|
83
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
84
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
85
|
+
>(
|
|
86
|
+
config: PikkuWorkflowConfigWithSchema<InputSchema, OutputSchema>
|
|
87
|
+
): PikkuFunctionConfig<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown, 'workflow', PikkuFunctionWorkflow<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown>, InputSchema, OutputSchema>
|
|
88
|
+
export function pikkuWorkflowFunc<In, Out = unknown>(
|
|
47
89
|
func:
|
|
48
90
|
| PikkuFunctionWorkflow<In, Out>
|
|
49
91
|
| PikkuFunctionConfig<In, Out, 'workflow', PikkuFunctionWorkflow<In, Out>>
|
|
50
|
-
)
|
|
92
|
+
): PikkuFunctionConfig<In, Out, 'workflow'>
|
|
93
|
+
export function pikkuWorkflowFunc(func: any) {
|
|
51
94
|
return typeof func === 'function' ? { func } : func
|
|
52
95
|
}
|
|
53
96
|
|
|
54
|
-
export
|
|
97
|
+
export function pikkuWorkflowComplexFunc<
|
|
98
|
+
InputSchema extends StandardSchemaV1 | undefined = undefined,
|
|
99
|
+
OutputSchema extends StandardSchemaV1 | undefined = undefined
|
|
100
|
+
>(
|
|
101
|
+
config: PikkuWorkflowConfigWithSchema<InputSchema, OutputSchema>
|
|
102
|
+
): PikkuFunctionConfig<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown, 'workflow', PikkuFunctionWorkflow<InputSchema extends StandardSchemaV1 ? InferSchemaOutput<InputSchema> : unknown, OutputSchema extends StandardSchemaV1 ? InferSchemaOutput<OutputSchema> : unknown>, InputSchema, OutputSchema>
|
|
103
|
+
export function pikkuWorkflowComplexFunc<In, Out = unknown>(
|
|
55
104
|
func:
|
|
56
105
|
| PikkuFunctionWorkflow<In, Out>
|
|
57
106
|
| PikkuFunctionConfig<In, Out, 'workflow', PikkuFunctionWorkflow<In, Out>>
|
|
58
|
-
)
|
|
107
|
+
): PikkuFunctionConfig<In, Out, 'workflow'>
|
|
108
|
+
export function pikkuWorkflowComplexFunc(func: any) {
|
|
59
109
|
return typeof func === 'function' ? { func } : func
|
|
60
110
|
}
|
|
61
111
|
|
|
@@ -115,44 +165,3 @@ export function pikkuWorkflowGraph<
|
|
|
115
165
|
return corePikkuWorkflowGraph(config as any)
|
|
116
166
|
}
|
|
117
167
|
|
|
118
|
-
export const workflow = <Name extends keyof WorkflowMap>(
|
|
119
|
-
workflowName: Name,
|
|
120
|
-
options?: { pollIntervalMs?: number }
|
|
121
|
-
) => {
|
|
122
|
-
return coreWorkflow<WorkflowMap>(workflowName as string & keyof WorkflowMap, options) as PikkuFunctionConfig<
|
|
123
|
-
WorkflowMap[Name]['input'],
|
|
124
|
-
WorkflowMap[Name]['output'],
|
|
125
|
-
'session' | 'rpc'
|
|
126
|
-
>
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
export const workflowStart = <Name extends keyof WorkflowMap>(
|
|
130
|
-
workflowName: Name
|
|
131
|
-
) => {
|
|
132
|
-
return coreWorkflowStart<WorkflowMap>(workflowName as string & keyof WorkflowMap) as PikkuFunctionConfig<
|
|
133
|
-
WorkflowMap[Name]['input'],
|
|
134
|
-
{ runId: string },
|
|
135
|
-
'session' | 'rpc'
|
|
136
|
-
>
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
export const workflowStatus = <Name extends keyof WorkflowMap>(
|
|
140
|
-
_workflowName: Name
|
|
141
|
-
) => {
|
|
142
|
-
return coreWorkflowStatus<WorkflowMap>(_workflowName as string & keyof WorkflowMap) as PikkuFunctionConfig<
|
|
143
|
-
{ runId: string },
|
|
144
|
-
{ id: string; status: 'running' | 'completed' | 'failed' | 'cancelled'; output?: WorkflowMap[Name]['output']; error?: { message?: string } },
|
|
145
|
-
'session' | 'rpc'
|
|
146
|
-
>
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
export const graphStart = <Name extends keyof GraphsMap, Node extends string & keyof GraphsMap[Name]>(
|
|
150
|
-
graphName: Name,
|
|
151
|
-
startNode: Node
|
|
152
|
-
) => {
|
|
153
|
-
return coreGraphStart<GraphsMap>(graphName as string & keyof GraphsMap, startNode as string) as PikkuFunctionConfig<
|
|
154
|
-
GraphsMap[Name][Node] extends { input: infer I } ? I : never,
|
|
155
|
-
{ runId: string },
|
|
156
|
-
'session' | 'rpc'
|
|
157
|
-
>
|
|
158
|
-
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Addon package types for pikkuAddonConfig and pikkuAddonServices
|
|
6
6
|
*/
|
|
7
|
-
import type { CreateConfig } from '@pikku/core';
|
|
7
|
+
import type { CreateConfig, PikkuWire } from '@pikku/core';
|
|
8
8
|
import type { SingletonServices } from '../../types/application-types.d.js';
|
|
9
9
|
import type { Config } from '../../types/application-types.d.js';
|
|
10
10
|
import type { RequiredSingletonServices } from '../pikku-services.gen.js';
|
|
@@ -46,4 +46,20 @@ export declare const pikkuAddonConfig: <ExistingServices extends Omit<Partial<Si
|
|
|
46
46
|
* ```
|
|
47
47
|
*/
|
|
48
48
|
export declare const pikkuAddonServices: <T extends Record<string, any>, ExistingServices extends Omit<Partial<SingletonServices>, "variables" | "secrets"> & AddonBaseServices>(func: (config: Config, services: ExistingServices) => Promise<T>) => (config: Config, existingServices?: Partial<SingletonServices>) => Promise<RequiredSingletonServices>;
|
|
49
|
+
/**
|
|
50
|
+
* Creates a Pikku wire services factory for addon packages.
|
|
51
|
+
* Wire services are created per-request and have access to the HTTP request context.
|
|
52
|
+
*
|
|
53
|
+
* @param func - Wire services factory function that receives singleton services and the wire context
|
|
54
|
+
* @returns The wire services factory function
|
|
55
|
+
*
|
|
56
|
+
* @example
|
|
57
|
+
* ```typescript
|
|
58
|
+
* export const createWireServices = pikkuAddonWireServices(async (services, wire) => {
|
|
59
|
+
* const authHeader = wire.http?.request?.header('authorization')
|
|
60
|
+
* return { myService: new MyService(authHeader) }
|
|
61
|
+
* })
|
|
62
|
+
* ```
|
|
63
|
+
*/
|
|
64
|
+
export declare const pikkuAddonWireServices: <ExistingServices extends Omit<Partial<SingletonServices>, "variables" | "secrets"> & AddonBaseServices>(func: (services: ExistingServices, wire: PikkuWire) => Promise<Record<string, any>>) => any;
|
|
49
65
|
//# sourceMappingURL=pikku-addon-types.gen.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pikku-addon-types.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/addon/pikku-addon-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"pikku-addon-types.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/addon/pikku-addon-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAC1D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,oCAAoC,CAAA;AAC3E,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oCAAoC,CAAA;AAChE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAA;AACzE,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAA;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAA;AAM3E;;;GAGG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,MAAM,EAAE,iBAAiB,CAAC,QAAQ,CAAC,CAAA;IACnC,SAAS,EAAE,qBAAqB,CAAA;IAChC,OAAO,EAAE,kBAAkB,CAAA;CAC5B,CAAA;AAED;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,GAAI,gBAAgB,SAAS,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC,GAAG,iBAAiB,EACrI,MAAM,CAAC,QAAQ,EAAE,gBAAgB,KAAK,OAAO,CAAC,MAAM,CAAC,KACpD,YAAY,CAAC,MAAM,CAKrB,CAAA;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,kBAAkB,GAAI,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,gBAAgB,SAAS,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC,GAAG,iBAAiB,EACtK,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,gBAAgB,KAAK,OAAO,CAAC,CAAC,CAAC,MAElD,QAAQ,MAAM,EAAE,mBAAmB,OAAO,CAAC,iBAAiB,CAAC,KAAG,OAAO,CAAC,yBAAyB,CAchH,CAAA;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,sBAAsB,GAAI,gBAAgB,SAAS,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC,GAAG,iBAAiB,EAC3I,MAAM,CAAC,QAAQ,EAAE,gBAAgB,EAAE,IAAI,EAAE,SAAS,KAAK,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,KAM7E,GACP,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Addon package types for pikkuAddonConfig and pikkuAddonServices
|
|
@@ -39,17 +39,40 @@ export const pikkuAddonConfig = (func) => {
|
|
|
39
39
|
*/
|
|
40
40
|
export const pikkuAddonServices = (func) => {
|
|
41
41
|
return async (config, existingServices) => {
|
|
42
|
-
const { logger, variables, secrets } = (existingServices ?? {});
|
|
42
|
+
const { logger, variables, secrets, schema } = (existingServices ?? {});
|
|
43
43
|
const typedVariables = new TypedVariablesService(variables);
|
|
44
44
|
const typedSecrets = new TypedSecretService(secrets);
|
|
45
45
|
const result = await func(config, { ...existingServices, logger, variables: typedVariables, secrets: typedSecrets });
|
|
46
46
|
return {
|
|
47
47
|
config,
|
|
48
48
|
logger,
|
|
49
|
+
schema,
|
|
49
50
|
variables: typedVariables,
|
|
50
51
|
secrets: typedSecrets,
|
|
51
52
|
...result,
|
|
52
53
|
};
|
|
53
54
|
};
|
|
54
55
|
};
|
|
56
|
+
/**
|
|
57
|
+
* Creates a Pikku wire services factory for addon packages.
|
|
58
|
+
* Wire services are created per-request and have access to the HTTP request context.
|
|
59
|
+
*
|
|
60
|
+
* @param func - Wire services factory function that receives singleton services and the wire context
|
|
61
|
+
* @returns The wire services factory function
|
|
62
|
+
*
|
|
63
|
+
* @example
|
|
64
|
+
* ```typescript
|
|
65
|
+
* export const createWireServices = pikkuAddonWireServices(async (services, wire) => {
|
|
66
|
+
* const authHeader = wire.http?.request?.header('authorization')
|
|
67
|
+
* return { myService: new MyService(authHeader) }
|
|
68
|
+
* })
|
|
69
|
+
* ```
|
|
70
|
+
*/
|
|
71
|
+
export const pikkuAddonWireServices = (func) => {
|
|
72
|
+
return ((services, wire) => {
|
|
73
|
+
const typedVariables = new TypedVariablesService(services.variables);
|
|
74
|
+
const typedSecrets = new TypedSecretService(services.secrets);
|
|
75
|
+
return func({ ...services, variables: typedVariables, secrets: typedSecrets }, wire);
|
|
76
|
+
});
|
|
77
|
+
};
|
|
55
78
|
//# sourceMappingURL=pikku-addon-types.gen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pikku-addon-types.gen.js","sourceRoot":"","sources":["../../../.pikku/addon/pikku-addon-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAMH,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAA;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAA;
|
|
1
|
+
{"version":3,"file":"pikku-addon-types.gen.js","sourceRoot":"","sources":["../../../.pikku/addon/pikku-addon-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAMH,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAA;AACpE,OAAO,EAAE,qBAAqB,EAAE,MAAM,qCAAqC,CAAA;AAgB3E;;;;GAIG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC9B,IAAqD,EAC/B,EAAE;IACxB,OAAO,CAAC,KAAK,EAAE,UAAe,EAAE,gBAA6C,EAAmB,EAAE;QAChG,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC,gBAAgB,IAAI,EAAE,CAAiC,CAAA;QAChG,OAAO,IAAI,CAAC,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,IAAI,kBAAkB,CAAC,OAAO,CAAC,EAAE,SAAS,EAAE,IAAI,qBAAqB,CAAC,SAAS,CAAC,EAAsB,CAAC,CAAA;IACzI,CAAC,CAAoC,CAAA;AACvC,CAAC,CAAA;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAChC,IAAgE,EAChE,EAAE;IACF,OAAO,KAAK,EAAE,MAAc,EAAE,gBAA6C,EAAsC,EAAE;QACjH,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,CAAC,gBAAgB,IAAI,EAAE,CAAiC,CAAA;QACvG,MAAM,cAAc,GAAG,IAAI,qBAAqB,CAAC,SAAS,CAAC,CAAA;QAC3D,MAAM,YAAY,GAAG,IAAI,kBAAkB,CAAC,OAAO,CAAC,CAAA;QACpD,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,MAAM,EAAE,EAAE,GAAG,gBAAgB,EAAE,MAAM,EAAE,SAAS,EAAE,cAAc,EAAE,OAAO,EAAE,YAAY,EAAsB,CAAC,CAAA;QACxI,OAAO;YACL,MAAM;YACN,MAAM;YACN,MAAM;YACN,SAAS,EAAE,cAAc;YACzB,OAAO,EAAE,YAAY;YACrB,GAAG,MAAM;SAC8B,CAAA;IAC3C,CAAC,CAAA;AACH,CAAC,CAAA;AAED;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAG,CACpC,IAAmF,EACnF,EAAE;IACF,OAAO,CAAC,CAAC,QAAa,EAAE,IAAe,EAAE,EAAE;QACzC,MAAM,cAAc,GAAG,IAAI,qBAAqB,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAA;QACpE,MAAM,YAAY,GAAG,IAAI,kBAAkB,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAA;QAC7D,OAAO,IAAI,CAAC,EAAE,GAAG,QAAQ,EAAE,SAAS,EAAE,cAAc,EAAE,OAAO,EAAE,YAAY,EAAsB,EAAE,IAAI,CAAC,CAAA;IAC1G,CAAC,CAAQ,CAAA;AACX,CAAC,CAAA"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Addon package types for pikkuAddonConfig and pikkuAddonServices
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import type { CreateConfig } from '@pikku/core'
|
|
8
|
+
import type { CreateConfig, PikkuWire } from '@pikku/core'
|
|
9
9
|
import type { SingletonServices } from '../../types/application-types.d.js'
|
|
10
10
|
import type { Config } from '../../types/application-types.d.js'
|
|
11
11
|
import type { RequiredSingletonServices } from '../pikku-services.gen.js'
|
|
@@ -15,6 +15,7 @@ import { TypedVariablesService } from '../variables/pikku-variables.gen.js'
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
+
|
|
18
19
|
/**
|
|
19
20
|
* Base services provided to addon package service factories.
|
|
20
21
|
* These are always available from the parent application.
|
|
@@ -63,16 +64,42 @@ export const pikkuAddonServices = <T extends Record<string, any>, ExistingServic
|
|
|
63
64
|
func: (config: Config, services: ExistingServices) => Promise<T>
|
|
64
65
|
) => {
|
|
65
66
|
return async (config: Config, existingServices?: Partial<SingletonServices>): Promise<RequiredSingletonServices> => {
|
|
66
|
-
const { logger, variables, secrets } = (existingServices ?? {}) as unknown as SingletonServices
|
|
67
|
+
const { logger, variables, secrets, schema } = (existingServices ?? {}) as unknown as SingletonServices
|
|
67
68
|
const typedVariables = new TypedVariablesService(variables)
|
|
68
69
|
const typedSecrets = new TypedSecretService(secrets)
|
|
69
70
|
const result = await func(config, { ...existingServices, logger, variables: typedVariables, secrets: typedSecrets } as ExistingServices)
|
|
70
71
|
return {
|
|
71
72
|
config,
|
|
72
73
|
logger,
|
|
74
|
+
schema,
|
|
73
75
|
variables: typedVariables,
|
|
74
76
|
secrets: typedSecrets,
|
|
75
77
|
...result,
|
|
76
78
|
} as unknown as RequiredSingletonServices
|
|
77
79
|
}
|
|
78
80
|
}
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* Creates a Pikku wire services factory for addon packages.
|
|
84
|
+
* Wire services are created per-request and have access to the HTTP request context.
|
|
85
|
+
*
|
|
86
|
+
* @param func - Wire services factory function that receives singleton services and the wire context
|
|
87
|
+
* @returns The wire services factory function
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* ```typescript
|
|
91
|
+
* export const createWireServices = pikkuAddonWireServices(async (services, wire) => {
|
|
92
|
+
* const authHeader = wire.http?.request?.header('authorization')
|
|
93
|
+
* return { myService: new MyService(authHeader) }
|
|
94
|
+
* })
|
|
95
|
+
* ```
|
|
96
|
+
*/
|
|
97
|
+
export const pikkuAddonWireServices = <ExistingServices extends Omit<Partial<SingletonServices>, 'variables' | 'secrets'> & AddonBaseServices>(
|
|
98
|
+
func: (services: ExistingServices, wire: PikkuWire) => Promise<Record<string, any>>
|
|
99
|
+
) => {
|
|
100
|
+
return ((services: any, wire: PikkuWire) => {
|
|
101
|
+
const typedVariables = new TypedVariablesService(services.variables)
|
|
102
|
+
const typedSecrets = new TypedSecretService(services.secrets)
|
|
103
|
+
return func({ ...services, variables: typedVariables, secrets: typedSecrets } as ExistingServices, wire)
|
|
104
|
+
}) as any
|
|
105
|
+
}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { pikkuState } from '@pikku/core/internal';
|
|
5
5
|
import { createSingletonServices as createSingletonServices } from '../../src/services.js';
|
|
6
6
|
pikkuState('@pikku/addon-graph', 'package', 'factories', {
|
|
7
7
|
createSingletonServices,
|
|
8
8
|
});
|
|
9
|
+
pikkuState('@pikku/addon-graph', 'package', 'requiredParentServices', ["jwt"]);
|
|
9
10
|
//# sourceMappingURL=pikku-package.gen.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pikku-package.gen.js","sourceRoot":"","sources":["../../../.pikku/addon/pikku-package.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACjD,OAAO,EAAE,uBAAuB,IAAI,uBAAuB,EAAE,MAAM,uBAAuB,CAAA;AAE1F,UAAU,CAAC,oBAAoB,EAAE,SAAS,EAAE,WAAW,EAAE;IACvD,uBAAuB;CACxB,CAAC,CAAA"}
|
|
1
|
+
{"version":3,"file":"pikku-package.gen.js","sourceRoot":"","sources":["../../../.pikku/addon/pikku-package.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACjD,OAAO,EAAE,uBAAuB,IAAI,uBAAuB,EAAE,MAAM,uBAAuB,CAAA;AAE1F,UAAU,CAAC,oBAAoB,EAAE,SAAS,EAAE,WAAW,EAAE;IACvD,uBAAuB;CACxB,CAAC,CAAA;AAEF,UAAU,CAAC,oBAAoB,EAAE,SAAS,EAAE,wBAAwB,EAAE,CAAC,KAAK,CAAC,CAAC,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
4
|
import { pikkuState } from '@pikku/core/internal'
|
|
5
5
|
import { createSingletonServices as createSingletonServices } from '../../src/services.js'
|
|
@@ -7,3 +7,5 @@ import { createSingletonServices as createSingletonServices } from '../../src/se
|
|
|
7
7
|
pikkuState('@pikku/addon-graph', 'package', 'factories', {
|
|
8
8
|
createSingletonServices,
|
|
9
9
|
})
|
|
10
|
+
|
|
11
|
+
pikkuState('@pikku/addon-graph', 'package', 'requiredParentServices', ["jwt"])
|
|
@@ -1,16 +1,4 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* This file was generated by @pikku/cli@0.12.
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.19
|
|
3
3
|
*/
|
|
4
|
-
|
|
5
|
-
* Agent type map with output types for each agent
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
interface AgentHandler<O> {
|
|
12
|
-
output: O;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export type AgentMap = {
|
|
16
|
-
};
|
|
4
|
+
export type AgentMap = {}
|