@http-forge/core 1.0.7 → 1.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/index.js +90 -90
- package/dist/index.mjs +86 -86
- package/dist/infrastructure/http/native-http-client.d.ts +3 -1
- package/dist/infrastructure/secrets/base-secret-resolver.d.ts +1 -0
- package/dist/infrastructure/secrets/secret-resolver-registry.d.ts +8 -1
- package/package.json +1 -1
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* - Cookie parsing from Set-Cookie headers
|
|
16
16
|
*/
|
|
17
17
|
import { IHttpClient } from '../../types/platform';
|
|
18
|
+
import { IConsoleService } from '../../types/console-service';
|
|
18
19
|
import { HttpRequest, HttpResponse, RequestSettings } from '../../types/types';
|
|
19
20
|
import { ProxyConfig } from '../config/config.interface';
|
|
20
21
|
import type { SecretResolverRegistry } from '../secrets/secret-resolver-registry';
|
|
@@ -51,9 +52,10 @@ export declare class NodeHttpClient implements IHttpClient {
|
|
|
51
52
|
private readonly resolveDefaults;
|
|
52
53
|
private readonly resolveProxy;
|
|
53
54
|
private readonly resolveSecretRegistry;
|
|
55
|
+
private readonly resolveConsole;
|
|
54
56
|
private version;
|
|
55
57
|
private readonly basePath;
|
|
56
|
-
constructor(defaultSettings?: RequestSettingsSource, basePath?: string, proxySource?: ProxySource, secretRegistrySource?: SecretRegistrySource);
|
|
58
|
+
constructor(defaultSettings?: RequestSettingsSource, basePath?: string, proxySource?: ProxySource, secretRegistrySource?: SecretRegistrySource, consoleServiceSource?: (() => IConsoleService | null | undefined));
|
|
57
59
|
/** Current default settings, resolved fresh from the configured source. */
|
|
58
60
|
private get settings();
|
|
59
61
|
/**
|
|
@@ -32,6 +32,7 @@ export declare abstract class BaseSecretResolver {
|
|
|
32
32
|
* traversal. Providers implement `fetchRaw` only.
|
|
33
33
|
*/
|
|
34
34
|
resolve(secretPath: string): Promise<string | undefined>;
|
|
35
|
+
private resolvePath;
|
|
35
36
|
/**
|
|
36
37
|
* Provider-specific raw string retrieval. Implement in subclasses.
|
|
37
38
|
* Must return the raw secret payload as a string (possibly JSON).
|
|
@@ -12,8 +12,10 @@
|
|
|
12
12
|
* - Results are cached within a single request lifetime to avoid redundant API calls
|
|
13
13
|
*/
|
|
14
14
|
import type { IConfigService } from '../config/config.interface';
|
|
15
|
+
import type { IConsoleService } from '../../types/console-service';
|
|
15
16
|
export declare class SecretResolverRegistry {
|
|
16
17
|
private readonly configService?;
|
|
18
|
+
private readonly consoleService?;
|
|
17
19
|
private readonly resolvers;
|
|
18
20
|
/**
|
|
19
21
|
* Require function rooted at the user's project (via config `scripts.modulePaths`),
|
|
@@ -27,7 +29,12 @@ export declare class SecretResolverRegistry {
|
|
|
27
29
|
* rebuild on the next resolution instead of leaving startup resolvers stale.
|
|
28
30
|
*/
|
|
29
31
|
private configKey?;
|
|
30
|
-
constructor(configService?: IConfigService | undefined);
|
|
32
|
+
constructor(configService?: IConfigService | undefined, consoleService?: IConsoleService | undefined);
|
|
33
|
+
/**
|
|
34
|
+
* Log a warning via the console service (VS Code output channel) when
|
|
35
|
+
* available, falling back to console.warn for CLI/standalone.
|
|
36
|
+
*/
|
|
37
|
+
private logWarn;
|
|
31
38
|
/**
|
|
32
39
|
* Scan a string (or recursively, any object) for {{secret:alias/path}} tokens
|
|
33
40
|
* and resolve them all in parallel.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@http-forge/core",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.8",
|
|
4
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",
|