@mavogel/awscdk-rootmail 0.0.157 → 0.0.159
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/.jsii +7 -7
- package/lib/rootmail.js +1 -1
- package/lib/ses-receive.js +1 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-cloudwatch-logs/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-cloudwatch-logs/package.json +14 -14
- package/node_modules/@aws-sdk/client-route-53/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-route-53/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-route-53/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-route-53/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-route-53/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-route-53/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-route-53/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-route-53/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-route-53/package.json +15 -15
- package/node_modules/@aws-sdk/client-s3/dist-cjs/index.js +38 -25
- package/node_modules/@aws-sdk/client-s3/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-s3/dist-es/commands/PutBucketLifecycleConfigurationCommand.js +2 -0
- package/node_modules/@aws-sdk/client-s3/dist-es/models/models_0.js +4 -0
- package/node_modules/@aws-sdk/client-s3/dist-es/protocols/Aws_restXml.js +5 -0
- package/node_modules/@aws-sdk/client-s3/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketLifecycleConfigurationCommand.d.ts +1 -0
- package/node_modules/@aws-sdk/client-s3/dist-types/commands/HeadObjectCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketLifecycleConfigurationCommand.d.ts +11 -10
- package/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketNotificationConfigurationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/commands/PutBucketOwnershipControlsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/models/models_0.d.ts +98 -80
- package/node_modules/@aws-sdk/client-s3/dist-types/models/models_1.d.ts +95 -21
- package/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketLifecycleConfigurationCommand.d.ts +7 -3
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketNotificationConfigurationCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/commands/PutBucketOwnershipControlsCommand.d.ts +1 -1
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/models_0.d.ts +11 -12
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/models_1.d.ts +14 -0
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.d.ts +8 -3
- package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-s3/package.json +22 -22
- package/node_modules/@aws-sdk/client-ses/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-ses/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-ses/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ses/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ses/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ses/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-ses/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-ses/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-ses/package.json +14 -14
- package/node_modules/@aws-sdk/client-ssm/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-ssm/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-ssm/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ssm/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ssm/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-ssm/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-ssm/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-ssm/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-ssm/package.json +14 -14
- package/node_modules/@aws-sdk/client-sso/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-sso/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sso/package.json +11 -11
- package/node_modules/@aws-sdk/client-sso-oidc/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-sso-oidc/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sso-oidc/package.json +13 -13
- package/node_modules/@aws-sdk/client-sts/dist-cjs/runtimeConfig.js +1 -0
- package/node_modules/@aws-sdk/client-sts/dist-es/runtimeConfig.js +2 -1
- package/node_modules/@aws-sdk/client-sts/dist-types/runtimeConfig.browser.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sts/dist-types/runtimeConfig.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sts/dist-types/runtimeConfig.native.d.ts +2 -1
- package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/runtimeConfig.browser.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/runtimeConfig.d.ts +6 -3
- package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/runtimeConfig.native.d.ts +7 -3
- package/node_modules/@aws-sdk/client-sts/package.json +13 -13
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.js +17 -2
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/index.js +1 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/setFeature.js +11 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/submodules/client/setFeature.d.ts +12 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/index.d.ts +1 -0
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/setFeature.d.ts +6 -0
- package/node_modules/@aws-sdk/core/package.json +2 -1
- package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-http/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +8 -8
- package/node_modules/@aws-sdk/credential-provider-node/package.json +8 -8
- package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
- package/node_modules/@aws-sdk/middleware-bucket-endpoint/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-expect-continue/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-flexible-checksums/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-host-header/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-location-constraint/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-logger/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-recursion-detection/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-sdk-route53/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +3 -3
- package/node_modules/@aws-sdk/middleware-ssec/package.json +2 -2
- package/node_modules/@aws-sdk/middleware-user-agent/dist-cjs/index.js +60 -4
- package/node_modules/@aws-sdk/middleware-user-agent/dist-es/configurations.js +22 -0
- package/node_modules/@aws-sdk/middleware-user-agent/dist-es/encode-features.js +18 -0
- package/node_modules/@aws-sdk/middleware-user-agent/dist-es/user-agent-middleware.js +9 -1
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/configurations.d.ts +14 -1
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/encode-features.d.ts +5 -0
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/ts3.4/configurations.d.ts +5 -1
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/ts3.4/encode-features.d.ts +2 -0
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/ts3.4/user-agent-middleware.d.ts +2 -1
- package/node_modules/@aws-sdk/middleware-user-agent/dist-types/user-agent-middleware.d.ts +2 -1
- package/node_modules/@aws-sdk/middleware-user-agent/package.json +4 -3
- package/node_modules/@aws-sdk/region-config-resolver/package.json +2 -2
- package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +3 -3
- package/node_modules/@aws-sdk/token-providers/package.json +3 -3
- package/node_modules/@aws-sdk/types/dist-es/feature-ids.js +1 -0
- package/node_modules/@aws-sdk/types/dist-es/index.js +1 -0
- package/node_modules/@aws-sdk/types/dist-types/feature-ids.d.ts +54 -0
- package/node_modules/@aws-sdk/types/dist-types/index.d.ts +1 -0
- package/node_modules/@aws-sdk/types/dist-types/middleware.d.ts +12 -0
- package/node_modules/@aws-sdk/types/dist-types/ts3.4/feature-ids.d.ts +51 -0
- package/node_modules/@aws-sdk/types/dist-types/ts3.4/index.d.ts +1 -0
- package/node_modules/@aws-sdk/types/dist-types/ts3.4/middleware.d.ts +7 -0
- package/node_modules/@aws-sdk/types/package.json +1 -1
- package/node_modules/@aws-sdk/util-endpoints/package.json +2 -2
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-cjs/index.js +6 -2
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-cjs/index.native.js +1 -1
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-es/index.js +6 -2
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-es/index.native.js +1 -1
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/index.d.ts +4 -1
- package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/ts3.4/index.d.ts +6 -1
- package/node_modules/@aws-sdk/util-user-agent-browser/package.json +2 -2
- package/node_modules/@aws-sdk/util-user-agent-node/dist-cjs/index.js +46 -39
- package/node_modules/@aws-sdk/util-user-agent-node/dist-es/defaultUserAgent.js +29 -0
- package/node_modules/@aws-sdk/util-user-agent-node/dist-es/index.js +2 -39
- package/node_modules/@aws-sdk/util-user-agent-node/dist-es/nodeAppIdConfigOptions.js +8 -0
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/defaultUserAgent.d.ts +23 -0
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/index.d.ts +2 -20
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/nodeAppIdConfigOptions.d.ts +13 -0
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/ts3.4/defaultUserAgent.d.ts +21 -0
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/ts3.4/index.d.ts +2 -12
- package/node_modules/@aws-sdk/util-user-agent-node/dist-types/ts3.4/nodeAppIdConfigOptions.d.ts +6 -0
- package/node_modules/@aws-sdk/util-user-agent-node/package.json +3 -2
- package/package.json +9 -9
|
@@ -21,13 +21,16 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
21
21
|
// src/index.ts
|
|
22
22
|
var src_exports = {};
|
|
23
23
|
__export(src_exports, {
|
|
24
|
+
NODE_APP_ID_CONFIG_OPTIONS: () => NODE_APP_ID_CONFIG_OPTIONS,
|
|
24
25
|
UA_APP_ID_ENV_NAME: () => UA_APP_ID_ENV_NAME,
|
|
25
26
|
UA_APP_ID_INI_NAME: () => UA_APP_ID_INI_NAME,
|
|
27
|
+
createDefaultUserAgentProvider: () => createDefaultUserAgentProvider,
|
|
26
28
|
crtAvailability: () => crtAvailability,
|
|
27
29
|
defaultUserAgent: () => defaultUserAgent
|
|
28
30
|
});
|
|
29
31
|
module.exports = __toCommonJS(src_exports);
|
|
30
|
-
|
|
32
|
+
|
|
33
|
+
// src/defaultUserAgent.ts
|
|
31
34
|
var import_os = require("os");
|
|
32
35
|
var import_process = require("process");
|
|
33
36
|
|
|
@@ -44,52 +47,56 @@ var isCrtAvailable = /* @__PURE__ */ __name(() => {
|
|
|
44
47
|
return null;
|
|
45
48
|
}, "isCrtAvailable");
|
|
46
49
|
|
|
47
|
-
// src/
|
|
48
|
-
var
|
|
49
|
-
|
|
50
|
-
var
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
}
|
|
67
|
-
if (serviceId) {
|
|
68
|
-
sections.push([`api/${serviceId}`, clientVersion]);
|
|
69
|
-
}
|
|
70
|
-
if (import_process.env.AWS_EXECUTION_ENV) {
|
|
71
|
-
sections.push([`exec-env/${import_process.env.AWS_EXECUTION_ENV}`]);
|
|
72
|
-
}
|
|
73
|
-
const appIdPromise = (0, import_node_config_provider.loadConfig)({
|
|
74
|
-
environmentVariableSelector: (env2) => env2[UA_APP_ID_ENV_NAME],
|
|
75
|
-
configFileSelector: (profile) => profile[UA_APP_ID_INI_NAME],
|
|
76
|
-
default: void 0
|
|
77
|
-
})();
|
|
78
|
-
let resolvedUserAgent = void 0;
|
|
79
|
-
return async () => {
|
|
80
|
-
if (!resolvedUserAgent) {
|
|
81
|
-
const appId = await appIdPromise;
|
|
82
|
-
resolvedUserAgent = appId ? [...sections, [`app/${appId}`]] : [...sections];
|
|
50
|
+
// src/defaultUserAgent.ts
|
|
51
|
+
var createDefaultUserAgentProvider = /* @__PURE__ */ __name(({ serviceId, clientVersion }) => {
|
|
52
|
+
return async (config) => {
|
|
53
|
+
var _a;
|
|
54
|
+
const sections = [
|
|
55
|
+
// sdk-metadata
|
|
56
|
+
["aws-sdk-js", clientVersion],
|
|
57
|
+
// ua-metadata
|
|
58
|
+
["ua", "2.1"],
|
|
59
|
+
// os-metadata
|
|
60
|
+
[`os/${(0, import_os.platform)()}`, (0, import_os.release)()],
|
|
61
|
+
// language-metadata
|
|
62
|
+
// ECMAScript edition doesn't matter in JS, so no version needed.
|
|
63
|
+
["lang/js"],
|
|
64
|
+
["md/nodejs", `${import_process.versions.node}`]
|
|
65
|
+
];
|
|
66
|
+
const crtAvailable = isCrtAvailable();
|
|
67
|
+
if (crtAvailable) {
|
|
68
|
+
sections.push(crtAvailable);
|
|
83
69
|
}
|
|
70
|
+
if (serviceId) {
|
|
71
|
+
sections.push([`api/${serviceId}`, clientVersion]);
|
|
72
|
+
}
|
|
73
|
+
if (import_process.env.AWS_EXECUTION_ENV) {
|
|
74
|
+
sections.push([`exec-env/${import_process.env.AWS_EXECUTION_ENV}`]);
|
|
75
|
+
}
|
|
76
|
+
const appId = await ((_a = config == null ? void 0 : config.userAgentAppId) == null ? void 0 : _a.call(config));
|
|
77
|
+
const resolvedUserAgent = appId ? [...sections, [`app/${appId}`]] : [...sections];
|
|
84
78
|
return resolvedUserAgent;
|
|
85
79
|
};
|
|
86
|
-
}, "
|
|
80
|
+
}, "createDefaultUserAgentProvider");
|
|
81
|
+
var defaultUserAgent = createDefaultUserAgentProvider;
|
|
82
|
+
|
|
83
|
+
// src/nodeAppIdConfigOptions.ts
|
|
84
|
+
var import_middleware_user_agent = require("@aws-sdk/middleware-user-agent");
|
|
85
|
+
var UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
86
|
+
var UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
87
|
+
var NODE_APP_ID_CONFIG_OPTIONS = {
|
|
88
|
+
environmentVariableSelector: (env2) => env2[UA_APP_ID_ENV_NAME],
|
|
89
|
+
configFileSelector: (profile) => profile[UA_APP_ID_INI_NAME],
|
|
90
|
+
default: import_middleware_user_agent.DEFAULT_UA_APP_ID
|
|
91
|
+
};
|
|
87
92
|
// Annotate the CommonJS export names for ESM import in node:
|
|
88
93
|
|
|
89
94
|
0 && (module.exports = {
|
|
90
95
|
crtAvailability,
|
|
96
|
+
createDefaultUserAgentProvider,
|
|
97
|
+
defaultUserAgent,
|
|
91
98
|
UA_APP_ID_ENV_NAME,
|
|
92
99
|
UA_APP_ID_INI_NAME,
|
|
93
|
-
|
|
100
|
+
NODE_APP_ID_CONFIG_OPTIONS
|
|
94
101
|
});
|
|
95
102
|
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { platform, release } from "os";
|
|
2
|
+
import { env, versions } from "process";
|
|
3
|
+
import { isCrtAvailable } from "./is-crt-available";
|
|
4
|
+
export { crtAvailability } from "./crt-availability";
|
|
5
|
+
export const createDefaultUserAgentProvider = ({ serviceId, clientVersion }) => {
|
|
6
|
+
return async (config) => {
|
|
7
|
+
const sections = [
|
|
8
|
+
["aws-sdk-js", clientVersion],
|
|
9
|
+
["ua", "2.1"],
|
|
10
|
+
[`os/${platform()}`, release()],
|
|
11
|
+
["lang/js"],
|
|
12
|
+
["md/nodejs", `${versions.node}`],
|
|
13
|
+
];
|
|
14
|
+
const crtAvailable = isCrtAvailable();
|
|
15
|
+
if (crtAvailable) {
|
|
16
|
+
sections.push(crtAvailable);
|
|
17
|
+
}
|
|
18
|
+
if (serviceId) {
|
|
19
|
+
sections.push([`api/${serviceId}`, clientVersion]);
|
|
20
|
+
}
|
|
21
|
+
if (env.AWS_EXECUTION_ENV) {
|
|
22
|
+
sections.push([`exec-env/${env.AWS_EXECUTION_ENV}`]);
|
|
23
|
+
}
|
|
24
|
+
const appId = await config?.userAgentAppId?.();
|
|
25
|
+
const resolvedUserAgent = appId ? [...sections, [`app/${appId}`]] : [...sections];
|
|
26
|
+
return resolvedUserAgent;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
export const defaultUserAgent = createDefaultUserAgentProvider;
|
|
@@ -1,39 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import { env, versions } from "process";
|
|
4
|
-
import { isCrtAvailable } from "./is-crt-available";
|
|
5
|
-
export { crtAvailability } from "./crt-availability";
|
|
6
|
-
export const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
7
|
-
export const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
8
|
-
export const defaultUserAgent = ({ serviceId, clientVersion }) => {
|
|
9
|
-
const sections = [
|
|
10
|
-
["aws-sdk-js", clientVersion],
|
|
11
|
-
["ua", "2.0"],
|
|
12
|
-
[`os/${platform()}`, release()],
|
|
13
|
-
["lang/js"],
|
|
14
|
-
["md/nodejs", `${versions.node}`],
|
|
15
|
-
];
|
|
16
|
-
const crtAvailable = isCrtAvailable();
|
|
17
|
-
if (crtAvailable) {
|
|
18
|
-
sections.push(crtAvailable);
|
|
19
|
-
}
|
|
20
|
-
if (serviceId) {
|
|
21
|
-
sections.push([`api/${serviceId}`, clientVersion]);
|
|
22
|
-
}
|
|
23
|
-
if (env.AWS_EXECUTION_ENV) {
|
|
24
|
-
sections.push([`exec-env/${env.AWS_EXECUTION_ENV}`]);
|
|
25
|
-
}
|
|
26
|
-
const appIdPromise = loadConfig({
|
|
27
|
-
environmentVariableSelector: (env) => env[UA_APP_ID_ENV_NAME],
|
|
28
|
-
configFileSelector: (profile) => profile[UA_APP_ID_INI_NAME],
|
|
29
|
-
default: undefined,
|
|
30
|
-
})();
|
|
31
|
-
let resolvedUserAgent = undefined;
|
|
32
|
-
return async () => {
|
|
33
|
-
if (!resolvedUserAgent) {
|
|
34
|
-
const appId = await appIdPromise;
|
|
35
|
-
resolvedUserAgent = appId ? [...sections, [`app/${appId}`]] : [...sections];
|
|
36
|
-
}
|
|
37
|
-
return resolvedUserAgent;
|
|
38
|
-
};
|
|
39
|
-
};
|
|
1
|
+
export * from "./defaultUserAgent";
|
|
2
|
+
export * from "./nodeAppIdConfigOptions";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { DEFAULT_UA_APP_ID } from "@aws-sdk/middleware-user-agent";
|
|
2
|
+
export const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
3
|
+
export const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
4
|
+
export const NODE_APP_ID_CONFIG_OPTIONS = {
|
|
5
|
+
environmentVariableSelector: (env) => env[UA_APP_ID_ENV_NAME],
|
|
6
|
+
configFileSelector: (profile) => profile[UA_APP_ID_INI_NAME],
|
|
7
|
+
default: DEFAULT_UA_APP_ID,
|
|
8
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Provider, UserAgent } from "@smithy/types";
|
|
2
|
+
export { crtAvailability } from "./crt-availability";
|
|
3
|
+
export interface DefaultUserAgentOptions {
|
|
4
|
+
serviceId?: string;
|
|
5
|
+
clientVersion: string;
|
|
6
|
+
}
|
|
7
|
+
export interface PreviouslyResolved {
|
|
8
|
+
userAgentAppId: Provider<string | undefined>;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* @internal
|
|
12
|
+
*
|
|
13
|
+
* Collect metrics from runtime to put into user agent.
|
|
14
|
+
*/
|
|
15
|
+
export declare const createDefaultUserAgentProvider: ({ serviceId, clientVersion }: DefaultUserAgentOptions) => (config?: PreviouslyResolved) => Promise<UserAgent>;
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @internal
|
|
19
|
+
*
|
|
20
|
+
* @deprecated use createDefaultUserAgentProvider
|
|
21
|
+
*
|
|
22
|
+
*/
|
|
23
|
+
export declare const defaultUserAgent: ({ serviceId, clientVersion }: DefaultUserAgentOptions) => (config?: PreviouslyResolved) => Promise<UserAgent>;
|
|
@@ -1,20 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
3
|
-
/**
|
|
4
|
-
* @internal
|
|
5
|
-
*/
|
|
6
|
-
export declare const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
7
|
-
/**
|
|
8
|
-
* @internal
|
|
9
|
-
*/
|
|
10
|
-
export declare const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
11
|
-
interface DefaultUserAgentOptions {
|
|
12
|
-
serviceId?: string;
|
|
13
|
-
clientVersion: string;
|
|
14
|
-
}
|
|
15
|
-
/**
|
|
16
|
-
* @internal
|
|
17
|
-
*
|
|
18
|
-
* Collect metrics from runtime to put into user agent.
|
|
19
|
-
*/
|
|
20
|
-
export declare const defaultUserAgent: ({ serviceId, clientVersion }: DefaultUserAgentOptions) => Provider<UserAgent>;
|
|
1
|
+
export * from "./defaultUserAgent";
|
|
2
|
+
export * from "./nodeAppIdConfigOptions";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { LoadedConfigSelectors } from "@smithy/node-config-provider";
|
|
2
|
+
/**
|
|
3
|
+
* @internal
|
|
4
|
+
*/
|
|
5
|
+
export declare const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
6
|
+
/**
|
|
7
|
+
* @internal
|
|
8
|
+
*/
|
|
9
|
+
export declare const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
10
|
+
/**
|
|
11
|
+
* @internal
|
|
12
|
+
*/
|
|
13
|
+
export declare const NODE_APP_ID_CONFIG_OPTIONS: LoadedConfigSelectors<string | undefined>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Provider, UserAgent } from "@smithy/types";
|
|
2
|
+
export { crtAvailability } from "./crt-availability";
|
|
3
|
+
export interface DefaultUserAgentOptions {
|
|
4
|
+
serviceId?: string;
|
|
5
|
+
clientVersion: string;
|
|
6
|
+
}
|
|
7
|
+
export interface PreviouslyResolved {
|
|
8
|
+
userAgentAppId: Provider<string | undefined>;
|
|
9
|
+
}
|
|
10
|
+
export declare const createDefaultUserAgentProvider: ({
|
|
11
|
+
serviceId,
|
|
12
|
+
clientVersion,
|
|
13
|
+
}: DefaultUserAgentOptions) => (
|
|
14
|
+
config?: PreviouslyResolved
|
|
15
|
+
) => Promise<UserAgent>;
|
|
16
|
+
export declare const defaultUserAgent: ({
|
|
17
|
+
serviceId,
|
|
18
|
+
clientVersion,
|
|
19
|
+
}: DefaultUserAgentOptions) => (
|
|
20
|
+
config?: PreviouslyResolved
|
|
21
|
+
) => Promise<UserAgent>;
|
|
@@ -1,12 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
3
|
-
export declare const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
4
|
-
export declare const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
5
|
-
interface DefaultUserAgentOptions {
|
|
6
|
-
serviceId?: string;
|
|
7
|
-
clientVersion: string;
|
|
8
|
-
}
|
|
9
|
-
export declare const defaultUserAgent: ({
|
|
10
|
-
serviceId,
|
|
11
|
-
clientVersion,
|
|
12
|
-
}: DefaultUserAgentOptions) => Provider<UserAgent>;
|
|
1
|
+
export * from "./defaultUserAgent";
|
|
2
|
+
export * from "./nodeAppIdConfigOptions";
|
package/node_modules/@aws-sdk/util-user-agent-node/dist-types/ts3.4/nodeAppIdConfigOptions.d.ts
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { LoadedConfigSelectors } from "@smithy/node-config-provider";
|
|
2
|
+
export declare const UA_APP_ID_ENV_NAME = "AWS_SDK_UA_APP_ID";
|
|
3
|
+
export declare const UA_APP_ID_INI_NAME = "sdk-ua-app-id";
|
|
4
|
+
export declare const NODE_APP_ID_CONFIG_OPTIONS: LoadedConfigSelectors<
|
|
5
|
+
string | undefined
|
|
6
|
+
>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/util-user-agent-node",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.664.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
6
6
|
"build:cjs": "node ../../scripts/compilation/inline util-user-agent-node",
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
},
|
|
21
21
|
"license": "Apache-2.0",
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@aws-sdk/
|
|
23
|
+
"@aws-sdk/middleware-user-agent": "3.664.0",
|
|
24
|
+
"@aws-sdk/types": "3.664.0",
|
|
24
25
|
"@smithy/node-config-provider": "^3.1.8",
|
|
25
26
|
"@smithy/types": "^3.5.0",
|
|
26
27
|
"tslib": "^2.6.2"
|
package/package.json
CHANGED
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"@aws-cdk/integ-tests-alpha": "^2.90.0-alpha.0",
|
|
45
45
|
"@commitlint/cli": "^17.8.1",
|
|
46
46
|
"@commitlint/config-conventional": "^17.8.1",
|
|
47
|
-
"@types/async-retry": "^1.4.
|
|
47
|
+
"@types/async-retry": "^1.4.9",
|
|
48
48
|
"@types/aws-lambda": "^8.10.145",
|
|
49
49
|
"@types/axios": "^0.14.0",
|
|
50
50
|
"@types/jest": "^29.5.13",
|
|
@@ -55,12 +55,12 @@
|
|
|
55
55
|
"@typescript-eslint/eslint-plugin": "^7",
|
|
56
56
|
"@typescript-eslint/parser": "^7",
|
|
57
57
|
"aws-cdk-lib": "2.90.0",
|
|
58
|
-
"cdk-assets": "^2.
|
|
58
|
+
"cdk-assets": "^2.155.2",
|
|
59
59
|
"commit-and-tag-version": "^12",
|
|
60
60
|
"constructs": "10.0.5",
|
|
61
61
|
"eslint": "^8",
|
|
62
62
|
"eslint-import-resolver-typescript": "^3.6.3",
|
|
63
|
-
"eslint-plugin-import": "^2.
|
|
63
|
+
"eslint-plugin-import": "^2.31.0",
|
|
64
64
|
"husky": "^8.0.3",
|
|
65
65
|
"jest": "^29.7.0",
|
|
66
66
|
"jest-junit": "^15",
|
|
@@ -80,11 +80,11 @@
|
|
|
80
80
|
"constructs": "^10.0.5"
|
|
81
81
|
},
|
|
82
82
|
"dependencies": {
|
|
83
|
-
"@aws-sdk/client-cloudwatch-logs": "^3.
|
|
84
|
-
"@aws-sdk/client-route-53": "^3.
|
|
85
|
-
"@aws-sdk/client-s3": "^3.
|
|
86
|
-
"@aws-sdk/client-ses": "^3.
|
|
87
|
-
"@aws-sdk/client-ssm": "^3.
|
|
83
|
+
"@aws-sdk/client-cloudwatch-logs": "^3.664.0",
|
|
84
|
+
"@aws-sdk/client-route-53": "^3.664.0",
|
|
85
|
+
"@aws-sdk/client-s3": "^3.664.0",
|
|
86
|
+
"@aws-sdk/client-ses": "^3.664.0",
|
|
87
|
+
"@aws-sdk/client-ssm": "^3.664.0",
|
|
88
88
|
"async-retry": "^1.3.3",
|
|
89
89
|
"axios": "^1.7.7",
|
|
90
90
|
"cdk-nag": "^2.28.195",
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
"publishConfig": {
|
|
116
116
|
"access": "public"
|
|
117
117
|
},
|
|
118
|
-
"version": "0.0.
|
|
118
|
+
"version": "0.0.159",
|
|
119
119
|
"jest": {
|
|
120
120
|
"coverageProvider": "v8",
|
|
121
121
|
"testMatch": [
|