@http-forge/core 0.6.10 → 0.6.12

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.
@@ -100,10 +100,13 @@ export interface McpCorsConfig {
100
100
  export type McpToolMode = 'flat' | 'drilldown' | 'auto';
101
101
  /**
102
102
  * MCP Server project-level configuration (stored in http-forge.config.json)
103
- *
104
- * Machine-specific settings (port, autoStart) remain in VS Code settings.
105
103
  */
106
104
  export interface McpConfig {
105
+ /**
106
+ * Port for the embedded MCP HTTP server. Defaults to 3100.
107
+ * Runtime callers can still override this via `createMcpRuntime({ port })`.
108
+ */
109
+ port: number;
107
110
  /**
108
111
  * Collection IDs or names to hide from MCP tools.
109
112
  * Empty array (default) = expose all collections.
@@ -93,6 +93,11 @@ export declare class OpenApiExporter {
93
93
  private tryParseBodyContent;
94
94
  private buildFormDataSchemaFromBody;
95
95
  private buildResponses;
96
+ /**
97
+ * Map operation-level response definitions (from metadata) to OpenAPI format.
98
+ * Converts OperationResponse[] indexed by status code into OpenAPI responses object.
99
+ */
100
+ private mapResponseDefinitions;
96
101
  private buildOperationSecurity;
97
102
  private mapAuthToSecurityScheme;
98
103
  private parseScopes;
@@ -39,6 +39,24 @@ export interface UnifiedFolder {
39
39
  scripts?: CollectionScripts;
40
40
  items: (UnifiedFolder | UnifiedRequest)[];
41
41
  }
42
+ /**
43
+ * Operation example (for OpenAPI generation)
44
+ */
45
+ export interface OperationExample {
46
+ name: string;
47
+ description?: string;
48
+ value: any;
49
+ }
50
+ /**
51
+ * Operation response definition (for OpenAPI generation)
52
+ */
53
+ export interface OperationResponse {
54
+ description: string;
55
+ contentType?: string;
56
+ schema?: JSONSchema7;
57
+ examples?: Record<string, any>;
58
+ headers?: Record<string, KeyValueEntry>;
59
+ }
42
60
  /**
43
61
  * Unified Request - normalized request format
44
62
  * Supports full feature set from CollectionRequest with metadata preservation
@@ -71,6 +89,18 @@ export interface UnifiedRequest {
71
89
  responseSchema?: ResponseSchemaDefinition;
72
90
  /** Body schema for validation */
73
91
  bodySchema?: BodySchemaDefinition;
92
+ /** Explicit OpenAPI operationId (e.g., from @Operation, @RequestMapping) */
93
+ operationId?: string;
94
+ /** Explicit OpenAPI summary, separate from name */
95
+ summary?: string;
96
+ /** Explicit OpenAPI tags (e.g., from @Tag, controller class) */
97
+ tags?: string[];
98
+ /** Request/response examples for OpenAPI */
99
+ examples?: OperationExample[];
100
+ /** Per-status-code response definitions */
101
+ responses?: Record<string, OperationResponse>;
102
+ /** Operation-level security requirements */
103
+ security?: Record<string, string[]>[];
74
104
  }
75
105
  /**
76
106
  * Collection-level scripts
@@ -578,6 +608,12 @@ export interface CollectionRequest {
578
608
  deprecated?: boolean;
579
609
  responseSchema?: ResponseSchemaDefinition;
580
610
  bodySchema?: BodySchemaDefinition;
611
+ operationId?: string;
612
+ summary?: string;
613
+ tags?: string[];
614
+ examples?: OperationExample[];
615
+ responses?: Record<string, OperationResponse>;
616
+ security?: Record<string, string[]>[];
581
617
  }
582
618
  /**
583
619
  * Encoded request body ready for HTTP transmission
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@http-forge/core",
3
- "version": "0.6.10",
4
- "description": "Headless HTTP testing engine with Postman collection support, dynamic variables, and script-based automation.",
3
+ "version": "0.6.12",
4
+ "description": "Headless Postman-compatible API testing engine for Node.js, CI/CD, OpenAPI workflows, and HTTP Forge automation",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
7
7
  "types": "./dist/index.d.ts",
@@ -27,18 +27,32 @@
27
27
  "clean": "rimraf dist"
28
28
  },
29
29
  "keywords": [
30
+ "http-forge",
31
+ "http forge",
30
32
  "http",
31
33
  "api",
32
34
  "testing",
33
- "automation",
35
+ "api testing",
34
36
  "postman",
37
+ "postman alternative",
38
+ "postman runtime",
39
+ "openapi",
40
+ "graphql",
41
+ "automation",
42
+ "ci",
43
+ "cd",
44
+ "ci-cd",
45
+ "api engine",
35
46
  "collection",
47
+ "headless",
48
+ "headless api testing",
49
+ "nodejs",
50
+ "mcp",
51
+ "mcp server",
36
52
  "scripting",
37
53
  "variables",
38
54
  "cookies",
39
- "ci-cd",
40
- "headless",
41
- "http-forge"
55
+ "runtime"
42
56
  ],
43
57
  "author": "Henry Huang",
44
58
  "license": "MIT",