@http-forge/core 0.6.1 → 0.6.2-2.beta.2

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 (41) hide show
  1. package/README.md +223 -251
  2. package/dist/di/platform-adapters.d.ts +11 -4
  3. package/dist/index.d.ts +13 -2
  4. package/dist/index.js +499 -283
  5. package/dist/index.mjs +498 -282
  6. package/dist/infrastructure/ai/ai-provider.d.ts +16 -0
  7. package/dist/infrastructure/analysis/ai-env-suggester.d.ts +22 -0
  8. package/dist/infrastructure/analysis/collection-enhancer.d.ts +23 -0
  9. package/dist/infrastructure/analysis/env-suggester.d.ts +57 -0
  10. package/dist/infrastructure/collection/collection-store.d.ts +1 -1
  11. package/dist/infrastructure/config/config-service.d.ts +20 -1
  12. package/dist/infrastructure/config/config.interface.d.ts +26 -2
  13. package/dist/infrastructure/config/default-config.d.ts +4 -2
  14. package/dist/infrastructure/environment/environment-config-service.d.ts +2 -1
  15. package/dist/infrastructure/execution/collection-request-executor.d.ts +3 -2
  16. package/dist/infrastructure/execution/request-executor.d.ts +5 -0
  17. package/dist/infrastructure/execution/request-preparer.d.ts +1 -0
  18. package/dist/infrastructure/http/native-http-client.d.ts +6 -1
  19. package/dist/infrastructure/openapi/openapi-exporter.d.ts +5 -0
  20. package/dist/infrastructure/parsers/curl-parser.d.ts +61 -0
  21. package/dist/infrastructure/script/expect-chain.d.ts +120 -0
  22. package/dist/infrastructure/script/interfaces.d.ts +3 -0
  23. package/dist/infrastructure/script/json-schema-validator.d.ts +9 -0
  24. package/dist/infrastructure/script/module-loader.d.ts +1 -1
  25. package/dist/infrastructure/script/script-factories.d.ts +10 -73
  26. package/dist/infrastructure/test-suite/interfaces.d.ts +103 -6
  27. package/dist/infrastructure/test-suite/result-storage.d.ts +6 -0
  28. package/dist/infrastructure/test-suite/statistics-service.d.ts +1 -1
  29. package/dist/infrastructure/test-suite/test-suite-service.d.ts +2 -2
  30. package/dist/infrastructure/test-suite/test-suite-store.d.ts +27 -9
  31. package/dist/runtime/mcp-collection-utils.d.ts +29 -1
  32. package/dist/runtime/mcp-prompts.d.ts +39 -0
  33. package/dist/runtime/mcp-run-store.d.ts +11 -1
  34. package/dist/runtime/mcp-tool-builder.d.ts +6 -0
  35. package/dist/runtime/mcp-tool-name.d.ts +4 -5
  36. package/dist/runtime/mcp-tool-schemas.d.ts +45 -0
  37. package/dist/runtime/node-bootstrap.d.ts +9 -0
  38. package/dist/runtime/runtime-contracts.d.ts +14 -0
  39. package/dist/types/types.d.ts +67 -1
  40. package/dist/utils/typed-value.d.ts +14 -0
  41. package/package.json +20 -6
@@ -26,6 +26,76 @@ export interface SuiteRequest {
26
26
  /** Optional description of what this request does in the suite */
27
27
  description?: string;
28
28
  }
29
+ /**
30
+ * Base properties for suite flow nodes.
31
+ */
32
+ export interface SuiteFlowNodeBase {
33
+ /** Optional stable node id */
34
+ id?: string;
35
+ /** Optional display label */
36
+ name?: string;
37
+ /** Whether this node is enabled */
38
+ enabled?: boolean;
39
+ /** JavaScript boolean expression evaluated before entering the node */
40
+ condition?: string;
41
+ }
42
+ export interface SuiteRequestNode extends SuiteFlowNodeBase {
43
+ type: 'request';
44
+ request: SuiteRequest;
45
+ }
46
+ export interface SuiteBlockNode extends SuiteFlowNodeBase {
47
+ type: 'block';
48
+ nodes: SuiteFlowNode[];
49
+ }
50
+ export interface SuiteElseIfBranch {
51
+ condition: string;
52
+ nodes: SuiteFlowNode[];
53
+ }
54
+ export interface SuiteIfNode extends SuiteFlowNodeBase {
55
+ type: 'if';
56
+ if: string;
57
+ then: SuiteFlowNode[];
58
+ elseif?: SuiteElseIfBranch[];
59
+ else?: SuiteFlowNode[];
60
+ }
61
+ export interface SuiteSwitchCase {
62
+ /** If provided, this case matches when `equals === switchExpressionResult` */
63
+ equals?: unknown;
64
+ /** Optional boolean expression when equals is omitted */
65
+ condition?: string;
66
+ nodes: SuiteFlowNode[];
67
+ }
68
+ export interface SuiteSwitchNode extends SuiteFlowNodeBase {
69
+ type: 'switch';
70
+ expression: string;
71
+ cases: SuiteSwitchCase[];
72
+ default?: SuiteFlowNode[];
73
+ }
74
+ export interface SuiteForNode extends SuiteFlowNodeBase {
75
+ type: 'for';
76
+ init?: string | string[];
77
+ /** Loop continuation expression. Distinct from `condition` (guard) on SuiteFlowNodeBase. */
78
+ loopCondition?: string;
79
+ update?: string | string[];
80
+ nodes: SuiteFlowNode[];
81
+ maxIterations?: number;
82
+ }
83
+ export interface SuiteWhileNode extends SuiteFlowNodeBase {
84
+ type: 'while';
85
+ while: string;
86
+ nodes: SuiteFlowNode[];
87
+ maxIterations?: number;
88
+ }
89
+ export interface SuiteScriptNode extends SuiteFlowNodeBase {
90
+ type: 'script';
91
+ /** Inline script source */
92
+ script?: string | string[];
93
+ /** Reusable script key from TestSuite.scripts */
94
+ scriptRef?: string;
95
+ /** Optional phase hint. Defaults to 'pre'. */
96
+ phase?: 'pre' | 'post';
97
+ }
98
+ export type SuiteFlowNode = SuiteRequestNode | SuiteBlockNode | SuiteIfNode | SuiteSwitchNode | SuiteForNode | SuiteWhileNode | SuiteScriptNode;
29
99
  /**
30
100
  * Test Suite run configuration
31
101
  */
@@ -44,7 +114,26 @@ export interface SuiteConfig {
44
114
  dataFilePath?: string;
45
115
  }
46
116
  /**
47
- * Test Suite definition
117
+ * Raw shape of a suite.json file on disk — includes the deprecated `requests`
118
+ * field that may be present in legacy files. Never used as an in-memory model.
119
+ */
120
+ export interface LegacySuiteFileData {
121
+ id: string;
122
+ name: string;
123
+ description?: string;
124
+ /** @deprecated Legacy flat list — migrated to `nodes` on load. */
125
+ requests?: SuiteRequest[];
126
+ scripts?: Record<string, string | string[]>;
127
+ nodes?: SuiteFlowNode[];
128
+ config?: SuiteConfig;
129
+ isTemporary?: boolean;
130
+ createdAt?: number;
131
+ updatedAt?: number;
132
+ [key: string]: unknown;
133
+ }
134
+ /**
135
+ * Test Suite definition — in-memory model only.
136
+ * `requests` never appears here; legacy files are migrated to `nodes` on load.
48
137
  */
49
138
  export interface TestSuite {
50
139
  /** Unique identifier */
@@ -53,8 +142,14 @@ export interface TestSuite {
53
142
  name: string;
54
143
  /** Optional description */
55
144
  description?: string;
56
- /** Ordered list of request references */
57
- requests: SuiteRequest[];
145
+ /**
146
+ * Optional reusable script library addressable by `scriptRef` from flow nodes.
147
+ */
148
+ scripts?: Record<string, string | string[]>;
149
+ /**
150
+ * Control-flow graph — the primary and only execution model.
151
+ */
152
+ nodes: SuiteFlowNode[];
58
153
  /** Run configuration */
59
154
  config: SuiteConfig;
60
155
  /** Whether this is a temporary suite (not saved) */
@@ -68,6 +163,8 @@ export interface TestSuite {
68
163
  * Per-request statistics
69
164
  */
70
165
  export interface RequestStatistics {
166
+ /** Unique identity key for this request in statistics */
167
+ key: string;
71
168
  /** Request name */
72
169
  name: string;
73
170
  /** Number of executions */
@@ -129,7 +226,7 @@ export interface ErrorSummary {
129
226
  export interface RunStatistics {
130
227
  /** Summary statistics */
131
228
  summary: RunSummary;
132
- /** Statistics grouped by request name */
229
+ /** Statistics grouped by request identity key */
133
230
  byRequest: Map<string, RequestStatistics>;
134
231
  /** Overall statistics across all requests */
135
232
  overall: RequestStatistics;
@@ -140,7 +237,7 @@ export interface RunStatistics {
140
237
  * Test Suite Service Interface
141
238
  */
142
239
  export interface ITestSuiteService {
143
- createSuite(name: string, requests?: SuiteRequest[]): Promise<TestSuite>;
240
+ createSuite(name: string): Promise<TestSuite>;
144
241
  getSuite(id: string): Promise<TestSuite | undefined>;
145
242
  getAllSuites(): Promise<TestSuite[]>;
146
243
  updateSuite(suite: TestSuite): Promise<void>;
@@ -155,7 +252,7 @@ export interface ITestSuiteService {
155
252
  */
156
253
  export interface IStatisticsService {
157
254
  /** Add a result and update statistics */
158
- addResult(requestName: string, duration: number, passed: boolean, skipped: boolean, error?: string): void;
255
+ addResult(requestKey: string, requestName: string, duration: number, passed: boolean, skipped: boolean, error?: string): void;
159
256
  /** Get current statistics */
160
257
  getStatistics(): RunStatistics;
161
258
  /** Reset statistics for a new run */
@@ -114,6 +114,12 @@ export interface RunStats {
114
114
  minDuration: number;
115
115
  /** Maximum duration */
116
116
  maxDuration: number;
117
+ /** 50th percentile latency across all requests */
118
+ p50?: number;
119
+ /** 95th percentile latency across all requests */
120
+ p95?: number;
121
+ /** 99th percentile latency across all requests */
122
+ p99?: number;
117
123
  }
118
124
  /**
119
125
  * Run configuration stored in manifest
@@ -34,7 +34,7 @@ export declare class StatisticsService implements IStatisticsService {
34
34
  /**
35
35
  * Add a result and update statistics
36
36
  */
37
- addResult(requestName: string, duration: number, passed: boolean, skipped: boolean, error?: string): void;
37
+ addResult(requestKey: string, requestName: string, duration: number, passed: boolean, skipped: boolean, error?: string): void;
38
38
  /**
39
39
  * Get current statistics
40
40
  */
@@ -6,7 +6,7 @@
6
6
  */
7
7
  import { ICollectionService } from '../../types/collection';
8
8
  import { IConfigService } from '../config';
9
- import { ITestSuiteService, SuiteRequest, TestSuite } from './interfaces';
9
+ import { ITestSuiteService, TestSuite } from './interfaces';
10
10
  /**
11
11
  * Callback invoked when the suites on disk change.
12
12
  */
@@ -58,7 +58,7 @@ export declare class TestSuiteService implements ITestSuiteService {
58
58
  /**
59
59
  * Create a new suite
60
60
  */
61
- createSuite(name: string, requests?: SuiteRequest[]): Promise<TestSuite>;
61
+ createSuite(name: string): Promise<TestSuite>;
62
62
  /**
63
63
  * Update an existing suite
64
64
  */
@@ -8,7 +8,7 @@
8
8
  * Single Responsibility: Maintain suite state and resolve requests
9
9
  * Dependency Inversion: Depends on ICollectionService abstraction
10
10
  */
11
- import { CollectionRequest, ICollectionService, RequestScripts } from '../../types/collection';
11
+ import { CollectionRequest, ICollectionService, RequestAuth, RequestScripts } from '../../types/collection';
12
12
  import { SuiteRequest, TestSuite } from './interfaces';
13
13
  /**
14
14
  * Cached request entry with full context
@@ -20,8 +20,12 @@ export interface SuiteRequestEntry {
20
20
  suiteRequest: SuiteRequest;
21
21
  /** Collection scripts */
22
22
  collectionScripts?: RequestScripts;
23
+ /** Collection auth */
24
+ collectionAuth?: RequestAuth;
23
25
  /** Folder scripts chain */
24
26
  folderScriptsChain: RequestScripts[];
27
+ /** Folder auth chain */
28
+ folderAuthChain: RequestAuth[];
25
29
  }
26
30
  /**
27
31
  * Interface for TestSuiteStore
@@ -51,6 +55,11 @@ export interface ITestSuiteStore {
51
55
  * Get all suite requests with their resolved data
52
56
  */
53
57
  getAllSuiteRequests(): SuiteRequestEntry[];
58
+ /**
59
+ * Resolve a SuiteRequest to a full entry with collection context.
60
+ * Works for any SuiteRequest object regardless of whether it's in suite.requests.
61
+ */
62
+ resolveRequestEntry(suiteRequest: SuiteRequest): SuiteRequestEntry | undefined;
54
63
  /**
55
64
  * Get resolved requests for webview display
56
65
  */
@@ -66,6 +75,7 @@ export interface ITestSuiteStore {
66
75
  enabled: boolean;
67
76
  hasEmbeddedRequest: boolean;
68
77
  slug?: string;
78
+ description?: string;
69
79
  }>;
70
80
  /**
71
81
  * Get suite requests by selection state
@@ -103,6 +113,7 @@ export declare class TestSuiteStore implements ITestSuiteStore {
103
113
  constructor(collectionService: ICollectionService);
104
114
  /**
105
115
  * Set the suite
116
+ * Converts legacy requests to request nodes for unified nodes-only architecture
106
117
  */
107
118
  setSuite(suite: TestSuite): void;
108
119
  /**
@@ -120,7 +131,7 @@ export declare class TestSuiteStore implements ITestSuiteStore {
120
131
  private loadSuiteRequest;
121
132
  /**
122
133
  * Save a suite request to its folder.
123
- * Writes request.json + scripts/pre-request.js + scripts/post-response.js
134
+ * Writes request.json + scripts/pre-request.js + scripts/post-response.js atomically.
124
135
  */
125
136
  private saveSuiteRequest;
126
137
  /**
@@ -131,7 +142,7 @@ export declare class TestSuiteStore implements ITestSuiteStore {
131
142
  * Resolve a suite request to its full request data.
132
143
  * Priority: suite folder → collection (fallback for legacy suites)
133
144
  */
134
- private resolveRequest;
145
+ resolveRequestEntry(suiteRequest: SuiteRequest): SuiteRequestEntry | undefined;
135
146
  /**
136
147
  * Find a request in a collection, including folder scripts
137
148
  */
@@ -161,8 +172,8 @@ export declare class TestSuiteStore implements ITestSuiteStore {
161
172
  */
162
173
  getAllSuiteRequests(): SuiteRequestEntry[];
163
174
  /**
164
- * Get resolved requests for webview display
165
- * Returns simplified format with display-relevant properties
175
+ * Get resolved requests for webview display.
176
+ * Returns simplified format with display-relevant properties, ordered by nodes.
166
177
  */
167
178
  getResolvedRequests(): Array<{
168
179
  id: string;
@@ -176,6 +187,7 @@ export declare class TestSuiteStore implements ITestSuiteStore {
176
187
  enabled: boolean;
177
188
  hasEmbeddedRequest: boolean;
178
189
  slug?: string;
190
+ description?: string;
179
191
  }>;
180
192
  /**
181
193
  * Get selected requests in order
@@ -183,8 +195,9 @@ export declare class TestSuiteStore implements ITestSuiteStore {
183
195
  */
184
196
  getSelectedRequests(selectedIds: string[]): SuiteRequestEntry[];
185
197
  /**
186
- * Add a request to the suite.
187
- * If fullRequest is provided and suiteDir is set, creates a folder with request.json + scripts.
198
+ * Add a request to the suite as a flow node.
199
+ * Copy-on-write: do NOT create an embedded request folder at add time.
200
+ * A folder snapshot is created only when the request is edited/reset in-suite.
188
201
  */
189
202
  addRequest(request: SuiteRequest, fullRequest?: CollectionRequest): void;
190
203
  /**
@@ -192,11 +205,11 @@ export declare class TestSuiteStore implements ITestSuiteStore {
192
205
  */
193
206
  private resolveUniqueSlug;
194
207
  /**
195
- * Remove a request from the suite
208
+ * Remove a request from the suite (removes its node)
196
209
  */
197
210
  removeRequest(requestId: string): void;
198
211
  /**
199
- * Reorder requests by request IDs (format: "collectionId:requestId")
212
+ * Reorder request nodes by "collectionId:requestId" keys
200
213
  */
201
214
  reorderRequests(orderedKeys: string[]): void;
202
215
  /**
@@ -209,4 +222,9 @@ export declare class TestSuiteStore implements ITestSuiteStore {
209
222
  * Overwrites the request folder content.
210
223
  */
211
224
  resyncFromCollection(slug: string): CollectionRequest | undefined;
225
+ /**
226
+ * Extract all SuiteRequest objects from top-level request nodes.
227
+ * Nodes is the sole source of truth — no suite.requests access.
228
+ */
229
+ private _getRequestNodes;
212
230
  }
@@ -11,10 +11,38 @@ export interface FlatRequest {
11
11
  request: CollectionRequestItem;
12
12
  folderPath: string;
13
13
  }
14
+ /**
15
+ * Encode a single folder name segment so that '/' within the name is
16
+ * unambiguous from the '/' path separator used in folderPath strings.
17
+ * Only '/' is encoded; all other characters are left as-is.
18
+ */
19
+ export declare function encodeFolderName(name: string): string;
20
+ /**
21
+ * Decode a single folder name segment back to its display form.
22
+ */
23
+ export declare function decodeFolderName(name: string): string;
24
+ /**
25
+ * Convert an internal folderPath (segments joined by '/', with '/' inside
26
+ * names encoded as '%2F') to a human-readable display string.
27
+ * E.g. "agl-page-composition/TRAY%2FEPG/AVS5-5303 - TRAY%2FEPG"
28
+ * → "agl-page-composition / TRAY/EPG / AVS5-5303 - TRAY/EPG"
29
+ */
30
+ export declare function decodeFolderPath(folderPath: string): string;
31
+ /**
32
+ * Convert a user-supplied folder input to an internal folderPath.
33
+ * Accepts both the display form ("A / B/C / D" with ' / ' separators)
34
+ * and the raw form ("A/B/C"). In the raw form, each slash that matches a
35
+ * known separator boundary is kept; slashes within a segment are encoded.
36
+ * The simplest reliable approach: if ' / ' is present, treat it as the
37
+ * separator; otherwise encode all '/' as '%2F' (treating the whole input
38
+ * as a single folder name or leaf to match by inclusion).
39
+ */
40
+ export declare function normalizeFolderInput(input: string): string;
14
41
  /** Flatten all requests in a collection into a list with their folder paths. */
15
42
  export declare function flattenRequests(collection: Collection, items?: CollectionItem[], folderPath?: string): FlatRequest[];
16
- /** Enumerate every folder path in a collection along with its recursive request count. */
43
+ /** Enumerate every folder path in a collection along with its id and recursive request count. */
17
44
  export declare function enumerateFolders(collection: Collection, items?: CollectionItem[], prefix?: string): Array<{
45
+ folderId: string;
18
46
  folderPath: string;
19
47
  requestCount: number;
20
48
  }>;
@@ -0,0 +1,39 @@
1
+ /**
2
+ * MCP Prompts — pre-defined analysis prompts that leverage the calling LLM.
3
+ *
4
+ * When an MCP client (Copilot, Claude Code, etc.) invokes a prompt, the server
5
+ * fetches workspace data, assembles a rich structured message, and returns it
6
+ * to the client. The client feeds this message to its already-connected LLM,
7
+ * which produces AI-quality analysis without any extra configuration.
8
+ *
9
+ * Available prompts:
10
+ * analyze-test-failure — diagnose failures from a completed run
11
+ * suggest-assertions — write pm.test() scripts for a request
12
+ * review-collection — structural review of a collection
13
+ */
14
+ import type { ICollectionService } from '../types/collection';
15
+ import type { McpRunStore } from './mcp-run-store';
16
+ export interface McpPromptArg {
17
+ name: string;
18
+ description: string;
19
+ required: boolean;
20
+ }
21
+ export interface McpPromptDef {
22
+ name: string;
23
+ description: string;
24
+ arguments: McpPromptArg[];
25
+ }
26
+ export declare const MCP_PROMPTS: McpPromptDef[];
27
+ interface PromptMessage {
28
+ role: 'user' | 'assistant';
29
+ content: {
30
+ type: 'text';
31
+ text: string;
32
+ };
33
+ }
34
+ export interface PromptResult {
35
+ description: string;
36
+ messages: PromptMessage[];
37
+ }
38
+ export declare function buildPromptResult(name: string, args: Record<string, string>, collectionService: ICollectionService, runStore: McpRunStore): Promise<PromptResult>;
39
+ export {};
@@ -8,7 +8,7 @@
8
8
  */
9
9
  export interface McpRunRecord {
10
10
  id: string;
11
- status: 'running' | 'completed' | 'failed';
11
+ status: 'running' | 'completed' | 'failed' | 'cancelled';
12
12
  suiteName: string;
13
13
  startedAt: number;
14
14
  completedAt?: number;
@@ -26,6 +26,8 @@ export interface McpRunRecord {
26
26
  allResults: object[];
27
27
  reportPath: string | null;
28
28
  error?: string;
29
+ /** Request names (unique) that ran without any pm.test() assertion */
30
+ noAssertionExamples?: string[];
29
31
  }
30
32
  export declare class McpRunStore {
31
33
  private readonly store;
@@ -42,4 +44,12 @@ export declare class McpRunStore {
42
44
  prune(): void;
43
45
  /** Iterate all stored run records (non-expired). */
44
46
  values(): IterableIterator<McpRunRecord>;
47
+ /**
48
+ * Best-effort cancellation: mark a running run as 'cancelled' so that the
49
+ * execution loop can detect it and skip remaining requests.
50
+ *
51
+ * Returns `true` when the status was changed; `false` if the run doesn't
52
+ * exist, has already finished, or is in an unmodifiable state.
53
+ */
54
+ cancel(id: string): boolean;
45
55
  }
@@ -13,6 +13,12 @@ export interface McpTool {
13
13
  name: string;
14
14
  description: string;
15
15
  inputSchema: object;
16
+ annotations?: {
17
+ readOnlyHint?: boolean;
18
+ destructiveHint?: boolean;
19
+ idempotentHint?: boolean;
20
+ openWorldHint?: boolean;
21
+ };
16
22
  }
17
23
  /** Remove tools that share an identical name, keeping the first occurrence. */
18
24
  export declare function dedupeToolsByName(tools: McpTool[]): McpTool[];
@@ -21,12 +21,11 @@
21
21
  * human-readable names), so the exact tool name does not affect tool choice.
22
22
  */
23
23
  /**
24
- * Deterministic short token for an ID or folder path (12 hex chars).
25
- * @param value The value to be hashed.
26
- * @param maxLen The maximum length of the raw segment before appending the hash.
27
- * @returns A string combining the truncated value and its hash.
24
+ * Deterministic readable token for an ID or folder path.
25
+ *
26
+ * Shape: `<slug>_<hash12>`
28
27
  */
29
- export declare function mcpToolToken(value: string, maxLen?: number): string;
28
+ export declare function mcpToolToken(value: string): string;
30
29
  /**
31
30
  * Return `value` verbatim when it is a safe, short raw segment (discoverable),
32
31
  * otherwise its deterministic hash token. Either way the result never contains
@@ -67,6 +67,10 @@ export declare const COLLECTION_INPUT_SCHEMA: {
67
67
  readonly type: "number";
68
68
  readonly description: "Number of iterations (default: 1)";
69
69
  };
70
+ readonly concurrency: {
71
+ readonly type: "number";
72
+ readonly description: "Number of parallel virtual users (1–50, default: 1). Each VU runs the full request sequence independently, preserving inter-request dependencies.";
73
+ };
70
74
  readonly stopOnError: {
71
75
  readonly type: "boolean";
72
76
  readonly description: "Stop on first failure";
@@ -107,6 +111,10 @@ export declare const FOLDER_INPUT_SCHEMA: {
107
111
  readonly type: "number";
108
112
  readonly description: "Number of iterations (default: 1)";
109
113
  };
114
+ readonly concurrency: {
115
+ readonly type: "number";
116
+ readonly description: "Number of parallel virtual users (1–50, default: 1). Each VU runs the full request sequence independently.";
117
+ };
110
118
  readonly stopOnError: {
111
119
  readonly type: "boolean";
112
120
  readonly description: "Stop on first failure";
@@ -144,6 +152,10 @@ export declare const SUITE_INPUT_SCHEMA: {
144
152
  readonly type: "number";
145
153
  readonly description: "Number of iterations (overrides suite default)";
146
154
  };
155
+ readonly concurrency: {
156
+ readonly type: "number";
157
+ readonly description: "Number of parallel virtual users (1–50, default: 1). Each VU runs the full request sequence independently.";
158
+ };
147
159
  readonly stopOnError: {
148
160
  readonly type: "boolean";
149
161
  readonly description: "Stop on first failure";
@@ -195,6 +207,7 @@ export declare const GENERIC_TOOL_NAMES: {
195
207
  readonly getRunSummary: "get_run_summary";
196
208
  readonly getFailedRequests: "get_failed_requests";
197
209
  readonly getRequestResult: "get_request_result";
210
+ readonly cancelRun: "cancel_run";
198
211
  readonly setVariable: "set_variable";
199
212
  readonly createCollection: "create_collection";
200
213
  readonly renameCollection: "rename_collection";
@@ -202,6 +215,7 @@ export declare const GENERIC_TOOL_NAMES: {
202
215
  readonly duplicateCollection: "duplicate_collection";
203
216
  readonly createFolder: "create_folder";
204
217
  readonly deleteFolder: "delete_folder";
218
+ readonly getRequest: "get_request";
205
219
  readonly createRequest: "create_request";
206
220
  readonly updateRequest: "update_request";
207
221
  readonly deleteRequest: "delete_request";
@@ -212,6 +226,12 @@ export declare const GENERIC_TOOL_NAMES: {
212
226
  readonly getSuite: "get_suite";
213
227
  readonly createSuite: "create_suite";
214
228
  readonly updateSuiteConfig: "update_suite_config";
229
+ readonly getSuiteNode: "get_suite_node";
230
+ readonly listSuiteNodePaths: "list_suite_node_paths";
231
+ readonly addSuiteNode: "add_suite_node";
232
+ readonly updateSuiteNode: "update_suite_node";
233
+ readonly removeSuiteNode: "remove_suite_node";
234
+ readonly moveSuiteNode: "move_suite_node";
215
235
  readonly addSuiteRequests: "add_suite_requests";
216
236
  readonly removeSuiteRequest: "remove_suite_request";
217
237
  readonly reorderSuiteRequests: "reorder_suite_requests";
@@ -229,12 +249,37 @@ export declare const GENERIC_TOOL_NAMES: {
229
249
  readonly scaffoldCollectionFromOpenApi: "scaffold_collection_from_openapi";
230
250
  readonly suggestAssertions: "suggest_assertions";
231
251
  readonly explainFailure: "explain_failure";
252
+ readonly suggestEnvVars: "suggest_env_vars";
253
+ readonly applyEnvVars: "apply_env_vars";
254
+ readonly getRequestsForEnhancement: "get_requests_for_enhancement";
255
+ readonly applyRequestEnhancements: "apply_request_enhancements";
256
+ readonly aiSuggestEnvVars: "ai_suggest_env_vars";
257
+ readonly aiEnhanceCollection: "ai_enhance_collection";
258
+ readonly analyzeCoverage: "analyze_coverage";
259
+ readonly aiAnalyzeCoverage: "ai_analyze_coverage";
260
+ readonly generateRequestFromIntent: "generate_request_from_intent";
261
+ readonly validateAgainstSpec: "validate_against_spec";
262
+ readonly generateScenarios: "generate_scenarios";
263
+ readonly healAssertions: "heal_assertions";
264
+ readonly generateIterationData: "generate_iteration_data";
232
265
  };
233
266
  export type GenericToolName = (typeof GENERIC_TOOL_NAMES)[keyof typeof GENERIC_TOOL_NAMES];
267
+ /** MCP 2025-11 tool annotations — surface hints to AI clients about safety and idempotency. */
268
+ interface ToolAnnotations {
269
+ /** true = no side-effects (safe to call freely) */
270
+ readOnlyHint?: boolean;
271
+ /** true = irreversible side-effect (client should confirm before calling) */
272
+ destructiveHint?: boolean;
273
+ /** true = safe to retry without unintended side-effects */
274
+ idempotentHint?: boolean;
275
+ /** true = may interact with external systems; false = workspace-local only */
276
+ openWorldHint?: boolean;
277
+ }
234
278
  interface GenericToolDef {
235
279
  name: string;
236
280
  description: string;
237
281
  inputSchema: Record<string, unknown>;
282
+ annotations?: ToolAnnotations;
238
283
  }
239
284
  /**
240
285
  * Build the generic drill-down tool definitions. `collectionLabels` and
@@ -13,6 +13,11 @@ export interface NodeBootstrapOptions {
13
13
  name: string;
14
14
  version: string;
15
15
  };
16
+ /**
17
+ * Optional global store file path.
18
+ * If relative, it is resolved against the workspace folder.
19
+ */
20
+ globalStorePath?: string;
16
21
  }
17
22
  /**
18
23
  * Bootstrap HTTP Forge core services for Node.js environment.
@@ -27,3 +32,7 @@ export declare function bootstrapNodeRuntime(options: NodeBootstrapOptions): Ser
27
32
  * This is a convenience wrapper that combines bootstrap and returns the container.
28
33
  */
29
34
  export declare function createNodeContainer(workspaceFolder: string): ServiceContainer;
35
+ /**
36
+ * Create and initialize service container with optional Node bootstrap overrides.
37
+ */
38
+ export declare function createNodeContainerWithOptions(workspaceFolder: string, options: Omit<NodeBootstrapOptions, 'workspaceFolder'>): ServiceContainer;
@@ -118,6 +118,15 @@ export interface RunCollectionOptions {
118
118
  include?: string[];
119
119
  /** Additional machine-readable reports to generate, e.g. ['junit'] */
120
120
  reporters?: string[];
121
+ /**
122
+ * Maximum number of iterations to execute in parallel (default: 1 = sequential).
123
+ * Each iteration runs the full request sequence in order so that inter-request
124
+ * dependencies (e.g. login → use token → call protected endpoint) are always
125
+ * preserved within an iteration. Concurrency means N independent virtual users
126
+ * running the same flow simultaneously, not requests within one flow running in
127
+ * parallel. Max: 50.
128
+ */
129
+ concurrency?: number;
121
130
  /**
122
131
  * Restrict execution to requests under this folder path (slash-separated
123
132
  * folder names, e.g. "Auth/Login"). When omitted, the whole collection runs.
@@ -153,6 +162,11 @@ export interface RunSuiteOptions {
153
162
  include?: string[];
154
163
  /** Additional machine-readable reports to generate, e.g. ['junit'] */
155
164
  reporters?: string[];
165
+ /**
166
+ * Maximum number of iterations to execute in parallel (default: 1 = sequential).
167
+ * Each iteration runs the full request sequence in order. Max: 50.
168
+ */
169
+ concurrency?: number;
156
170
  }
157
171
  /**
158
172
  * Execute a single request directly without MCP server.