@requence/service 1.0.0-alpha.5 → 1.0.0-alpha.51

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 (99) hide show
  1. package/CHANGELOG.md +276 -0
  2. package/build/{chunk-0x9092n4.js → chunk-6w7td62p.js} +5 -44
  3. package/build/chunk-6w7td62p.js.map +10 -0
  4. package/build/cli.js +123 -25
  5. package/build/cli.js.map +3 -3
  6. package/build/index.js +979 -840
  7. package/build/index.js.map +18 -16
  8. package/build/types/helpers/src/files/RequenceFile.d.ts +40 -0
  9. package/build/types/helpers/src/files/RequenceFile.d.ts.map +1 -0
  10. package/build/types/helpers/src/files/RequenceStream.d.ts +32 -0
  11. package/build/types/helpers/src/files/RequenceStream.d.ts.map +1 -0
  12. package/build/types/helpers/src/files/fileObject.d.ts +16 -0
  13. package/build/types/helpers/src/files/fileObject.d.ts.map +1 -0
  14. package/build/types/helpers/src/files/index.d.ts +7 -0
  15. package/build/types/helpers/src/files/index.d.ts.map +1 -0
  16. package/build/types/helpers/src/files/isValidMimeType.d.ts +5 -0
  17. package/build/types/helpers/src/files/isValidMimeType.d.ts.map +1 -0
  18. package/build/types/helpers/src/files/mapOutput.d.ts +10 -0
  19. package/build/types/helpers/src/files/mapOutput.d.ts.map +1 -0
  20. package/build/types/helpers/src/files/streamObject.d.ts +14 -0
  21. package/build/types/helpers/src/files/streamObject.d.ts.map +1 -0
  22. package/build/types/helpers/src/files/types.d.ts +4 -0
  23. package/build/types/helpers/src/files/types.d.ts.map +1 -0
  24. package/build/types/helpers/src/index.d.ts +12 -6
  25. package/build/types/helpers/src/index.d.ts.map +1 -1
  26. package/build/types/helpers/src/jsonschema/mapSchema.d.ts +20 -0
  27. package/build/types/helpers/src/jsonschema/mapSchema.d.ts.map +1 -0
  28. package/build/types/helpers/src/jsonschema/types.d.ts +13 -0
  29. package/build/types/helpers/src/jsonschema/types.d.ts.map +1 -0
  30. package/build/types/helpers/src/jsonschema/validate.d.ts +32 -0
  31. package/build/types/helpers/src/jsonschema/validate.d.ts.map +1 -0
  32. package/build/types/helpers/src/jsonschema/zod.d.ts +17 -0
  33. package/build/types/helpers/src/jsonschema/zod.d.ts.map +1 -0
  34. package/build/types/helpers/src/protocol/NodeTree.d.ts +496 -0
  35. package/build/types/helpers/src/protocol/NodeTree.d.ts.map +1 -0
  36. package/build/types/helpers/src/protocol/command.d.ts +481 -0
  37. package/build/types/helpers/src/protocol/command.d.ts.map +1 -0
  38. package/build/types/helpers/src/protocol/helpers.d.ts +7 -0
  39. package/build/types/helpers/src/protocol/helpers.d.ts.map +1 -0
  40. package/build/types/helpers/src/protocol/index.d.ts +8 -0
  41. package/build/types/helpers/src/protocol/index.d.ts.map +1 -0
  42. package/build/types/helpers/src/protocol/nodeType.d.ts +171 -0
  43. package/build/types/helpers/src/protocol/nodeType.d.ts.map +1 -0
  44. package/build/types/helpers/src/protocol/taskOptions.d.ts +20 -0
  45. package/build/types/helpers/src/protocol/taskOptions.d.ts.map +1 -0
  46. package/build/types/helpers/src/protocol/templateNodeTypes.d.ts +267 -0
  47. package/build/types/helpers/src/protocol/templateNodeTypes.d.ts.map +1 -0
  48. package/build/types/helpers/src/protocol/treeNodes.d.ts +836 -0
  49. package/build/types/helpers/src/protocol/treeNodes.d.ts.map +1 -0
  50. package/build/types/helpers/src/protocol/update.d.ts +383 -0
  51. package/build/types/helpers/src/protocol/update.d.ts.map +1 -0
  52. package/build/types/helpers/src/utils/callbackToAsyncIterator.d.ts +3 -0
  53. package/build/types/helpers/src/utils/callbackToAsyncIterator.d.ts.map +1 -0
  54. package/build/types/helpers/src/utils/clone.d.ts +3 -0
  55. package/build/types/helpers/src/utils/clone.d.ts.map +1 -0
  56. package/build/types/helpers/src/utils/createObjectProxy.d.ts +2 -0
  57. package/build/types/helpers/src/utils/createObjectProxy.d.ts.map +1 -0
  58. package/build/types/helpers/src/utils/debounce.d.ts +4 -0
  59. package/build/types/helpers/src/utils/debounce.d.ts.map +1 -0
  60. package/build/types/helpers/src/utils/guards.d.ts +3 -0
  61. package/build/types/helpers/src/utils/guards.d.ts.map +1 -0
  62. package/build/types/helpers/src/utils/mapData.d.ts +18 -0
  63. package/build/types/helpers/src/utils/mapData.d.ts.map +1 -0
  64. package/build/types/helpers/src/{utils.d.ts → utils/matchSchema.d.ts} +2 -2
  65. package/build/types/helpers/src/utils/matchSchema.d.ts.map +1 -0
  66. package/build/types/helpers/src/utils/obfuscate.d.ts.map +1 -0
  67. package/build/types/helpers/src/utils/obj.d.ts +4 -0
  68. package/build/types/helpers/src/utils/obj.d.ts.map +1 -0
  69. package/build/types/helpers/src/utils/requenceCallback.d.ts +17 -0
  70. package/build/types/helpers/src/utils/requenceCallback.d.ts.map +1 -0
  71. package/build/types/helpers/src/utils/resolveRequenceTypes.d.ts +8 -0
  72. package/build/types/helpers/src/utils/resolveRequenceTypes.d.ts.map +1 -0
  73. package/build/types/helpers/src/utils/types.d.ts +7 -0
  74. package/build/types/helpers/src/utils/types.d.ts.map +1 -0
  75. package/build/types/service/src/createAmqpConnection.d.ts +29 -27
  76. package/build/types/service/src/createAmqpConnection.d.ts.map +1 -1
  77. package/build/types/service/src/errors.d.ts +3 -0
  78. package/build/types/service/src/errors.d.ts.map +1 -0
  79. package/build/types/service/src/helpers.d.ts +72 -90
  80. package/build/types/service/src/helpers.d.ts.map +1 -1
  81. package/build/types/service/src/index.d.ts +11 -4
  82. package/build/types/service/src/index.d.ts.map +1 -1
  83. package/build/types/service/src/macro.d.ts +2 -0
  84. package/build/types/service/src/macro.d.ts.map +1 -0
  85. package/build/types/service/src/mapInput.d.ts +2 -0
  86. package/build/types/service/src/mapInput.d.ts.map +1 -0
  87. package/build/types/service/src/utils.d.ts +6 -0
  88. package/build/types/service/src/utils.d.ts.map +1 -0
  89. package/package.json +10 -7
  90. package/build/chunk-0x9092n4.js.map +0 -12
  91. package/build/types/helpers/src/clone.d.ts +0 -3
  92. package/build/types/helpers/src/clone.d.ts.map +0 -1
  93. package/build/types/helpers/src/createObjectProxy.d.ts +0 -2
  94. package/build/types/helpers/src/createObjectProxy.d.ts.map +0 -1
  95. package/build/types/helpers/src/createRemotePromise.d.ts +0 -7
  96. package/build/types/helpers/src/createRemotePromise.d.ts.map +0 -1
  97. package/build/types/helpers/src/obfuscate.d.ts.map +0 -1
  98. package/build/types/helpers/src/utils.d.ts.map +0 -1
  99. /package/build/types/helpers/src/{obfuscate.d.ts → utils/obfuscate.d.ts} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,281 @@
1
1
  # @requence/service
2
2
 
3
+ ## 1.0.0-alpha.51
4
+
5
+ ### Patch Changes
6
+
7
+ - f67ef38: zod v4 issue
8
+
9
+ ## 1.0.0-alpha.50
10
+
11
+ ### Patch Changes
12
+
13
+ - 3a4654c: road to 1.0
14
+
15
+ ## 1.0.0-alpha.49
16
+
17
+ ### Patch Changes
18
+
19
+ - 143d23d: throw an error when a message key is used twice
20
+
21
+ ## 1.0.0-alpha.48
22
+
23
+ ### Patch Changes
24
+
25
+ - dbcc97a: better logging and message order
26
+
27
+ ## 1.0.0-alpha.47
28
+
29
+ ### Patch Changes
30
+
31
+ - 895de9e: improved service error messages
32
+
33
+ ## 1.0.0-alpha.46
34
+
35
+ ### Patch Changes
36
+
37
+ - 0480927: event sourcing
38
+
39
+ ## 1.0.0-alpha.45
40
+
41
+ ### Patch Changes
42
+
43
+ - 533dc5d: fixed bun version
44
+
45
+ ## 1.0.0-alpha.44
46
+
47
+ ### Patch Changes
48
+
49
+ - 7b2e007: added ttl and retry to ui
50
+
51
+ ## 1.0.0-alpha.43
52
+
53
+ ### Patch Changes
54
+
55
+ - a2c6256: add missing types
56
+
57
+ ## 1.0.0-alpha.42
58
+
59
+ ### Patch Changes
60
+
61
+ - cc258b9: added types for amqplib
62
+
63
+ ## 1.0.0-alpha.41
64
+
65
+ ### Patch Changes
66
+
67
+ - 3175063: new service layout
68
+
69
+ ## 1.0.0-alpha.40
70
+
71
+ ### Patch Changes
72
+
73
+ - 4952eff: python types & bug fixes
74
+
75
+ ## 1.0.0-alpha.39
76
+
77
+ ### Patch Changes
78
+
79
+ - e50d691: use setup code to consume and create queues
80
+
81
+ ## 1.0.0-alpha.38
82
+
83
+ ### Patch Changes
84
+
85
+ - 0c7da80: python types
86
+
87
+ ## 1.0.0-alpha.37
88
+
89
+ ### Patch Changes
90
+
91
+ - b1c67cc: make package.json not mandatory during execution #2
92
+
93
+ ## 1.0.0-alpha.36
94
+
95
+ ### Patch Changes
96
+
97
+ - 08a3d9d: make package.json not mandatory during execution
98
+
99
+ ## 1.0.0-alpha.35
100
+
101
+ ### Patch Changes
102
+
103
+ - b68da9e: linting
104
+
105
+ ## 1.0.0-alpha.34
106
+
107
+ ### Patch Changes
108
+
109
+ - 106afe2: ease version naming restrictions, added iterator helpers to service, added default for boolean and number
110
+
111
+ ## 1.0.0-alpha.33
112
+
113
+ ### Patch Changes
114
+
115
+ - 3463821: wait for connect before assume backchannel exists
116
+
117
+ ## 1.0.0-alpha.32
118
+
119
+ ### Patch Changes
120
+
121
+ - 6555130: fix order of creation
122
+
123
+ ## 1.0.0-alpha.31
124
+
125
+ ### Patch Changes
126
+
127
+ - 9ab17d6: ui improvements, reduce time between backchannel creation and usage
128
+
129
+ ## 1.0.0-alpha.30
130
+
131
+ ### Patch Changes
132
+
133
+ - 63b22b8: fix library display
134
+
135
+ ## 1.0.0-alpha.29
136
+
137
+ ### Patch Changes
138
+
139
+ - e8e7ace: ack after done
140
+
141
+ ## 1.0.0-alpha.28
142
+
143
+ ### Patch Changes
144
+
145
+ - d6b58d4: communicate libversion
146
+
147
+ ## 1.0.0-alpha.27
148
+
149
+ ### Patch Changes
150
+
151
+ - d316984: persist operator instance name
152
+
153
+ ## 1.0.0-alpha.26
154
+
155
+ ### Patch Changes
156
+
157
+ - f6c481d: make services resumable in continuous mode
158
+
159
+ ## 1.0.0-alpha.25
160
+
161
+ ### Patch Changes
162
+
163
+ - d91ec98: added callback types
164
+
165
+ ## 1.0.0-alpha.24
166
+
167
+ ### Patch Changes
168
+
169
+ - f2a63fa: added missing type
170
+
171
+ ## 1.0.0-alpha.23
172
+
173
+ ### Patch Changes
174
+
175
+ - 13c28db: backchannel
176
+
177
+ ## 1.0.0-alpha.22
178
+
179
+ ### Patch Changes
180
+
181
+ - 7cbcfe5: continuous mode improvement
182
+
183
+ ## 1.0.0-alpha.21
184
+
185
+ ### Patch Changes
186
+
187
+ - a5c0c46: scaling
188
+
189
+ ## 1.0.0-alpha.20
190
+
191
+ ### Patch Changes
192
+
193
+ - a8b9588: rerelease
194
+
195
+ ## 1.0.0-alpha.19
196
+
197
+ ### Patch Changes
198
+
199
+ - 817e7ee: granular data / sub tasks / operator logic
200
+
201
+ ## 1.0.0-alpha.18
202
+
203
+ ### Patch Changes
204
+
205
+ - 515325e: use isRecord from helper package
206
+
207
+ ## 1.0.0-alpha.17
208
+
209
+ ### Patch Changes
210
+
211
+ - 41ef8e2: allow overwriting tls options
212
+
213
+ ## 1.0.0-alpha.16
214
+
215
+ ### Patch Changes
216
+
217
+ - 3a5e3e2: allow more access token options
218
+
219
+ ## 1.0.0-alpha.15
220
+
221
+ ### Patch Changes
222
+
223
+ - dc413ab: deps update
224
+
225
+ ## 1.0.0-alpha.14
226
+
227
+ ### Patch Changes
228
+
229
+ - 77bc2ed: improved task creation and event order
230
+
231
+ ## 1.0.0-alpha.13
232
+
233
+ ### Patch Changes
234
+
235
+ - 9dcaeae: fixed dependencies
236
+
237
+ ## 1.0.0-alpha.12
238
+
239
+ ### Patch Changes
240
+
241
+ - 1df3d43: improved typing
242
+
243
+ ## 1.0.0-alpha.11
244
+
245
+ ### Patch Changes
246
+
247
+ - 679cbaf: streams
248
+
249
+ ## 1.0.0-alpha.10
250
+
251
+ ### Patch Changes
252
+
253
+ - a464543: improved file matching algorithm
254
+
255
+ ## 1.0.0-alpha.9
256
+
257
+ ### Patch Changes
258
+
259
+ - 1d847ee: improved files handling
260
+
261
+ ## 1.0.0-alpha.8
262
+
263
+ ### Patch Changes
264
+
265
+ - f7ea7fa: added files support
266
+
267
+ ## 1.0.0-alpha.7
268
+
269
+ ### Patch Changes
270
+
271
+ - 04ce4a9: improved caching and live queries
272
+
273
+ ## 1.0.0-alpha.6
274
+
275
+ ### Patch Changes
276
+
277
+ - 1a0bca0: structure redesign
278
+
3
279
  ## 1.0.0-alpha.5
4
280
 
5
281
  ### Patch Changes
@@ -1,4 +1,4 @@
1
- // ../helpers/src/obfuscate.ts
1
+ // ../helpers/src/utils/obfuscate.ts
2
2
  var separator = "";
3
3
  var base65Chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$";
4
4
  var base65CharToIndex = {};
@@ -49,47 +49,8 @@ function deobfuscate(str) {
49
49
  }
50
50
  return decodedString.split(separator);
51
51
  }
52
- // ../helpers/src/clone.ts
53
- var CLONE_SYMBOL = Symbol("original");
54
- function clone(data) {
55
- if (typeof data !== "object" || data === null) {
56
- return data;
57
- }
58
- const target = data[CLONE_SYMBOL];
59
- if (target) {
60
- return clone(target);
61
- }
62
- if (Array.isArray(data)) {
63
- return data.map(clone);
64
- }
65
- return Object.fromEntries(Object.entries(data).map(([key, value]) => [key, clone(value)]));
66
- }
67
- // ../helpers/src/createObjectProxy.ts
68
- function createObjectProxy(obj, onChange) {
69
- return new Proxy(obj, {
70
- set(target, property, newValue) {
71
- const result = Reflect.set(target, property, newValue);
72
- onChange(target);
73
- return result;
74
- },
75
- deleteProperty(target, property) {
76
- const result = Reflect.deleteProperty(target, property);
77
- onChange(target);
78
- return result;
79
- },
80
- get(target, property, receiver) {
81
- if (property === CLONE_SYMBOL) {
82
- return target;
83
- }
84
- const result = Reflect.get(target, property, receiver);
85
- if (typeof result === "object" && result !== null) {
86
- return createObjectProxy(result, () => onChange(target));
87
- }
88
- return result;
89
- }
90
- });
91
- }
92
- export { obfuscate, deobfuscate, clone, createObjectProxy };
93
52
 
94
- //# debugId=A14CF1AD3BCA776264756E2164756E21
95
- //# sourceMappingURL=chunk-0x9092n4.js.map
53
+ export { obfuscate, deobfuscate };
54
+
55
+ //# debugId=E6AE9819DA2983FC64756E2164756E21
56
+ //# sourceMappingURL=chunk-6w7td62p.js.map
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../helpers/src/utils/obfuscate.ts"],
4
+ "sourcesContent": [
5
+ "const separator = '\\u{f6ee}'\n\nconst base65Chars =\n 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$'\n\nconst base65CharToIndex: Record<string, number> = {}\nfor (let i = 0; i < base65Chars.length; i++) {\n base65CharToIndex[base65Chars[i]] = i\n}\n\nexport function obfuscate(...parts: Array<string>) {\n const str = parts.join(separator)\n let binaryString = ''\n\n for (let i = 0; i < str.length; i++) {\n const charCode = str.charCodeAt(i)\n binaryString += charCode.toString(2).padStart(16, '0')\n }\n\n let encodedString = ''\n const chunkSize = 6\n let paddingCount = 0\n\n for (let i = 0; i < binaryString.length; i += chunkSize) {\n let chunk = binaryString.substring(i, i + chunkSize)\n\n if (chunk.length < chunkSize) {\n paddingCount = chunkSize - chunk.length\n chunk = chunk.padEnd(chunkSize, '0')\n }\n\n const decimalValue = parseInt(chunk, 2)\n encodedString += base65Chars[decimalValue]\n }\n\n return encodedString + paddingCount.toString()\n}\n\nexport function randomString(length: number) {\n const randomValues = new Uint8Array(length)\n crypto.getRandomValues(randomValues)\n\n let randomString = ''\n for (let i = 0; i < length; i++) {\n randomString += base65Chars[randomValues[i] % base65Chars.length]\n }\n\n return randomString\n}\n\nexport function deobfuscate(str: string) {\n const paddingCount = parseInt(str.slice(-1), 10)\n str = str.slice(0, -1)\n\n let binaryString = ''\n\n for (let i = 0; i < str.length; i++) {\n const decimalValue = base65CharToIndex[str[i]]\n const binaryChunk = decimalValue.toString(2).padStart(6, '0')\n binaryString += binaryChunk\n }\n\n if (paddingCount > 0) {\n binaryString = binaryString.slice(0, -paddingCount)\n }\n\n let decodedString = ''\n const charSize = 16\n\n for (let i = 0; i < binaryString.length; i += charSize) {\n const byte = binaryString.substring(i, i + charSize)\n if (byte.length === 16) {\n const charCode = parseInt(byte, 2)\n decodedString += String.fromCharCode(charCode)\n }\n }\n\n return decodedString.split(separator)\n}\n"
6
+ ],
7
+ "mappings": ";AAAA,IAAM,YAAY;AAElB,IAAM,cACJ;AAEF,IAAM,oBAA4C,CAAC;AACnD,SAAS,IAAI,EAAG,IAAI,YAAY,QAAQ,KAAK;AAAA,EAC3C,kBAAkB,YAAY,MAAM;AACtC;AAEO,SAAS,SAAS,IAAI,OAAsB;AAAA,EACjD,MAAM,MAAM,MAAM,KAAK,SAAS;AAAA,EAChC,IAAI,eAAe;AAAA,EAEnB,SAAS,IAAI,EAAG,IAAI,IAAI,QAAQ,KAAK;AAAA,IACnC,MAAM,WAAW,IAAI,WAAW,CAAC;AAAA,IACjC,gBAAgB,SAAS,SAAS,CAAC,EAAE,SAAS,IAAI,GAAG;AAAA,EACvD;AAAA,EAEA,IAAI,gBAAgB;AAAA,EACpB,MAAM,YAAY;AAAA,EAClB,IAAI,eAAe;AAAA,EAEnB,SAAS,IAAI,EAAG,IAAI,aAAa,QAAQ,KAAK,WAAW;AAAA,IACvD,IAAI,QAAQ,aAAa,UAAU,GAAG,IAAI,SAAS;AAAA,IAEnD,IAAI,MAAM,SAAS,WAAW;AAAA,MAC5B,eAAe,YAAY,MAAM;AAAA,MACjC,QAAQ,MAAM,OAAO,WAAW,GAAG;AAAA,IACrC;AAAA,IAEA,MAAM,eAAe,SAAS,OAAO,CAAC;AAAA,IACtC,iBAAiB,YAAY;AAAA,EAC/B;AAAA,EAEA,OAAO,gBAAgB,aAAa,SAAS;AAAA;AAexC,SAAS,WAAW,CAAC,KAAa;AAAA,EACvC,MAAM,eAAe,SAAS,IAAI,MAAM,EAAE,GAAG,EAAE;AAAA,EAC/C,MAAM,IAAI,MAAM,GAAG,EAAE;AAAA,EAErB,IAAI,eAAe;AAAA,EAEnB,SAAS,IAAI,EAAG,IAAI,IAAI,QAAQ,KAAK;AAAA,IACnC,MAAM,eAAe,kBAAkB,IAAI;AAAA,IAC3C,MAAM,cAAc,aAAa,SAAS,CAAC,EAAE,SAAS,GAAG,GAAG;AAAA,IAC5D,gBAAgB;AAAA,EAClB;AAAA,EAEA,IAAI,eAAe,GAAG;AAAA,IACpB,eAAe,aAAa,MAAM,IAAI,YAAY;AAAA,EACpD;AAAA,EAEA,IAAI,gBAAgB;AAAA,EACpB,MAAM,WAAW;AAAA,EAEjB,SAAS,IAAI,EAAG,IAAI,aAAa,QAAQ,KAAK,UAAU;AAAA,IACtD,MAAM,OAAO,aAAa,UAAU,GAAG,IAAI,QAAQ;AAAA,IACnD,IAAI,KAAK,WAAW,IAAI;AAAA,MACtB,MAAM,WAAW,SAAS,MAAM,CAAC;AAAA,MACjC,iBAAiB,OAAO,aAAa,QAAQ;AAAA,IAC/C;AAAA,EACF;AAAA,EAEA,OAAO,cAAc,MAAM,SAAS;AAAA;",
8
+ "debugId": "E6AE9819DA2983FC64756E2164756E21",
9
+ "names": []
10
+ }
package/build/cli.js CHANGED
@@ -1,62 +1,160 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  deobfuscate
4
- } from "./chunk-0x9092n4.js";
4
+ } from "./chunk-6w7td62p.js";
5
5
 
6
6
  // src/cli.ts
7
7
  import fs from "node:fs";
8
8
  import path from "node:path";
9
9
  import chalk from "chalk";
10
+ import { createEventSource } from "eventsource-client";
10
11
  import yargs from "yargs";
11
12
  import { hideBin } from "yargs/helpers";
13
+ import { z } from "zod/v4";
12
14
  var y = yargs(hideBin(process.argv));
15
+ var colors = {
16
+ red: chalk.hex("#ef4444"),
17
+ green: chalk.hex("#22c55e"),
18
+ yellow: chalk.hex("#eab308"),
19
+ orange: chalk.hex("#f97316"),
20
+ zinc: chalk.hex("#71717a")
21
+ };
13
22
  function errorExit(title, text) {
14
- console.error(chalk.red.bold(title + `
23
+ console.error(colors.red.bold(title + `
15
24
  `));
16
25
  if (text) {
17
- console.error(chalk.red(text) + `
26
+ console.error(colors.red(text) + `
18
27
  `);
19
28
  }
20
29
  process.exit(1);
21
30
  }
31
+ var pkgJson;
32
+ function loadPkgJson() {
33
+ if (!pkgJson) {
34
+ pkgJson = JSON.parse(fs.readFileSync("package.json", "utf-8"));
35
+ }
36
+ return pkgJson;
37
+ }
38
+ async function fetchTypes(url, headers, targetFile, clear = false, showTimestamp = false) {
39
+ const timestamp = () => colors.zinc(new Date().toLocaleTimeString("en-GB", { hour12: false }));
40
+ const response = await fetch(url, {
41
+ method: "GET",
42
+ headers
43
+ });
44
+ const branchName = response.headers.get("x-branch-name");
45
+ const text = await response.text();
46
+ if (!response.ok) {
47
+ errorExit(text);
48
+ }
49
+ let header = `// Generated by requence-service CLI — DO NOT EDIT.
50
+ // Changes will be overwritten.
51
+
52
+ `;
53
+ if (branchName) {
54
+ header += `// !!! types for branch "${branchName}" !!!
55
+
56
+ `;
57
+ }
58
+ const data = `${header}/* eslint-disable */
59
+ /* prettier-ignore */
60
+
61
+ ${text}`;
62
+ fs.writeFileSync(targetFile, data);
63
+ if (clear) {
64
+ console.clear();
65
+ }
66
+ if (branchName) {
67
+ console.info(...showTimestamp ? [timestamp()] : [], colors.yellow("types for branch", chalk.bold(branchName), "saved to", chalk.bold(path.relative(process.cwd(), targetFile))));
68
+ } else {
69
+ console.info(...showTimestamp ? [timestamp()] : [], colors.green("types saved to", chalk.bold(path.relative(process.cwd(), targetFile))));
70
+ }
71
+ }
22
72
  y.command("generate-types", "generates typescript types", (yargs2) => yargs2.option("access-token", {
23
- describe: "service key"
73
+ describe: "access token",
74
+ type: "string"
75
+ }).option("dev-token", {
76
+ description: "dev token",
77
+ type: "string"
24
78
  }).option("outfile", {
25
79
  default: "requence-env.d.ts"
26
80
  }).option("outdir", {
27
81
  default: ""
82
+ }).option("watch", {
83
+ type: "boolean"
84
+ }).option("clear", {
85
+ description: "clear the terminal on watch updates (use --no-clear to disable)",
86
+ type: "boolean",
87
+ default: true
28
88
  }), async (argv) => {
29
- const token = argv.accessToken ?? process.env.REQUENCE_ACCESS_TOKEN ?? JSON.parse(fs.readFileSync("package.json", "utf-8")).requence?.accessToken;
30
- console.info();
89
+ let token = argv.accessToken ?? process.env.REQUENCE_SERVICE_ACCESS_TOKEN ?? process.env.REQUENCE_ACCESS_TOKEN;
31
90
  if (!token) {
32
- errorExit("No access token found", `You can provide the access token as argument to ${chalk.bold("createTask")},
33
- as environment variable ${chalk.bold("REQUENCE_ACCESS_TOKEN")} or
34
- in your ${chalk.bold("package.json")} in ${chalk.bold("requence.accessToken")}`);
91
+ const pkgJson2 = loadPkgJson();
92
+ token = pkgJson2.requence?.service?.accessToken ?? pkgJson2.requence?.accessToken;
93
+ }
94
+ if (argv.clear) {
95
+ console.info();
96
+ }
97
+ if (!token) {
98
+ errorExit("No access token found", `You can provide the access token as argument to ${chalk.bold("requence-service")},
99
+ as environment variable ${chalk.bold("REQUENCE_ACCESS_TOKEN")} / ${chalk.bold("REQUENCE_SERVICE_ACCESS_TOKEN")} or
100
+ in your ${chalk.bold("package.json")} in ${chalk.bold("requence.accessToken")} / ${chalk.bold("requence.service.accessToken")}`);
35
101
  }
36
102
  const parts = deobfuscate(token);
37
103
  if (parts.length !== 3 || parts[0] !== "service") {
38
104
  errorExit("Invalid service key");
39
105
  }
40
106
  const [, connectionString, serverUrl] = parts;
41
- const response = await fetch(serverUrl + "/service/types/typescript", {
42
- method: "GET",
43
- headers: {
44
- Authorization: `Bearer ${connectionString}`
107
+ const headers = {
108
+ Authorization: `Bearer ${connectionString}`
109
+ };
110
+ let devToken = argv.devToken ?? process.env.REQUENCE_SERVICE_ACCESS_TOKEN ?? process.env.REQUENCE_ACCESS_TOKEN;
111
+ if (!devToken) {
112
+ const pkgJson2 = loadPkgJson();
113
+ devToken = pkgJson2.requence?.service?.devToken ?? pkgJson2.requence?.devToken;
114
+ }
115
+ if (devToken) {
116
+ const devParts = deobfuscate(devToken);
117
+ if (devParts[0] !== "api") {
118
+ throw new Error("invalid dev token: please provide a personal access token");
45
119
  }
46
- });
47
- if (!response.ok) {
48
- const error = await response.text();
49
- errorExit(error);
120
+ if (devParts[2] !== parts[2]) {
121
+ throw new Error("invalid dev token: access token and dev token belong to different requence instances");
122
+ }
123
+ headers["x-dev-authorization"] = devParts[1];
50
124
  }
51
- const text = await response.text();
52
- const data = `/* eslint-disable */
53
- /* prettier-ignore */
125
+ await fetchTypes(serverUrl + "/service/types/typescript", headers, path.join(argv.outdir || process.cwd(), argv.outfile));
126
+ if (!argv.watch) {
127
+ return;
128
+ }
129
+ if (argv.clear) {
130
+ console.clear();
131
+ }
132
+ console.info(colors.orange.bold("Watching for type changes…"));
133
+ let lastWrite = Date.now();
134
+ const timeSchema = z.coerce.number().int().positive();
135
+ createEventSource({
136
+ method: "GET",
137
+ url: serverUrl + "/service/watch",
138
+ headers,
139
+ async onMessage({ data }) {
140
+ const timeResult = timeSchema.safeParse(data);
141
+ if (!timeResult.success || timeResult.data < lastWrite) {
142
+ return;
143
+ }
144
+ lastWrite = timeResult.data;
145
+ if (argv.clear) {
146
+ console.clear();
147
+ }
148
+ console.info(colors.zinc.bold(`Regenerating types…${argv.clear ? `
54
149
 
55
- ${text}`;
56
- const file = path.join(argv.outdir || process.cwd(), argv.outfile);
57
- fs.writeFileSync(file, data);
58
- console.info(chalk.green("types saved to", chalk.bold(path.relative(process.cwd(), file))));
150
+ ` : ""}`));
151
+ await fetchTypes(serverUrl + "/service/types/typescript", headers, path.join(argv.outdir || process.cwd(), argv.outfile), argv.clear, true);
152
+ console.info(colors.orange.bold(`${argv.clear ? `
153
+
154
+ ` : ""}Watching for type changes…`));
155
+ }
156
+ });
59
157
  }).scriptName("requence-service").help("h").demandCommand(1, 1).strict().parse();
60
158
 
61
- //# debugId=46FA48218F6D1DD064756E2164756E21
159
+ //# debugId=190F4F01CE4319C364756E2164756E21
62
160
  //# sourceMappingURL=cli.js.map
package/build/cli.js.map CHANGED
@@ -2,9 +2,9 @@
2
2
  "version": 3,
3
3
  "sources": ["../src/cli.ts"],
4
4
  "sourcesContent": [
5
- "#!/usr/bin/env node\n\nimport fs from 'node:fs'\nimport path from 'node:path'\n\nimport { deobfuscate } from '@requence/helpers'\nimport chalk from 'chalk'\nimport yargs from 'yargs'\nimport { hideBin } from 'yargs/helpers'\n\nconst y = yargs(hideBin(process.argv))\n\nfunction errorExit(title: string, text?: string): never {\n console.error(chalk.red.bold(title + '\\n'))\n if (text) {\n console.error(chalk.red(text) + '\\n')\n }\n process.exit(1)\n}\n\ny.command(\n 'generate-types',\n 'generates typescript types',\n (yargs) =>\n yargs\n .option('access-token', {\n describe: 'service key',\n })\n .option('outfile', {\n default: 'requence-env.d.ts',\n })\n .option('outdir', {\n default: '',\n }),\n async (argv) => {\n const token =\n argv.accessToken ??\n process.env.REQUENCE_ACCESS_TOKEN ??\n JSON.parse(fs.readFileSync('package.json', 'utf-8')).requence?.accessToken\n\n console.info() // newline\n if (!token) {\n errorExit(\n 'No access token found',\n `You can provide the access token as argument to ${chalk.bold('createTask')},\\nas environment variable ${chalk.bold('REQUENCE_ACCESS_TOKEN')} or\\nin your ${chalk.bold('package.json')} in ${chalk.bold('requence.accessToken')}`,\n )\n }\n\n const parts = deobfuscate(token)\n if (parts.length !== 3 || parts[0] !== 'service') {\n errorExit('Invalid service key')\n }\n\n const [, connectionString, serverUrl] = parts\n\n const response = await fetch(serverUrl + '/service/types/typescript', {\n method: 'GET',\n headers: {\n Authorization: `Bearer ${connectionString}`,\n },\n })\n\n if (!response.ok) {\n const error = await response.text()\n errorExit(error)\n }\n\n const text = await response.text()\n const data = `/* eslint-disable */\\n/* prettier-ignore */\\n\\n${text}`\n\n const file = path.join(argv.outdir || process.cwd(), argv.outfile)\n fs.writeFileSync(file, data)\n\n console.info(\n chalk.green(\n 'types saved to',\n chalk.bold(path.relative(process.cwd(), file)),\n ),\n )\n },\n)\n .scriptName('requence-service')\n .help('h')\n .demandCommand(1, 1)\n .strict()\n .parse()\n"
5
+ "#!/usr/bin/env node\n\nimport fs from 'node:fs'\nimport path from 'node:path'\n\nimport { deobfuscate } from '@requence/helpers'\nimport chalk from 'chalk'\nimport { createEventSource } from 'eventsource-client'\nimport yargs from 'yargs'\nimport { hideBin } from 'yargs/helpers'\nimport { z } from 'zod/v4'\n\nconst y = yargs(hideBin(process.argv))\n\nconst colors = {\n red: chalk.hex('#ef4444'),\n green: chalk.hex('#22c55e'),\n yellow: chalk.hex('#eab308'),\n orange: chalk.hex('#f97316'),\n zinc: chalk.hex('#71717a'),\n}\n\nfunction errorExit(title: string, text?: string): never {\n console.error(colors.red.bold(title + '\\n'))\n if (text) {\n console.error(colors.red(text) + '\\n')\n }\n process.exit(1)\n}\n\nlet pkgJson: any | null\nfunction loadPkgJson() {\n if (!pkgJson) {\n pkgJson = JSON.parse(fs.readFileSync('package.json', 'utf-8'))\n }\n return pkgJson\n}\n\nasync function fetchTypes(\n url: string,\n headers: HeadersInit,\n targetFile: string,\n clear = false,\n showTimestamp = false,\n) {\n const timestamp = () =>\n colors.zinc(new Date().toLocaleTimeString('en-GB', { hour12: false }))\n const response = await fetch(url, {\n method: 'GET',\n headers,\n })\n\n const branchName = response.headers.get('x-branch-name')\n const text = await response.text()\n\n if (!response.ok) {\n errorExit(text)\n }\n\n let header =\n '// Generated by requence-service CLI — DO NOT EDIT.\\n// Changes will be overwritten.\\n\\n'\n\n if (branchName) {\n header += `// !!! types for branch \"${branchName}\" !!!\\n\\n`\n }\n const data = `${header}/* eslint-disable */\\n/* prettier-ignore */\\n\\n${text}`\n\n fs.writeFileSync(targetFile, data)\n\n if (clear) {\n console.clear()\n }\n\n if (branchName) {\n console.info(\n ...(showTimestamp ? [timestamp()] : []),\n colors.yellow(\n 'types for branch',\n chalk.bold(branchName),\n 'saved to',\n chalk.bold(path.relative(process.cwd(), targetFile)),\n ),\n )\n } else {\n console.info(\n ...(showTimestamp ? [timestamp()] : []),\n colors.green(\n 'types saved to',\n chalk.bold(path.relative(process.cwd(), targetFile)),\n ),\n )\n }\n}\n\ny.command(\n 'generate-types',\n 'generates typescript types',\n (yargs) =>\n yargs\n .option('access-token', {\n describe: 'access token',\n type: 'string',\n })\n .option('dev-token', {\n description: 'dev token',\n type: 'string',\n })\n .option('outfile', {\n default: 'requence-env.d.ts',\n })\n .option('outdir', {\n default: '',\n })\n .option('watch', {\n type: 'boolean',\n })\n .option('clear', {\n description:\n 'clear the terminal on watch updates (use --no-clear to disable)',\n type: 'boolean',\n default: true,\n }),\n async (argv) => {\n let token =\n argv.accessToken ??\n process.env.REQUENCE_SERVICE_ACCESS_TOKEN ??\n process.env.REQUENCE_ACCESS_TOKEN\n\n if (!token) {\n const pkgJson = loadPkgJson()\n token =\n pkgJson.requence?.service?.accessToken ?? pkgJson.requence?.accessToken\n }\n\n if (argv.clear) {\n console.info() // newline\n }\n if (!token) {\n errorExit(\n 'No access token found',\n `You can provide the access token as argument to ${chalk.bold('requence-service')},\\nas environment variable ${chalk.bold('REQUENCE_ACCESS_TOKEN')} / ${chalk.bold('REQUENCE_SERVICE_ACCESS_TOKEN')} or\\nin your ${chalk.bold('package.json')} in ${chalk.bold('requence.accessToken')} / ${chalk.bold('requence.service.accessToken')}`,\n )\n }\n\n const parts = deobfuscate(token)\n if (parts.length !== 3 || parts[0] !== 'service') {\n errorExit('Invalid service key')\n }\n\n const [, connectionString, serverUrl] = parts\n const headers: HeadersInit = {\n Authorization: `Bearer ${connectionString}`,\n }\n let devToken =\n argv.devToken ??\n process.env.REQUENCE_SERVICE_ACCESS_TOKEN ??\n process.env.REQUENCE_ACCESS_TOKEN\n\n if (!devToken) {\n const pkgJson = loadPkgJson()\n devToken =\n pkgJson.requence?.service?.devToken ?? pkgJson.requence?.devToken\n }\n\n if (devToken) {\n const devParts = deobfuscate(devToken)\n if (devParts[0] !== 'api') {\n throw new Error(\n 'invalid dev token: please provide a personal access token',\n )\n }\n if (devParts[2] !== parts[2]) {\n throw new Error(\n 'invalid dev token: access token and dev token belong to different requence instances',\n )\n }\n\n headers['x-dev-authorization'] = devParts[1]\n }\n\n await fetchTypes(\n serverUrl + '/service/types/typescript',\n headers,\n path.join(argv.outdir || process.cwd(), argv.outfile),\n )\n\n if (!argv.watch) {\n return\n }\n\n if (argv.clear) {\n console.clear()\n }\n console.info(colors.orange.bold('Watching for type changes…'))\n let lastWrite = Date.now()\n const timeSchema = z.coerce.number().int().positive()\n createEventSource({\n method: 'GET',\n url: serverUrl + '/service/watch',\n headers,\n async onMessage({ data }) {\n const timeResult = timeSchema.safeParse(data)\n if (!timeResult.success || timeResult.data < lastWrite) {\n return\n }\n lastWrite = timeResult.data\n if (argv.clear) {\n console.clear()\n }\n console.info(\n colors.zinc.bold(`Regenerating types…${argv.clear ? '\\n\\n' : ''}`),\n )\n\n await fetchTypes(\n serverUrl + '/service/types/typescript',\n headers,\n path.join(argv.outdir || process.cwd(), argv.outfile),\n argv.clear,\n true,\n )\n console.info(\n colors.orange.bold(\n `${argv.clear ? '\\n\\n' : ''}Watching for type changes…`,\n ),\n )\n },\n })\n },\n)\n .scriptName('requence-service')\n .help('h')\n .demandCommand(1, 1)\n .strict()\n .parse()\n"
6
6
  ],
7
- "mappings": ";;;;;;AAEA;AACA;AAGA;AACA;AACA;AAEA,IAAM,IAAI,MAAM,QAAQ,QAAQ,IAAI,CAAC;AAErC,SAAS,SAAS,CAAC,OAAe,MAAsB;AACtD,UAAQ,MAAM,MAAM,IAAI,KAAK,QAAQ;AAAA,CAAI,CAAC;AAC1C,MAAI,MAAM;AACR,YAAQ,MAAM,MAAM,IAAI,IAAI,IAAI;AAAA,CAAI;AAAA,EACtC;AACA,UAAQ,KAAK,CAAC;AAAA;AAGhB,EAAE,QACA,kBACA,8BACA,CAAC,WACC,OACG,OAAO,gBAAgB;AAAA,EACtB,UAAU;AACZ,CAAC,EACA,OAAO,WAAW;AAAA,EACjB,SAAS;AACX,CAAC,EACA,OAAO,UAAU;AAAA,EAChB,SAAS;AACX,CAAC,GACL,OAAO,SAAS;AACd,QAAM,Q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