@t-req/sdk 0.1.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.
Files changed (44) hide show
  1. package/README.md +81 -0
  2. package/dist/client.d.ts +36 -0
  3. package/dist/client.d.ts.map +1 -0
  4. package/dist/client.js +10 -0
  5. package/dist/client.js.map +20 -0
  6. package/dist/gen/client/client.gen.d.ts +3 -0
  7. package/dist/gen/client/client.gen.d.ts.map +1 -0
  8. package/dist/gen/client/index.d.ts +9 -0
  9. package/dist/gen/client/index.d.ts.map +1 -0
  10. package/dist/gen/client/types.gen.d.ts +118 -0
  11. package/dist/gen/client/types.gen.d.ts.map +1 -0
  12. package/dist/gen/client/utils.gen.d.ts +34 -0
  13. package/dist/gen/client/utils.gen.d.ts.map +1 -0
  14. package/dist/gen/client.gen.d.ts +13 -0
  15. package/dist/gen/client.gen.d.ts.map +1 -0
  16. package/dist/gen/core/auth.gen.d.ts +19 -0
  17. package/dist/gen/core/auth.gen.d.ts.map +1 -0
  18. package/dist/gen/core/bodySerializer.gen.d.ts +26 -0
  19. package/dist/gen/core/bodySerializer.gen.d.ts.map +1 -0
  20. package/dist/gen/core/params.gen.d.ts +44 -0
  21. package/dist/gen/core/params.gen.d.ts.map +1 -0
  22. package/dist/gen/core/pathSerializer.gen.d.ts +34 -0
  23. package/dist/gen/core/pathSerializer.gen.d.ts.map +1 -0
  24. package/dist/gen/core/queryKeySerializer.gen.d.ts +19 -0
  25. package/dist/gen/core/queryKeySerializer.gen.d.ts.map +1 -0
  26. package/dist/gen/core/serverSentEvents.gen.d.ts +72 -0
  27. package/dist/gen/core/serverSentEvents.gen.d.ts.map +1 -0
  28. package/dist/gen/core/types.gen.d.ts +79 -0
  29. package/dist/gen/core/types.gen.d.ts.map +1 -0
  30. package/dist/gen/core/utils.gen.d.ts +20 -0
  31. package/dist/gen/core/utils.gen.d.ts.map +1 -0
  32. package/dist/gen/sdk.gen.d.ts +198 -0
  33. package/dist/gen/sdk.gen.d.ts.map +1 -0
  34. package/dist/gen/types.gen.d.ts +1138 -0
  35. package/dist/gen/types.gen.d.ts.map +1 -0
  36. package/dist/index.d.ts +35 -0
  37. package/dist/index.d.ts.map +1 -0
  38. package/dist/index.js +10 -0
  39. package/dist/index.js.map +22 -0
  40. package/dist/server.d.ts +26 -0
  41. package/dist/server.d.ts.map +1 -0
  42. package/dist/server.js +4 -0
  43. package/dist/server.js.map +10 -0
  44. package/package.json +74 -0
@@ -0,0 +1,1138 @@
1
+ export type ClientOptions = {
2
+ baseUrl: 'http://localhost:4097' | (string & {});
3
+ };
4
+ export type GetHealthData = {
5
+ body?: never;
6
+ path?: never;
7
+ query?: never;
8
+ url: '/health';
9
+ };
10
+ export type GetHealthResponses = {
11
+ /**
12
+ * Server is healthy
13
+ */
14
+ 200: {
15
+ healthy: true;
16
+ version: string;
17
+ };
18
+ };
19
+ export type GetHealthResponse = GetHealthResponses[keyof GetHealthResponses];
20
+ export type GetCapabilitiesData = {
21
+ body?: never;
22
+ path?: never;
23
+ query?: never;
24
+ url: '/capabilities';
25
+ };
26
+ export type GetCapabilitiesResponses = {
27
+ /**
28
+ * Server capabilities
29
+ */
30
+ 200: {
31
+ protocolVersion: string;
32
+ version: string;
33
+ features: {
34
+ sessions: boolean;
35
+ diagnostics: boolean;
36
+ streamingBodies: boolean;
37
+ };
38
+ };
39
+ };
40
+ export type GetCapabilitiesResponse = GetCapabilitiesResponses[keyof GetCapabilitiesResponses];
41
+ export type GetConfigData = {
42
+ body?: never;
43
+ path?: never;
44
+ query?: {
45
+ profile?: string;
46
+ path?: string;
47
+ };
48
+ url: '/config';
49
+ };
50
+ export type GetConfigResponses = {
51
+ /**
52
+ * Resolved configuration summary
53
+ */
54
+ 200: {
55
+ configPath?: string;
56
+ projectRoot: string;
57
+ format?: 'jsonc' | 'json' | 'ts' | 'js' | 'mjs';
58
+ profile?: string;
59
+ availableProfiles: Array<string>;
60
+ layersApplied: Array<string>;
61
+ resolvedConfig: {
62
+ variables: {
63
+ [key: string]: unknown;
64
+ };
65
+ defaults: {
66
+ timeoutMs: number;
67
+ followRedirects: boolean;
68
+ validateSSL: boolean;
69
+ proxy?: string;
70
+ headers: {
71
+ [key: string]: string;
72
+ };
73
+ };
74
+ cookies: {
75
+ enabled: boolean;
76
+ jarPath?: string;
77
+ mode: 'disabled' | 'memory' | 'persistent';
78
+ };
79
+ security: {
80
+ allowExternalFiles: boolean;
81
+ allowPluginsOutsideProject: boolean;
82
+ pluginPermissions?: {
83
+ [key: string]: Array<string>;
84
+ };
85
+ };
86
+ resolverNames: Array<string>;
87
+ };
88
+ warnings: Array<string>;
89
+ };
90
+ };
91
+ export type GetConfigResponse = GetConfigResponses[keyof GetConfigResponses];
92
+ export type PostParseData = {
93
+ body?: {
94
+ content?: string;
95
+ path?: string;
96
+ includeDiagnostics?: boolean;
97
+ };
98
+ path?: never;
99
+ query?: never;
100
+ url: '/parse';
101
+ };
102
+ export type PostParseErrors = {
103
+ /**
104
+ * Invalid request
105
+ */
106
+ 400: {
107
+ error: {
108
+ code: string;
109
+ message: string;
110
+ details?: unknown;
111
+ };
112
+ };
113
+ };
114
+ export type PostParseError = PostParseErrors[keyof PostParseErrors];
115
+ export type PostParseResponses = {
116
+ /**
117
+ * Parsed requests with diagnostics
118
+ */
119
+ 200: {
120
+ requests: Array<{
121
+ request?: {
122
+ index: number;
123
+ name?: string;
124
+ method: string;
125
+ url: string;
126
+ headers: {
127
+ [key: string]: string;
128
+ };
129
+ hasBody: boolean;
130
+ hasFormData: boolean;
131
+ hasBodyFile: boolean;
132
+ meta: {
133
+ [key: string]: string;
134
+ };
135
+ };
136
+ diagnostics: Array<{
137
+ severity: 'error' | 'warning' | 'info';
138
+ code: string;
139
+ message: string;
140
+ range: {
141
+ start: {
142
+ line: number;
143
+ column: number;
144
+ };
145
+ end: {
146
+ line: number;
147
+ column: number;
148
+ };
149
+ };
150
+ }>;
151
+ }>;
152
+ diagnostics: Array<{
153
+ severity: 'error' | 'warning' | 'info';
154
+ code: string;
155
+ message: string;
156
+ range: {
157
+ start: {
158
+ line: number;
159
+ column: number;
160
+ };
161
+ end: {
162
+ line: number;
163
+ column: number;
164
+ };
165
+ };
166
+ }>;
167
+ resolved: {
168
+ workspaceRoot: string;
169
+ projectRoot: string;
170
+ httpFilePath?: string;
171
+ basePath: string;
172
+ configPath?: string;
173
+ };
174
+ };
175
+ };
176
+ export type PostParseResponse = PostParseResponses[keyof PostParseResponses];
177
+ export type PostExecuteData = {
178
+ body?: {
179
+ content?: string;
180
+ path?: string;
181
+ requestName?: string;
182
+ requestIndex?: number;
183
+ sessionId?: string;
184
+ profile?: string;
185
+ variables?: {
186
+ [key: string]: unknown;
187
+ };
188
+ flowId?: string;
189
+ reqLabel?: string;
190
+ timeoutMs?: number;
191
+ basePath?: string;
192
+ followRedirects?: boolean;
193
+ validateSSL?: boolean;
194
+ };
195
+ path?: never;
196
+ query?: never;
197
+ url: '/execute';
198
+ };
199
+ export type PostExecuteErrors = {
200
+ /**
201
+ * Invalid request
202
+ */
203
+ 400: {
204
+ error: {
205
+ code: string;
206
+ message: string;
207
+ details?: unknown;
208
+ };
209
+ };
210
+ /**
211
+ * Request not found
212
+ */
213
+ 404: {
214
+ error: {
215
+ code: string;
216
+ message: string;
217
+ details?: unknown;
218
+ };
219
+ };
220
+ };
221
+ export type PostExecuteError = PostExecuteErrors[keyof PostExecuteErrors];
222
+ export type PostExecuteResponses = {
223
+ /**
224
+ * Request executed successfully
225
+ */
226
+ 200: {
227
+ runId: string;
228
+ reqExecId?: string;
229
+ flowId?: string;
230
+ session?: {
231
+ sessionId: string;
232
+ snapshotVersion: number;
233
+ };
234
+ request: {
235
+ index: number;
236
+ name?: string;
237
+ method: string;
238
+ url: string;
239
+ };
240
+ resolved: {
241
+ workspaceRoot: string;
242
+ projectRoot: string;
243
+ httpFilePath?: string;
244
+ basePath: string;
245
+ configPath?: string;
246
+ };
247
+ response: {
248
+ status: number;
249
+ statusText: string;
250
+ headers: Array<{
251
+ name: string;
252
+ value: string;
253
+ }>;
254
+ bodyMode: 'buffered' | 'none';
255
+ body?: string;
256
+ encoding: 'utf-8' | 'base64';
257
+ truncated: boolean;
258
+ bodyBytes: number;
259
+ };
260
+ limits: {
261
+ maxBodyBytes: number;
262
+ };
263
+ timing: {
264
+ startTime: number;
265
+ endTime: number;
266
+ durationMs: number;
267
+ };
268
+ };
269
+ };
270
+ export type PostExecuteResponse = PostExecuteResponses[keyof PostExecuteResponses];
271
+ export type PostExecuteSseData = {
272
+ body?: {
273
+ content?: string;
274
+ path?: string;
275
+ requestName?: string;
276
+ requestIndex?: number;
277
+ sessionId?: string;
278
+ profile?: string;
279
+ variables?: {
280
+ [key: string]: unknown;
281
+ };
282
+ flowId?: string;
283
+ reqLabel?: string;
284
+ timeout?: number;
285
+ lastEventId?: string;
286
+ };
287
+ path?: never;
288
+ query?: never;
289
+ url: '/execute/sse';
290
+ };
291
+ export type PostExecuteSseErrors = {
292
+ /**
293
+ * Invalid request or not an SSE request
294
+ */
295
+ 400: {
296
+ error: {
297
+ code: string;
298
+ message: string;
299
+ details?: unknown;
300
+ };
301
+ };
302
+ /**
303
+ * Request not found
304
+ */
305
+ 404: {
306
+ error: {
307
+ code: string;
308
+ message: string;
309
+ details?: unknown;
310
+ };
311
+ };
312
+ };
313
+ export type PostExecuteSseError = PostExecuteSseErrors[keyof PostExecuteSseErrors];
314
+ export type PostExecuteSseResponses = {
315
+ /**
316
+ * SSE event stream
317
+ */
318
+ 200: {
319
+ type: 'parseStarted' | 'parseFinished' | 'interpolateStarted' | 'interpolateFinished' | 'compileStarted' | 'compileFinished' | 'fetchStarted' | 'fetchFinished' | 'error' | 'sessionUpdated' | 'flowStarted' | 'flowFinished' | 'requestQueued' | 'executionFailed' | 'scriptStarted' | 'scriptOutput' | 'scriptFinished' | 'testStarted' | 'testOutput' | 'testFinished';
320
+ ts: number;
321
+ runId: string;
322
+ sessionId?: string;
323
+ flowId?: string;
324
+ reqExecId?: string;
325
+ seq: number;
326
+ payload: {
327
+ [key: string]: unknown;
328
+ };
329
+ };
330
+ };
331
+ export type PostExecuteSseResponse = PostExecuteSseResponses[keyof PostExecuteSseResponses];
332
+ export type PostSessionData = {
333
+ body?: {
334
+ variables?: {
335
+ [key: string]: unknown;
336
+ };
337
+ };
338
+ path?: never;
339
+ query?: never;
340
+ url: '/session';
341
+ };
342
+ export type PostSessionResponses = {
343
+ /**
344
+ * Session created
345
+ */
346
+ 201: {
347
+ sessionId: string;
348
+ };
349
+ };
350
+ export type PostSessionResponse = PostSessionResponses[keyof PostSessionResponses];
351
+ export type DeleteSessionByIdData = {
352
+ body?: never;
353
+ path: {
354
+ id: string;
355
+ };
356
+ query?: never;
357
+ url: '/session/{id}';
358
+ };
359
+ export type DeleteSessionByIdErrors = {
360
+ /**
361
+ * Session not found
362
+ */
363
+ 404: {
364
+ error: {
365
+ code: string;
366
+ message: string;
367
+ details?: unknown;
368
+ };
369
+ };
370
+ };
371
+ export type DeleteSessionByIdError = DeleteSessionByIdErrors[keyof DeleteSessionByIdErrors];
372
+ export type DeleteSessionByIdResponses = {
373
+ /**
374
+ * Session deleted
375
+ */
376
+ 204: void;
377
+ };
378
+ export type DeleteSessionByIdResponse = DeleteSessionByIdResponses[keyof DeleteSessionByIdResponses];
379
+ export type GetSessionByIdData = {
380
+ body?: never;
381
+ path: {
382
+ id: string;
383
+ };
384
+ query?: never;
385
+ url: '/session/{id}';
386
+ };
387
+ export type GetSessionByIdErrors = {
388
+ /**
389
+ * Session not found
390
+ */
391
+ 404: {
392
+ error: {
393
+ code: string;
394
+ message: string;
395
+ details?: unknown;
396
+ };
397
+ };
398
+ };
399
+ export type GetSessionByIdError = GetSessionByIdErrors[keyof GetSessionByIdErrors];
400
+ export type GetSessionByIdResponses = {
401
+ /**
402
+ * Session state
403
+ */
404
+ 200: {
405
+ sessionId: string;
406
+ variables: {
407
+ [key: string]: unknown;
408
+ };
409
+ cookieCount: number;
410
+ createdAt: number;
411
+ lastUsedAt: number;
412
+ snapshotVersion: number;
413
+ };
414
+ };
415
+ export type GetSessionByIdResponse = GetSessionByIdResponses[keyof GetSessionByIdResponses];
416
+ export type PutSessionByIdVariablesData = {
417
+ body?: {
418
+ variables: {
419
+ [key: string]: unknown;
420
+ };
421
+ mode: 'merge' | 'replace';
422
+ };
423
+ path: {
424
+ id: string;
425
+ };
426
+ query?: never;
427
+ url: '/session/{id}/variables';
428
+ };
429
+ export type PutSessionByIdVariablesErrors = {
430
+ /**
431
+ * Session not found
432
+ */
433
+ 404: {
434
+ error: {
435
+ code: string;
436
+ message: string;
437
+ details?: unknown;
438
+ };
439
+ };
440
+ };
441
+ export type PutSessionByIdVariablesError = PutSessionByIdVariablesErrors[keyof PutSessionByIdVariablesErrors];
442
+ export type PutSessionByIdVariablesResponses = {
443
+ /**
444
+ * Variables updated
445
+ */
446
+ 200: {
447
+ sessionId: string;
448
+ snapshotVersion: number;
449
+ };
450
+ };
451
+ export type PutSessionByIdVariablesResponse = PutSessionByIdVariablesResponses[keyof PutSessionByIdVariablesResponses];
452
+ export type PostFlowsData = {
453
+ body?: {
454
+ sessionId?: string;
455
+ label?: string;
456
+ meta?: {
457
+ [key: string]: unknown;
458
+ };
459
+ };
460
+ path?: never;
461
+ query?: never;
462
+ url: '/flows';
463
+ };
464
+ export type PostFlowsErrors = {
465
+ /**
466
+ * Session not found (if sessionId provided)
467
+ */
468
+ 404: {
469
+ error: {
470
+ code: string;
471
+ message: string;
472
+ details?: unknown;
473
+ };
474
+ };
475
+ };
476
+ export type PostFlowsError = PostFlowsErrors[keyof PostFlowsErrors];
477
+ export type PostFlowsResponses = {
478
+ /**
479
+ * Flow created
480
+ */
481
+ 201: {
482
+ flowId: string;
483
+ };
484
+ };
485
+ export type PostFlowsResponse = PostFlowsResponses[keyof PostFlowsResponses];
486
+ export type PostFlowsByFlowIdFinishData = {
487
+ body?: never;
488
+ path: {
489
+ flowId: string;
490
+ };
491
+ query?: never;
492
+ url: '/flows/{flowId}/finish';
493
+ };
494
+ export type PostFlowsByFlowIdFinishErrors = {
495
+ /**
496
+ * Flow not found
497
+ */
498
+ 404: {
499
+ error: {
500
+ code: string;
501
+ message: string;
502
+ details?: unknown;
503
+ };
504
+ };
505
+ };
506
+ export type PostFlowsByFlowIdFinishError = PostFlowsByFlowIdFinishErrors[keyof PostFlowsByFlowIdFinishErrors];
507
+ export type PostFlowsByFlowIdFinishResponses = {
508
+ /**
509
+ * Flow finished with summary
510
+ */
511
+ 200: {
512
+ flowId: string;
513
+ summary: {
514
+ total: number;
515
+ succeeded: number;
516
+ failed: number;
517
+ durationMs: number;
518
+ };
519
+ };
520
+ };
521
+ export type PostFlowsByFlowIdFinishResponse = PostFlowsByFlowIdFinishResponses[keyof PostFlowsByFlowIdFinishResponses];
522
+ export type GetFlowsByFlowIdExecutionsByReqExecIdData = {
523
+ body?: never;
524
+ path: {
525
+ flowId: string;
526
+ reqExecId: string;
527
+ };
528
+ query?: never;
529
+ url: '/flows/{flowId}/executions/{reqExecId}';
530
+ };
531
+ export type GetFlowsByFlowIdExecutionsByReqExecIdErrors = {
532
+ /**
533
+ * Flow or execution not found
534
+ */
535
+ 404: {
536
+ error: {
537
+ code: string;
538
+ message: string;
539
+ details?: unknown;
540
+ };
541
+ };
542
+ };
543
+ export type GetFlowsByFlowIdExecutionsByReqExecIdError = GetFlowsByFlowIdExecutionsByReqExecIdErrors[keyof GetFlowsByFlowIdExecutionsByReqExecIdErrors];
544
+ export type GetFlowsByFlowIdExecutionsByReqExecIdResponses = {
545
+ /**
546
+ * Execution details
547
+ */
548
+ 200: {
549
+ reqExecId: string;
550
+ flowId: string;
551
+ sessionId?: string;
552
+ reqLabel?: string;
553
+ source?: {
554
+ kind: 'file' | 'string';
555
+ path?: string;
556
+ requestIndex?: number;
557
+ requestName?: string;
558
+ };
559
+ rawHttpBlock?: string;
560
+ method?: string;
561
+ urlTemplate?: string;
562
+ urlResolved?: string;
563
+ headers?: Array<{
564
+ name: string;
565
+ value: string;
566
+ }>;
567
+ bodyPreview?: string;
568
+ timing: {
569
+ startTime: number;
570
+ endTime?: number;
571
+ durationMs?: number;
572
+ ttfb?: number;
573
+ };
574
+ response?: {
575
+ status: number;
576
+ statusText: string;
577
+ headers: Array<{
578
+ name: string;
579
+ value: string;
580
+ }>;
581
+ body?: string;
582
+ encoding: 'utf-8' | 'base64';
583
+ truncated: boolean;
584
+ bodyBytes: number;
585
+ };
586
+ pluginHooks?: Array<{
587
+ pluginName: string;
588
+ hook: string;
589
+ durationMs: number;
590
+ modified: boolean;
591
+ }>;
592
+ status: 'pending' | 'running' | 'success' | 'failed';
593
+ error?: {
594
+ stage: string;
595
+ message: string;
596
+ };
597
+ };
598
+ };
599
+ export type GetFlowsByFlowIdExecutionsByReqExecIdResponse = GetFlowsByFlowIdExecutionsByReqExecIdResponses[keyof GetFlowsByFlowIdExecutionsByReqExecIdResponses];
600
+ export type GetWorkspaceFilesData = {
601
+ body?: never;
602
+ path?: never;
603
+ query?: {
604
+ /**
605
+ * Comma-separated additional glob patterns to ignore
606
+ */
607
+ ignore?: string;
608
+ };
609
+ url: '/workspace/files';
610
+ };
611
+ export type GetWorkspaceFilesResponses = {
612
+ /**
613
+ * List of .http files
614
+ */
615
+ 200: {
616
+ files: Array<{
617
+ path: string;
618
+ name: string;
619
+ requestCount: number;
620
+ lastModified: number;
621
+ }>;
622
+ workspaceRoot: string;
623
+ };
624
+ };
625
+ export type GetWorkspaceFilesResponse = GetWorkspaceFilesResponses[keyof GetWorkspaceFilesResponses];
626
+ export type GetWorkspaceRequestsData = {
627
+ body?: never;
628
+ path?: never;
629
+ query: {
630
+ /**
631
+ * Path to .http file (relative to workspace)
632
+ */
633
+ path: string;
634
+ };
635
+ url: '/workspace/requests';
636
+ };
637
+ export type GetWorkspaceRequestsErrors = {
638
+ /**
639
+ * Invalid path
640
+ */
641
+ 400: {
642
+ error: {
643
+ code: string;
644
+ message: string;
645
+ details?: unknown;
646
+ };
647
+ };
648
+ /**
649
+ * File not found
650
+ */
651
+ 404: {
652
+ error: {
653
+ code: string;
654
+ message: string;
655
+ details?: unknown;
656
+ };
657
+ };
658
+ };
659
+ export type GetWorkspaceRequestsError = GetWorkspaceRequestsErrors[keyof GetWorkspaceRequestsErrors];
660
+ export type GetWorkspaceRequestsResponses = {
661
+ /**
662
+ * List of requests
663
+ */
664
+ 200: {
665
+ path: string;
666
+ requests: Array<{
667
+ index: number;
668
+ name?: string;
669
+ method: string;
670
+ url: string;
671
+ protocol?: 'http' | 'sse';
672
+ }>;
673
+ };
674
+ };
675
+ export type GetWorkspaceRequestsResponse = GetWorkspaceRequestsResponses[keyof GetWorkspaceRequestsResponses];
676
+ export type DeleteWorkspaceFileData = {
677
+ body?: never;
678
+ path?: never;
679
+ query: {
680
+ /**
681
+ * Path to .http file (relative to workspace)
682
+ */
683
+ path: string;
684
+ };
685
+ url: '/workspace/file';
686
+ };
687
+ export type DeleteWorkspaceFileErrors = {
688
+ /**
689
+ * Invalid request
690
+ */
691
+ 400: {
692
+ error: {
693
+ code: string;
694
+ message: string;
695
+ details?: unknown;
696
+ };
697
+ };
698
+ /**
699
+ * Path outside workspace
700
+ */
701
+ 403: {
702
+ error: {
703
+ code: string;
704
+ message: string;
705
+ details?: unknown;
706
+ };
707
+ };
708
+ /**
709
+ * File not found
710
+ */
711
+ 404: {
712
+ error: {
713
+ code: string;
714
+ message: string;
715
+ details?: unknown;
716
+ };
717
+ };
718
+ };
719
+ export type DeleteWorkspaceFileError = DeleteWorkspaceFileErrors[keyof DeleteWorkspaceFileErrors];
720
+ export type DeleteWorkspaceFileResponses = {
721
+ /**
722
+ * File deleted
723
+ */
724
+ 204: void;
725
+ };
726
+ export type DeleteWorkspaceFileResponse = DeleteWorkspaceFileResponses[keyof DeleteWorkspaceFileResponses];
727
+ export type GetWorkspaceFileData = {
728
+ body?: never;
729
+ path?: never;
730
+ query: {
731
+ /**
732
+ * Path to .http file (relative to workspace)
733
+ */
734
+ path: string;
735
+ };
736
+ url: '/workspace/file';
737
+ };
738
+ export type GetWorkspaceFileErrors = {
739
+ /**
740
+ * Invalid path
741
+ */
742
+ 400: {
743
+ error: {
744
+ code: string;
745
+ message: string;
746
+ details?: unknown;
747
+ };
748
+ };
749
+ /**
750
+ * Path outside workspace
751
+ */
752
+ 403: {
753
+ error: {
754
+ code: string;
755
+ message: string;
756
+ details?: unknown;
757
+ };
758
+ };
759
+ /**
760
+ * File not found
761
+ */
762
+ 404: {
763
+ error: {
764
+ code: string;
765
+ message: string;
766
+ details?: unknown;
767
+ };
768
+ };
769
+ };
770
+ export type GetWorkspaceFileError = GetWorkspaceFileErrors[keyof GetWorkspaceFileErrors];
771
+ export type GetWorkspaceFileResponses = {
772
+ /**
773
+ * File content
774
+ */
775
+ 200: {
776
+ path: string;
777
+ content: string;
778
+ lastModified: number;
779
+ };
780
+ };
781
+ export type GetWorkspaceFileResponse = GetWorkspaceFileResponses[keyof GetWorkspaceFileResponses];
782
+ export type PostWorkspaceFileData = {
783
+ body?: {
784
+ path: string;
785
+ content?: string;
786
+ };
787
+ path?: never;
788
+ query?: never;
789
+ url: '/workspace/file';
790
+ };
791
+ export type PostWorkspaceFileErrors = {
792
+ /**
793
+ * Invalid path or file already exists
794
+ */
795
+ 400: {
796
+ error: {
797
+ code: string;
798
+ message: string;
799
+ details?: unknown;
800
+ };
801
+ };
802
+ /**
803
+ * Path outside workspace
804
+ */
805
+ 403: {
806
+ error: {
807
+ code: string;
808
+ message: string;
809
+ details?: unknown;
810
+ };
811
+ };
812
+ };
813
+ export type PostWorkspaceFileError = PostWorkspaceFileErrors[keyof PostWorkspaceFileErrors];
814
+ export type PostWorkspaceFileResponses = {
815
+ /**
816
+ * File created
817
+ */
818
+ 201: {
819
+ path: string;
820
+ content: string;
821
+ lastModified: number;
822
+ };
823
+ };
824
+ export type PostWorkspaceFileResponse = PostWorkspaceFileResponses[keyof PostWorkspaceFileResponses];
825
+ export type PutWorkspaceFileData = {
826
+ body?: {
827
+ path: string;
828
+ content: string;
829
+ };
830
+ path?: never;
831
+ query?: never;
832
+ url: '/workspace/file';
833
+ };
834
+ export type PutWorkspaceFileErrors = {
835
+ /**
836
+ * Invalid request
837
+ */
838
+ 400: {
839
+ error: {
840
+ code: string;
841
+ message: string;
842
+ details?: unknown;
843
+ };
844
+ };
845
+ /**
846
+ * Path outside workspace
847
+ */
848
+ 403: {
849
+ error: {
850
+ code: string;
851
+ message: string;
852
+ details?: unknown;
853
+ };
854
+ };
855
+ /**
856
+ * File not found
857
+ */
858
+ 404: {
859
+ error: {
860
+ code: string;
861
+ message: string;
862
+ details?: unknown;
863
+ };
864
+ };
865
+ };
866
+ export type PutWorkspaceFileError = PutWorkspaceFileErrors[keyof PutWorkspaceFileErrors];
867
+ export type PutWorkspaceFileResponses = {
868
+ /**
869
+ * File updated successfully
870
+ */
871
+ 200: unknown;
872
+ };
873
+ export type PostScriptData = {
874
+ body?: {
875
+ filePath: string;
876
+ runnerId?: string;
877
+ flowId?: string;
878
+ };
879
+ path?: never;
880
+ query?: never;
881
+ url: '/script';
882
+ };
883
+ export type PostScriptErrors = {
884
+ /**
885
+ * Invalid request or runner
886
+ */
887
+ 400: {
888
+ error: {
889
+ code: string;
890
+ message: string;
891
+ details?: unknown;
892
+ };
893
+ };
894
+ /**
895
+ * Path outside workspace
896
+ */
897
+ 403: {
898
+ error: {
899
+ code: string;
900
+ message: string;
901
+ details?: unknown;
902
+ };
903
+ };
904
+ /**
905
+ * Flow not found (if flowId provided)
906
+ */
907
+ 404: {
908
+ error: {
909
+ code: string;
910
+ message: string;
911
+ details?: unknown;
912
+ };
913
+ };
914
+ };
915
+ export type PostScriptError = PostScriptErrors[keyof PostScriptErrors];
916
+ export type PostScriptResponses = {
917
+ /**
918
+ * Script started, subscribe to flow SSE for output
919
+ */
920
+ 200: {
921
+ runId: string;
922
+ flowId: string;
923
+ };
924
+ };
925
+ export type PostScriptResponse = PostScriptResponses[keyof PostScriptResponses];
926
+ export type DeleteScriptByRunIdData = {
927
+ body?: never;
928
+ path: {
929
+ runId: string;
930
+ };
931
+ query?: never;
932
+ url: '/script/{runId}';
933
+ };
934
+ export type DeleteScriptByRunIdErrors = {
935
+ /**
936
+ * Script not found or already finished
937
+ */
938
+ 404: {
939
+ error: {
940
+ code: string;
941
+ message: string;
942
+ details?: unknown;
943
+ };
944
+ };
945
+ };
946
+ export type DeleteScriptByRunIdError = DeleteScriptByRunIdErrors[keyof DeleteScriptByRunIdErrors];
947
+ export type DeleteScriptByRunIdResponses = {
948
+ /**
949
+ * Script cancelled
950
+ */
951
+ 204: void;
952
+ };
953
+ export type DeleteScriptByRunIdResponse = DeleteScriptByRunIdResponses[keyof DeleteScriptByRunIdResponses];
954
+ export type GetScriptRunnersData = {
955
+ body?: never;
956
+ path?: never;
957
+ query?: {
958
+ /**
959
+ * Optional file path to filter available runners
960
+ */
961
+ filePath?: string;
962
+ };
963
+ url: '/script/runners';
964
+ };
965
+ export type GetScriptRunnersResponses = {
966
+ /**
967
+ * Available runners with detected default
968
+ */
969
+ 200: {
970
+ detected: string | null;
971
+ options: Array<{
972
+ id: string;
973
+ label: string;
974
+ }>;
975
+ };
976
+ };
977
+ export type GetScriptRunnersResponse = GetScriptRunnersResponses[keyof GetScriptRunnersResponses];
978
+ export type PostTestData = {
979
+ body?: {
980
+ filePath: string;
981
+ frameworkId?: string;
982
+ flowId?: string;
983
+ };
984
+ path?: never;
985
+ query?: never;
986
+ url: '/test';
987
+ };
988
+ export type PostTestErrors = {
989
+ /**
990
+ * Invalid request or framework
991
+ */
992
+ 400: {
993
+ error: {
994
+ code: string;
995
+ message: string;
996
+ details?: unknown;
997
+ };
998
+ };
999
+ /**
1000
+ * Path outside workspace
1001
+ */
1002
+ 403: {
1003
+ error: {
1004
+ code: string;
1005
+ message: string;
1006
+ details?: unknown;
1007
+ };
1008
+ };
1009
+ /**
1010
+ * Flow not found (if flowId provided)
1011
+ */
1012
+ 404: {
1013
+ error: {
1014
+ code: string;
1015
+ message: string;
1016
+ details?: unknown;
1017
+ };
1018
+ };
1019
+ };
1020
+ export type PostTestError = PostTestErrors[keyof PostTestErrors];
1021
+ export type PostTestResponses = {
1022
+ /**
1023
+ * Tests started, subscribe to flow SSE for output
1024
+ */
1025
+ 200: {
1026
+ runId: string;
1027
+ flowId: string;
1028
+ };
1029
+ };
1030
+ export type PostTestResponse = PostTestResponses[keyof PostTestResponses];
1031
+ export type DeleteTestByRunIdData = {
1032
+ body?: never;
1033
+ path: {
1034
+ runId: string;
1035
+ };
1036
+ query?: never;
1037
+ url: '/test/{runId}';
1038
+ };
1039
+ export type DeleteTestByRunIdErrors = {
1040
+ /**
1041
+ * Test not found or already finished
1042
+ */
1043
+ 404: {
1044
+ error: {
1045
+ code: string;
1046
+ message: string;
1047
+ details?: unknown;
1048
+ };
1049
+ };
1050
+ };
1051
+ export type DeleteTestByRunIdError = DeleteTestByRunIdErrors[keyof DeleteTestByRunIdErrors];
1052
+ export type DeleteTestByRunIdResponses = {
1053
+ /**
1054
+ * Test cancelled
1055
+ */
1056
+ 204: void;
1057
+ };
1058
+ export type DeleteTestByRunIdResponse = DeleteTestByRunIdResponses[keyof DeleteTestByRunIdResponses];
1059
+ export type GetTestFrameworksData = {
1060
+ body?: never;
1061
+ path?: never;
1062
+ query?: {
1063
+ /**
1064
+ * Optional file path to help detect the framework
1065
+ */
1066
+ filePath?: string;
1067
+ };
1068
+ url: '/test/frameworks';
1069
+ };
1070
+ export type GetTestFrameworksResponses = {
1071
+ /**
1072
+ * Available frameworks with detected default
1073
+ */
1074
+ 200: {
1075
+ detected: string | null;
1076
+ options: Array<{
1077
+ id: string;
1078
+ label: string;
1079
+ }>;
1080
+ };
1081
+ };
1082
+ export type GetTestFrameworksResponse = GetTestFrameworksResponses[keyof GetTestFrameworksResponses];
1083
+ export type GetPluginsData = {
1084
+ body?: never;
1085
+ path?: never;
1086
+ query?: never;
1087
+ url: '/plugins';
1088
+ };
1089
+ export type GetPluginsResponses = {
1090
+ /**
1091
+ * List of loaded plugins with their capabilities
1092
+ */
1093
+ 200: {
1094
+ plugins: Array<{
1095
+ name: string;
1096
+ version?: string;
1097
+ source: 'npm' | 'file' | 'inline' | 'subprocess';
1098
+ permissions: Array<string>;
1099
+ capabilities: {
1100
+ hasHooks: boolean;
1101
+ hasResolvers: boolean;
1102
+ hasCommands: boolean;
1103
+ hasMiddleware: boolean;
1104
+ hasTools: boolean;
1105
+ };
1106
+ }>;
1107
+ count: number;
1108
+ };
1109
+ };
1110
+ export type GetPluginsResponse = GetPluginsResponses[keyof GetPluginsResponses];
1111
+ export type GetEventData = {
1112
+ body?: never;
1113
+ path?: never;
1114
+ query?: {
1115
+ sessionId?: string;
1116
+ flowId?: string;
1117
+ };
1118
+ url: '/event';
1119
+ };
1120
+ export type GetEventResponses = {
1121
+ /**
1122
+ * SSE stream
1123
+ */
1124
+ 200: {
1125
+ type: 'parseStarted' | 'parseFinished' | 'interpolateStarted' | 'interpolateFinished' | 'compileStarted' | 'compileFinished' | 'fetchStarted' | 'fetchFinished' | 'error' | 'sessionUpdated' | 'flowStarted' | 'flowFinished' | 'requestQueued' | 'executionFailed' | 'scriptStarted' | 'scriptOutput' | 'scriptFinished' | 'testStarted' | 'testOutput' | 'testFinished';
1126
+ ts: number;
1127
+ runId: string;
1128
+ sessionId?: string;
1129
+ flowId?: string;
1130
+ reqExecId?: string;
1131
+ seq: number;
1132
+ payload: {
1133
+ [key: string]: unknown;
1134
+ };
1135
+ };
1136
+ };
1137
+ export type GetEventResponse = GetEventResponses[keyof GetEventResponses];
1138
+ //# sourceMappingURL=types.gen.d.ts.map