@qqbrowser/openclaw-qbot 0.10.8 → 0.10.10
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 -54
- package/dist/build-info.json +3 -3
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/canvas-host/a2ui/a2ui.bundle.js +72 -71
- package/node_modules/@aws-sdk/client-bedrock-runtime/package.json +21 -21
- package/node_modules/@aws-sdk/core/dist-cjs/index.js +17 -7
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.js +18 -6
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +0 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/emitWarningIfUnsupportedVersion.js +15 -6
- package/node_modules/@aws-sdk/core/dist-es/submodules/client/setFeature.js +2 -0
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/AwsRestXmlProtocol.js +0 -1
- package/node_modules/@aws-sdk/core/package.json +7 -5
- package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-http/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +9 -9
- package/node_modules/@aws-sdk/credential-provider-login/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-node/package.json +7 -7
- package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +157 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/constants.js +2 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromEnvSigningName.js +16 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +81 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromStatic.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getNewSsoOidcToken.js +11 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getSsoOidcClient.js +10 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/index.js +4 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/nodeProvider.js +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenExpiry.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenKey.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/writeSSOTokenToFile.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/package.json +70 -0
- 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-sdk-s3/dist-cjs/index.js +9 -25
- package/node_modules/@aws-sdk/middleware-sdk-s3/dist-cjs/toStream.browser.js +11 -0
- package/node_modules/@aws-sdk/middleware-sdk-s3/dist-cjs/toStream.js +7 -0
- package/node_modules/@aws-sdk/middleware-sdk-s3/dist-es/throw-200-exceptions.js +9 -25
- package/node_modules/@aws-sdk/middleware-sdk-s3/dist-es/toStream.browser.js +8 -0
- package/node_modules/@aws-sdk/middleware-sdk-s3/dist-es/toStream.js +4 -0
- package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +15 -8
- package/node_modules/@aws-sdk/middleware-user-agent/package.json +5 -5
- package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/models/errors.js +1 -0
- package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/models/errors.js +1 -0
- package/node_modules/@aws-sdk/nested-clients/package.json +18 -18
- package/node_modules/@aws-sdk/region-config-resolver/package.json +2 -2
- package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +3 -3
- package/node_modules/@aws-sdk/util-endpoints/package.json +2 -2
- package/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
- package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-external/nodable_entities.js +336 -0
- package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.js +26 -2
- package/node_modules/@aws-sdk/xml-builder/dist-es/xml-external/nodable_entities.js +332 -0
- package/node_modules/@aws-sdk/xml-builder/dist-es/xml-parser.js +26 -2
- package/node_modules/@aws-sdk/xml-builder/package.json +3 -2
- package/node_modules/@clack/core/dist/index.mjs +16 -10
- package/node_modules/@clack/core/package.json +5 -2
- package/node_modules/@clack/prompts/dist/index.mjs +114 -107
- package/node_modules/@clack/prompts/package.json +7 -4
- package/node_modules/@google/genai/dist/index.cjs +207 -146
- package/node_modules/@google/genai/dist/index.mjs +208 -147
- package/node_modules/@google/genai/dist/node/index.cjs +235 -156
- package/node_modules/@google/genai/dist/node/index.mjs +236 -157
- package/node_modules/@google/genai/dist/tokenizer/node.cjs +15 -1
- package/node_modules/@google/genai/dist/tokenizer/node.mjs +15 -1
- package/node_modules/@google/genai/dist/vertex_internal/index.cjs +130 -117
- package/node_modules/@google/genai/dist/vertex_internal/index.js +130 -117
- package/node_modules/@google/genai/dist/web/index.mjs +201 -145
- package/node_modules/@google/genai/package.json +6 -1
- package/node_modules/@line/bot-sdk/node_modules/@types/node/package.json +2 -2
- package/node_modules/@nodable/entities/package.json +54 -0
- package/node_modules/@nodable/entities/src/EntityDecoder.js +543 -0
- package/node_modules/@nodable/entities/src/EntityEncoder.js +194 -0
- package/node_modules/@nodable/entities/src/entities.js +1177 -0
- package/node_modules/@nodable/entities/src/entityTries.js +49 -0
- package/node_modules/@nodable/entities/src/index.js +29 -0
- package/node_modules/@opentelemetry/context-async-hooks/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/context-async-hooks/package.json +2 -2
- package/node_modules/@opentelemetry/resources/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/resources/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/resources/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esm/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esm/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esnext/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esnext/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/src/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/src/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/resources/node_modules/@opentelemetry/core/package.json +2 -2
- package/node_modules/@opentelemetry/resources/package.json +3 -3
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/exemplar/ExemplarReservoir.js +6 -5
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/state/AsyncMetricStorage.js +2 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/state/DeltaMetricProcessor.js +4 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/state/MultiWritableMetricStorage.js +4 -3
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/build/esm/view/AttributesProcessor.js +10 -8
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/exemplar/ExemplarReservoir.js +6 -5
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/state/AsyncMetricStorage.js +2 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/state/DeltaMetricProcessor.js +4 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/state/MultiWritableMetricStorage.js +4 -3
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/build/esnext/view/AttributesProcessor.js +10 -8
- package/node_modules/@opentelemetry/sdk-metrics/build/src/exemplar/ExemplarReservoir.js +6 -5
- package/node_modules/@opentelemetry/sdk-metrics/build/src/state/AsyncMetricStorage.js +2 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/src/state/DeltaMetricProcessor.js +4 -2
- package/node_modules/@opentelemetry/sdk-metrics/build/src/state/MultiWritableMetricStorage.js +4 -3
- package/node_modules/@opentelemetry/sdk-metrics/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/build/src/view/AttributesProcessor.js +10 -8
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esm/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esm/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esnext/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esnext/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/src/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/src/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-metrics/node_modules/@opentelemetry/core/package.json +2 -2
- package/node_modules/@opentelemetry/sdk-metrics/package.json +4 -4
- package/node_modules/@opentelemetry/sdk-trace-base/build/esm/sampler/TraceIdRatioBasedSampler.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/build/esnext/sampler/TraceIdRatioBasedSampler.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/build/src/sampler/TraceIdRatioBasedSampler.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esm/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esm/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esnext/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esnext/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/src/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/src/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-base/node_modules/@opentelemetry/core/package.json +2 -2
- package/node_modules/@opentelemetry/sdk-trace-base/package.json +5 -5
- package/node_modules/@opentelemetry/sdk-trace-node/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esm/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esm/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esm/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esnext/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esnext/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/esnext/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/src/propagation/composite.js +8 -3
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/src/trace/TraceState.js +101 -51
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/build/src/version.js +1 -1
- package/node_modules/@opentelemetry/sdk-trace-node/node_modules/@opentelemetry/core/package.json +2 -2
- package/node_modules/@opentelemetry/sdk-trace-node/package.json +6 -6
- package/node_modules/@protobufjs/codegen/index.js +14 -1
- package/node_modules/@protobufjs/codegen/package.json +1 -1
- package/node_modules/@protobufjs/inquire/index.js +25 -5
- package/node_modules/@protobufjs/inquire/package.json +2 -2
- package/node_modules/@protobufjs/utf8/index.js +27 -28
- package/node_modules/@protobufjs/utf8/package.json +21 -21
- package/node_modules/@slack/bolt/dist/conversation-store.js +2 -0
- package/node_modules/@slack/bolt/dist/errors.js +1 -1
- package/node_modules/@slack/bolt/dist/receivers/HTTPModuleFunctions.js +7 -2
- package/node_modules/@slack/bolt/dist/receivers/HTTPReceiver.js +4 -3
- package/node_modules/@slack/bolt/package.json +12 -6
- package/node_modules/@slack/socket-mode/dist/package.json +1 -1
- package/node_modules/@slack/socket-mode/dist/src/SlackWebSocket.js +7 -1
- package/node_modules/@slack/socket-mode/package.json +1 -1
- package/node_modules/@slack/types/package.json +1 -1
- package/node_modules/@slack/web-api/package.json +4 -5
- package/node_modules/@smithy/config-resolver/dist-cjs/index.js +22 -198
- package/node_modules/@smithy/config-resolver/dist-es/index.js +1 -3
- package/node_modules/@smithy/config-resolver/package.json +5 -30
- package/node_modules/@smithy/core/checksum.js +5 -0
- package/node_modules/@smithy/core/client.js +6 -0
- package/node_modules/@smithy/core/config.js +5 -0
- package/node_modules/@smithy/core/dist-cjs/index.js +6 -7
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/httpAuthSchemeMiddleware.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/httpSigningMiddleware.js +4 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +8 -12
- package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.browser.js +202 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.js +259 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.native.js +229 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +1136 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.browser.js +375 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.js +735 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.native.js +364 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.browser.js +860 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.js +873 -3
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.browser.js +866 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +627 -3
- package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +297 -20
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.browser.js +800 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/retry/index.js +827 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +5 -5
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +1452 -0
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +996 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +1452 -0
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpApiKeyAuth.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpBearerAuth.js +2 -2
- package/node_modules/@smithy/core/dist-es/middleware-http-auth-scheme/httpAuthSchemeMiddleware.js +1 -1
- package/node_modules/@smithy/core/dist-es/middleware-http-signing/httpSigningMiddleware.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/cbor/CborCodec.js +1 -3
- package/node_modules/@smithy/core/dist-es/submodules/cbor/SmithyRpcV2CborProtocol.js +2 -3
- package/node_modules/@smithy/core/dist-es/submodules/cbor/cbor-decode.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/cbor/cbor-encode.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/cbor/parseCborBody.js +2 -3
- package/node_modules/@smithy/core/dist-es/submodules/checksum/chunked-blob-reader/chunked-blob-reader.js +9 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/chunked-blob-reader/chunked-blob-reader.native.js +27 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/hash-blob-browser/blobHasher.js +8 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/hash-stream-node/HashCalculator.js +18 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/hash-stream-node/fileStreamHasher.js +24 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/hash-stream-node/readableStreamHasher.js +19 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/index.browser.js +6 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/index.js +5 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/index.native.js +6 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/constants.js +3 -0
- package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/md5.js +168 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/index.js +26 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/client.js +1 -1
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/command.js +2 -2
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/extensions/checksum.js +1 -1
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/extensions/defaultExtensionConfiguration.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/circularReplacer.js +12 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/createWaiter.js +48 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/poller.js +87 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/utils/sleep.js +3 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/utils/validate.js +17 -0
- package/node_modules/@smithy/core/dist-es/submodules/client/util-waiter/waiter.js +35 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/endpointsConfig/NodeUseDualstackEndpointConfigOptions.js +2 -1
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/endpointsConfig/NodeUseFipsEndpointConfigOptions.js +2 -1
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/endpointsConfig/resolveCustomEndpointsConfig.js +1 -1
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/endpointsConfig/resolveEndpointsConfig.js +1 -1
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionConfig/checkRegion.js +1 -1
- package/node_modules/@smithy/{util-defaults-mode-browser/dist-es/resolveDefaultsModeConfig.js → core/dist-es/submodules/config/defaults-mode/resolveDefaultsModeConfig.browser.js} +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/config/defaults-mode/resolveDefaultsModeConfig.js +98 -0
- package/node_modules/@smithy/{util-defaults-mode-browser/dist-es → core/dist-es/submodules/config/defaults-mode}/resolveDefaultsModeConfig.native.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/config/index.browser.js +43 -0
- package/node_modules/@smithy/core/dist-es/submodules/config/index.js +29 -0
- package/node_modules/@smithy/core/dist-es/submodules/config/index.native.js +43 -0
- package/node_modules/@smithy/{node-config-provider/dist-es → core/dist-es/submodules/config/node-config-provider}/configLoader.js +2 -1
- package/node_modules/@smithy/{node-config-provider/dist-es → core/dist-es/submodules/config/node-config-provider}/fromEnv.js +1 -1
- package/node_modules/@smithy/{node-config-provider/dist-es → core/dist-es/submodules/config/node-config-provider}/fromSharedConfigFiles.js +3 -2
- package/node_modules/@smithy/core/dist-es/submodules/config/node-config-provider/fromStatic.js +3 -0
- package/node_modules/@smithy/core/dist-es/submodules/config/property-provider/fromValue.js +1 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getConfigFilepath.js +1 -1
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getCredentialsFilepath.js +1 -1
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getHomeDir.js +2 -2
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getSSOTokenFilepath.js +2 -2
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getSSOTokenFromFile.js +1 -1
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/loadSharedConfigFiles.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/index.browser.js +22 -0
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/index.js +21 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/adaptors/getEndpointFromConfig.js +1 -1
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/adaptors/getEndpointFromInstructions.js +28 -27
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/adaptors/getEndpointUrlConfig.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/adaptors/toEndpointV1.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/endpointMiddleware.js +47 -0
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/getEndpointPlugin.js +26 -0
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/resolveEndpointConfig.js +25 -0
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/toEndpointV1.js +1 -1
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateExpression.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/EventStreamSerde.js +1 -1
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/HeaderMarshaller.js +1 -1
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/Int64.js +1 -1
- package/node_modules/@smithy/{eventstream-serde-browser/dist-es/EventStreamMarshaller.js → core/dist-es/submodules/event-streams/eventstream-serde/EventStreamMarshaller.browser.js} +6 -5
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-serde/EventStreamMarshaller.js +45 -0
- package/node_modules/@smithy/{eventstream-serde-browser/dist-es → core/dist-es/submodules/event-streams/eventstream-serde}/utils.js +1 -1
- package/node_modules/@smithy/{eventstream-serde-universal/dist-es → core/dist-es/submodules/event-streams/eventstream-serde-universal}/EventStreamMarshaller.js +6 -1
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/index.browser.js +14 -0
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/index.js +14 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js +3 -4
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +3 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/collect-stream-body.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/index.js +12 -0
- package/node_modules/@smithy/core/dist-es/submodules/protocols/middleware-content-length/contentLengthMiddleware.js +39 -0
- package/node_modules/@smithy/core/dist-es/submodules/protocols/querystring-builder/buildQueryString.js +21 -0
- package/node_modules/@smithy/core/dist-es/submodules/protocols/requestBuilder.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/serde/FromStringShapeDeserializer.js +1 -3
- package/node_modules/@smithy/core/dist-es/submodules/protocols/serde/HttpInterceptingShapeDeserializer.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/serde/ToStringShapeSerializer.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/url-parser/parseUrl.js +18 -0
- package/node_modules/@smithy/core/dist-es/submodules/retry/index.browser.js +27 -0
- package/node_modules/@smithy/core/dist-es/submodules/retry/index.js +20 -0
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/configurations.js +4 -2
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/isStreamingPayload/isStreamingPayload.js +1 -1
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/omitRetryHeadersMiddleware.js +2 -2
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/parseRetryAfterHeader.js +1 -1
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/retry-pre-sra-deprecated/AdaptiveRetryStrategy.js +2 -1
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/retry-pre-sra-deprecated/StandardRetryStrategy.js +5 -4
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/retry-pre-sra-deprecated/defaultRetryQuota.js +1 -1
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/retry-pre-sra-deprecated/delayDecider.js +1 -1
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/retry-pre-sra-deprecated/retryDecider.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/retry/middleware-retry/retryMiddleware.js +109 -0
- package/node_modules/@smithy/{service-error-classification/dist-es/index.js → core/dist-es/submodules/retry/service-error-classification/service-error-classification.js} +1 -0
- package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/AdaptiveRetryStrategy.js +6 -3
- package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/DefaultRateLimiter.js +3 -2
- package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/StandardRetryStrategy.js +22 -12
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaDeserializationMiddleware.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaSerializationMiddleware.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/serde/generateIdempotencyToken.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/serde/hash-node/hash-node.js +36 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.browser.js +34 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.js +33 -10
- package/node_modules/@smithy/core/dist-es/submodules/serde/index.native.js +34 -0
- package/node_modules/@smithy/{middleware-serde/dist-es → core/dist-es/submodules/serde/middleware-serde}/deserializerMiddleware.js +1 -1
- package/node_modules/@smithy/{util-base64/dist-es → core/dist-es/submodules/serde/util-base64}/fromBase64.browser.js +1 -1
- package/node_modules/@smithy/{util-base64/dist-es → core/dist-es/submodules/serde/util-base64}/fromBase64.js +1 -1
- package/node_modules/@smithy/{util-base64/dist-es → core/dist-es/submodules/serde/util-base64}/toBase64.browser.js +2 -2
- package/node_modules/@smithy/{util-base64/dist-es → core/dist-es/submodules/serde/util-base64}/toBase64.js +2 -2
- package/node_modules/@smithy/{util-body-length-node/dist-es → core/dist-es/submodules/serde/util-body-length}/calculateBodyLength.js +1 -1
- package/node_modules/{@aws-crypto/sha256-browser/node_modules/@smithy/util-buffer-from/dist-es/index.js → @smithy/core/dist-es/submodules/serde/util-buffer-from/buffer-from.js} +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/serde/util-hex-encoding/hex-encoding.js +33 -0
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/blob/Uint8ArrayBlobAdapter.js +4 -2
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/checksum/ChecksumStream.js +2 -2
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/checksum/createChecksumStream.browser.js +1 -1
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/checksum/createChecksumStream.js +1 -1
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/createBufferedReadable.js +1 -1
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/headStream.js +1 -1
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/sdk-stream-mixin.browser.js +4 -4
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/sdk-stream-mixin.js +3 -3
- package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/splitStream.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.browser.js +53 -0
- package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.js +48 -0
- package/node_modules/@smithy/{util-utf8/dist-es → core/dist-es/submodules/serde/util-utf8}/fromUtf8.js +1 -1
- package/node_modules/@smithy/{util-utf8/dist-es → core/dist-es/submodules/serde/util-utf8}/toUtf8.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/serde/uuid/randomUUID.js +3 -0
- package/node_modules/@smithy/core/dist-es/util-identity-and-auth/httpAuthSchemes/httpApiKeyAuth.js +2 -2
- package/node_modules/@smithy/core/dist-es/util-identity-and-auth/httpAuthSchemes/httpBearerAuth.js +1 -1
- package/node_modules/@smithy/core/package.json +110 -11
- package/node_modules/@smithy/core/retry.js +5 -0
- package/node_modules/@smithy/credential-provider-imds/dist-cjs/index.js +39 -41
- package/node_modules/@smithy/credential-provider-imds/dist-es/error/InstanceMetadataV1FallbackError.js +1 -1
- package/node_modules/@smithy/credential-provider-imds/dist-es/fromContainerMetadata.js +3 -3
- package/node_modules/@smithy/credential-provider-imds/dist-es/fromInstanceMetadata.js +2 -3
- package/node_modules/@smithy/credential-provider-imds/dist-es/remoteProvider/httpRequest.js +2 -3
- package/node_modules/@smithy/credential-provider-imds/dist-es/utils/getInstanceMetadataEndpoint.js +2 -2
- package/node_modules/@smithy/credential-provider-imds/package.json +2 -4
- package/node_modules/@smithy/eventstream-codec/dist-cjs/index.js +11 -401
- package/node_modules/@smithy/eventstream-codec/dist-es/index.js +1 -8
- package/node_modules/@smithy/eventstream-codec/package.json +5 -26
- package/node_modules/@smithy/eventstream-serde-browser/dist-cjs/index.js +9 -58
- package/node_modules/@smithy/eventstream-serde-browser/dist-es/index.js +3 -3
- package/node_modules/@smithy/eventstream-serde-browser/package.json +7 -24
- package/node_modules/@smithy/eventstream-serde-config-resolver/dist-cjs/index.js +5 -7
- package/node_modules/@smithy/eventstream-serde-config-resolver/dist-es/index.js +1 -1
- package/node_modules/@smithy/eventstream-serde-config-resolver/package.json +7 -25
- package/node_modules/@smithy/eventstream-serde-node/dist-cjs/index.js +6 -53
- package/node_modules/@smithy/eventstream-serde-node/dist-es/index.js +1 -2
- package/node_modules/@smithy/eventstream-serde-node/package.json +5 -23
- package/node_modules/@smithy/fetch-http-handler/dist-cjs/index.js +6 -7
- package/node_modules/@smithy/fetch-http-handler/dist-es/fetch-http-handler.js +1 -2
- package/node_modules/@smithy/fetch-http-handler/dist-es/stream-collector.js +1 -1
- package/node_modules/@smithy/fetch-http-handler/package.json +2 -4
- package/node_modules/@smithy/hash-node/dist-cjs/index.js +5 -42
- package/node_modules/@smithy/hash-node/dist-es/index.js +1 -37
- package/node_modules/@smithy/hash-node/package.json +5 -29
- package/node_modules/@smithy/invalid-dependency/dist-cjs/index.js +6 -10
- package/node_modules/@smithy/invalid-dependency/dist-es/index.js +1 -2
- package/node_modules/@smithy/invalid-dependency/package.json +5 -25
- package/node_modules/@smithy/is-array-buffer/dist-cjs/index.js +30 -4
- package/node_modules/@smithy/is-array-buffer/package.json +12 -13
- package/node_modules/@smithy/middleware-content-length/dist-cjs/index.js +7 -46
- package/node_modules/@smithy/middleware-content-length/dist-es/index.js +1 -39
- package/node_modules/@smithy/middleware-content-length/package.json +5 -28
- package/node_modules/@smithy/middleware-endpoint/dist-cjs/index.js +12 -264
- package/node_modules/@smithy/middleware-endpoint/dist-es/index.js +1 -6
- package/node_modules/@smithy/middleware-endpoint/package.json +5 -39
- package/node_modules/@smithy/middleware-retry/dist-cjs/index.js +22 -396
- package/node_modules/@smithy/middleware-retry/dist-es/index.js +1 -8
- package/node_modules/@smithy/middleware-retry/package.json +5 -44
- package/node_modules/@smithy/middleware-serde/dist-cjs/index.js +9 -104
- package/node_modules/@smithy/middleware-serde/dist-es/index.js +1 -3
- package/node_modules/@smithy/middleware-serde/package.json +5 -30
- package/node_modules/@smithy/middleware-stack/dist-cjs/index.js +5 -285
- package/node_modules/@smithy/middleware-stack/dist-es/index.js +1 -1
- package/node_modules/@smithy/middleware-stack/package.json +5 -26
- package/node_modules/@smithy/node-config-provider/dist-cjs/index.js +5 -62
- package/node_modules/@smithy/node-config-provider/dist-es/index.js +1 -1
- package/node_modules/@smithy/node-config-provider/package.json +5 -28
- package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +72 -41
- package/node_modules/@smithy/node-http-handler/dist-es/get-transformed-headers.js +1 -1
- package/node_modules/@smithy/node-http-handler/dist-es/http2/ClientHttp2SessionRef.js +5 -0
- package/node_modules/@smithy/node-http-handler/dist-es/node-http-handler.js +26 -16
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-connection-manager.js +31 -18
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-handler.js +6 -4
- package/node_modules/@smithy/node-http-handler/dist-es/server.mock.js +1 -1
- package/node_modules/@smithy/node-http-handler/dist-es/write-request-body.js +2 -2
- package/node_modules/@smithy/node-http-handler/package.json +2 -3
- package/node_modules/@smithy/property-provider/dist-cjs/index.js +10 -117
- package/node_modules/@smithy/property-provider/dist-es/index.js +1 -6
- package/node_modules/@smithy/property-provider/package.json +5 -25
- package/node_modules/@smithy/protocol-http/dist-cjs/index.js +11 -169
- package/node_modules/@smithy/protocol-http/dist-es/index.js +1 -8
- package/node_modules/@smithy/protocol-http/package.json +5 -25
- package/node_modules/@smithy/querystring-builder/dist-cjs/index.js +5 -26
- package/node_modules/@smithy/querystring-builder/dist-es/index.js +1 -21
- package/node_modules/@smithy/querystring-builder/package.json +5 -25
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/index.js +16 -196
- package/node_modules/@smithy/shared-ini-file-loader/dist-es/index.js +1 -10
- package/node_modules/@smithy/shared-ini-file-loader/package.json +5 -37
- package/node_modules/@smithy/signature-v4/dist-cjs/index.js +167 -170
- package/node_modules/@smithy/signature-v4/dist-es/HeaderFormatter.js +1 -2
- package/node_modules/@smithy/signature-v4/dist-es/SignatureV4.js +3 -4
- package/node_modules/@smithy/signature-v4/dist-es/SignatureV4Base.js +3 -4
- package/node_modules/@smithy/signature-v4/dist-es/credentialDerivation.js +1 -2
- package/node_modules/@smithy/signature-v4/dist-es/getCanonicalQuery.js +1 -1
- package/node_modules/@smithy/signature-v4/dist-es/getPayloadHash.js +1 -3
- package/node_modules/@smithy/signature-v4/dist-es/moveHeadersToQuery.js +1 -1
- package/node_modules/@smithy/signature-v4/dist-es/prepareRequest.js +1 -1
- package/node_modules/@smithy/signature-v4/package.json +2 -7
- package/node_modules/@smithy/smithy-client/dist-cjs/index.js +75 -642
- package/node_modules/@smithy/smithy-client/dist-es/index.js +3 -20
- package/node_modules/@smithy/smithy-client/package.json +5 -33
- package/node_modules/@smithy/url-parser/dist-cjs/index.js +5 -23
- package/node_modules/@smithy/url-parser/dist-es/index.js +1 -18
- package/node_modules/@smithy/url-parser/package.json +5 -26
- package/node_modules/@smithy/util-base64/dist-cjs/index.js +6 -27
- package/node_modules/@smithy/util-base64/dist-es/index.js +1 -2
- package/node_modules/@smithy/util-base64/package.json +5 -38
- package/node_modules/@smithy/util-body-length-browser/dist-cjs/index.js +5 -30
- package/node_modules/@smithy/util-body-length-browser/dist-es/index.js +1 -1
- package/node_modules/@smithy/util-body-length-browser/package.json +5 -25
- package/node_modules/@smithy/util-body-length-node/dist-cjs/index.js +5 -32
- package/node_modules/@smithy/util-body-length-node/dist-es/index.js +1 -1
- package/node_modules/@smithy/util-body-length-node/package.json +5 -26
- package/node_modules/@smithy/util-buffer-from/dist-cjs/index.js +44 -17
- package/node_modules/@smithy/util-buffer-from/package.json +14 -15
- package/node_modules/@smithy/util-config-provider/dist-cjs/index.js +7 -30
- package/node_modules/@smithy/util-config-provider/dist-es/index.js +1 -3
- package/node_modules/@smithy/util-config-provider/package.json +5 -26
- package/node_modules/@smithy/util-defaults-mode-browser/dist-cjs/index.js +5 -16
- package/node_modules/@smithy/util-defaults-mode-browser/dist-es/index.js +1 -1
- package/node_modules/@smithy/util-defaults-mode-browser/package.json +5 -30
- package/node_modules/@smithy/util-defaults-mode-node/dist-cjs/index.js +5 -74
- package/node_modules/@smithy/util-defaults-mode-node/dist-es/index.js +1 -1
- package/node_modules/@smithy/util-defaults-mode-node/package.json +5 -31
- package/node_modules/@smithy/util-endpoints/dist-cjs/index.js +12 -573
- package/node_modules/@smithy/util-endpoints/dist-es/index.js +1 -8
- package/node_modules/@smithy/util-endpoints/package.json +5 -29
- package/node_modules/@smithy/util-hex-encoding/dist-cjs/index.js +6 -38
- package/node_modules/@smithy/util-hex-encoding/dist-es/index.js +1 -33
- package/node_modules/@smithy/util-hex-encoding/package.json +5 -25
- package/node_modules/@smithy/util-middleware/dist-cjs/index.js +6 -15
- package/node_modules/@smithy/util-middleware/dist-es/index.js +1 -2
- package/node_modules/@smithy/util-middleware/package.json +5 -26
- package/node_modules/@smithy/util-retry/dist-cjs/index.js +21 -333
- package/node_modules/@smithy/util-retry/dist-es/index.js +1 -8
- package/node_modules/@smithy/util-retry/package.json +5 -30
- package/node_modules/@smithy/util-stream/dist-cjs/index.js +14 -108
- package/node_modules/@smithy/util-stream/dist-es/index.js +1 -9
- package/node_modules/@smithy/util-stream/package.json +7 -63
- package/node_modules/@smithy/util-utf8/dist-cjs/index.js +7 -32
- package/node_modules/@smithy/util-utf8/dist-es/index.js +1 -3
- package/node_modules/@smithy/util-utf8/package.json +5 -31
- package/node_modules/@whiskeysockets/baileys/node_modules/p-queue/dist/priority-queue.js +53 -6
- package/node_modules/@whiskeysockets/baileys/node_modules/p-queue/package.json +3 -3
- package/node_modules/ajv/dist/core.js +1 -1
- package/node_modules/ajv/package.json +2 -3
- package/node_modules/axios/dist/axios.js +1416 -1075
- package/node_modules/axios/dist/axios.min.js +3 -3
- package/node_modules/axios/dist/browser/axios.cjs +1511 -1122
- package/node_modules/axios/dist/esm/axios.js +1513 -1123
- package/node_modules/axios/dist/esm/axios.min.js +2 -2
- package/node_modules/axios/dist/node/axios.cjs +1150 -737
- package/node_modules/axios/index.d.cts +26 -13
- package/node_modules/axios/index.js +2 -0
- package/node_modules/axios/lib/adapters/adapters.js +4 -2
- package/node_modules/axios/lib/adapters/fetch.js +126 -10
- package/node_modules/axios/lib/adapters/http.js +232 -66
- package/node_modules/axios/lib/adapters/xhr.js +6 -2
- package/node_modules/axios/lib/core/Axios.js +7 -3
- package/node_modules/axios/lib/core/AxiosError.js +86 -1
- package/node_modules/axios/lib/core/AxiosHeaders.js +3 -0
- package/node_modules/axios/lib/core/dispatchRequest.js +19 -7
- package/node_modules/axios/lib/core/mergeConfig.js +16 -1
- package/node_modules/axios/lib/core/settle.js +7 -11
- package/node_modules/axios/lib/defaults/index.js +1 -1
- package/node_modules/axios/lib/env/data.js +1 -1
- package/node_modules/axios/lib/helpers/buildURL.js +1 -1
- package/node_modules/axios/lib/helpers/cookies.js +14 -2
- package/node_modules/axios/lib/helpers/estimateDataURLDecodedBytes.js +28 -1
- package/node_modules/axios/lib/helpers/formDataToStream.js +1 -1
- package/node_modules/axios/lib/helpers/parseProtocol.js +1 -1
- package/node_modules/axios/lib/helpers/resolveConfig.js +46 -18
- package/node_modules/axios/lib/helpers/shouldBypassProxy.js +26 -1
- package/node_modules/axios/lib/helpers/validator.js +3 -1
- package/node_modules/axios/lib/utils.js +27 -15
- package/node_modules/axios/package.json +17 -24
- package/node_modules/basic-ftp/dist/FtpContext.js +7 -1
- package/node_modules/basic-ftp/package.json +5 -5
- package/node_modules/brace-expansion/dist/commonjs/index.js +1 -1
- package/node_modules/brace-expansion/dist/esm/index.js +1 -1
- package/node_modules/brace-expansion/package.json +1 -1
- package/node_modules/cacheable/dist/index.cjs +17 -6
- package/node_modules/cacheable/dist/index.js +17 -6
- package/node_modules/cacheable/package.json +6 -6
- package/node_modules/express-rate-limit/dist/index.cjs +51 -10
- package/node_modules/express-rate-limit/dist/index.d.cts +31 -1
- package/node_modules/express-rate-limit/dist/index.mjs +51 -10
- package/node_modules/express-rate-limit/package.json +3 -2
- package/node_modules/fast-string-truncated-width/dist/index.js +36 -96
- package/node_modules/fast-string-truncated-width/dist/utils.js +14 -9
- package/node_modules/fast-string-truncated-width/package.json +1 -1
- package/node_modules/fast-string-width/package.json +2 -2
- package/node_modules/fast-uri/.github/workflows/ci.yml +12 -7
- package/node_modules/fast-uri/.github/workflows/lock-threads.yml +19 -0
- package/node_modules/fast-uri/.github/workflows/package-manager-ci.yml +1 -1
- package/node_modules/fast-uri/index.js +90 -24
- package/node_modules/fast-uri/lib/utils.js +129 -22
- package/node_modules/fast-uri/package.json +3 -4
- package/node_modules/fast-wrap-ansi/lib/main.js +4 -1
- package/node_modules/fast-wrap-ansi/package.json +2 -2
- package/node_modules/fast-xml-builder/lib/fxb.cjs +1 -1
- package/node_modules/fast-xml-builder/lib/fxb.d.cts +91 -1
- package/node_modules/fast-xml-builder/lib/fxb.min.js +1 -1
- package/node_modules/fast-xml-builder/package.json +3 -2
- package/node_modules/fast-xml-builder/src/fxb.js +106 -40
- package/node_modules/fast-xml-builder/src/orderedJs2Xml.js +95 -42
- package/node_modules/fast-xml-builder/src/util.js +16 -0
- package/node_modules/fast-xml-parser/lib/fxbuilder.min.js +1 -1
- package/node_modules/fast-xml-parser/lib/fxp.cjs +1 -1
- package/node_modules/fast-xml-parser/lib/fxp.d.cts +172 -6
- package/node_modules/fast-xml-parser/lib/fxp.min.js +1 -1
- package/node_modules/fast-xml-parser/lib/fxparser.min.js +1 -1
- package/node_modules/fast-xml-parser/package.json +5 -4
- package/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js +2 -5
- package/node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js +15 -11
- package/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +174 -245
- package/node_modules/fast-xml-parser/src/xmlparser/XMLParser.js +2 -2
- package/node_modules/get-east-asian-width/lookup-data.js +15 -12
- package/node_modules/get-east-asian-width/lookup.js +25 -22
- package/node_modules/get-east-asian-width/package.json +1 -1
- package/node_modules/hosted-git-info/lib/hosts.js +2 -2
- package/node_modules/hosted-git-info/package.json +13 -17
- package/node_modules/ip-address/dist/common.js +21 -0
- package/node_modules/ip-address/dist/ipv4.js +193 -68
- package/node_modules/ip-address/dist/ipv6.js +345 -131
- package/node_modules/ip-address/dist/v6/constants.js +5 -0
- package/node_modules/ip-address/dist/v6/helpers.js +12 -3
- package/node_modules/ip-address/package.json +45 -35
- package/node_modules/ipaddr.js/ipaddr.min.js +1 -1
- package/node_modules/ipaddr.js/lib/ipaddr.js +21 -6
- package/node_modules/ipaddr.js/package.json +1 -1
- package/node_modules/jiti/dist/babel.cjs +38 -27
- package/node_modules/jiti/dist/jiti.cjs +1 -1
- package/node_modules/jiti/lib/jiti-static.mjs +23 -0
- package/node_modules/jiti/package.json +56 -43
- package/node_modules/jose/dist/webapi/jwks/remote.js +1 -1
- package/node_modules/jose/dist/webapi/lib/pbes2kw.js +3 -0
- package/node_modules/jose/package.json +1 -1
- package/node_modules/lru-cache/dist/commonjs/browser/diagnostics-channel.js +7 -0
- package/node_modules/lru-cache/dist/commonjs/browser/index.js +1686 -0
- package/node_modules/lru-cache/dist/commonjs/browser/index.min.js +2 -0
- package/node_modules/lru-cache/dist/commonjs/browser/perf.js +11 -0
- package/node_modules/lru-cache/dist/commonjs/diagnostics-channel-cjs.d.cts.map +1 -0
- package/node_modules/lru-cache/dist/commonjs/diagnostics-channel.js +4 -7
- package/node_modules/lru-cache/dist/commonjs/index.js +10 -16
- package/node_modules/lru-cache/dist/commonjs/index.min.js +1 -1
- package/node_modules/lru-cache/dist/commonjs/node/diagnostics-channel.js +9 -0
- package/node_modules/lru-cache/dist/commonjs/node/index.js +1686 -0
- package/node_modules/lru-cache/dist/commonjs/node/index.min.js +2 -0
- package/node_modules/lru-cache/dist/commonjs/node/perf.js +11 -0
- package/node_modules/lru-cache/dist/commonjs/perf.js +11 -0
- package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel.js +1 -1
- package/node_modules/lru-cache/dist/esm/browser/index.js +9 -15
- package/node_modules/lru-cache/dist/esm/browser/index.min.js +1 -1
- package/node_modules/lru-cache/dist/esm/browser/perf.js +8 -0
- package/node_modules/lru-cache/dist/esm/diagnostics-channel-esm.d.mts.map +1 -1
- package/node_modules/lru-cache/dist/esm/index.js +9 -15
- package/node_modules/lru-cache/dist/esm/index.min.js +1 -1
- package/node_modules/lru-cache/dist/esm/node/diagnostics-channel.js +2 -3
- package/node_modules/lru-cache/dist/esm/node/index.js +9 -15
- package/node_modules/lru-cache/dist/esm/node/index.min.js +1 -1
- package/node_modules/lru-cache/dist/esm/node/perf.js +8 -0
- package/node_modules/lru-cache/dist/esm/perf.js +8 -0
- package/node_modules/lru-cache/package.json +44 -16
- package/node_modules/protobufjs/dist/light/protobuf.js +233 -109
- package/node_modules/protobufjs/dist/light/protobuf.min.js +3 -3
- package/node_modules/protobufjs/dist/minimal/protobuf.js +90 -38
- package/node_modules/protobufjs/dist/minimal/protobuf.min.js +3 -3
- package/node_modules/protobufjs/dist/protobuf.js +237 -112
- package/node_modules/protobufjs/dist/protobuf.min.js +3 -3
- package/node_modules/protobufjs/ext/descriptor/index.js +35 -16
- package/node_modules/protobufjs/package.json +7 -4
- package/node_modules/protobufjs/src/converter.js +14 -5
- package/node_modules/protobufjs/src/decoder.js +17 -9
- package/node_modules/protobufjs/src/enum.js +4 -1
- package/node_modules/protobufjs/src/namespace.js +13 -7
- package/node_modules/protobufjs/src/object.js +4 -0
- package/node_modules/protobufjs/src/parse.js +4 -3
- package/node_modules/protobufjs/src/reader.js +12 -2
- package/node_modules/protobufjs/src/service.js +8 -4
- package/node_modules/protobufjs/src/type.js +22 -12
- package/node_modules/protobufjs/src/types.js +1 -1
- package/node_modules/protobufjs/src/util/minimal.js +24 -1
- package/node_modules/protobufjs/src/util/patterns.js +8 -0
- package/node_modules/protobufjs/src/util.js +9 -9
- package/node_modules/protobufjs/src/verifier.js +7 -4
- package/node_modules/protobufjs/src/wrappers.js +4 -3
- package/node_modules/qified/dist/index.cjs +129 -24
- package/node_modules/qified/dist/index.d.cts +41 -14
- package/node_modules/qified/dist/index.mjs +129 -24
- package/node_modules/qified/node_modules/hookified/dist/browser/index.global.js +949 -890
- package/node_modules/qified/node_modules/hookified/dist/browser/index.js +934 -886
- package/node_modules/qified/node_modules/hookified/dist/node/index.cjs +900 -912
- package/node_modules/qified/node_modules/hookified/dist/node/index.d.cts +730 -631
- package/node_modules/qified/node_modules/hookified/dist/node/index.js +895 -882
- package/node_modules/qified/node_modules/hookified/package.json +12 -11
- package/node_modules/qified/package.json +1 -1
- package/node_modules/semver/bin/semver.js +14 -10
- package/node_modules/semver/functions/truncate.js +48 -0
- package/node_modules/semver/index.js +2 -0
- package/node_modules/semver/internal/re.js +1 -1
- package/node_modules/semver/package.json +3 -3
- package/node_modules/semver/range.bnf +5 -4
- package/node_modules/socks/package.json +3 -3
- package/node_modules/strnum/package.json +3 -2
- package/node_modules/strnum/strnum.js +12 -10
- package/node_modules/xml-naming/package.json +54 -0
- package/node_modules/xml-naming/src/index.js +270 -0
- package/node_modules/yaml/browser/dist/compose/resolve-flow-scalar.js +5 -3
- package/node_modules/yaml/browser/dist/nodes/Alias.js +2 -0
- package/node_modules/yaml/browser/dist/schema/yaml-1.1/merge.js +11 -8
- package/node_modules/yaml/browser/dist/stringify/stringifyNumber.js +2 -1
- package/node_modules/yaml/dist/compose/resolve-flow-scalar.js +5 -3
- package/node_modules/yaml/dist/nodes/Alias.js +2 -0
- package/node_modules/yaml/dist/schema/yaml-1.1/merge.js +10 -7
- package/node_modules/yaml/dist/stringify/stringifyNumber.js +2 -1
- package/node_modules/yaml/package.json +1 -1
- package/node_modules/zod/locales/package.json +2 -1
- package/node_modules/zod/mini/package.json +2 -1
- package/node_modules/zod/package.json +1 -1
- package/node_modules/zod/v3/package.json +2 -1
- package/node_modules/zod/v4/classic/errors.js +2 -2
- package/node_modules/zod/v4/classic/external.d.cts +1 -0
- package/node_modules/zod/v4/classic/from-json-schema.cjs +31 -16
- package/node_modules/zod/v4/classic/from-json-schema.js +31 -16
- package/node_modules/zod/v4/classic/package.json +2 -1
- package/node_modules/zod/v4/classic/schemas.cjs +358 -119
- package/node_modules/zod/v4/classic/schemas.d.cts +42 -14
- package/node_modules/zod/v4/classic/schemas.js +356 -118
- package/node_modules/zod/v4/core/api.cjs +7 -2
- package/node_modules/zod/v4/core/api.d.cts +26 -5
- package/node_modules/zod/v4/core/api.js +7 -2
- package/node_modules/zod/v4/core/checks.d.cts +1 -1
- package/node_modules/zod/v4/core/core.cjs +3 -1
- package/node_modules/zod/v4/core/core.js +4 -2
- package/node_modules/zod/v4/core/errors.cjs +26 -23
- package/node_modules/zod/v4/core/errors.d.cts +1 -0
- package/node_modules/zod/v4/core/errors.js +26 -23
- package/node_modules/zod/v4/core/json-schema-processors.cjs +16 -20
- package/node_modules/zod/v4/core/json-schema-processors.js +16 -20
- package/node_modules/zod/v4/core/package.json +2 -1
- package/node_modules/zod/v4/core/parse.cjs +7 -7
- package/node_modules/zod/v4/core/parse.js +7 -7
- package/node_modules/zod/v4/core/regexes.cjs +9 -3
- package/node_modules/zod/v4/core/regexes.d.cts +6 -0
- package/node_modules/zod/v4/core/regexes.js +7 -1
- package/node_modules/zod/v4/core/schemas.cjs +211 -65
- package/node_modules/zod/v4/core/schemas.d.cts +39 -1
- package/node_modules/zod/v4/core/schemas.js +210 -64
- package/node_modules/zod/v4/core/to-json-schema.cjs +12 -1
- package/node_modules/zod/v4/core/to-json-schema.js +12 -1
- package/node_modules/zod/v4/core/util.cjs +54 -30
- package/node_modules/zod/v4/core/util.d.cts +1 -0
- package/node_modules/zod/v4/core/util.js +55 -32
- package/node_modules/zod/v4/core/versions.cjs +2 -2
- package/node_modules/zod/v4/core/versions.d.cts +1 -1
- package/node_modules/zod/v4/core/versions.js +2 -2
- package/node_modules/zod/v4/locales/el.cjs +136 -0
- package/node_modules/zod/v4/locales/el.d.cts +5 -0
- package/node_modules/zod/v4/locales/el.js +109 -0
- package/node_modules/zod/v4/locales/en.cjs +4 -0
- package/node_modules/zod/v4/locales/en.js +4 -0
- package/node_modules/zod/v4/locales/fr.cjs +24 -7
- package/node_modules/zod/v4/locales/fr.js +24 -7
- package/node_modules/zod/v4/locales/hr.cjs +149 -0
- package/node_modules/zod/v4/locales/hr.d.cts +5 -0
- package/node_modules/zod/v4/locales/hr.js +122 -0
- package/node_modules/zod/v4/locales/index.cjs +8 -1
- package/node_modules/zod/v4/locales/index.d.cts +3 -0
- package/node_modules/zod/v4/locales/index.js +3 -0
- package/node_modules/zod/v4/locales/it.cjs +1 -1
- package/node_modules/zod/v4/locales/it.js +1 -1
- package/node_modules/zod/v4/locales/ka.cjs +8 -8
- package/node_modules/zod/v4/locales/ka.js +8 -8
- package/node_modules/zod/v4/locales/package.json +2 -1
- package/node_modules/zod/v4/locales/ro.cjs +146 -0
- package/node_modules/zod/v4/locales/ro.d.cts +5 -0
- package/node_modules/zod/v4/locales/ro.js +119 -0
- package/node_modules/zod/v4/locales/uz.cjs +1 -0
- package/node_modules/zod/v4/locales/uz.js +1 -0
- package/node_modules/zod/v4/mini/external.d.cts +1 -0
- package/node_modules/zod/v4/mini/package.json +2 -1
- package/node_modules/zod/v4/mini/schemas.cjs +41 -4
- package/node_modules/zod/v4/mini/schemas.d.cts +28 -10
- package/node_modules/zod/v4/mini/schemas.js +40 -4
- package/node_modules/zod/v4/package.json +2 -1
- package/node_modules/zod/v4-mini/package.json +2 -1
- package/package.json +2 -2
- package/skills/news-fetcher/SKILL.md +278 -0
- package/skills/qqbrowser-skill/SKILL.md +15 -4
- package/skills/social-publish/SKILL.md +115 -0
- package/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/is-array-buffer/dist-cjs/index.js +0 -32
- package/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/is-array-buffer/package.json +0 -60
- package/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-buffer-from/dist-cjs/index.js +0 -47
- package/node_modules/@aws-crypto/sha256-browser/node_modules/@smithy/util-buffer-from/package.json +0 -61
- package/node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer/dist-cjs/index.js +0 -32
- package/node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer/dist-es/index.js +0 -2
- package/node_modules/@aws-crypto/util/node_modules/@smithy/is-array-buffer/package.json +0 -60
- package/node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from/dist-cjs/index.js +0 -47
- package/node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from/dist-es/index.js +0 -14
- package/node_modules/@aws-crypto/util/node_modules/@smithy/util-buffer-from/package.json +0 -61
- package/node_modules/@protobufjs/inquire/.npmignore +0 -3
- package/node_modules/@protobufjs/utf8/.npmignore +0 -3
- package/node_modules/@smithy/config-resolver/dist-es/endpointsConfig/index.js +0 -4
- package/node_modules/@smithy/config-resolver/dist-es/regionConfig/index.js +0 -2
- package/node_modules/@smithy/config-resolver/dist-es/regionInfo/index.js +0 -3
- package/node_modules/@smithy/eventstream-serde-browser/dist-es/provider.js +0 -2
- package/node_modules/@smithy/eventstream-serde-node/dist-es/EventStreamMarshaller.js +0 -19
- package/node_modules/@smithy/eventstream-serde-node/dist-es/provider.js +0 -2
- package/node_modules/@smithy/eventstream-serde-node/dist-es/utils.js +0 -26
- package/node_modules/@smithy/eventstream-serde-universal/dist-cjs/index.js +0 -132
- package/node_modules/@smithy/eventstream-serde-universal/dist-es/index.js +0 -2
- package/node_modules/@smithy/eventstream-serde-universal/dist-es/provider.js +0 -2
- package/node_modules/@smithy/eventstream-serde-universal/package.json +0 -65
- package/node_modules/@smithy/middleware-endpoint/dist-cjs/adaptors/getEndpointFromConfig.browser.js +0 -5
- package/node_modules/@smithy/middleware-endpoint/dist-cjs/adaptors/getEndpointFromConfig.js +0 -7
- package/node_modules/@smithy/middleware-endpoint/dist-cjs/adaptors/getEndpointUrlConfig.js +0 -35
- package/node_modules/@smithy/middleware-endpoint/dist-es/adaptors/index.js +0 -2
- package/node_modules/@smithy/middleware-endpoint/dist-es/adaptors/toEndpointV1.js +0 -17
- package/node_modules/@smithy/middleware-endpoint/dist-es/endpointMiddleware.js +0 -36
- package/node_modules/@smithy/middleware-endpoint/dist-es/getEndpointPlugin.js +0 -18
- package/node_modules/@smithy/middleware-endpoint/dist-es/resolveEndpointConfig.js +0 -24
- package/node_modules/@smithy/middleware-retry/dist-cjs/isStreamingPayload/isStreamingPayload.browser.js +0 -5
- package/node_modules/@smithy/middleware-retry/dist-cjs/isStreamingPayload/isStreamingPayload.js +0 -7
- package/node_modules/@smithy/middleware-retry/dist-es/retryMiddleware.js +0 -105
- package/node_modules/@smithy/node-config-provider/dist-es/fromStatic.js +0 -3
- package/node_modules/@smithy/property-provider/dist-es/fromStatic.js +0 -1
- package/node_modules/@smithy/protocol-http/dist-es/extensions/index.js +0 -1
- package/node_modules/@smithy/querystring-parser/dist-cjs/index.js +0 -27
- package/node_modules/@smithy/querystring-parser/package.json +0 -60
- package/node_modules/@smithy/service-error-classification/dist-cjs/index.js +0 -82
- package/node_modules/@smithy/service-error-classification/package.json +0 -59
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/getHomeDir.js +0 -26
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/getSSOTokenFilepath.js +0 -12
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/getSSOTokenFromFile.js +0 -15
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/readFile.js +0 -16
- package/node_modules/@smithy/smithy-client/dist-es/collect-stream-body.js +0 -1
- package/node_modules/@smithy/smithy-client/dist-es/extended-encode-uri-component.js +0 -1
- package/node_modules/@smithy/smithy-client/dist-es/extensions/index.js +0 -1
- package/node_modules/@smithy/smithy-client/dist-es/resolve-path.js +0 -1
- package/node_modules/@smithy/util-base64/dist-cjs/constants.browser.js +0 -12
- package/node_modules/@smithy/util-base64/dist-cjs/fromBase64.browser.js +0 -40
- package/node_modules/@smithy/util-base64/dist-cjs/fromBase64.js +0 -16
- package/node_modules/@smithy/util-base64/dist-cjs/toBase64.browser.js +0 -38
- package/node_modules/@smithy/util-base64/dist-cjs/toBase64.js +0 -19
- package/node_modules/@smithy/util-defaults-mode-browser/dist-cjs/constants.js +0 -4
- package/node_modules/@smithy/util-defaults-mode-browser/dist-cjs/resolveDefaultsModeConfig.js +0 -34
- package/node_modules/@smithy/util-defaults-mode-browser/dist-cjs/resolveDefaultsModeConfig.native.js +0 -23
- package/node_modules/@smithy/util-defaults-mode-browser/dist-es/constants.js +0 -1
- package/node_modules/@smithy/util-defaults-mode-node/dist-es/resolveDefaultsModeConfig.js +0 -52
- package/node_modules/@smithy/util-stream/dist-cjs/ByteArrayCollector.js +0 -36
- package/node_modules/@smithy/util-stream/dist-cjs/checksum/ChecksumStream.browser.js +0 -7
- package/node_modules/@smithy/util-stream/dist-cjs/checksum/ChecksumStream.js +0 -64
- package/node_modules/@smithy/util-stream/dist-cjs/checksum/createChecksumStream.browser.js +0 -39
- package/node_modules/@smithy/util-stream/dist-cjs/checksum/createChecksumStream.js +0 -12
- package/node_modules/@smithy/util-stream/dist-cjs/createBufferedReadable.js +0 -60
- package/node_modules/@smithy/util-stream/dist-cjs/createBufferedReadableStream.js +0 -103
- package/node_modules/@smithy/util-stream/dist-cjs/getAwsChunkedEncodingStream.browser.js +0 -31
- package/node_modules/@smithy/util-stream/dist-cjs/getAwsChunkedEncodingStream.js +0 -41
- package/node_modules/@smithy/util-stream/dist-cjs/headStream.browser.js +0 -34
- package/node_modules/@smithy/util-stream/dist-cjs/headStream.js +0 -42
- package/node_modules/@smithy/util-stream/dist-cjs/sdk-stream-mixin.browser.js +0 -68
- package/node_modules/@smithy/util-stream/dist-cjs/sdk-stream-mixin.js +0 -54
- package/node_modules/@smithy/util-stream/dist-cjs/splitStream.browser.js +0 -10
- package/node_modules/@smithy/util-stream/dist-cjs/splitStream.js +0 -16
- package/node_modules/@smithy/util-stream/dist-cjs/stream-type-check.js +0 -10
- package/node_modules/@smithy/util-uri-escape/dist-cjs/index.js +0 -9
- package/node_modules/@smithy/util-uri-escape/dist-es/index.js +0 -2
- package/node_modules/@smithy/util-uri-escape/package.json +0 -60
- package/node_modules/@smithy/uuid/dist-cjs/index.js +0 -36
- package/node_modules/@smithy/uuid/dist-cjs/randomUUID.js +0 -6
- package/node_modules/@smithy/uuid/dist-cjs/randomUUID.native.js +0 -4
- package/node_modules/@smithy/uuid/dist-es/index.js +0 -1
- package/node_modules/@smithy/uuid/dist-es/randomUUID.browser.js +0 -1
- package/node_modules/@smithy/uuid/dist-es/randomUUID.js +0 -2
- package/node_modules/@smithy/uuid/dist-es/randomUUID.native.js +0 -1
- package/node_modules/@smithy/uuid/package.json +0 -66
- package/node_modules/fast-uri/.github/.stale.yml +0 -21
- package/node_modules/fast-uri/.github/tests_checker.yml +0 -8
- package/node_modules/fast-xml-parser/lib/pem.d.cts +0 -148
- package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel-browser.d.mts.map +0 -1
- package/node_modules/lru-cache/dist/esm/node/diagnostics-channel-node.d.mts.map +0 -1
- package/node_modules/@smithy/{invalid-dependency/dist-es → core/dist-es/submodules/client/invalid-dependency}/invalidFunction.js +0 -0
- package/node_modules/@smithy/{invalid-dependency/dist-es → core/dist-es/submodules/client/invalid-dependency}/invalidProvider.js +0 -0
- package/node_modules/@smithy/{middleware-stack/dist-es → core/dist-es/submodules/client/middleware-stack}/MiddlewareStack.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/client/middleware-stack}/types.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/NoOpLogger.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/constants.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/create-aggregated-client.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/default-error-handler.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/defaults-mode.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/emitWarningIfUnsupportedVersion.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/exceptions.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/extensions/retry.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/get-array-if-single-item.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/get-value-from-text-node.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/is-serializable-header-value.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/object-mapping.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/schemaLogFilter.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/ser-utils.js +0 -0
- package/node_modules/@smithy/{smithy-client/dist-es → core/dist-es/submodules/client/smithy-client}/serde-json.js +0 -0
- package/node_modules/@smithy/{util-middleware/dist-es → core/dist-es/submodules/client/util-middleware}/getSmithyContext.js +0 -0
- package/node_modules/@smithy/{util-middleware/dist-es → core/dist-es/submodules/client/util-middleware}/normalizeProvider.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/endpointsConfig/utils/getEndpointFromRegion.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionConfig/config.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionConfig/getRealRegion.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionConfig/isFipsRegion.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionConfig/resolveRegionConfig.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/EndpointVariant.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/EndpointVariantTag.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/PartitionHash.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/RegionHash.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/getHostnameFromVariants.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/getRegionInfo.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/getResolvedHostname.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/getResolvedPartition.js +0 -0
- package/node_modules/@smithy/{config-resolver/dist-es → core/dist-es/submodules/config/config-resolver}/regionInfo/getResolvedSigningRegion.js +0 -0
- package/node_modules/@smithy/{util-defaults-mode-node/dist-es → core/dist-es/submodules/config/defaults-mode}/constants.js +0 -0
- package/node_modules/@smithy/{util-defaults-mode-node/dist-es → core/dist-es/submodules/config/defaults-mode}/defaultsModeConfig.js +0 -0
- package/node_modules/@smithy/{node-config-provider/dist-es → core/dist-es/submodules/config/node-config-provider}/getSelectorName.js +0 -0
- package/node_modules/@smithy/{property-provider/dist-es → core/dist-es/submodules/config/property-provider}/CredentialsProviderError.js +0 -0
- package/node_modules/@smithy/{property-provider/dist-es → core/dist-es/submodules/config/property-provider}/ProviderError.js +0 -0
- package/node_modules/@smithy/{property-provider/dist-es → core/dist-es/submodules/config/property-provider}/TokenProviderError.js +0 -0
- package/node_modules/@smithy/{property-provider/dist-es → core/dist-es/submodules/config/property-provider}/chain.js +0 -0
- package/node_modules/@smithy/{property-provider/dist-es → core/dist-es/submodules/config/property-provider}/memoize.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/constants.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/externalDataInterceptor.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getConfigData.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getProfileName.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/getSsoSessionData.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/loadSsoSessionData.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/mergeConfigFiles.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/parseIni.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/parseKnownFiles.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/config/shared-ini-file-loader}/readFile.js +0 -0
- package/node_modules/@smithy/{middleware-retry/dist-es/retry-pre-sra-deprecated → core/dist-es/submodules/config/shared-ini-file-loader}/types.js +0 -0
- package/node_modules/@smithy/{util-config-provider/dist-es → core/dist-es/submodules/config/util-config-provider}/booleanSelector.js +0 -0
- package/node_modules/@smithy/{util-config-provider/dist-es → core/dist-es/submodules/config/util-config-provider}/numberSelector.js +0 -0
- package/node_modules/@smithy/{util-config-provider/dist-es → core/dist-es/submodules/config/util-config-provider}/types.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/adaptors/createConfigValueProvider.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/adaptors/getEndpointFromConfig.browser.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/resolveEndpointRequiredConfig.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/service-customizations/index.js +0 -0
- package/node_modules/@smithy/{middleware-endpoint/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/service-customizations/s3.js +0 -0
- package/node_modules/@smithy/{middleware-stack/dist-es → core/dist-es/submodules/endpoints/middleware-endpoint}/types.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/bdd/BinaryDecisionDiagram.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/cache/EndpointCache.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/debug/debugId.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/debug/index.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/debug/toDebugString.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/decideEndpoint.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/getEndpointUrlConfig.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/booleanEquals.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/coalesce.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/getAttr.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/getAttrPathList.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/index.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/isIpAddress.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/isSet.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/isValidHostLabel.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/ite.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/not.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/parseURL.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/split.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/stringEquals.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/substring.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/lib/uriEncode.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/resolveEndpoint.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/EndpointError.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/EndpointFunctions.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/EndpointRuleObject.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/ErrorRuleObject.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/RuleSetObject.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/TreeRuleObject.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/index.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/types/shared.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/callFunction.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/customEndpointFunctions.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/endpointFunctions.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateCondition.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateConditions.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateEndpointRule.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateErrorRule.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateRules.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateTemplate.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/evaluateTreeRule.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/getEndpointHeaders.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/getEndpointProperties.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/getEndpointProperty.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/getEndpointUrl.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/getReferenceValue.js +0 -0
- package/node_modules/@smithy/{util-endpoints/dist-es → core/dist-es/submodules/endpoints/util-endpoints}/utils/index.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/EventStreamCodec.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/Message.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/MessageDecoderStream.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/MessageEncoderStream.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/SmithyMessageDecoderStream.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/SmithyMessageEncoderStream.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/TestVectors.fixture.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/splitMessage.js +0 -0
- package/node_modules/@smithy/{eventstream-codec/dist-es → core/dist-es/submodules/event-streams/eventstream-codec}/vectorTypes.fixture.js +0 -0
- package/node_modules/@smithy/{eventstream-serde-config-resolver/dist-es → core/dist-es/submodules/event-streams/eventstream-serde-config-resolver}/EventStreamSerdeConfig.js +0 -0
- package/node_modules/@smithy/{eventstream-serde-universal/dist-es → core/dist-es/submodules/event-streams/eventstream-serde-universal}/getChunkedStream.js +0 -0
- package/node_modules/@smithy/{eventstream-serde-universal/dist-es → core/dist-es/submodules/event-streams/eventstream-serde-universal}/getUnmarshalledStream.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/Field.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/Fields.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/extensions/httpExtensionConfiguration.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/httpHandler.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/httpRequest.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/httpResponse.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/isValidHostname.js +0 -0
- package/node_modules/@smithy/{protocol-http/dist-es → core/dist-es/submodules/protocols/protocol-http}/types.js +0 -0
- package/node_modules/@smithy/{querystring-parser/dist-es/index.js → core/dist-es/submodules/protocols/querystring-parser/parseQueryString.js} +0 -0
- package/node_modules/@smithy/{util-uri-escape/dist-es → core/dist-es/submodules/protocols/util-uri-escape}/escape-uri-path.js +0 -0
- package/node_modules/@smithy/{util-uri-escape/dist-es → core/dist-es/submodules/protocols/util-uri-escape}/escape-uri.js +0 -0
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/isStreamingPayload/isStreamingPayload.browser.js +0 -0
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/longPollMiddleware.js +0 -0
- package/node_modules/@smithy/{shared-ini-file-loader/dist-es → core/dist-es/submodules/retry/middleware-retry/retry-pre-sra-deprecated}/types.js +0 -0
- package/node_modules/@smithy/{middleware-retry/dist-es → core/dist-es/submodules/retry/middleware-retry}/util.js +0 -0
- package/node_modules/@smithy/{service-error-classification/dist-es → core/dist-es/submodules/retry/service-error-classification}/constants.js +0 -0
- package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/ConfiguredRetryStrategy.js +1 -1
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/DefaultRetryBackoffStrategy.js +0 -0
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/DefaultRetryToken.js +0 -0
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/config.js +0 -0
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/constants.js +0 -0
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/retries-2026-config.js +0 -0
- /package/node_modules/@smithy/{util-retry/dist-es → core/dist-es/submodules/retry/util-retry}/types.js +0 -0
- /package/node_modules/{@aws-crypto/sha256-browser/node_modules/@smithy/is-array-buffer/dist-es/index.js → @smithy/core/dist-es/submodules/serde/is-array-buffer/is-array-buffer.js} +0 -0
- /package/node_modules/@smithy/{middleware-serde/dist-es → core/dist-es/submodules/serde/middleware-serde}/serdePlugin.js +0 -0
- /package/node_modules/@smithy/{middleware-serde/dist-es → core/dist-es/submodules/serde/middleware-serde}/serializerMiddleware.js +0 -0
- /package/node_modules/@smithy/{util-base64/dist-es/constants.browser.js → core/dist-es/submodules/serde/util-base64/constants-for-browser.js} +0 -0
- /package/node_modules/@smithy/{util-body-length-browser/dist-es/calculateBodyLength.js → core/dist-es/submodules/serde/util-body-length/calculateBodyLength.browser.js} +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/ByteArrayCollector.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/checksum/ChecksumStream.browser.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es/createBufferedReadableStream.js → core/dist-es/submodules/serde/util-stream/createBufferedReadable.browser.js} +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/getAwsChunkedEncodingStream.browser.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/getAwsChunkedEncodingStream.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/headStream.browser.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/splitStream.browser.js +0 -0
- /package/node_modules/@smithy/{util-stream/dist-es → core/dist-es/submodules/serde/util-stream}/stream-type-check.js +0 -0
- /package/node_modules/@smithy/{util-utf8/dist-es → core/dist-es/submodules/serde/util-utf8}/fromUtf8.browser.js +0 -0
- /package/node_modules/@smithy/{util-utf8/dist-es → core/dist-es/submodules/serde/util-utf8}/toUint8Array.js +0 -0
- /package/node_modules/@smithy/{util-utf8/dist-es → core/dist-es/submodules/serde/util-utf8}/toUtf8.browser.js +0 -0
- /package/node_modules/@smithy/{uuid/dist-es → core/dist-es/submodules/serde/uuid}/v4.js +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! Axios v1.
|
|
1
|
+
/*! Axios v1.16.0 Copyright (c) 2026 Matt Zabriskie and contributors */
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
4
|
var FormData$1 = require('form-data');
|
|
@@ -8,6 +8,7 @@ var http = require('http');
|
|
|
8
8
|
var https = require('https');
|
|
9
9
|
var http2 = require('http2');
|
|
10
10
|
var util = require('util');
|
|
11
|
+
var path = require('path');
|
|
11
12
|
var followRedirects = require('follow-redirects');
|
|
12
13
|
var zlib = require('zlib');
|
|
13
14
|
var stream = require('stream');
|
|
@@ -207,9 +208,9 @@ const isFile = kindOfTest('File');
|
|
|
207
208
|
* also have a `name` and `type` attribute to specify filename and content type
|
|
208
209
|
*
|
|
209
210
|
* @see https://github.com/facebook/react-native/blob/26684cf3adf4094eb6c405d345a75bf8c7c0bf88/Libraries/Network/FormData.js#L68-L71
|
|
210
|
-
*
|
|
211
|
+
*
|
|
211
212
|
* @param {*} value The value to test
|
|
212
|
-
*
|
|
213
|
+
*
|
|
213
214
|
* @returns {boolean} True if value is a React Native Blob, otherwise false
|
|
214
215
|
*/
|
|
215
216
|
const isReactNativeBlob = value => {
|
|
@@ -219,9 +220,9 @@ const isReactNativeBlob = value => {
|
|
|
219
220
|
/**
|
|
220
221
|
* Determine if environment is React Native
|
|
221
222
|
* ReactNative `FormData` has a non-standard `getParts()` method
|
|
222
|
-
*
|
|
223
|
+
*
|
|
223
224
|
* @param {*} formData The formData to test
|
|
224
|
-
*
|
|
225
|
+
*
|
|
225
226
|
* @returns {boolean} True if environment is React Native, otherwise false
|
|
226
227
|
*/
|
|
227
228
|
const isReactNative = formData => formData && typeof formData.getParts !== 'undefined';
|
|
@@ -240,7 +241,7 @@ const isBlob = kindOfTest('Blob');
|
|
|
240
241
|
*
|
|
241
242
|
* @param {*} val The value to test
|
|
242
243
|
*
|
|
243
|
-
* @returns {boolean} True if value is a
|
|
244
|
+
* @returns {boolean} True if value is a FileList, otherwise false
|
|
244
245
|
*/
|
|
245
246
|
const isFileList = kindOfTest('FileList');
|
|
246
247
|
|
|
@@ -272,7 +273,7 @@ const FormDataCtor = typeof G.FormData !== 'undefined' ? G.FormData : undefined;
|
|
|
272
273
|
const isFormData = thing => {
|
|
273
274
|
if (!thing) return false;
|
|
274
275
|
if (FormDataCtor && thing instanceof FormDataCtor) return true;
|
|
275
|
-
// Reject plain objects inheriting directly from Object.prototype so prototype-pollution gadgets can't spoof FormData
|
|
276
|
+
// Reject plain objects inheriting directly from Object.prototype so prototype-pollution gadgets can't spoof FormData.
|
|
276
277
|
const proto = getPrototypeOf(thing);
|
|
277
278
|
if (!proto || proto === Object.prototype) return false;
|
|
278
279
|
if (!isFunction$1(thing.append)) return false;
|
|
@@ -404,8 +405,7 @@ const isContextDefined = context => !isUndefined(context) && context !== _global
|
|
|
404
405
|
*
|
|
405
406
|
* @returns {Object} Result of all merge properties
|
|
406
407
|
*/
|
|
407
|
-
function merge(
|
|
408
|
-
) {
|
|
408
|
+
function merge(...objs) {
|
|
409
409
|
const {
|
|
410
410
|
caseless,
|
|
411
411
|
skipUndefined
|
|
@@ -417,8 +417,12 @@ function merge(/* obj1, obj2, obj3, ... */
|
|
|
417
417
|
return;
|
|
418
418
|
}
|
|
419
419
|
const targetKey = caseless && findKey(result, key) || key;
|
|
420
|
-
|
|
421
|
-
|
|
420
|
+
// Read via own-prop only — a bare `result[targetKey]` walks the prototype
|
|
421
|
+
// chain, so a polluted Object.prototype value could surface here and get
|
|
422
|
+
// copied into the merged result.
|
|
423
|
+
const existing = hasOwnProperty(result, targetKey) ? result[targetKey] : undefined;
|
|
424
|
+
if (isPlainObject(existing) && isPlainObject(val)) {
|
|
425
|
+
result[targetKey] = merge(existing, val);
|
|
422
426
|
} else if (isPlainObject(val)) {
|
|
423
427
|
result[targetKey] = merge({}, val);
|
|
424
428
|
} else if (isArray(val)) {
|
|
@@ -427,8 +431,8 @@ function merge(/* obj1, obj2, obj3, ... */
|
|
|
427
431
|
result[targetKey] = val;
|
|
428
432
|
}
|
|
429
433
|
};
|
|
430
|
-
for (let i = 0, l =
|
|
431
|
-
|
|
434
|
+
for (let i = 0, l = objs.length; i < l; i++) {
|
|
435
|
+
objs[i] && forEach(objs[i], assignValue);
|
|
432
436
|
}
|
|
433
437
|
return result;
|
|
434
438
|
}
|
|
@@ -450,6 +454,9 @@ const extend = (a, b, thisArg, {
|
|
|
450
454
|
forEach(b, (val, key) => {
|
|
451
455
|
if (thisArg && isFunction$1(val)) {
|
|
452
456
|
Object.defineProperty(a, key, {
|
|
457
|
+
// Null-proto descriptor so a polluted Object.prototype.get cannot
|
|
458
|
+
// hijack defineProperty's accessor-vs-data resolution.
|
|
459
|
+
__proto__: null,
|
|
453
460
|
value: bind(val, thisArg),
|
|
454
461
|
writable: true,
|
|
455
462
|
enumerable: true,
|
|
@@ -457,6 +464,7 @@ const extend = (a, b, thisArg, {
|
|
|
457
464
|
});
|
|
458
465
|
} else {
|
|
459
466
|
Object.defineProperty(a, key, {
|
|
467
|
+
__proto__: null,
|
|
460
468
|
value: val,
|
|
461
469
|
writable: true,
|
|
462
470
|
enumerable: true,
|
|
@@ -495,12 +503,14 @@ const stripBOM = content => {
|
|
|
495
503
|
const inherits = (constructor, superConstructor, props, descriptors) => {
|
|
496
504
|
constructor.prototype = Object.create(superConstructor.prototype, descriptors);
|
|
497
505
|
Object.defineProperty(constructor.prototype, 'constructor', {
|
|
506
|
+
__proto__: null,
|
|
498
507
|
value: constructor,
|
|
499
508
|
writable: true,
|
|
500
509
|
enumerable: false,
|
|
501
510
|
configurable: true
|
|
502
511
|
});
|
|
503
512
|
Object.defineProperty(constructor, 'super', {
|
|
513
|
+
__proto__: null,
|
|
504
514
|
value: superConstructor.prototype
|
|
505
515
|
});
|
|
506
516
|
props && Object.assign(constructor.prototype, props);
|
|
@@ -668,7 +678,7 @@ const reduceDescriptors = (obj, reducer) => {
|
|
|
668
678
|
const freezeMethods = obj => {
|
|
669
679
|
reduceDescriptors(obj, (descriptor, name) => {
|
|
670
680
|
// skip restricted props in strict mode
|
|
671
|
-
if (isFunction$1(obj) && ['arguments', 'caller', 'callee'].
|
|
681
|
+
if (isFunction$1(obj) && ['arguments', 'caller', 'callee'].includes(name)) {
|
|
672
682
|
return false;
|
|
673
683
|
}
|
|
674
684
|
const value = obj[name];
|
|
@@ -875,192 +885,561 @@ var utils$1 = {
|
|
|
875
885
|
isIterable
|
|
876
886
|
};
|
|
877
887
|
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
axiosError.cause = error;
|
|
882
|
-
axiosError.name = error.name;
|
|
888
|
+
// RawAxiosHeaders whose duplicates are ignored by node
|
|
889
|
+
// c.f. https://nodejs.org/api/http.html#http_message_headers
|
|
890
|
+
const ignoreDuplicateOf = utils$1.toObjectSet(['age', 'authorization', 'content-length', 'content-type', 'etag', 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', 'last-modified', 'location', 'max-forwards', 'proxy-authorization', 'referer', 'retry-after', 'user-agent']);
|
|
883
891
|
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
892
|
+
/**
|
|
893
|
+
* Parse headers into an object
|
|
894
|
+
*
|
|
895
|
+
* ```
|
|
896
|
+
* Date: Wed, 27 Aug 2014 08:58:49 GMT
|
|
897
|
+
* Content-Type: application/json
|
|
898
|
+
* Connection: keep-alive
|
|
899
|
+
* Transfer-Encoding: chunked
|
|
900
|
+
* ```
|
|
901
|
+
*
|
|
902
|
+
* @param {String} rawHeaders Headers needing to be parsed
|
|
903
|
+
*
|
|
904
|
+
* @returns {Object} Headers parsed into an object
|
|
905
|
+
*/
|
|
906
|
+
var parseHeaders = rawHeaders => {
|
|
907
|
+
const parsed = {};
|
|
908
|
+
let key;
|
|
909
|
+
let val;
|
|
910
|
+
let i;
|
|
911
|
+
rawHeaders && rawHeaders.split('\n').forEach(function parser(line) {
|
|
912
|
+
i = line.indexOf(':');
|
|
913
|
+
key = line.substring(0, i).trim().toLowerCase();
|
|
914
|
+
val = line.substring(i + 1).trim();
|
|
915
|
+
if (!key || parsed[key] && ignoreDuplicateOf[key]) {
|
|
916
|
+
return;
|
|
887
917
|
}
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
*
|
|
901
|
-
* @returns {Error} The created error.
|
|
902
|
-
*/
|
|
903
|
-
constructor(message, code, config, request, response) {
|
|
904
|
-
super(message);
|
|
918
|
+
if (key === 'set-cookie') {
|
|
919
|
+
if (parsed[key]) {
|
|
920
|
+
parsed[key].push(val);
|
|
921
|
+
} else {
|
|
922
|
+
parsed[key] = [val];
|
|
923
|
+
}
|
|
924
|
+
} else {
|
|
925
|
+
parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
|
926
|
+
}
|
|
927
|
+
});
|
|
928
|
+
return parsed;
|
|
929
|
+
};
|
|
905
930
|
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
this.name = 'AxiosError';
|
|
916
|
-
this.isAxiosError = true;
|
|
917
|
-
code && (this.code = code);
|
|
918
|
-
config && (this.config = config);
|
|
919
|
-
request && (this.request = request);
|
|
920
|
-
if (response) {
|
|
921
|
-
this.response = response;
|
|
922
|
-
this.status = response.status;
|
|
931
|
+
const $internals = Symbol('internals');
|
|
932
|
+
const INVALID_HEADER_VALUE_CHARS_RE = /[^\x09\x20-\x7E\x80-\xFF]/g;
|
|
933
|
+
function trimSPorHTAB(str) {
|
|
934
|
+
let start = 0;
|
|
935
|
+
let end = str.length;
|
|
936
|
+
while (start < end) {
|
|
937
|
+
const code = str.charCodeAt(start);
|
|
938
|
+
if (code !== 0x09 && code !== 0x20) {
|
|
939
|
+
break;
|
|
923
940
|
}
|
|
941
|
+
start += 1;
|
|
924
942
|
}
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
description: this.description,
|
|
932
|
-
number: this.number,
|
|
933
|
-
// Mozilla
|
|
934
|
-
fileName: this.fileName,
|
|
935
|
-
lineNumber: this.lineNumber,
|
|
936
|
-
columnNumber: this.columnNumber,
|
|
937
|
-
stack: this.stack,
|
|
938
|
-
// Axios
|
|
939
|
-
config: utils$1.toJSONObject(this.config),
|
|
940
|
-
code: this.code,
|
|
941
|
-
status: this.status
|
|
942
|
-
};
|
|
943
|
+
while (end > start) {
|
|
944
|
+
const code = str.charCodeAt(end - 1);
|
|
945
|
+
if (code !== 0x09 && code !== 0x20) {
|
|
946
|
+
break;
|
|
947
|
+
}
|
|
948
|
+
end -= 1;
|
|
943
949
|
}
|
|
950
|
+
return start === 0 && end === str.length ? str : str.slice(start, end);
|
|
944
951
|
}
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
AxiosError.ERR_BAD_OPTION_VALUE = 'ERR_BAD_OPTION_VALUE';
|
|
948
|
-
AxiosError.ERR_BAD_OPTION = 'ERR_BAD_OPTION';
|
|
949
|
-
AxiosError.ECONNABORTED = 'ECONNABORTED';
|
|
950
|
-
AxiosError.ETIMEDOUT = 'ETIMEDOUT';
|
|
951
|
-
AxiosError.ERR_NETWORK = 'ERR_NETWORK';
|
|
952
|
-
AxiosError.ERR_FR_TOO_MANY_REDIRECTS = 'ERR_FR_TOO_MANY_REDIRECTS';
|
|
953
|
-
AxiosError.ERR_DEPRECATED = 'ERR_DEPRECATED';
|
|
954
|
-
AxiosError.ERR_BAD_RESPONSE = 'ERR_BAD_RESPONSE';
|
|
955
|
-
AxiosError.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
|
|
956
|
-
AxiosError.ERR_CANCELED = 'ERR_CANCELED';
|
|
957
|
-
AxiosError.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
|
|
958
|
-
AxiosError.ERR_INVALID_URL = 'ERR_INVALID_URL';
|
|
959
|
-
AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = 'ERR_FORM_DATA_DEPTH_EXCEEDED';
|
|
960
|
-
|
|
961
|
-
/**
|
|
962
|
-
* Determines if the given thing is a array or js object.
|
|
963
|
-
*
|
|
964
|
-
* @param {string} thing - The object or array to be visited.
|
|
965
|
-
*
|
|
966
|
-
* @returns {boolean}
|
|
967
|
-
*/
|
|
968
|
-
function isVisitable(thing) {
|
|
969
|
-
return utils$1.isPlainObject(thing) || utils$1.isArray(thing);
|
|
952
|
+
function normalizeHeader(header) {
|
|
953
|
+
return header && String(header).trim().toLowerCase();
|
|
970
954
|
}
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
* It removes the brackets from the end of a string
|
|
974
|
-
*
|
|
975
|
-
* @param {string} key - The key of the parameter.
|
|
976
|
-
*
|
|
977
|
-
* @returns {string} the key without the brackets.
|
|
978
|
-
*/
|
|
979
|
-
function removeBrackets(key) {
|
|
980
|
-
return utils$1.endsWith(key, '[]') ? key.slice(0, -2) : key;
|
|
955
|
+
function sanitizeHeaderValue(str) {
|
|
956
|
+
return trimSPorHTAB(str.replace(INVALID_HEADER_VALUE_CHARS_RE, ''));
|
|
981
957
|
}
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
* @param {string} key - The key of the current object being iterated over.
|
|
988
|
-
* @param {string} dots - If true, the key will be rendered with dots instead of brackets.
|
|
989
|
-
*
|
|
990
|
-
* @returns {string} The path to the current key.
|
|
991
|
-
*/
|
|
992
|
-
function renderKey(path, key, dots) {
|
|
993
|
-
if (!path) return key;
|
|
994
|
-
return path.concat(key).map(function each(token, i) {
|
|
995
|
-
// eslint-disable-next-line no-param-reassign
|
|
996
|
-
token = removeBrackets(token);
|
|
997
|
-
return !dots && i ? '[' + token + ']' : token;
|
|
998
|
-
}).join(dots ? '.' : '');
|
|
958
|
+
function normalizeValue(value) {
|
|
959
|
+
if (value === false || value == null) {
|
|
960
|
+
return value;
|
|
961
|
+
}
|
|
962
|
+
return utils$1.isArray(value) ? value.map(normalizeValue) : sanitizeHeaderValue(String(value));
|
|
999
963
|
}
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
function isFlatArray(arr) {
|
|
1009
|
-
return utils$1.isArray(arr) && !arr.some(isVisitable);
|
|
964
|
+
function parseTokens(str) {
|
|
965
|
+
const tokens = Object.create(null);
|
|
966
|
+
const tokensRE = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
967
|
+
let match;
|
|
968
|
+
while (match = tokensRE.exec(str)) {
|
|
969
|
+
tokens[match[1]] = match[2];
|
|
970
|
+
}
|
|
971
|
+
return tokens;
|
|
1010
972
|
}
|
|
1011
|
-
const
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
/**
|
|
1016
|
-
* Convert a data object to FormData
|
|
1017
|
-
*
|
|
1018
|
-
* @param {Object} obj
|
|
1019
|
-
* @param {?Object} [formData]
|
|
1020
|
-
* @param {?Object} [options]
|
|
1021
|
-
* @param {Function} [options.visitor]
|
|
1022
|
-
* @param {Boolean} [options.metaTokens = true]
|
|
1023
|
-
* @param {Boolean} [options.dots = false]
|
|
1024
|
-
* @param {?Boolean} [options.indexes = false]
|
|
1025
|
-
*
|
|
1026
|
-
* @returns {Object}
|
|
1027
|
-
**/
|
|
1028
|
-
|
|
1029
|
-
/**
|
|
1030
|
-
* It converts an object into a FormData object
|
|
1031
|
-
*
|
|
1032
|
-
* @param {Object<any, any>} obj - The object to convert to form data.
|
|
1033
|
-
* @param {string} formData - The FormData object to append to.
|
|
1034
|
-
* @param {Object<string, any>} options
|
|
1035
|
-
*
|
|
1036
|
-
* @returns
|
|
1037
|
-
*/
|
|
1038
|
-
function toFormData(obj, formData, options) {
|
|
1039
|
-
if (!utils$1.isObject(obj)) {
|
|
1040
|
-
throw new TypeError('target must be an object');
|
|
973
|
+
const isValidHeaderName = str => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
|
|
974
|
+
function matchHeaderValue(context, value, header, filter, isHeaderNameFilter) {
|
|
975
|
+
if (utils$1.isFunction(filter)) {
|
|
976
|
+
return filter.call(this, value, header);
|
|
1041
977
|
}
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
}
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
const
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
978
|
+
if (isHeaderNameFilter) {
|
|
979
|
+
value = header;
|
|
980
|
+
}
|
|
981
|
+
if (!utils$1.isString(value)) return;
|
|
982
|
+
if (utils$1.isString(filter)) {
|
|
983
|
+
return value.indexOf(filter) !== -1;
|
|
984
|
+
}
|
|
985
|
+
if (utils$1.isRegExp(filter)) {
|
|
986
|
+
return filter.test(value);
|
|
987
|
+
}
|
|
988
|
+
}
|
|
989
|
+
function formatHeader(header) {
|
|
990
|
+
return header.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (w, char, str) => {
|
|
991
|
+
return char.toUpperCase() + str;
|
|
992
|
+
});
|
|
993
|
+
}
|
|
994
|
+
function buildAccessors(obj, header) {
|
|
995
|
+
const accessorName = utils$1.toCamelCase(' ' + header);
|
|
996
|
+
['get', 'set', 'has'].forEach(methodName => {
|
|
997
|
+
Object.defineProperty(obj, methodName + accessorName, {
|
|
998
|
+
// Null-proto descriptor so a polluted Object.prototype.get cannot turn
|
|
999
|
+
// this data descriptor into an accessor descriptor on the way in.
|
|
1000
|
+
__proto__: null,
|
|
1001
|
+
value: function (arg1, arg2, arg3) {
|
|
1002
|
+
return this[methodName].call(this, header, arg1, arg2, arg3);
|
|
1003
|
+
},
|
|
1004
|
+
configurable: true
|
|
1005
|
+
});
|
|
1006
|
+
});
|
|
1007
|
+
}
|
|
1008
|
+
class AxiosHeaders {
|
|
1009
|
+
constructor(headers) {
|
|
1010
|
+
headers && this.set(headers);
|
|
1011
|
+
}
|
|
1012
|
+
set(header, valueOrRewrite, rewrite) {
|
|
1013
|
+
const self = this;
|
|
1014
|
+
function setHeader(_value, _header, _rewrite) {
|
|
1015
|
+
const lHeader = normalizeHeader(_header);
|
|
1016
|
+
if (!lHeader) {
|
|
1017
|
+
throw new Error('header name must be a non-empty string');
|
|
1018
|
+
}
|
|
1019
|
+
const key = utils$1.findKey(self, lHeader);
|
|
1020
|
+
if (!key || self[key] === undefined || _rewrite === true || _rewrite === undefined && self[key] !== false) {
|
|
1021
|
+
self[key || _header] = normalizeValue(_value);
|
|
1022
|
+
}
|
|
1023
|
+
}
|
|
1024
|
+
const setHeaders = (headers, _rewrite) => utils$1.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
|
|
1025
|
+
if (utils$1.isPlainObject(header) || header instanceof this.constructor) {
|
|
1026
|
+
setHeaders(header, valueOrRewrite);
|
|
1027
|
+
} else if (utils$1.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
|
|
1028
|
+
setHeaders(parseHeaders(header), valueOrRewrite);
|
|
1029
|
+
} else if (utils$1.isObject(header) && utils$1.isIterable(header)) {
|
|
1030
|
+
let obj = {},
|
|
1031
|
+
dest,
|
|
1032
|
+
key;
|
|
1033
|
+
for (const entry of header) {
|
|
1034
|
+
if (!utils$1.isArray(entry)) {
|
|
1035
|
+
throw TypeError('Object iterator must return a key-value pair');
|
|
1036
|
+
}
|
|
1037
|
+
obj[key = entry[0]] = (dest = obj[key]) ? utils$1.isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]] : entry[1];
|
|
1038
|
+
}
|
|
1039
|
+
setHeaders(obj, valueOrRewrite);
|
|
1040
|
+
} else {
|
|
1041
|
+
header != null && setHeader(valueOrRewrite, header, rewrite);
|
|
1042
|
+
}
|
|
1043
|
+
return this;
|
|
1044
|
+
}
|
|
1045
|
+
get(header, parser) {
|
|
1046
|
+
header = normalizeHeader(header);
|
|
1047
|
+
if (header) {
|
|
1048
|
+
const key = utils$1.findKey(this, header);
|
|
1049
|
+
if (key) {
|
|
1050
|
+
const value = this[key];
|
|
1051
|
+
if (!parser) {
|
|
1052
|
+
return value;
|
|
1053
|
+
}
|
|
1054
|
+
if (parser === true) {
|
|
1055
|
+
return parseTokens(value);
|
|
1056
|
+
}
|
|
1057
|
+
if (utils$1.isFunction(parser)) {
|
|
1058
|
+
return parser.call(this, value, key);
|
|
1059
|
+
}
|
|
1060
|
+
if (utils$1.isRegExp(parser)) {
|
|
1061
|
+
return parser.exec(value);
|
|
1062
|
+
}
|
|
1063
|
+
throw new TypeError('parser must be boolean|regexp|function');
|
|
1064
|
+
}
|
|
1065
|
+
}
|
|
1066
|
+
}
|
|
1067
|
+
has(header, matcher) {
|
|
1068
|
+
header = normalizeHeader(header);
|
|
1069
|
+
if (header) {
|
|
1070
|
+
const key = utils$1.findKey(this, header);
|
|
1071
|
+
return !!(key && this[key] !== undefined && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
|
|
1072
|
+
}
|
|
1073
|
+
return false;
|
|
1074
|
+
}
|
|
1075
|
+
delete(header, matcher) {
|
|
1076
|
+
const self = this;
|
|
1077
|
+
let deleted = false;
|
|
1078
|
+
function deleteHeader(_header) {
|
|
1079
|
+
_header = normalizeHeader(_header);
|
|
1080
|
+
if (_header) {
|
|
1081
|
+
const key = utils$1.findKey(self, _header);
|
|
1082
|
+
if (key && (!matcher || matchHeaderValue(self, self[key], key, matcher))) {
|
|
1083
|
+
delete self[key];
|
|
1084
|
+
deleted = true;
|
|
1085
|
+
}
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
if (utils$1.isArray(header)) {
|
|
1089
|
+
header.forEach(deleteHeader);
|
|
1090
|
+
} else {
|
|
1091
|
+
deleteHeader(header);
|
|
1092
|
+
}
|
|
1093
|
+
return deleted;
|
|
1094
|
+
}
|
|
1095
|
+
clear(matcher) {
|
|
1096
|
+
const keys = Object.keys(this);
|
|
1097
|
+
let i = keys.length;
|
|
1098
|
+
let deleted = false;
|
|
1099
|
+
while (i--) {
|
|
1100
|
+
const key = keys[i];
|
|
1101
|
+
if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
|
|
1102
|
+
delete this[key];
|
|
1103
|
+
deleted = true;
|
|
1104
|
+
}
|
|
1105
|
+
}
|
|
1106
|
+
return deleted;
|
|
1107
|
+
}
|
|
1108
|
+
normalize(format) {
|
|
1109
|
+
const self = this;
|
|
1110
|
+
const headers = {};
|
|
1111
|
+
utils$1.forEach(this, (value, header) => {
|
|
1112
|
+
const key = utils$1.findKey(headers, header);
|
|
1113
|
+
if (key) {
|
|
1114
|
+
self[key] = normalizeValue(value);
|
|
1115
|
+
delete self[header];
|
|
1116
|
+
return;
|
|
1117
|
+
}
|
|
1118
|
+
const normalized = format ? formatHeader(header) : String(header).trim();
|
|
1119
|
+
if (normalized !== header) {
|
|
1120
|
+
delete self[header];
|
|
1121
|
+
}
|
|
1122
|
+
self[normalized] = normalizeValue(value);
|
|
1123
|
+
headers[normalized] = true;
|
|
1124
|
+
});
|
|
1125
|
+
return this;
|
|
1126
|
+
}
|
|
1127
|
+
concat(...targets) {
|
|
1128
|
+
return this.constructor.concat(this, ...targets);
|
|
1129
|
+
}
|
|
1130
|
+
toJSON(asStrings) {
|
|
1131
|
+
const obj = Object.create(null);
|
|
1132
|
+
utils$1.forEach(this, (value, header) => {
|
|
1133
|
+
value != null && value !== false && (obj[header] = asStrings && utils$1.isArray(value) ? value.join(', ') : value);
|
|
1134
|
+
});
|
|
1135
|
+
return obj;
|
|
1136
|
+
}
|
|
1137
|
+
[Symbol.iterator]() {
|
|
1138
|
+
return Object.entries(this.toJSON())[Symbol.iterator]();
|
|
1139
|
+
}
|
|
1140
|
+
toString() {
|
|
1141
|
+
return Object.entries(this.toJSON()).map(([header, value]) => header + ': ' + value).join('\n');
|
|
1142
|
+
}
|
|
1143
|
+
getSetCookie() {
|
|
1144
|
+
return this.get('set-cookie') || [];
|
|
1145
|
+
}
|
|
1146
|
+
get [Symbol.toStringTag]() {
|
|
1147
|
+
return 'AxiosHeaders';
|
|
1148
|
+
}
|
|
1149
|
+
static from(thing) {
|
|
1150
|
+
return thing instanceof this ? thing : new this(thing);
|
|
1151
|
+
}
|
|
1152
|
+
static concat(first, ...targets) {
|
|
1153
|
+
const computed = new this(first);
|
|
1154
|
+
targets.forEach(target => computed.set(target));
|
|
1155
|
+
return computed;
|
|
1156
|
+
}
|
|
1157
|
+
static accessor(header) {
|
|
1158
|
+
const internals = this[$internals] = this[$internals] = {
|
|
1159
|
+
accessors: {}
|
|
1160
|
+
};
|
|
1161
|
+
const accessors = internals.accessors;
|
|
1162
|
+
const prototype = this.prototype;
|
|
1163
|
+
function defineAccessor(_header) {
|
|
1164
|
+
const lHeader = normalizeHeader(_header);
|
|
1165
|
+
if (!accessors[lHeader]) {
|
|
1166
|
+
buildAccessors(prototype, _header);
|
|
1167
|
+
accessors[lHeader] = true;
|
|
1168
|
+
}
|
|
1169
|
+
}
|
|
1170
|
+
utils$1.isArray(header) ? header.forEach(defineAccessor) : defineAccessor(header);
|
|
1171
|
+
return this;
|
|
1172
|
+
}
|
|
1173
|
+
}
|
|
1174
|
+
AxiosHeaders.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
|
|
1175
|
+
|
|
1176
|
+
// reserved names hotfix
|
|
1177
|
+
utils$1.reduceDescriptors(AxiosHeaders.prototype, ({
|
|
1178
|
+
value
|
|
1179
|
+
}, key) => {
|
|
1180
|
+
let mapped = key[0].toUpperCase() + key.slice(1); // map `set` => `Set`
|
|
1181
|
+
return {
|
|
1182
|
+
get: () => value,
|
|
1183
|
+
set(headerValue) {
|
|
1184
|
+
this[mapped] = headerValue;
|
|
1185
|
+
}
|
|
1186
|
+
};
|
|
1187
|
+
});
|
|
1188
|
+
utils$1.freezeMethods(AxiosHeaders);
|
|
1189
|
+
|
|
1190
|
+
const REDACTED = '[REDACTED ****]';
|
|
1191
|
+
function hasOwnOrPrototypeToJSON(source) {
|
|
1192
|
+
if (utils$1.hasOwnProp(source, 'toJSON')) {
|
|
1193
|
+
return true;
|
|
1194
|
+
}
|
|
1195
|
+
let prototype = Object.getPrototypeOf(source);
|
|
1196
|
+
while (prototype && prototype !== Object.prototype) {
|
|
1197
|
+
if (utils$1.hasOwnProp(prototype, 'toJSON')) {
|
|
1198
|
+
return true;
|
|
1199
|
+
}
|
|
1200
|
+
prototype = Object.getPrototypeOf(prototype);
|
|
1201
|
+
}
|
|
1202
|
+
return false;
|
|
1203
|
+
}
|
|
1204
|
+
|
|
1205
|
+
// Build a plain-object snapshot of `config` and replace the value of any key
|
|
1206
|
+
// (case-insensitive) listed in `redactKeys` with REDACTED. Walks through arrays
|
|
1207
|
+
// and AxiosHeaders, and short-circuits on circular references.
|
|
1208
|
+
function redactConfig(config, redactKeys) {
|
|
1209
|
+
const lowerKeys = new Set(redactKeys.map(k => String(k).toLowerCase()));
|
|
1210
|
+
const seen = [];
|
|
1211
|
+
const visit = source => {
|
|
1212
|
+
if (source === null || typeof source !== 'object') return source;
|
|
1213
|
+
if (utils$1.isBuffer(source)) return source;
|
|
1214
|
+
if (seen.indexOf(source) !== -1) return undefined;
|
|
1215
|
+
if (source instanceof AxiosHeaders) {
|
|
1216
|
+
source = source.toJSON();
|
|
1217
|
+
}
|
|
1218
|
+
seen.push(source);
|
|
1219
|
+
let result;
|
|
1220
|
+
if (utils$1.isArray(source)) {
|
|
1221
|
+
result = [];
|
|
1222
|
+
source.forEach((v, i) => {
|
|
1223
|
+
const reducedValue = visit(v);
|
|
1224
|
+
if (!utils$1.isUndefined(reducedValue)) {
|
|
1225
|
+
result[i] = reducedValue;
|
|
1226
|
+
}
|
|
1227
|
+
});
|
|
1228
|
+
} else {
|
|
1229
|
+
if (!utils$1.isPlainObject(source) && hasOwnOrPrototypeToJSON(source)) {
|
|
1230
|
+
seen.pop();
|
|
1231
|
+
return source;
|
|
1232
|
+
}
|
|
1233
|
+
result = Object.create(null);
|
|
1234
|
+
for (const [key, value] of Object.entries(source)) {
|
|
1235
|
+
const reducedValue = lowerKeys.has(key.toLowerCase()) ? REDACTED : visit(value);
|
|
1236
|
+
if (!utils$1.isUndefined(reducedValue)) {
|
|
1237
|
+
result[key] = reducedValue;
|
|
1238
|
+
}
|
|
1239
|
+
}
|
|
1240
|
+
}
|
|
1241
|
+
seen.pop();
|
|
1242
|
+
return result;
|
|
1243
|
+
};
|
|
1244
|
+
return visit(config);
|
|
1245
|
+
}
|
|
1246
|
+
class AxiosError extends Error {
|
|
1247
|
+
static from(error, code, config, request, response, customProps) {
|
|
1248
|
+
const axiosError = new AxiosError(error.message, code || error.code, config, request, response);
|
|
1249
|
+
axiosError.cause = error;
|
|
1250
|
+
axiosError.name = error.name;
|
|
1251
|
+
|
|
1252
|
+
// Preserve status from the original error if not already set from response
|
|
1253
|
+
if (error.status != null && axiosError.status == null) {
|
|
1254
|
+
axiosError.status = error.status;
|
|
1255
|
+
}
|
|
1256
|
+
customProps && Object.assign(axiosError, customProps);
|
|
1257
|
+
return axiosError;
|
|
1258
|
+
}
|
|
1259
|
+
|
|
1260
|
+
/**
|
|
1261
|
+
* Create an Error with the specified message, config, error code, request and response.
|
|
1262
|
+
*
|
|
1263
|
+
* @param {string} message The error message.
|
|
1264
|
+
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
|
1265
|
+
* @param {Object} [config] The config.
|
|
1266
|
+
* @param {Object} [request] The request.
|
|
1267
|
+
* @param {Object} [response] The response.
|
|
1268
|
+
*
|
|
1269
|
+
* @returns {Error} The created error.
|
|
1270
|
+
*/
|
|
1271
|
+
constructor(message, code, config, request, response) {
|
|
1272
|
+
super(message);
|
|
1273
|
+
|
|
1274
|
+
// Make message enumerable to maintain backward compatibility
|
|
1275
|
+
// The native Error constructor sets message as non-enumerable,
|
|
1276
|
+
// but axios < v1.13.3 had it as enumerable
|
|
1277
|
+
Object.defineProperty(this, 'message', {
|
|
1278
|
+
// Null-proto descriptor so a polluted Object.prototype.get cannot turn
|
|
1279
|
+
// this data descriptor into an accessor descriptor on the way in.
|
|
1280
|
+
__proto__: null,
|
|
1281
|
+
value: message,
|
|
1282
|
+
enumerable: true,
|
|
1283
|
+
writable: true,
|
|
1284
|
+
configurable: true
|
|
1285
|
+
});
|
|
1286
|
+
this.name = 'AxiosError';
|
|
1287
|
+
this.isAxiosError = true;
|
|
1288
|
+
code && (this.code = code);
|
|
1289
|
+
config && (this.config = config);
|
|
1290
|
+
request && (this.request = request);
|
|
1291
|
+
if (response) {
|
|
1292
|
+
this.response = response;
|
|
1293
|
+
this.status = response.status;
|
|
1294
|
+
}
|
|
1295
|
+
}
|
|
1296
|
+
toJSON() {
|
|
1297
|
+
// Opt-in redaction: when the request config carries a `redact` array, the
|
|
1298
|
+
// value of any matching key (case-insensitive, at any depth) is replaced
|
|
1299
|
+
// with REDACTED in the serialized snapshot. Undefined or empty leaves the
|
|
1300
|
+
// existing serialization behavior unchanged.
|
|
1301
|
+
const config = this.config;
|
|
1302
|
+
const redactKeys = config && utils$1.hasOwnProp(config, 'redact') ? config.redact : undefined;
|
|
1303
|
+
const serializedConfig = utils$1.isArray(redactKeys) && redactKeys.length > 0 ? redactConfig(config, redactKeys) : utils$1.toJSONObject(config);
|
|
1304
|
+
return {
|
|
1305
|
+
// Standard
|
|
1306
|
+
message: this.message,
|
|
1307
|
+
name: this.name,
|
|
1308
|
+
// Microsoft
|
|
1309
|
+
description: this.description,
|
|
1310
|
+
number: this.number,
|
|
1311
|
+
// Mozilla
|
|
1312
|
+
fileName: this.fileName,
|
|
1313
|
+
lineNumber: this.lineNumber,
|
|
1314
|
+
columnNumber: this.columnNumber,
|
|
1315
|
+
stack: this.stack,
|
|
1316
|
+
// Axios
|
|
1317
|
+
config: serializedConfig,
|
|
1318
|
+
code: this.code,
|
|
1319
|
+
status: this.status
|
|
1320
|
+
};
|
|
1321
|
+
}
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
// This can be changed to static properties as soon as the parser options in .eslint.cjs are updated.
|
|
1325
|
+
AxiosError.ERR_BAD_OPTION_VALUE = 'ERR_BAD_OPTION_VALUE';
|
|
1326
|
+
AxiosError.ERR_BAD_OPTION = 'ERR_BAD_OPTION';
|
|
1327
|
+
AxiosError.ECONNABORTED = 'ECONNABORTED';
|
|
1328
|
+
AxiosError.ETIMEDOUT = 'ETIMEDOUT';
|
|
1329
|
+
AxiosError.ECONNREFUSED = 'ECONNREFUSED';
|
|
1330
|
+
AxiosError.ERR_NETWORK = 'ERR_NETWORK';
|
|
1331
|
+
AxiosError.ERR_FR_TOO_MANY_REDIRECTS = 'ERR_FR_TOO_MANY_REDIRECTS';
|
|
1332
|
+
AxiosError.ERR_DEPRECATED = 'ERR_DEPRECATED';
|
|
1333
|
+
AxiosError.ERR_BAD_RESPONSE = 'ERR_BAD_RESPONSE';
|
|
1334
|
+
AxiosError.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
|
|
1335
|
+
AxiosError.ERR_CANCELED = 'ERR_CANCELED';
|
|
1336
|
+
AxiosError.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
|
|
1337
|
+
AxiosError.ERR_INVALID_URL = 'ERR_INVALID_URL';
|
|
1338
|
+
AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = 'ERR_FORM_DATA_DEPTH_EXCEEDED';
|
|
1339
|
+
|
|
1340
|
+
/**
|
|
1341
|
+
* Determines if the given thing is a array or js object.
|
|
1342
|
+
*
|
|
1343
|
+
* @param {string} thing - The object or array to be visited.
|
|
1344
|
+
*
|
|
1345
|
+
* @returns {boolean}
|
|
1346
|
+
*/
|
|
1347
|
+
function isVisitable(thing) {
|
|
1348
|
+
return utils$1.isPlainObject(thing) || utils$1.isArray(thing);
|
|
1349
|
+
}
|
|
1350
|
+
|
|
1351
|
+
/**
|
|
1352
|
+
* It removes the brackets from the end of a string
|
|
1353
|
+
*
|
|
1354
|
+
* @param {string} key - The key of the parameter.
|
|
1355
|
+
*
|
|
1356
|
+
* @returns {string} the key without the brackets.
|
|
1357
|
+
*/
|
|
1358
|
+
function removeBrackets(key) {
|
|
1359
|
+
return utils$1.endsWith(key, '[]') ? key.slice(0, -2) : key;
|
|
1360
|
+
}
|
|
1361
|
+
|
|
1362
|
+
/**
|
|
1363
|
+
* It takes a path, a key, and a boolean, and returns a string
|
|
1364
|
+
*
|
|
1365
|
+
* @param {string} path - The path to the current key.
|
|
1366
|
+
* @param {string} key - The key of the current object being iterated over.
|
|
1367
|
+
* @param {string} dots - If true, the key will be rendered with dots instead of brackets.
|
|
1368
|
+
*
|
|
1369
|
+
* @returns {string} The path to the current key.
|
|
1370
|
+
*/
|
|
1371
|
+
function renderKey(path, key, dots) {
|
|
1372
|
+
if (!path) return key;
|
|
1373
|
+
return path.concat(key).map(function each(token, i) {
|
|
1374
|
+
// eslint-disable-next-line no-param-reassign
|
|
1375
|
+
token = removeBrackets(token);
|
|
1376
|
+
return !dots && i ? '[' + token + ']' : token;
|
|
1377
|
+
}).join(dots ? '.' : '');
|
|
1378
|
+
}
|
|
1379
|
+
|
|
1380
|
+
/**
|
|
1381
|
+
* If the array is an array and none of its elements are visitable, then it's a flat array.
|
|
1382
|
+
*
|
|
1383
|
+
* @param {Array<any>} arr - The array to check
|
|
1384
|
+
*
|
|
1385
|
+
* @returns {boolean}
|
|
1386
|
+
*/
|
|
1387
|
+
function isFlatArray(arr) {
|
|
1388
|
+
return utils$1.isArray(arr) && !arr.some(isVisitable);
|
|
1389
|
+
}
|
|
1390
|
+
const predicates = utils$1.toFlatObject(utils$1, {}, null, function filter(prop) {
|
|
1391
|
+
return /^is[A-Z]/.test(prop);
|
|
1392
|
+
});
|
|
1393
|
+
|
|
1394
|
+
/**
|
|
1395
|
+
* Convert a data object to FormData
|
|
1396
|
+
*
|
|
1397
|
+
* @param {Object} obj
|
|
1398
|
+
* @param {?Object} [formData]
|
|
1399
|
+
* @param {?Object} [options]
|
|
1400
|
+
* @param {Function} [options.visitor]
|
|
1401
|
+
* @param {Boolean} [options.metaTokens = true]
|
|
1402
|
+
* @param {Boolean} [options.dots = false]
|
|
1403
|
+
* @param {?Boolean} [options.indexes = false]
|
|
1404
|
+
*
|
|
1405
|
+
* @returns {Object}
|
|
1406
|
+
**/
|
|
1407
|
+
|
|
1408
|
+
/**
|
|
1409
|
+
* It converts an object into a FormData object
|
|
1410
|
+
*
|
|
1411
|
+
* @param {Object<any, any>} obj - The object to convert to form data.
|
|
1412
|
+
* @param {string} formData - The FormData object to append to.
|
|
1413
|
+
* @param {Object<string, any>} options
|
|
1414
|
+
*
|
|
1415
|
+
* @returns
|
|
1416
|
+
*/
|
|
1417
|
+
function toFormData(obj, formData, options) {
|
|
1418
|
+
if (!utils$1.isObject(obj)) {
|
|
1419
|
+
throw new TypeError('target must be an object');
|
|
1420
|
+
}
|
|
1421
|
+
|
|
1422
|
+
// eslint-disable-next-line no-param-reassign
|
|
1423
|
+
formData = formData || new (FormData$1 || FormData)();
|
|
1424
|
+
|
|
1425
|
+
// eslint-disable-next-line no-param-reassign
|
|
1426
|
+
options = utils$1.toFlatObject(options, {
|
|
1427
|
+
metaTokens: true,
|
|
1428
|
+
dots: false,
|
|
1429
|
+
indexes: false
|
|
1430
|
+
}, false, function defined(option, source) {
|
|
1431
|
+
// eslint-disable-next-line no-eq-null,eqeqeq
|
|
1432
|
+
return !utils$1.isUndefined(source[option]);
|
|
1433
|
+
});
|
|
1434
|
+
const metaTokens = options.metaTokens;
|
|
1435
|
+
// eslint-disable-next-line no-use-before-define
|
|
1436
|
+
const visitor = options.visitor || defaultVisitor;
|
|
1437
|
+
const dots = options.dots;
|
|
1438
|
+
const indexes = options.indexes;
|
|
1439
|
+
const _Blob = options.Blob || typeof Blob !== 'undefined' && Blob;
|
|
1440
|
+
const maxDepth = options.maxDepth === undefined ? 100 : options.maxDepth;
|
|
1441
|
+
const useBlob = _Blob && utils$1.isSpecCompliantForm(formData);
|
|
1442
|
+
if (!utils$1.isFunction(visitor)) {
|
|
1064
1443
|
throw new TypeError('visitor must be a function');
|
|
1065
1444
|
}
|
|
1066
1445
|
function convertValue(value) {
|
|
@@ -1447,469 +1826,170 @@ function arrayToObject(arr) {
|
|
|
1447
1826
|
for (i = 0; i < len; i++) {
|
|
1448
1827
|
key = keys[i];
|
|
1449
1828
|
obj[key] = arr[key];
|
|
1450
|
-
}
|
|
1451
|
-
return obj;
|
|
1452
|
-
}
|
|
1453
|
-
|
|
1454
|
-
/**
|
|
1455
|
-
* It takes a FormData object and returns a JavaScript object
|
|
1456
|
-
*
|
|
1457
|
-
* @param {string} formData The FormData object to convert to JSON.
|
|
1458
|
-
*
|
|
1459
|
-
* @returns {Object<string, any> | null} The converted object.
|
|
1460
|
-
*/
|
|
1461
|
-
function formDataToJSON(formData) {
|
|
1462
|
-
function buildPath(path, value, target, index) {
|
|
1463
|
-
let name = path[index++];
|
|
1464
|
-
if (name === '__proto__') return true;
|
|
1465
|
-
const isNumericKey = Number.isFinite(+name);
|
|
1466
|
-
const isLast = index >= path.length;
|
|
1467
|
-
name = !name && utils$1.isArray(target) ? target.length : name;
|
|
1468
|
-
if (isLast) {
|
|
1469
|
-
if (utils$1.hasOwnProp(target, name)) {
|
|
1470
|
-
target[name] = utils$1.isArray(target[name]) ? target[name].concat(value) : [target[name], value];
|
|
1471
|
-
} else {
|
|
1472
|
-
target[name] = value;
|
|
1473
|
-
}
|
|
1474
|
-
return !isNumericKey;
|
|
1475
|
-
}
|
|
1476
|
-
if (!target[name] || !utils$1.isObject(target[name])) {
|
|
1477
|
-
target[name] = [];
|
|
1478
|
-
}
|
|
1479
|
-
const result = buildPath(path, value, target[name], index);
|
|
1480
|
-
if (result && utils$1.isArray(target[name])) {
|
|
1481
|
-
target[name] = arrayToObject(target[name]);
|
|
1482
|
-
}
|
|
1483
|
-
return !isNumericKey;
|
|
1484
|
-
}
|
|
1485
|
-
if (utils$1.isFormData(formData) && utils$1.isFunction(formData.entries)) {
|
|
1486
|
-
const obj = {};
|
|
1487
|
-
utils$1.forEachEntry(formData, (name, value) => {
|
|
1488
|
-
buildPath(parsePropPath(name), value, obj, 0);
|
|
1489
|
-
});
|
|
1490
|
-
return obj;
|
|
1491
|
-
}
|
|
1492
|
-
return null;
|
|
1493
|
-
}
|
|
1494
|
-
|
|
1495
|
-
const own = (obj, key) => obj != null && utils$1.hasOwnProp(obj, key) ? obj[key] : undefined;
|
|
1496
|
-
|
|
1497
|
-
/**
|
|
1498
|
-
* It takes a string, tries to parse it, and if it fails, it returns the stringified version
|
|
1499
|
-
* of the input
|
|
1500
|
-
*
|
|
1501
|
-
* @param {any} rawValue - The value to be stringified.
|
|
1502
|
-
* @param {Function} parser - A function that parses a string into a JavaScript object.
|
|
1503
|
-
* @param {Function} encoder - A function that takes a value and returns a string.
|
|
1504
|
-
*
|
|
1505
|
-
* @returns {string} A stringified version of the rawValue.
|
|
1506
|
-
*/
|
|
1507
|
-
function stringifySafely(rawValue, parser, encoder) {
|
|
1508
|
-
if (utils$1.isString(rawValue)) {
|
|
1509
|
-
try {
|
|
1510
|
-
(parser || JSON.parse)(rawValue);
|
|
1511
|
-
return utils$1.trim(rawValue);
|
|
1512
|
-
} catch (e) {
|
|
1513
|
-
if (e.name !== 'SyntaxError') {
|
|
1514
|
-
throw e;
|
|
1515
|
-
}
|
|
1516
|
-
}
|
|
1517
|
-
}
|
|
1518
|
-
return (encoder || JSON.stringify)(rawValue);
|
|
1519
|
-
}
|
|
1520
|
-
const defaults = {
|
|
1521
|
-
transitional: transitionalDefaults,
|
|
1522
|
-
adapter: ['xhr', 'http', 'fetch'],
|
|
1523
|
-
transformRequest: [function transformRequest(data, headers) {
|
|
1524
|
-
const contentType = headers.getContentType() || '';
|
|
1525
|
-
const hasJSONContentType = contentType.indexOf('application/json') > -1;
|
|
1526
|
-
const isObjectPayload = utils$1.isObject(data);
|
|
1527
|
-
if (isObjectPayload && utils$1.isHTMLForm(data)) {
|
|
1528
|
-
data = new FormData(data);
|
|
1529
|
-
}
|
|
1530
|
-
const isFormData = utils$1.isFormData(data);
|
|
1531
|
-
if (isFormData) {
|
|
1532
|
-
return hasJSONContentType ? JSON.stringify(formDataToJSON(data)) : data;
|
|
1533
|
-
}
|
|
1534
|
-
if (utils$1.isArrayBuffer(data) || utils$1.isBuffer(data) || utils$1.isStream(data) || utils$1.isFile(data) || utils$1.isBlob(data) || utils$1.isReadableStream(data)) {
|
|
1535
|
-
return data;
|
|
1536
|
-
}
|
|
1537
|
-
if (utils$1.isArrayBufferView(data)) {
|
|
1538
|
-
return data.buffer;
|
|
1539
|
-
}
|
|
1540
|
-
if (utils$1.isURLSearchParams(data)) {
|
|
1541
|
-
headers.setContentType('application/x-www-form-urlencoded;charset=utf-8', false);
|
|
1542
|
-
return data.toString();
|
|
1543
|
-
}
|
|
1544
|
-
let isFileList;
|
|
1545
|
-
if (isObjectPayload) {
|
|
1546
|
-
const formSerializer = own(this, 'formSerializer');
|
|
1547
|
-
if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
|
|
1548
|
-
return toURLEncodedForm(data, formSerializer).toString();
|
|
1549
|
-
}
|
|
1550
|
-
if ((isFileList = utils$1.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
|
|
1551
|
-
const env = own(this, 'env');
|
|
1552
|
-
const _FormData = env && env.FormData;
|
|
1553
|
-
return toFormData(isFileList ? {
|
|
1554
|
-
'files[]': data
|
|
1555
|
-
} : data, _FormData && new _FormData(), formSerializer);
|
|
1556
|
-
}
|
|
1557
|
-
}
|
|
1558
|
-
if (isObjectPayload || hasJSONContentType) {
|
|
1559
|
-
headers.setContentType('application/json', false);
|
|
1560
|
-
return stringifySafely(data);
|
|
1561
|
-
}
|
|
1562
|
-
return data;
|
|
1563
|
-
}],
|
|
1564
|
-
transformResponse: [function transformResponse(data) {
|
|
1565
|
-
const transitional = own(this, 'transitional') || defaults.transitional;
|
|
1566
|
-
const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
|
|
1567
|
-
const responseType = own(this, 'responseType');
|
|
1568
|
-
const JSONRequested = responseType === 'json';
|
|
1569
|
-
if (utils$1.isResponse(data) || utils$1.isReadableStream(data)) {
|
|
1570
|
-
return data;
|
|
1571
|
-
}
|
|
1572
|
-
if (data && utils$1.isString(data) && (forcedJSONParsing && !responseType || JSONRequested)) {
|
|
1573
|
-
const silentJSONParsing = transitional && transitional.silentJSONParsing;
|
|
1574
|
-
const strictJSONParsing = !silentJSONParsing && JSONRequested;
|
|
1575
|
-
try {
|
|
1576
|
-
return JSON.parse(data, own(this, 'parseReviver'));
|
|
1577
|
-
} catch (e) {
|
|
1578
|
-
if (strictJSONParsing) {
|
|
1579
|
-
if (e.name === 'SyntaxError') {
|
|
1580
|
-
throw AxiosError.from(e, AxiosError.ERR_BAD_RESPONSE, this, null, own(this, 'response'));
|
|
1581
|
-
}
|
|
1582
|
-
throw e;
|
|
1583
|
-
}
|
|
1584
|
-
}
|
|
1585
|
-
}
|
|
1586
|
-
return data;
|
|
1587
|
-
}],
|
|
1588
|
-
/**
|
|
1589
|
-
* A timeout in milliseconds to abort a request. If set to 0 (default) a
|
|
1590
|
-
* timeout is not created.
|
|
1591
|
-
*/
|
|
1592
|
-
timeout: 0,
|
|
1593
|
-
xsrfCookieName: 'XSRF-TOKEN',
|
|
1594
|
-
xsrfHeaderName: 'X-XSRF-TOKEN',
|
|
1595
|
-
maxContentLength: -1,
|
|
1596
|
-
maxBodyLength: -1,
|
|
1597
|
-
env: {
|
|
1598
|
-
FormData: platform.classes.FormData,
|
|
1599
|
-
Blob: platform.classes.Blob
|
|
1600
|
-
},
|
|
1601
|
-
validateStatus: function validateStatus(status) {
|
|
1602
|
-
return status >= 200 && status < 300;
|
|
1603
|
-
},
|
|
1604
|
-
headers: {
|
|
1605
|
-
common: {
|
|
1606
|
-
Accept: 'application/json, text/plain, */*',
|
|
1607
|
-
'Content-Type': undefined
|
|
1608
|
-
}
|
|
1609
|
-
}
|
|
1610
|
-
};
|
|
1611
|
-
utils$1.forEach(['delete', 'get', 'head', 'post', 'put', 'patch'], method => {
|
|
1612
|
-
defaults.headers[method] = {};
|
|
1613
|
-
});
|
|
1614
|
-
|
|
1615
|
-
// RawAxiosHeaders whose duplicates are ignored by node
|
|
1616
|
-
// c.f. https://nodejs.org/api/http.html#http_message_headers
|
|
1617
|
-
const ignoreDuplicateOf = utils$1.toObjectSet(['age', 'authorization', 'content-length', 'content-type', 'etag', 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', 'last-modified', 'location', 'max-forwards', 'proxy-authorization', 'referer', 'retry-after', 'user-agent']);
|
|
1829
|
+
}
|
|
1830
|
+
return obj;
|
|
1831
|
+
}
|
|
1618
1832
|
|
|
1619
1833
|
/**
|
|
1620
|
-
*
|
|
1621
|
-
*
|
|
1622
|
-
* ```
|
|
1623
|
-
* Date: Wed, 27 Aug 2014 08:58:49 GMT
|
|
1624
|
-
* Content-Type: application/json
|
|
1625
|
-
* Connection: keep-alive
|
|
1626
|
-
* Transfer-Encoding: chunked
|
|
1627
|
-
* ```
|
|
1834
|
+
* It takes a FormData object and returns a JavaScript object
|
|
1628
1835
|
*
|
|
1629
|
-
* @param {
|
|
1836
|
+
* @param {string} formData The FormData object to convert to JSON.
|
|
1630
1837
|
*
|
|
1631
|
-
* @returns {Object
|
|
1838
|
+
* @returns {Object<string, any> | null} The converted object.
|
|
1632
1839
|
*/
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
return;
|
|
1644
|
-
}
|
|
1645
|
-
if (key === 'set-cookie') {
|
|
1646
|
-
if (parsed[key]) {
|
|
1647
|
-
parsed[key].push(val);
|
|
1840
|
+
function formDataToJSON(formData) {
|
|
1841
|
+
function buildPath(path, value, target, index) {
|
|
1842
|
+
let name = path[index++];
|
|
1843
|
+
if (name === '__proto__') return true;
|
|
1844
|
+
const isNumericKey = Number.isFinite(+name);
|
|
1845
|
+
const isLast = index >= path.length;
|
|
1846
|
+
name = !name && utils$1.isArray(target) ? target.length : name;
|
|
1847
|
+
if (isLast) {
|
|
1848
|
+
if (utils$1.hasOwnProp(target, name)) {
|
|
1849
|
+
target[name] = utils$1.isArray(target[name]) ? target[name].concat(value) : [target[name], value];
|
|
1648
1850
|
} else {
|
|
1649
|
-
|
|
1851
|
+
target[name] = value;
|
|
1650
1852
|
}
|
|
1651
|
-
|
|
1652
|
-
parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
|
1853
|
+
return !isNumericKey;
|
|
1653
1854
|
}
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
};
|
|
1657
|
-
|
|
1658
|
-
const $internals = Symbol('internals');
|
|
1659
|
-
const INVALID_HEADER_VALUE_CHARS_RE = /[^\x09\x20-\x7E\x80-\xFF]/g;
|
|
1660
|
-
function trimSPorHTAB(str) {
|
|
1661
|
-
let start = 0;
|
|
1662
|
-
let end = str.length;
|
|
1663
|
-
while (start < end) {
|
|
1664
|
-
const code = str.charCodeAt(start);
|
|
1665
|
-
if (code !== 0x09 && code !== 0x20) {
|
|
1666
|
-
break;
|
|
1855
|
+
if (!target[name] || !utils$1.isObject(target[name])) {
|
|
1856
|
+
target[name] = [];
|
|
1667
1857
|
}
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
const code = str.charCodeAt(end - 1);
|
|
1672
|
-
if (code !== 0x09 && code !== 0x20) {
|
|
1673
|
-
break;
|
|
1858
|
+
const result = buildPath(path, value, target[name], index);
|
|
1859
|
+
if (result && utils$1.isArray(target[name])) {
|
|
1860
|
+
target[name] = arrayToObject(target[name]);
|
|
1674
1861
|
}
|
|
1675
|
-
|
|
1676
|
-
}
|
|
1677
|
-
return start === 0 && end === str.length ? str : str.slice(start, end);
|
|
1678
|
-
}
|
|
1679
|
-
function normalizeHeader(header) {
|
|
1680
|
-
return header && String(header).trim().toLowerCase();
|
|
1681
|
-
}
|
|
1682
|
-
function sanitizeHeaderValue(str) {
|
|
1683
|
-
return trimSPorHTAB(str.replace(INVALID_HEADER_VALUE_CHARS_RE, ''));
|
|
1684
|
-
}
|
|
1685
|
-
function normalizeValue(value) {
|
|
1686
|
-
if (value === false || value == null) {
|
|
1687
|
-
return value;
|
|
1862
|
+
return !isNumericKey;
|
|
1688
1863
|
}
|
|
1689
|
-
|
|
1690
|
-
}
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
while (match = tokensRE.exec(str)) {
|
|
1696
|
-
tokens[match[1]] = match[2];
|
|
1864
|
+
if (utils$1.isFormData(formData) && utils$1.isFunction(formData.entries)) {
|
|
1865
|
+
const obj = {};
|
|
1866
|
+
utils$1.forEachEntry(formData, (name, value) => {
|
|
1867
|
+
buildPath(parsePropPath(name), value, obj, 0);
|
|
1868
|
+
});
|
|
1869
|
+
return obj;
|
|
1697
1870
|
}
|
|
1698
|
-
return
|
|
1871
|
+
return null;
|
|
1699
1872
|
}
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1873
|
+
|
|
1874
|
+
const own = (obj, key) => obj != null && utils$1.hasOwnProp(obj, key) ? obj[key] : undefined;
|
|
1875
|
+
|
|
1876
|
+
/**
|
|
1877
|
+
* It takes a string, tries to parse it, and if it fails, it returns the stringified version
|
|
1878
|
+
* of the input
|
|
1879
|
+
*
|
|
1880
|
+
* @param {any} rawValue - The value to be stringified.
|
|
1881
|
+
* @param {Function} parser - A function that parses a string into a JavaScript object.
|
|
1882
|
+
* @param {Function} encoder - A function that takes a value and returns a string.
|
|
1883
|
+
*
|
|
1884
|
+
* @returns {string} A stringified version of the rawValue.
|
|
1885
|
+
*/
|
|
1886
|
+
function stringifySafely(rawValue, parser, encoder) {
|
|
1887
|
+
if (utils$1.isString(rawValue)) {
|
|
1888
|
+
try {
|
|
1889
|
+
(parser || JSON.parse)(rawValue);
|
|
1890
|
+
return utils$1.trim(rawValue);
|
|
1891
|
+
} catch (e) {
|
|
1892
|
+
if (e.name !== 'SyntaxError') {
|
|
1893
|
+
throw e;
|
|
1894
|
+
}
|
|
1895
|
+
}
|
|
1714
1896
|
}
|
|
1897
|
+
return (encoder || JSON.stringify)(rawValue);
|
|
1715
1898
|
}
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
value: function (arg1, arg2, arg3) {
|
|
1726
|
-
return this[methodName].call(this, header, arg1, arg2, arg3);
|
|
1727
|
-
},
|
|
1728
|
-
configurable: true
|
|
1729
|
-
});
|
|
1730
|
-
});
|
|
1731
|
-
}
|
|
1732
|
-
class AxiosHeaders {
|
|
1733
|
-
constructor(headers) {
|
|
1734
|
-
headers && this.set(headers);
|
|
1735
|
-
}
|
|
1736
|
-
set(header, valueOrRewrite, rewrite) {
|
|
1737
|
-
const self = this;
|
|
1738
|
-
function setHeader(_value, _header, _rewrite) {
|
|
1739
|
-
const lHeader = normalizeHeader(_header);
|
|
1740
|
-
if (!lHeader) {
|
|
1741
|
-
throw new Error('header name must be a non-empty string');
|
|
1742
|
-
}
|
|
1743
|
-
const key = utils$1.findKey(self, lHeader);
|
|
1744
|
-
if (!key || self[key] === undefined || _rewrite === true || _rewrite === undefined && self[key] !== false) {
|
|
1745
|
-
self[key || _header] = normalizeValue(_value);
|
|
1746
|
-
}
|
|
1899
|
+
const defaults = {
|
|
1900
|
+
transitional: transitionalDefaults,
|
|
1901
|
+
adapter: ['xhr', 'http', 'fetch'],
|
|
1902
|
+
transformRequest: [function transformRequest(data, headers) {
|
|
1903
|
+
const contentType = headers.getContentType() || '';
|
|
1904
|
+
const hasJSONContentType = contentType.indexOf('application/json') > -1;
|
|
1905
|
+
const isObjectPayload = utils$1.isObject(data);
|
|
1906
|
+
if (isObjectPayload && utils$1.isHTMLForm(data)) {
|
|
1907
|
+
data = new FormData(data);
|
|
1747
1908
|
}
|
|
1748
|
-
const
|
|
1749
|
-
if (
|
|
1750
|
-
|
|
1751
|
-
} else if (utils$1.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
|
|
1752
|
-
setHeaders(parseHeaders(header), valueOrRewrite);
|
|
1753
|
-
} else if (utils$1.isObject(header) && utils$1.isIterable(header)) {
|
|
1754
|
-
let obj = {},
|
|
1755
|
-
dest,
|
|
1756
|
-
key;
|
|
1757
|
-
for (const entry of header) {
|
|
1758
|
-
if (!utils$1.isArray(entry)) {
|
|
1759
|
-
throw TypeError('Object iterator must return a key-value pair');
|
|
1760
|
-
}
|
|
1761
|
-
obj[key = entry[0]] = (dest = obj[key]) ? utils$1.isArray(dest) ? [...dest, entry[1]] : [dest, entry[1]] : entry[1];
|
|
1762
|
-
}
|
|
1763
|
-
setHeaders(obj, valueOrRewrite);
|
|
1764
|
-
} else {
|
|
1765
|
-
header != null && setHeader(valueOrRewrite, header, rewrite);
|
|
1909
|
+
const isFormData = utils$1.isFormData(data);
|
|
1910
|
+
if (isFormData) {
|
|
1911
|
+
return hasJSONContentType ? JSON.stringify(formDataToJSON(data)) : data;
|
|
1766
1912
|
}
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
get(header, parser) {
|
|
1770
|
-
header = normalizeHeader(header);
|
|
1771
|
-
if (header) {
|
|
1772
|
-
const key = utils$1.findKey(this, header);
|
|
1773
|
-
if (key) {
|
|
1774
|
-
const value = this[key];
|
|
1775
|
-
if (!parser) {
|
|
1776
|
-
return value;
|
|
1777
|
-
}
|
|
1778
|
-
if (parser === true) {
|
|
1779
|
-
return parseTokens(value);
|
|
1780
|
-
}
|
|
1781
|
-
if (utils$1.isFunction(parser)) {
|
|
1782
|
-
return parser.call(this, value, key);
|
|
1783
|
-
}
|
|
1784
|
-
if (utils$1.isRegExp(parser)) {
|
|
1785
|
-
return parser.exec(value);
|
|
1786
|
-
}
|
|
1787
|
-
throw new TypeError('parser must be boolean|regexp|function');
|
|
1788
|
-
}
|
|
1913
|
+
if (utils$1.isArrayBuffer(data) || utils$1.isBuffer(data) || utils$1.isStream(data) || utils$1.isFile(data) || utils$1.isBlob(data) || utils$1.isReadableStream(data)) {
|
|
1914
|
+
return data;
|
|
1789
1915
|
}
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
header = normalizeHeader(header);
|
|
1793
|
-
if (header) {
|
|
1794
|
-
const key = utils$1.findKey(this, header);
|
|
1795
|
-
return !!(key && this[key] !== undefined && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
|
|
1916
|
+
if (utils$1.isArrayBufferView(data)) {
|
|
1917
|
+
return data.buffer;
|
|
1796
1918
|
}
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
let
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
if (
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1919
|
+
if (utils$1.isURLSearchParams(data)) {
|
|
1920
|
+
headers.setContentType('application/x-www-form-urlencoded;charset=utf-8', false);
|
|
1921
|
+
return data.toString();
|
|
1922
|
+
}
|
|
1923
|
+
let isFileList;
|
|
1924
|
+
if (isObjectPayload) {
|
|
1925
|
+
const formSerializer = own(this, 'formSerializer');
|
|
1926
|
+
if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
|
|
1927
|
+
return toURLEncodedForm(data, formSerializer).toString();
|
|
1928
|
+
}
|
|
1929
|
+
if ((isFileList = utils$1.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
|
|
1930
|
+
const env = own(this, 'env');
|
|
1931
|
+
const _FormData = env && env.FormData;
|
|
1932
|
+
return toFormData(isFileList ? {
|
|
1933
|
+
'files[]': data
|
|
1934
|
+
} : data, _FormData && new _FormData(), formSerializer);
|
|
1810
1935
|
}
|
|
1811
1936
|
}
|
|
1812
|
-
if (
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
deleteHeader(header);
|
|
1937
|
+
if (isObjectPayload || hasJSONContentType) {
|
|
1938
|
+
headers.setContentType('application/json', false);
|
|
1939
|
+
return stringifySafely(data);
|
|
1816
1940
|
}
|
|
1817
|
-
return
|
|
1818
|
-
}
|
|
1819
|
-
|
|
1820
|
-
const
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
delete this[key];
|
|
1827
|
-
deleted = true;
|
|
1828
|
-
}
|
|
1941
|
+
return data;
|
|
1942
|
+
}],
|
|
1943
|
+
transformResponse: [function transformResponse(data) {
|
|
1944
|
+
const transitional = own(this, 'transitional') || defaults.transitional;
|
|
1945
|
+
const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
|
|
1946
|
+
const responseType = own(this, 'responseType');
|
|
1947
|
+
const JSONRequested = responseType === 'json';
|
|
1948
|
+
if (utils$1.isResponse(data) || utils$1.isReadableStream(data)) {
|
|
1949
|
+
return data;
|
|
1829
1950
|
}
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
const normalized = format ? formatHeader(header) : String(header).trim();
|
|
1843
|
-
if (normalized !== header) {
|
|
1844
|
-
delete self[header];
|
|
1845
|
-
}
|
|
1846
|
-
self[normalized] = normalizeValue(value);
|
|
1847
|
-
headers[normalized] = true;
|
|
1848
|
-
});
|
|
1849
|
-
return this;
|
|
1850
|
-
}
|
|
1851
|
-
concat(...targets) {
|
|
1852
|
-
return this.constructor.concat(this, ...targets);
|
|
1853
|
-
}
|
|
1854
|
-
toJSON(asStrings) {
|
|
1855
|
-
const obj = Object.create(null);
|
|
1856
|
-
utils$1.forEach(this, (value, header) => {
|
|
1857
|
-
value != null && value !== false && (obj[header] = asStrings && utils$1.isArray(value) ? value.join(', ') : value);
|
|
1858
|
-
});
|
|
1859
|
-
return obj;
|
|
1860
|
-
}
|
|
1861
|
-
[Symbol.iterator]() {
|
|
1862
|
-
return Object.entries(this.toJSON())[Symbol.iterator]();
|
|
1863
|
-
}
|
|
1864
|
-
toString() {
|
|
1865
|
-
return Object.entries(this.toJSON()).map(([header, value]) => header + ': ' + value).join('\n');
|
|
1866
|
-
}
|
|
1867
|
-
getSetCookie() {
|
|
1868
|
-
return this.get('set-cookie') || [];
|
|
1869
|
-
}
|
|
1870
|
-
get [Symbol.toStringTag]() {
|
|
1871
|
-
return 'AxiosHeaders';
|
|
1872
|
-
}
|
|
1873
|
-
static from(thing) {
|
|
1874
|
-
return thing instanceof this ? thing : new this(thing);
|
|
1875
|
-
}
|
|
1876
|
-
static concat(first, ...targets) {
|
|
1877
|
-
const computed = new this(first);
|
|
1878
|
-
targets.forEach(target => computed.set(target));
|
|
1879
|
-
return computed;
|
|
1880
|
-
}
|
|
1881
|
-
static accessor(header) {
|
|
1882
|
-
const internals = this[$internals] = this[$internals] = {
|
|
1883
|
-
accessors: {}
|
|
1884
|
-
};
|
|
1885
|
-
const accessors = internals.accessors;
|
|
1886
|
-
const prototype = this.prototype;
|
|
1887
|
-
function defineAccessor(_header) {
|
|
1888
|
-
const lHeader = normalizeHeader(_header);
|
|
1889
|
-
if (!accessors[lHeader]) {
|
|
1890
|
-
buildAccessors(prototype, _header);
|
|
1891
|
-
accessors[lHeader] = true;
|
|
1951
|
+
if (data && utils$1.isString(data) && (forcedJSONParsing && !responseType || JSONRequested)) {
|
|
1952
|
+
const silentJSONParsing = transitional && transitional.silentJSONParsing;
|
|
1953
|
+
const strictJSONParsing = !silentJSONParsing && JSONRequested;
|
|
1954
|
+
try {
|
|
1955
|
+
return JSON.parse(data, own(this, 'parseReviver'));
|
|
1956
|
+
} catch (e) {
|
|
1957
|
+
if (strictJSONParsing) {
|
|
1958
|
+
if (e.name === 'SyntaxError') {
|
|
1959
|
+
throw AxiosError.from(e, AxiosError.ERR_BAD_RESPONSE, this, null, own(this, 'response'));
|
|
1960
|
+
}
|
|
1961
|
+
throw e;
|
|
1962
|
+
}
|
|
1892
1963
|
}
|
|
1893
1964
|
}
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1965
|
+
return data;
|
|
1966
|
+
}],
|
|
1967
|
+
/**
|
|
1968
|
+
* A timeout in milliseconds to abort a request. If set to 0 (default) a
|
|
1969
|
+
* timeout is not created.
|
|
1970
|
+
*/
|
|
1971
|
+
timeout: 0,
|
|
1972
|
+
xsrfCookieName: 'XSRF-TOKEN',
|
|
1973
|
+
xsrfHeaderName: 'X-XSRF-TOKEN',
|
|
1974
|
+
maxContentLength: -1,
|
|
1975
|
+
maxBodyLength: -1,
|
|
1976
|
+
env: {
|
|
1977
|
+
FormData: platform.classes.FormData,
|
|
1978
|
+
Blob: platform.classes.Blob
|
|
1979
|
+
},
|
|
1980
|
+
validateStatus: function validateStatus(status) {
|
|
1981
|
+
return status >= 200 && status < 300;
|
|
1982
|
+
},
|
|
1983
|
+
headers: {
|
|
1984
|
+
common: {
|
|
1985
|
+
Accept: 'application/json, text/plain, */*',
|
|
1986
|
+
'Content-Type': undefined
|
|
1909
1987
|
}
|
|
1910
|
-
}
|
|
1988
|
+
}
|
|
1989
|
+
};
|
|
1990
|
+
utils$1.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'query'], method => {
|
|
1991
|
+
defaults.headers[method] = {};
|
|
1911
1992
|
});
|
|
1912
|
-
utils$1.freezeMethods(AxiosHeaders);
|
|
1913
1993
|
|
|
1914
1994
|
/**
|
|
1915
1995
|
* Transform the data for a request or a response
|
|
@@ -1966,7 +2046,7 @@ function settle(resolve, reject, response) {
|
|
|
1966
2046
|
if (!response.status || !validateStatus || validateStatus(response.status)) {
|
|
1967
2047
|
resolve(response);
|
|
1968
2048
|
} else {
|
|
1969
|
-
reject(new AxiosError('Request failed with status code ' + response.status,
|
|
2049
|
+
reject(new AxiosError('Request failed with status code ' + response.status, response.status >= 400 && response.status < 500 ? AxiosError.ERR_BAD_REQUEST : AxiosError.ERR_BAD_RESPONSE, response.config, response.request, response));
|
|
1970
2050
|
}
|
|
1971
2051
|
}
|
|
1972
2052
|
|
|
@@ -2113,10 +2193,10 @@ function getEnv(key) {
|
|
|
2113
2193
|
return process.env[key.toLowerCase()] || process.env[key.toUpperCase()] || '';
|
|
2114
2194
|
}
|
|
2115
2195
|
|
|
2116
|
-
const VERSION = "1.
|
|
2196
|
+
const VERSION = "1.16.0";
|
|
2117
2197
|
|
|
2118
2198
|
function parseProtocol(url) {
|
|
2119
|
-
const match = /^([-+\w]{1,25})(
|
|
2199
|
+
const match = /^([-+\w]{1,25}):(?:\/\/)?/.exec(url);
|
|
2120
2200
|
return match && match[1] || '';
|
|
2121
2201
|
}
|
|
2122
2202
|
|
|
@@ -2343,7 +2423,7 @@ const formDataToStream = (form, headersHandler, options) => {
|
|
|
2343
2423
|
throw TypeError('FormData instance required');
|
|
2344
2424
|
}
|
|
2345
2425
|
if (boundary.length < 1 || boundary.length > 70) {
|
|
2346
|
-
throw Error('boundary must be
|
|
2426
|
+
throw Error('boundary must be 1-70 characters long');
|
|
2347
2427
|
}
|
|
2348
2428
|
const boundaryBytes = textEncoder.encode('--' + boundary + CRLF);
|
|
2349
2429
|
const footerBytes = textEncoder.encode('--' + boundary + '--' + CRLF);
|
|
@@ -2476,6 +2556,27 @@ const parseNoProxyEntry = entry => {
|
|
|
2476
2556
|
}
|
|
2477
2557
|
return [entryHost, entryPort];
|
|
2478
2558
|
};
|
|
2559
|
+
|
|
2560
|
+
// Convert IPv4-mapped IPv6 (::ffff:0:0/96 prefix) to IPv4 dotted form so both
|
|
2561
|
+
// sides of a NO_PROXY comparison see the same canonical address. Without this,
|
|
2562
|
+
// `NO_PROXY=192.168.1.5` would not match a request to `http://[::ffff:192.168.1.5]/`
|
|
2563
|
+
// (Node's URL parser normalises that to `[::ffff:c0a8:105]`), and vice-versa,
|
|
2564
|
+
// allowing the proxy-bypass policy to be circumvented by using the alternate
|
|
2565
|
+
// representation. Returns the input unchanged when not IPv4-mapped.
|
|
2566
|
+
const IPV4_MAPPED_DOTTED_RE = /^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:(\d+\.\d+\.\d+\.\d+)$/i;
|
|
2567
|
+
const IPV4_MAPPED_HEX_RE = /^(?:::|(?:0{1,4}:){1,4}:|(?:0{1,4}:){5})ffff:([0-9a-f]{1,4}):([0-9a-f]{1,4})$/i;
|
|
2568
|
+
const unmapIPv4MappedIPv6 = host => {
|
|
2569
|
+
if (typeof host !== 'string' || host.indexOf(':') === -1) return host;
|
|
2570
|
+
const dotted = host.match(IPV4_MAPPED_DOTTED_RE);
|
|
2571
|
+
if (dotted) return dotted[1];
|
|
2572
|
+
const hex = host.match(IPV4_MAPPED_HEX_RE);
|
|
2573
|
+
if (hex) {
|
|
2574
|
+
const high = parseInt(hex[1], 16);
|
|
2575
|
+
const low = parseInt(hex[2], 16);
|
|
2576
|
+
return `${high >> 8}.${high & 0xff}.${low >> 8}.${low & 0xff}`;
|
|
2577
|
+
}
|
|
2578
|
+
return host;
|
|
2579
|
+
};
|
|
2479
2580
|
const normalizeNoProxyHost = hostname => {
|
|
2480
2581
|
if (!hostname) {
|
|
2481
2582
|
return hostname;
|
|
@@ -2483,7 +2584,7 @@ const normalizeNoProxyHost = hostname => {
|
|
|
2483
2584
|
if (hostname.charAt(0) === '[' && hostname.charAt(hostname.length - 1) === ']') {
|
|
2484
2585
|
hostname = hostname.slice(1, -1);
|
|
2485
2586
|
}
|
|
2486
|
-
return hostname.replace(/\.+$/, '');
|
|
2587
|
+
return unmapIPv4MappedIPv6(hostname.replace(/\.+$/, ''));
|
|
2487
2588
|
};
|
|
2488
2589
|
function shouldBypassProxy(location) {
|
|
2489
2590
|
let parsed;
|
|
@@ -2696,7 +2797,34 @@ function estimateDataURLDecodedBytes(url) {
|
|
|
2696
2797
|
const bytes = groups * 3 - (pad || 0);
|
|
2697
2798
|
return bytes > 0 ? bytes : 0;
|
|
2698
2799
|
}
|
|
2699
|
-
|
|
2800
|
+
if (typeof Buffer !== 'undefined' && typeof Buffer.byteLength === 'function') {
|
|
2801
|
+
return Buffer.byteLength(body, 'utf8');
|
|
2802
|
+
}
|
|
2803
|
+
|
|
2804
|
+
// Compute UTF-8 byte length directly from UTF-16 code units without allocating
|
|
2805
|
+
// a byte buffer (TextEncoder.encode would defeat the DoS guard on large bodies).
|
|
2806
|
+
// Using body.length here would undercount non-ASCII (e.g. '€' is 1 code unit
|
|
2807
|
+
// but 3 UTF-8 bytes).
|
|
2808
|
+
let bytes = 0;
|
|
2809
|
+
for (let i = 0, len = body.length; i < len; i++) {
|
|
2810
|
+
const c = body.charCodeAt(i);
|
|
2811
|
+
if (c < 0x80) {
|
|
2812
|
+
bytes += 1;
|
|
2813
|
+
} else if (c < 0x800) {
|
|
2814
|
+
bytes += 2;
|
|
2815
|
+
} else if (c >= 0xd800 && c <= 0xdbff && i + 1 < len) {
|
|
2816
|
+
const next = body.charCodeAt(i + 1);
|
|
2817
|
+
if (next >= 0xdc00 && next <= 0xdfff) {
|
|
2818
|
+
bytes += 4;
|
|
2819
|
+
i++;
|
|
2820
|
+
} else {
|
|
2821
|
+
bytes += 3;
|
|
2822
|
+
}
|
|
2823
|
+
} else {
|
|
2824
|
+
bytes += 3;
|
|
2825
|
+
}
|
|
2826
|
+
}
|
|
2827
|
+
return bytes;
|
|
2700
2828
|
}
|
|
2701
2829
|
|
|
2702
2830
|
const zlibOptions = {
|
|
@@ -2713,9 +2841,41 @@ const {
|
|
|
2713
2841
|
https: httpsFollow
|
|
2714
2842
|
} = followRedirects;
|
|
2715
2843
|
const isHttps = /https:?/;
|
|
2844
|
+
const FORM_DATA_CONTENT_HEADERS$1 = ['content-type', 'content-length'];
|
|
2845
|
+
function setFormDataHeaders$1(headers, formHeaders, policy) {
|
|
2846
|
+
if (policy !== 'content-only') {
|
|
2847
|
+
headers.set(formHeaders);
|
|
2848
|
+
return;
|
|
2849
|
+
}
|
|
2850
|
+
Object.entries(formHeaders).forEach(([key, val]) => {
|
|
2851
|
+
if (FORM_DATA_CONTENT_HEADERS$1.includes(key.toLowerCase())) {
|
|
2852
|
+
headers.set(key, val);
|
|
2853
|
+
}
|
|
2854
|
+
});
|
|
2855
|
+
}
|
|
2856
|
+
|
|
2857
|
+
// Symbols used to bind a single 'error' listener to a pooled socket and track
|
|
2858
|
+
// the request currently owning that socket across keep-alive reuse (issue #10780).
|
|
2859
|
+
const kAxiosSocketListener = Symbol('axios.http.socketListener');
|
|
2860
|
+
const kAxiosCurrentReq = Symbol('axios.http.currentReq');
|
|
2716
2861
|
const supportedProtocols = platform.protocols.map(protocol => {
|
|
2717
2862
|
return protocol + ':';
|
|
2718
2863
|
});
|
|
2864
|
+
|
|
2865
|
+
// Node's WHATWG URL parser returns `username` and `password` percent-encoded.
|
|
2866
|
+
// Decode before composing the `auth` option so credentials such as
|
|
2867
|
+
// `my%40email.com:pass` are sent as `my@email.com:pass`. Falls back to the
|
|
2868
|
+
// original value for malformed input so a bad encoding never throws.
|
|
2869
|
+
const decodeURIComponentSafe = value => {
|
|
2870
|
+
if (!utils$1.isString(value)) {
|
|
2871
|
+
return value;
|
|
2872
|
+
}
|
|
2873
|
+
try {
|
|
2874
|
+
return decodeURIComponent(value);
|
|
2875
|
+
} catch (error) {
|
|
2876
|
+
return value;
|
|
2877
|
+
}
|
|
2878
|
+
};
|
|
2719
2879
|
const flushOnFinish = (stream, [throttled, flush]) => {
|
|
2720
2880
|
stream.on('end', flush).on('error', flush);
|
|
2721
2881
|
return throttled;
|
|
@@ -2803,12 +2963,12 @@ const http2Sessions = new Http2Sessions();
|
|
|
2803
2963
|
*
|
|
2804
2964
|
* @returns {Object<string, any>}
|
|
2805
2965
|
*/
|
|
2806
|
-
function dispatchBeforeRedirect(options, responseDetails) {
|
|
2966
|
+
function dispatchBeforeRedirect(options, responseDetails, requestDetails) {
|
|
2807
2967
|
if (options.beforeRedirects.proxy) {
|
|
2808
2968
|
options.beforeRedirects.proxy(options);
|
|
2809
2969
|
}
|
|
2810
2970
|
if (options.beforeRedirects.config) {
|
|
2811
|
-
options.beforeRedirects.config(options, responseDetails);
|
|
2971
|
+
options.beforeRedirects.config(options, responseDetails, requestDetails);
|
|
2812
2972
|
}
|
|
2813
2973
|
}
|
|
2814
2974
|
|
|
@@ -2821,7 +2981,7 @@ function dispatchBeforeRedirect(options, responseDetails) {
|
|
|
2821
2981
|
*
|
|
2822
2982
|
* @returns {http.ClientRequestArgs}
|
|
2823
2983
|
*/
|
|
2824
|
-
function setProxy(options, configProxy, location) {
|
|
2984
|
+
function setProxy(options, configProxy, location, isRedirect) {
|
|
2825
2985
|
let proxy = configProxy;
|
|
2826
2986
|
if (!proxy && proxy !== false) {
|
|
2827
2987
|
const proxyUrl = getProxyForUrl(location);
|
|
@@ -2831,39 +2991,80 @@ function setProxy(options, configProxy, location) {
|
|
|
2831
2991
|
}
|
|
2832
2992
|
}
|
|
2833
2993
|
}
|
|
2994
|
+
// On redirect re-invocation, strip any stale Proxy-Authorization header carried
|
|
2995
|
+
// over from the prior request (e.g. new target no longer uses a proxy, or uses
|
|
2996
|
+
// a different proxy). Skip on the initial request so user-supplied headers are
|
|
2997
|
+
// preserved. Header names are case-insensitive, so remove every case variant.
|
|
2998
|
+
if (isRedirect && options.headers) {
|
|
2999
|
+
for (const name of Object.keys(options.headers)) {
|
|
3000
|
+
if (name.toLowerCase() === 'proxy-authorization') {
|
|
3001
|
+
delete options.headers[name];
|
|
3002
|
+
}
|
|
3003
|
+
}
|
|
3004
|
+
}
|
|
2834
3005
|
if (proxy) {
|
|
3006
|
+
// Read proxy fields without traversing the prototype chain. URL instances expose
|
|
3007
|
+
// username/password/hostname/host/port/protocol via getters on URL.prototype (so
|
|
3008
|
+
// direct reads are shielded), but plain object proxies — and the `auth` field
|
|
3009
|
+
// (which URL does not expose) — must be guarded so a polluted Object.prototype
|
|
3010
|
+
// (e.g. Object.prototype.auth = { username, password }) cannot inject
|
|
3011
|
+
// attacker-controlled credentials into the Proxy-Authorization header or
|
|
3012
|
+
// redirect proxying to an attacker-controlled host.
|
|
3013
|
+
const isProxyURL = proxy instanceof URL;
|
|
3014
|
+
const readProxyField = key => isProxyURL || utils$1.hasOwnProp(proxy, key) ? proxy[key] : undefined;
|
|
3015
|
+
const proxyUsername = readProxyField('username');
|
|
3016
|
+
const proxyPassword = readProxyField('password');
|
|
3017
|
+
let proxyAuth = utils$1.hasOwnProp(proxy, 'auth') ? proxy.auth : undefined;
|
|
3018
|
+
|
|
2835
3019
|
// Basic proxy authorization
|
|
2836
|
-
if (
|
|
2837
|
-
|
|
2838
|
-
}
|
|
2839
|
-
if (
|
|
2840
|
-
// Support proxy auth object form
|
|
2841
|
-
|
|
3020
|
+
if (proxyUsername) {
|
|
3021
|
+
proxyAuth = (proxyUsername || '') + ':' + (proxyPassword || '');
|
|
3022
|
+
}
|
|
3023
|
+
if (proxyAuth) {
|
|
3024
|
+
// Support proxy auth object form. Read sub-fields via own-prop checks so a
|
|
3025
|
+
// plain object inheriting from polluted Object.prototype cannot leak creds.
|
|
3026
|
+
const authIsObject = typeof proxyAuth === 'object';
|
|
3027
|
+
const authUsername = authIsObject && utils$1.hasOwnProp(proxyAuth, 'username') ? proxyAuth.username : undefined;
|
|
3028
|
+
const authPassword = authIsObject && utils$1.hasOwnProp(proxyAuth, 'password') ? proxyAuth.password : undefined;
|
|
3029
|
+
const validProxyAuth = Boolean(authUsername || authPassword);
|
|
2842
3030
|
if (validProxyAuth) {
|
|
2843
|
-
|
|
2844
|
-
} else if (
|
|
3031
|
+
proxyAuth = (authUsername || '') + ':' + (authPassword || '');
|
|
3032
|
+
} else if (authIsObject) {
|
|
2845
3033
|
throw new AxiosError('Invalid proxy authorization', AxiosError.ERR_BAD_OPTION, {
|
|
2846
3034
|
proxy
|
|
2847
3035
|
});
|
|
2848
3036
|
}
|
|
2849
|
-
const base64 = Buffer.from(
|
|
3037
|
+
const base64 = Buffer.from(proxyAuth, 'utf8').toString('base64');
|
|
2850
3038
|
options.headers['Proxy-Authorization'] = 'Basic ' + base64;
|
|
2851
3039
|
}
|
|
2852
|
-
|
|
2853
|
-
|
|
3040
|
+
|
|
3041
|
+
// Preserve a user-supplied Host header (case-insensitive) so callers can override
|
|
3042
|
+
// the value forwarded to the proxy; otherwise default to the request URL's host.
|
|
3043
|
+
let hasUserHostHeader = false;
|
|
3044
|
+
for (const name of Object.keys(options.headers)) {
|
|
3045
|
+
if (name.toLowerCase() === 'host') {
|
|
3046
|
+
hasUserHostHeader = true;
|
|
3047
|
+
break;
|
|
3048
|
+
}
|
|
3049
|
+
}
|
|
3050
|
+
if (!hasUserHostHeader) {
|
|
3051
|
+
options.headers.host = options.hostname + (options.port ? ':' + options.port : '');
|
|
3052
|
+
}
|
|
3053
|
+
const proxyHost = readProxyField('hostname') || readProxyField('host');
|
|
2854
3054
|
options.hostname = proxyHost;
|
|
2855
3055
|
// Replace 'host' since options is not a URL object
|
|
2856
3056
|
options.host = proxyHost;
|
|
2857
|
-
options.port =
|
|
3057
|
+
options.port = readProxyField('port');
|
|
2858
3058
|
options.path = location;
|
|
2859
|
-
|
|
2860
|
-
|
|
3059
|
+
const proxyProtocol = readProxyField('protocol');
|
|
3060
|
+
if (proxyProtocol) {
|
|
3061
|
+
options.protocol = proxyProtocol.includes(':') ? proxyProtocol : `${proxyProtocol}:`;
|
|
2861
3062
|
}
|
|
2862
3063
|
}
|
|
2863
3064
|
options.beforeRedirects.proxy = function beforeRedirect(redirectOptions) {
|
|
2864
3065
|
// Configure proxy for redirected request, passing the original config proxy to apply
|
|
2865
3066
|
// the exact same logic as if the redirected request was performed by axios directly.
|
|
2866
|
-
setProxy(redirectOptions, configProxy, redirectOptions.href);
|
|
3067
|
+
setProxy(redirectOptions, configProxy, redirectOptions.href, true);
|
|
2867
3068
|
};
|
|
2868
3069
|
}
|
|
2869
3070
|
const isHttpAdapterSupported = typeof process !== 'undefined' && utils$1.kindOf(process) === 'process';
|
|
@@ -2959,6 +3160,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
2959
3160
|
let isDone;
|
|
2960
3161
|
let rejected = false;
|
|
2961
3162
|
let req;
|
|
3163
|
+
let connectPhaseTimer;
|
|
2962
3164
|
httpVersion = +httpVersion;
|
|
2963
3165
|
if (Number.isNaN(httpVersion)) {
|
|
2964
3166
|
throw TypeError(`Invalid protocol version: '${config.httpVersion}' is not a number`);
|
|
@@ -2988,8 +3190,23 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
2988
3190
|
console.warn('emit error', err);
|
|
2989
3191
|
}
|
|
2990
3192
|
}
|
|
3193
|
+
function clearConnectPhaseTimer() {
|
|
3194
|
+
if (connectPhaseTimer) {
|
|
3195
|
+
clearTimeout(connectPhaseTimer);
|
|
3196
|
+
connectPhaseTimer = null;
|
|
3197
|
+
}
|
|
3198
|
+
}
|
|
3199
|
+
function createTimeoutError() {
|
|
3200
|
+
let timeoutErrorMessage = config.timeout ? 'timeout of ' + config.timeout + 'ms exceeded' : 'timeout exceeded';
|
|
3201
|
+
const transitional = config.transitional || transitionalDefaults;
|
|
3202
|
+
if (config.timeoutErrorMessage) {
|
|
3203
|
+
timeoutErrorMessage = config.timeoutErrorMessage;
|
|
3204
|
+
}
|
|
3205
|
+
return new AxiosError(timeoutErrorMessage, transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED, config, req);
|
|
3206
|
+
}
|
|
2991
3207
|
abortEmitter.once('abort', reject);
|
|
2992
3208
|
const onFinished = () => {
|
|
3209
|
+
clearConnectPhaseTimer();
|
|
2993
3210
|
if (config.cancelToken) {
|
|
2994
3211
|
config.cancelToken.unsubscribe(abort);
|
|
2995
3212
|
}
|
|
@@ -3006,6 +3223,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3006
3223
|
}
|
|
3007
3224
|
onDone((response, isRejected) => {
|
|
3008
3225
|
isDone = true;
|
|
3226
|
+
clearConnectPhaseTimer();
|
|
3009
3227
|
if (isRejected) {
|
|
3010
3228
|
rejected = true;
|
|
3011
3229
|
onFinished();
|
|
@@ -3099,7 +3317,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3099
3317
|
});
|
|
3100
3318
|
// support for https://www.npmjs.com/package/form-data api
|
|
3101
3319
|
} else if (utils$1.isFormData(data) && utils$1.isFunction(data.getHeaders) && data.getHeaders !== Object.prototype.getHeaders) {
|
|
3102
|
-
headers
|
|
3320
|
+
setFormDataHeaders$1(headers, data.getHeaders(), own('formDataHeaderPolicy'));
|
|
3103
3321
|
if (!headers.hasContentLength()) {
|
|
3104
3322
|
try {
|
|
3105
3323
|
const knownLength = await util.promisify(data.getLength).call(data);
|
|
@@ -3147,20 +3365,21 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3147
3365
|
|
|
3148
3366
|
// HTTP basic authentication
|
|
3149
3367
|
let auth = undefined;
|
|
3150
|
-
|
|
3151
|
-
|
|
3152
|
-
const
|
|
3368
|
+
const configAuth = own('auth');
|
|
3369
|
+
if (configAuth) {
|
|
3370
|
+
const username = configAuth.username || '';
|
|
3371
|
+
const password = configAuth.password || '';
|
|
3153
3372
|
auth = username + ':' + password;
|
|
3154
3373
|
}
|
|
3155
3374
|
if (!auth && parsed.username) {
|
|
3156
|
-
const urlUsername = parsed.username;
|
|
3157
|
-
const urlPassword = parsed.password;
|
|
3375
|
+
const urlUsername = decodeURIComponentSafe(parsed.username);
|
|
3376
|
+
const urlPassword = decodeURIComponentSafe(parsed.password);
|
|
3158
3377
|
auth = urlUsername + ':' + urlPassword;
|
|
3159
3378
|
}
|
|
3160
3379
|
auth && headers.delete('authorization');
|
|
3161
|
-
let path;
|
|
3380
|
+
let path$1;
|
|
3162
3381
|
try {
|
|
3163
|
-
path = buildURL(parsed.pathname + parsed.search, config.params, config.paramsSerializer).replace(/^\?/, '');
|
|
3382
|
+
path$1 = buildURL(parsed.pathname + parsed.search, config.params, config.paramsSerializer).replace(/^\?/, '');
|
|
3164
3383
|
} catch (err) {
|
|
3165
3384
|
const customErr = new Error(err.message);
|
|
3166
3385
|
customErr.config = config;
|
|
@@ -3169,8 +3388,11 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3169
3388
|
return reject(customErr);
|
|
3170
3389
|
}
|
|
3171
3390
|
headers.set('Accept-Encoding', 'gzip, compress, deflate' + (isBrotliSupported ? ', br' : ''), false);
|
|
3172
|
-
|
|
3173
|
-
|
|
3391
|
+
|
|
3392
|
+
// Null-prototype to block prototype pollution gadgets on properties read
|
|
3393
|
+
// directly by Node's http.request (e.g. insecureHTTPParser, lookup).
|
|
3394
|
+
const options = Object.assign(Object.create(null), {
|
|
3395
|
+
path: path$1,
|
|
3174
3396
|
method: method,
|
|
3175
3397
|
headers: headers.toJSON(),
|
|
3176
3398
|
agents: {
|
|
@@ -3181,13 +3403,24 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3181
3403
|
protocol,
|
|
3182
3404
|
family,
|
|
3183
3405
|
beforeRedirect: dispatchBeforeRedirect,
|
|
3184
|
-
beforeRedirects:
|
|
3406
|
+
beforeRedirects: Object.create(null),
|
|
3185
3407
|
http2Options
|
|
3186
|
-
};
|
|
3408
|
+
});
|
|
3187
3409
|
|
|
3188
3410
|
// cacheable-lookup integration hotfix
|
|
3189
3411
|
!utils$1.isUndefined(lookup) && (options.lookup = lookup);
|
|
3190
3412
|
if (config.socketPath) {
|
|
3413
|
+
if (typeof config.socketPath !== 'string') {
|
|
3414
|
+
return reject(new AxiosError('socketPath must be a string', AxiosError.ERR_BAD_OPTION_VALUE, config));
|
|
3415
|
+
}
|
|
3416
|
+
if (config.allowedSocketPaths != null) {
|
|
3417
|
+
const allowed = Array.isArray(config.allowedSocketPaths) ? config.allowedSocketPaths : [config.allowedSocketPaths];
|
|
3418
|
+
const resolvedSocket = path.resolve(config.socketPath);
|
|
3419
|
+
const isAllowed = allowed.some(entry => typeof entry === 'string' && path.resolve(entry) === resolvedSocket);
|
|
3420
|
+
if (!isAllowed) {
|
|
3421
|
+
return reject(new AxiosError(`socketPath "${config.socketPath}" is not permitted by allowedSocketPaths`, AxiosError.ERR_BAD_OPTION_VALUE, config));
|
|
3422
|
+
}
|
|
3423
|
+
}
|
|
3191
3424
|
options.socketPath = config.socketPath;
|
|
3192
3425
|
} else {
|
|
3193
3426
|
options.hostname = parsed.hostname.startsWith('[') ? parsed.hostname.slice(1, -1) : parsed.hostname;
|
|
@@ -3195,6 +3428,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3195
3428
|
setProxy(options, config.proxy, protocol + '//' + parsed.hostname + (parsed.port ? ':' + parsed.port : '') + options.path);
|
|
3196
3429
|
}
|
|
3197
3430
|
let transport;
|
|
3431
|
+
let isNativeTransport = false;
|
|
3198
3432
|
const isHttpsRequest = isHttps.test(options.protocol);
|
|
3199
3433
|
options.agent = isHttpsRequest ? config.httpsAgent : config.httpAgent;
|
|
3200
3434
|
if (isHttp2) {
|
|
@@ -3205,12 +3439,14 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3205
3439
|
transport = configTransport;
|
|
3206
3440
|
} else if (config.maxRedirects === 0) {
|
|
3207
3441
|
transport = isHttpsRequest ? https : http;
|
|
3442
|
+
isNativeTransport = true;
|
|
3208
3443
|
} else {
|
|
3209
3444
|
if (config.maxRedirects) {
|
|
3210
3445
|
options.maxRedirects = config.maxRedirects;
|
|
3211
3446
|
}
|
|
3212
|
-
|
|
3213
|
-
|
|
3447
|
+
const configBeforeRedirect = own('beforeRedirect');
|
|
3448
|
+
if (configBeforeRedirect) {
|
|
3449
|
+
options.beforeRedirects.config = configBeforeRedirect;
|
|
3214
3450
|
}
|
|
3215
3451
|
transport = isHttpsRequest ? httpsFollow : httpFollow;
|
|
3216
3452
|
}
|
|
@@ -3221,12 +3457,15 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3221
3457
|
// follow-redirects does not skip comparison, so it should always succeed for axios -1 unlimited
|
|
3222
3458
|
options.maxBodyLength = Infinity;
|
|
3223
3459
|
}
|
|
3224
|
-
|
|
3225
|
-
|
|
3226
|
-
|
|
3460
|
+
|
|
3461
|
+
// Always set an explicit own value so a polluted
|
|
3462
|
+
// Object.prototype.insecureHTTPParser cannot enable the lenient parser
|
|
3463
|
+
// through Node's internal options copy
|
|
3464
|
+
options.insecureHTTPParser = Boolean(own('insecureHTTPParser'));
|
|
3227
3465
|
|
|
3228
3466
|
// Create the request
|
|
3229
3467
|
req = transport.request(options, function handleResponse(res) {
|
|
3468
|
+
clearConnectPhaseTimer();
|
|
3230
3469
|
if (req.destroyed) return;
|
|
3231
3470
|
const streams = [res];
|
|
3232
3471
|
const responseLength = utils$1.toFiniteNumber(res.headers['content-length']);
|
|
@@ -3289,7 +3528,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3289
3528
|
};
|
|
3290
3529
|
if (responseType === 'stream') {
|
|
3291
3530
|
// Enforce maxContentLength on streamed responses; previously this
|
|
3292
|
-
// was applied only to buffered responses.
|
|
3531
|
+
// was applied only to buffered responses.
|
|
3293
3532
|
if (config.maxContentLength > -1) {
|
|
3294
3533
|
const limit = config.maxContentLength;
|
|
3295
3534
|
const source = responseStream;
|
|
@@ -3328,13 +3567,13 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3328
3567
|
if (rejected) {
|
|
3329
3568
|
return;
|
|
3330
3569
|
}
|
|
3331
|
-
const err = new AxiosError('stream has been aborted', AxiosError.ERR_BAD_RESPONSE, config, lastRequest);
|
|
3570
|
+
const err = new AxiosError('stream has been aborted', AxiosError.ERR_BAD_RESPONSE, config, lastRequest, response);
|
|
3332
3571
|
responseStream.destroy(err);
|
|
3333
3572
|
reject(err);
|
|
3334
3573
|
});
|
|
3335
3574
|
responseStream.on('error', function handleStreamError(err) {
|
|
3336
|
-
if (
|
|
3337
|
-
reject(AxiosError.from(err, null, config, lastRequest));
|
|
3575
|
+
if (rejected) return;
|
|
3576
|
+
reject(AxiosError.from(err, null, config, lastRequest, response));
|
|
3338
3577
|
});
|
|
3339
3578
|
responseStream.on('end', function handleStreamEnd() {
|
|
3340
3579
|
try {
|
|
@@ -3373,20 +3612,44 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3373
3612
|
});
|
|
3374
3613
|
|
|
3375
3614
|
// set tcp keep alive to prevent drop connection by peer
|
|
3615
|
+
// Track every socket bound to this outer RedirectableRequest so a single
|
|
3616
|
+
// 'close' listener can release ownership on all of them. follow-redirects
|
|
3617
|
+
// re-emits the 'socket' event for each hop's native request onto the same
|
|
3618
|
+
// outer request, so attaching per-request listeners inside this handler
|
|
3619
|
+
// would accumulate across hops and trigger MaxListenersExceededWarning at
|
|
3620
|
+
// >= 11 redirects. Clearing only the last-bound socket would leave stale
|
|
3621
|
+
// kAxiosCurrentReq refs on earlier hop sockets returned to the keep-alive
|
|
3622
|
+
// pool, causing an idle-pool 'error' to be attributed to a closed req.
|
|
3623
|
+
const boundSockets = new Set();
|
|
3376
3624
|
req.on('socket', function handleRequestSocket(socket) {
|
|
3377
3625
|
// default interval of sending ack packet is 1 minute
|
|
3378
3626
|
socket.setKeepAlive(true, 1000 * 60);
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3627
|
+
|
|
3628
|
+
// Install a single 'error' listener per socket (not per request) to avoid
|
|
3629
|
+
// accumulating listeners on pooled keep-alive sockets that get reassigned
|
|
3630
|
+
// to new requests before the previous request's 'close' fires (issue #10780).
|
|
3631
|
+
// The listener is bound to the socket's currently-active request via a
|
|
3632
|
+
// symbol, which is swapped as the socket is reassigned.
|
|
3633
|
+
if (!socket[kAxiosSocketListener]) {
|
|
3634
|
+
socket.on('error', function handleSocketError(err) {
|
|
3635
|
+
const current = socket[kAxiosCurrentReq];
|
|
3636
|
+
if (current && !current.destroyed) {
|
|
3637
|
+
current.destroy(err);
|
|
3638
|
+
}
|
|
3639
|
+
});
|
|
3640
|
+
socket[kAxiosSocketListener] = true;
|
|
3641
|
+
}
|
|
3642
|
+
socket[kAxiosCurrentReq] = req;
|
|
3643
|
+
boundSockets.add(socket);
|
|
3644
|
+
});
|
|
3645
|
+
req.once('close', function clearCurrentReq() {
|
|
3646
|
+
clearConnectPhaseTimer();
|
|
3647
|
+
for (const socket of boundSockets) {
|
|
3648
|
+
if (socket[kAxiosCurrentReq] === req) {
|
|
3649
|
+
socket[kAxiosCurrentReq] = null;
|
|
3386
3650
|
}
|
|
3387
3651
|
}
|
|
3388
|
-
|
|
3389
|
-
req.once('close', removeSocketErrorListener);
|
|
3652
|
+
boundSockets.clear();
|
|
3390
3653
|
});
|
|
3391
3654
|
|
|
3392
3655
|
// Handle request timeout
|
|
@@ -3397,21 +3660,23 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3397
3660
|
abort(new AxiosError('error trying to parse `config.timeout` to int', AxiosError.ERR_BAD_OPTION_VALUE, config, req));
|
|
3398
3661
|
return;
|
|
3399
3662
|
}
|
|
3663
|
+
const handleTimeout = function handleTimeout() {
|
|
3664
|
+
if (isDone) return;
|
|
3665
|
+
abort(createTimeoutError());
|
|
3666
|
+
};
|
|
3667
|
+
if (isNativeTransport && timeout > 0) {
|
|
3668
|
+
// Native ClientRequest#setTimeout starts from the socket lifecycle and
|
|
3669
|
+
// may not fire while TCP connect is still pending. Mirror the
|
|
3670
|
+
// follow-redirects wall-clock timer for the maxRedirects === 0 path.
|
|
3671
|
+
connectPhaseTimer = setTimeout(handleTimeout, timeout);
|
|
3672
|
+
}
|
|
3400
3673
|
|
|
3401
3674
|
// Sometime, the response will be very slow, and does not respond, the connect event will be block by event loop system.
|
|
3402
3675
|
// And timer callback will be fired, and abort() will be invoked before connection, then get "socket hang up" and code ECONNRESET.
|
|
3403
3676
|
// At this time, if we have a large number of request, nodejs will hang up some socket on background. and the number will up and up.
|
|
3404
3677
|
// And then these socket which be hang up will devouring CPU little by little.
|
|
3405
3678
|
// ClientRequest.setTimeout will be fired on the specify milliseconds, and can make sure that abort() will be fired after connect.
|
|
3406
|
-
req.setTimeout(timeout,
|
|
3407
|
-
if (isDone) return;
|
|
3408
|
-
let timeoutErrorMessage = config.timeout ? 'timeout of ' + config.timeout + 'ms exceeded' : 'timeout exceeded';
|
|
3409
|
-
const transitional = config.transitional || transitionalDefaults;
|
|
3410
|
-
if (config.timeoutErrorMessage) {
|
|
3411
|
-
timeoutErrorMessage = config.timeoutErrorMessage;
|
|
3412
|
-
}
|
|
3413
|
-
abort(new AxiosError(timeoutErrorMessage, transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED, config, req));
|
|
3414
|
-
});
|
|
3679
|
+
req.setTimeout(timeout, handleTimeout);
|
|
3415
3680
|
} else {
|
|
3416
3681
|
// explicitly reset the socket timeout value for a possible `keep-alive` request
|
|
3417
3682
|
req.setTimeout(0);
|
|
@@ -3436,7 +3701,7 @@ var httpAdapter = isHttpAdapterSupported && function httpAdapter(config) {
|
|
|
3436
3701
|
|
|
3437
3702
|
// Enforce maxBodyLength for streamed uploads on the native http/https
|
|
3438
3703
|
// transport (maxRedirects === 0); follow-redirects enforces it on the
|
|
3439
|
-
// other path.
|
|
3704
|
+
// other path.
|
|
3440
3705
|
let uploadStream = data;
|
|
3441
3706
|
if (config.maxBodyLength > -1 && config.maxRedirects === 0) {
|
|
3442
3707
|
const limit = config.maxBodyLength;
|
|
@@ -3492,8 +3757,20 @@ var cookies = platform.hasStandardBrowserEnv ?
|
|
|
3492
3757
|
},
|
|
3493
3758
|
read(name) {
|
|
3494
3759
|
if (typeof document === 'undefined') return null;
|
|
3495
|
-
|
|
3496
|
-
|
|
3760
|
+
// Match name=value by splitting on the semicolon separator instead of building a
|
|
3761
|
+
// RegExp from `name` — interpolating an unescaped string into a RegExp would let
|
|
3762
|
+
// metacharacters (e.g. `.+?` in an attacker-influenced cookie name) cause ReDoS or
|
|
3763
|
+
// match the wrong cookie. Browsers may serialize cookie pairs as either ";" or
|
|
3764
|
+
// "; ", so ignore optional whitespace before each cookie name.
|
|
3765
|
+
const cookies = document.cookie.split(';');
|
|
3766
|
+
for (let i = 0; i < cookies.length; i++) {
|
|
3767
|
+
const cookie = cookies[i].replace(/^\s+/, '');
|
|
3768
|
+
const eq = cookie.indexOf('=');
|
|
3769
|
+
if (eq !== -1 && cookie.slice(0, eq) === name) {
|
|
3770
|
+
return decodeURIComponent(cookie.slice(eq + 1));
|
|
3771
|
+
}
|
|
3772
|
+
}
|
|
3773
|
+
return null;
|
|
3497
3774
|
},
|
|
3498
3775
|
remove(name) {
|
|
3499
3776
|
this.write(name, '', Date.now() - 86400000, '/');
|
|
@@ -3524,7 +3801,21 @@ const headersToObject = thing => thing instanceof AxiosHeaders ? {
|
|
|
3524
3801
|
function mergeConfig(config1, config2) {
|
|
3525
3802
|
// eslint-disable-next-line no-param-reassign
|
|
3526
3803
|
config2 = config2 || {};
|
|
3527
|
-
|
|
3804
|
+
|
|
3805
|
+
// Use a null-prototype object so that downstream reads such as `config.auth`
|
|
3806
|
+
// or `config.baseURL` cannot inherit polluted values from Object.prototype.
|
|
3807
|
+
// `hasOwnProperty` is restored as a non-enumerable own slot to preserve
|
|
3808
|
+
// ergonomics for user code that relies on it.
|
|
3809
|
+
const config = Object.create(null);
|
|
3810
|
+
Object.defineProperty(config, 'hasOwnProperty', {
|
|
3811
|
+
// Null-proto descriptor so a polluted Object.prototype.get cannot turn
|
|
3812
|
+
// this data descriptor into an accessor descriptor on the way in.
|
|
3813
|
+
__proto__: null,
|
|
3814
|
+
value: Object.prototype.hasOwnProperty,
|
|
3815
|
+
enumerable: false,
|
|
3816
|
+
writable: true,
|
|
3817
|
+
configurable: true
|
|
3818
|
+
});
|
|
3528
3819
|
function getMergedValue(target, source, prop, caseless) {
|
|
3529
3820
|
if (utils$1.isPlainObject(target) && utils$1.isPlainObject(source)) {
|
|
3530
3821
|
return utils$1.merge.call({
|
|
@@ -3596,6 +3887,7 @@ function mergeConfig(config1, config2) {
|
|
|
3596
3887
|
httpsAgent: defaultToConfig2,
|
|
3597
3888
|
cancelToken: defaultToConfig2,
|
|
3598
3889
|
socketPath: defaultToConfig2,
|
|
3890
|
+
allowedSocketPaths: defaultToConfig2,
|
|
3599
3891
|
responseEncoding: defaultToConfig2,
|
|
3600
3892
|
validateStatus: mergeDirectKeys,
|
|
3601
3893
|
headers: (a, b, prop) => mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true)
|
|
@@ -3614,36 +3906,56 @@ function mergeConfig(config1, config2) {
|
|
|
3614
3906
|
return config;
|
|
3615
3907
|
}
|
|
3616
3908
|
|
|
3909
|
+
const FORM_DATA_CONTENT_HEADERS = ['content-type', 'content-length'];
|
|
3910
|
+
function setFormDataHeaders(headers, formHeaders, policy) {
|
|
3911
|
+
if (policy !== 'content-only') {
|
|
3912
|
+
headers.set(formHeaders);
|
|
3913
|
+
return;
|
|
3914
|
+
}
|
|
3915
|
+
Object.entries(formHeaders).forEach(([key, val]) => {
|
|
3916
|
+
if (FORM_DATA_CONTENT_HEADERS.includes(key.toLowerCase())) {
|
|
3917
|
+
headers.set(key, val);
|
|
3918
|
+
}
|
|
3919
|
+
});
|
|
3920
|
+
}
|
|
3921
|
+
|
|
3922
|
+
/**
|
|
3923
|
+
* Encode a UTF-8 string to a Latin-1 byte string for use with btoa().
|
|
3924
|
+
* This is a modern replacement for the deprecated unescape(encodeURIComponent(str)) pattern.
|
|
3925
|
+
*
|
|
3926
|
+
* @param {string} str The string to encode
|
|
3927
|
+
*
|
|
3928
|
+
* @returns {string} UTF-8 bytes as a Latin-1 string
|
|
3929
|
+
*/
|
|
3930
|
+
const encodeUTF8 = str => encodeURIComponent(str).replace(/%([0-9A-F]{2})/gi, (_, hex) => String.fromCharCode(parseInt(hex, 16)));
|
|
3617
3931
|
var resolveConfig = config => {
|
|
3618
3932
|
const newConfig = mergeConfig({}, config);
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3933
|
+
|
|
3934
|
+
// Read only own properties to prevent prototype pollution gadgets
|
|
3935
|
+
// (e.g. Object.prototype.baseURL = 'https://evil.com').
|
|
3936
|
+
const own = key => utils$1.hasOwnProp(newConfig, key) ? newConfig[key] : undefined;
|
|
3937
|
+
const data = own('data');
|
|
3938
|
+
let withXSRFToken = own('withXSRFToken');
|
|
3939
|
+
const xsrfHeaderName = own('xsrfHeaderName');
|
|
3940
|
+
const xsrfCookieName = own('xsrfCookieName');
|
|
3941
|
+
let headers = own('headers');
|
|
3942
|
+
const auth = own('auth');
|
|
3943
|
+
const baseURL = own('baseURL');
|
|
3944
|
+
const allowAbsoluteUrls = own('allowAbsoluteUrls');
|
|
3945
|
+
const url = own('url');
|
|
3627
3946
|
newConfig.headers = headers = AxiosHeaders.from(headers);
|
|
3628
|
-
newConfig.url = buildURL(buildFullPath(
|
|
3947
|
+
newConfig.url = buildURL(buildFullPath(baseURL, url, allowAbsoluteUrls), config.params, config.paramsSerializer);
|
|
3629
3948
|
|
|
3630
3949
|
// HTTP basic authentication
|
|
3631
3950
|
if (auth) {
|
|
3632
|
-
headers.set('Authorization', 'Basic ' + btoa((auth.username || '') + ':' + (auth.password ?
|
|
3951
|
+
headers.set('Authorization', 'Basic ' + btoa((auth.username || '') + ':' + (auth.password ? encodeUTF8(auth.password) : '')));
|
|
3633
3952
|
}
|
|
3634
3953
|
if (utils$1.isFormData(data)) {
|
|
3635
3954
|
if (platform.hasStandardBrowserEnv || platform.hasStandardBrowserWebWorkerEnv) {
|
|
3636
3955
|
headers.setContentType(undefined); // browser handles it
|
|
3637
3956
|
} else if (utils$1.isFunction(data.getHeaders)) {
|
|
3638
3957
|
// Node.js FormData (like form-data package)
|
|
3639
|
-
|
|
3640
|
-
// Only set safe headers to avoid overwriting security headers
|
|
3641
|
-
const allowedHeaders = ['content-type', 'content-length'];
|
|
3642
|
-
Object.entries(formHeaders).forEach(([key, val]) => {
|
|
3643
|
-
if (allowedHeaders.includes(key.toLowerCase())) {
|
|
3644
|
-
headers.set(key, val);
|
|
3645
|
-
}
|
|
3646
|
-
});
|
|
3958
|
+
setFormDataHeaders(headers, data.getHeaders(), own('formDataHeaderPolicy'));
|
|
3647
3959
|
}
|
|
3648
3960
|
}
|
|
3649
3961
|
|
|
@@ -3658,7 +3970,7 @@ var resolveConfig = config => {
|
|
|
3658
3970
|
|
|
3659
3971
|
// Strict boolean check — prevents proto-pollution gadgets (e.g. Object.prototype.withXSRFToken = 1)
|
|
3660
3972
|
// and misconfigurations (e.g. "false") from short-circuiting the same-origin check and leaking
|
|
3661
|
-
// the XSRF token cross-origin.
|
|
3973
|
+
// the XSRF token cross-origin.
|
|
3662
3974
|
const shouldSendXSRF = withXSRFToken === true || withXSRFToken == null && isURLSameOrigin(newConfig.url);
|
|
3663
3975
|
if (shouldSendXSRF) {
|
|
3664
3976
|
const xsrfValue = xsrfHeaderName && xsrfCookieName && cookies.read(xsrfCookieName);
|
|
@@ -3736,7 +4048,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3736
4048
|
// handled by onerror instead
|
|
3737
4049
|
// With one exception: request that using file: protocol, most browsers
|
|
3738
4050
|
// will return status as 0 even though it's a successful request
|
|
3739
|
-
if (request.status === 0 && !(request.responseURL && request.responseURL.
|
|
4051
|
+
if (request.status === 0 && !(request.responseURL && request.responseURL.startsWith('file:'))) {
|
|
3740
4052
|
return;
|
|
3741
4053
|
}
|
|
3742
4054
|
// readystate handler is calling before onerror or ontimeout handlers,
|
|
@@ -3751,6 +4063,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3751
4063
|
return;
|
|
3752
4064
|
}
|
|
3753
4065
|
reject(new AxiosError('Request aborted', AxiosError.ECONNABORTED, config, request));
|
|
4066
|
+
done();
|
|
3754
4067
|
|
|
3755
4068
|
// Clean up request
|
|
3756
4069
|
request = null;
|
|
@@ -3766,6 +4079,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3766
4079
|
// attach the underlying event for consumers who want details
|
|
3767
4080
|
err.event = event || null;
|
|
3768
4081
|
reject(err);
|
|
4082
|
+
done();
|
|
3769
4083
|
request = null;
|
|
3770
4084
|
};
|
|
3771
4085
|
|
|
@@ -3777,6 +4091,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3777
4091
|
timeoutErrorMessage = _config.timeoutErrorMessage;
|
|
3778
4092
|
}
|
|
3779
4093
|
reject(new AxiosError(timeoutErrorMessage, transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED, config, request));
|
|
4094
|
+
done();
|
|
3780
4095
|
|
|
3781
4096
|
// Clean up request
|
|
3782
4097
|
request = null;
|
|
@@ -3823,6 +4138,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3823
4138
|
}
|
|
3824
4139
|
reject(!cancel || cancel.type ? new CanceledError(null, config, request) : cancel);
|
|
3825
4140
|
request.abort();
|
|
4141
|
+
done();
|
|
3826
4142
|
request = null;
|
|
3827
4143
|
};
|
|
3828
4144
|
_config.cancelToken && _config.cancelToken.subscribe(onCanceled);
|
|
@@ -3831,7 +4147,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
|
|
|
3831
4147
|
}
|
|
3832
4148
|
}
|
|
3833
4149
|
const protocol = parseProtocol(_config.url);
|
|
3834
|
-
if (protocol && platform.protocols.
|
|
4150
|
+
if (protocol && !platform.protocols.includes(protocol)) {
|
|
3835
4151
|
reject(new AxiosError('Unsupported protocol ' + protocol + ':', AxiosError.ERR_BAD_REQUEST, config));
|
|
3836
4152
|
return;
|
|
3837
4153
|
}
|
|
@@ -3965,17 +4281,6 @@ const DEFAULT_CHUNK_SIZE = 64 * 1024;
|
|
|
3965
4281
|
const {
|
|
3966
4282
|
isFunction
|
|
3967
4283
|
} = utils$1;
|
|
3968
|
-
const globalFetchAPI = (({
|
|
3969
|
-
Request,
|
|
3970
|
-
Response
|
|
3971
|
-
}) => ({
|
|
3972
|
-
Request,
|
|
3973
|
-
Response
|
|
3974
|
-
}))(utils$1.global);
|
|
3975
|
-
const {
|
|
3976
|
-
ReadableStream: ReadableStream$1,
|
|
3977
|
-
TextEncoder: TextEncoder$1
|
|
3978
|
-
} = utils$1.global;
|
|
3979
4284
|
const test = (fn, ...args) => {
|
|
3980
4285
|
try {
|
|
3981
4286
|
return !!fn(...args);
|
|
@@ -3984,9 +4289,18 @@ const test = (fn, ...args) => {
|
|
|
3984
4289
|
}
|
|
3985
4290
|
};
|
|
3986
4291
|
const factory = env => {
|
|
4292
|
+
var _utils$global;
|
|
4293
|
+
const globalObject = (_utils$global = utils$1.global) !== null && _utils$global !== void 0 ? _utils$global : globalThis;
|
|
4294
|
+
const {
|
|
4295
|
+
ReadableStream,
|
|
4296
|
+
TextEncoder
|
|
4297
|
+
} = globalObject;
|
|
3987
4298
|
env = utils$1.merge.call({
|
|
3988
4299
|
skipUndefined: true
|
|
3989
|
-
},
|
|
4300
|
+
}, {
|
|
4301
|
+
Request: globalObject.Request,
|
|
4302
|
+
Response: globalObject.Response
|
|
4303
|
+
}, env);
|
|
3990
4304
|
const {
|
|
3991
4305
|
fetch: envFetch,
|
|
3992
4306
|
Request,
|
|
@@ -3998,12 +4312,12 @@ const factory = env => {
|
|
|
3998
4312
|
if (!isFetchSupported) {
|
|
3999
4313
|
return false;
|
|
4000
4314
|
}
|
|
4001
|
-
const isReadableStreamSupported = isFetchSupported && isFunction(ReadableStream
|
|
4002
|
-
const encodeText = isFetchSupported && (typeof TextEncoder
|
|
4315
|
+
const isReadableStreamSupported = isFetchSupported && isFunction(ReadableStream);
|
|
4316
|
+
const encodeText = isFetchSupported && (typeof TextEncoder === 'function' ? (encoder => str => encoder.encode(str))(new TextEncoder()) : async str => new Uint8Array(await new Request(str).arrayBuffer()));
|
|
4003
4317
|
const supportsRequestStream = isRequestSupported && isReadableStreamSupported && test(() => {
|
|
4004
4318
|
let duplexAccessed = false;
|
|
4005
4319
|
const request = new Request(platform.origin, {
|
|
4006
|
-
body: new ReadableStream
|
|
4320
|
+
body: new ReadableStream(),
|
|
4007
4321
|
method: 'POST',
|
|
4008
4322
|
get duplex() {
|
|
4009
4323
|
duplexAccessed = true;
|
|
@@ -4072,8 +4386,12 @@ const factory = env => {
|
|
|
4072
4386
|
responseType,
|
|
4073
4387
|
headers,
|
|
4074
4388
|
withCredentials = 'same-origin',
|
|
4075
|
-
fetchOptions
|
|
4389
|
+
fetchOptions,
|
|
4390
|
+
maxContentLength,
|
|
4391
|
+
maxBodyLength
|
|
4076
4392
|
} = resolveConfig(config);
|
|
4393
|
+
const hasMaxContentLength = utils$1.isNumber(maxContentLength) && maxContentLength > -1;
|
|
4394
|
+
const hasMaxBodyLength = utils$1.isNumber(maxBodyLength) && maxBodyLength > -1;
|
|
4077
4395
|
let _fetch = envFetch || fetch;
|
|
4078
4396
|
responseType = responseType ? (responseType + '').toLowerCase() : 'text';
|
|
4079
4397
|
let composedSignal = composeSignals([signal, cancelToken && cancelToken.toAbortSignal()], timeout);
|
|
@@ -4083,6 +4401,26 @@ const factory = env => {
|
|
|
4083
4401
|
});
|
|
4084
4402
|
let requestContentLength;
|
|
4085
4403
|
try {
|
|
4404
|
+
// Enforce maxContentLength for data: URLs up-front so we never materialize
|
|
4405
|
+
// an oversized payload. The HTTP adapter applies the same check (see http.js
|
|
4406
|
+
// "if (protocol === 'data:')" branch).
|
|
4407
|
+
if (hasMaxContentLength && typeof url === 'string' && url.startsWith('data:')) {
|
|
4408
|
+
const estimated = estimateDataURLDecodedBytes(url);
|
|
4409
|
+
if (estimated > maxContentLength) {
|
|
4410
|
+
throw new AxiosError('maxContentLength size of ' + maxContentLength + ' exceeded', AxiosError.ERR_BAD_RESPONSE, config, request);
|
|
4411
|
+
}
|
|
4412
|
+
}
|
|
4413
|
+
|
|
4414
|
+
// Enforce maxBodyLength against the outbound request body before dispatch.
|
|
4415
|
+
// Mirrors http.js behavior (ERR_BAD_REQUEST / 'Request body larger than
|
|
4416
|
+
// maxBodyLength limit'). Skip when the body length cannot be determined
|
|
4417
|
+
// (e.g. a live ReadableStream supplied by the caller).
|
|
4418
|
+
if (hasMaxBodyLength && method !== 'get' && method !== 'head') {
|
|
4419
|
+
const outboundLength = await resolveBodyLength(headers, data);
|
|
4420
|
+
if (typeof outboundLength === 'number' && isFinite(outboundLength) && outboundLength > maxBodyLength) {
|
|
4421
|
+
throw new AxiosError('Request body larger than maxBodyLength limit', AxiosError.ERR_BAD_REQUEST, config, request);
|
|
4422
|
+
}
|
|
4423
|
+
}
|
|
4086
4424
|
if (onUploadProgress && supportsRequestStream && method !== 'get' && method !== 'head' && (requestContentLength = await resolveBodyLength(headers, data)) !== 0) {
|
|
4087
4425
|
let _request = new Request(url, {
|
|
4088
4426
|
method: 'POST',
|
|
@@ -4114,6 +4452,9 @@ const factory = env => {
|
|
|
4114
4452
|
headers.delete('content-type');
|
|
4115
4453
|
}
|
|
4116
4454
|
}
|
|
4455
|
+
|
|
4456
|
+
// Set User-Agent header if not already set (fetch defaults to 'node' in Node.js)
|
|
4457
|
+
headers.set('User-Agent', 'axios/' + VERSION, false);
|
|
4117
4458
|
const resolvedOptions = {
|
|
4118
4459
|
...fetchOptions,
|
|
4119
4460
|
signal: composedSignal,
|
|
@@ -4125,21 +4466,59 @@ const factory = env => {
|
|
|
4125
4466
|
};
|
|
4126
4467
|
request = isRequestSupported && new Request(url, resolvedOptions);
|
|
4127
4468
|
let response = await (isRequestSupported ? _fetch(request, fetchOptions) : _fetch(url, resolvedOptions));
|
|
4469
|
+
|
|
4470
|
+
// Cheap pre-check: if the server honestly declares a content-length that
|
|
4471
|
+
// already exceeds the cap, reject before we start streaming.
|
|
4472
|
+
if (hasMaxContentLength) {
|
|
4473
|
+
const declaredLength = utils$1.toFiniteNumber(response.headers.get('content-length'));
|
|
4474
|
+
if (declaredLength != null && declaredLength > maxContentLength) {
|
|
4475
|
+
throw new AxiosError('maxContentLength size of ' + maxContentLength + ' exceeded', AxiosError.ERR_BAD_RESPONSE, config, request);
|
|
4476
|
+
}
|
|
4477
|
+
}
|
|
4128
4478
|
const isStreamResponse = supportsResponseStream && (responseType === 'stream' || responseType === 'response');
|
|
4129
|
-
if (supportsResponseStream && (onDownloadProgress || isStreamResponse && unsubscribe)) {
|
|
4479
|
+
if (supportsResponseStream && response.body && (onDownloadProgress || hasMaxContentLength || isStreamResponse && unsubscribe)) {
|
|
4130
4480
|
const options = {};
|
|
4131
4481
|
['status', 'statusText', 'headers'].forEach(prop => {
|
|
4132
4482
|
options[prop] = response[prop];
|
|
4133
4483
|
});
|
|
4134
4484
|
const responseContentLength = utils$1.toFiniteNumber(response.headers.get('content-length'));
|
|
4135
4485
|
const [onProgress, flush] = onDownloadProgress && progressEventDecorator(responseContentLength, progressEventReducer(asyncDecorator(onDownloadProgress), true)) || [];
|
|
4136
|
-
|
|
4486
|
+
let bytesRead = 0;
|
|
4487
|
+
const onChunkProgress = loadedBytes => {
|
|
4488
|
+
if (hasMaxContentLength) {
|
|
4489
|
+
bytesRead = loadedBytes;
|
|
4490
|
+
if (bytesRead > maxContentLength) {
|
|
4491
|
+
throw new AxiosError('maxContentLength size of ' + maxContentLength + ' exceeded', AxiosError.ERR_BAD_RESPONSE, config, request);
|
|
4492
|
+
}
|
|
4493
|
+
}
|
|
4494
|
+
onProgress && onProgress(loadedBytes);
|
|
4495
|
+
};
|
|
4496
|
+
response = new Response(trackStream(response.body, DEFAULT_CHUNK_SIZE, onChunkProgress, () => {
|
|
4137
4497
|
flush && flush();
|
|
4138
4498
|
unsubscribe && unsubscribe();
|
|
4139
4499
|
}), options);
|
|
4140
4500
|
}
|
|
4141
4501
|
responseType = responseType || 'text';
|
|
4142
4502
|
let responseData = await resolvers[utils$1.findKey(resolvers, responseType) || 'text'](response, config);
|
|
4503
|
+
|
|
4504
|
+
// Fallback enforcement for environments without ReadableStream support
|
|
4505
|
+
// (legacy runtimes). Detect materialized size from typed output; skip
|
|
4506
|
+
// streams/Response passthrough since the user will read those themselves.
|
|
4507
|
+
if (hasMaxContentLength && !supportsResponseStream && !isStreamResponse) {
|
|
4508
|
+
let materializedSize;
|
|
4509
|
+
if (responseData != null) {
|
|
4510
|
+
if (typeof responseData.byteLength === 'number') {
|
|
4511
|
+
materializedSize = responseData.byteLength;
|
|
4512
|
+
} else if (typeof responseData.size === 'number') {
|
|
4513
|
+
materializedSize = responseData.size;
|
|
4514
|
+
} else if (typeof responseData === 'string') {
|
|
4515
|
+
materializedSize = typeof TextEncoder === 'function' ? new TextEncoder().encode(responseData).byteLength : responseData.length;
|
|
4516
|
+
}
|
|
4517
|
+
}
|
|
4518
|
+
if (typeof materializedSize === 'number' && materializedSize > maxContentLength) {
|
|
4519
|
+
throw new AxiosError('maxContentLength size of ' + maxContentLength + ' exceeded', AxiosError.ERR_BAD_RESPONSE, config, request);
|
|
4520
|
+
}
|
|
4521
|
+
}
|
|
4143
4522
|
!isStreamResponse && unsubscribe && unsubscribe();
|
|
4144
4523
|
return await new Promise((resolve, reject) => {
|
|
4145
4524
|
settle(resolve, reject, {
|
|
@@ -4153,6 +4532,17 @@ const factory = env => {
|
|
|
4153
4532
|
});
|
|
4154
4533
|
} catch (err) {
|
|
4155
4534
|
unsubscribe && unsubscribe();
|
|
4535
|
+
|
|
4536
|
+
// Safari can surface fetch aborts as a DOMException-like object whose
|
|
4537
|
+
// branded getters throw. Prefer our composed signal reason before reading
|
|
4538
|
+
// the caught error, preserving timeout vs cancellation semantics.
|
|
4539
|
+
if (composedSignal && composedSignal.aborted && composedSignal.reason instanceof AxiosError) {
|
|
4540
|
+
const canceledError = composedSignal.reason;
|
|
4541
|
+
canceledError.config = config;
|
|
4542
|
+
request && (canceledError.request = request);
|
|
4543
|
+
err !== canceledError && (canceledError.cause = err);
|
|
4544
|
+
throw canceledError;
|
|
4545
|
+
}
|
|
4156
4546
|
if (err && err.name === 'TypeError' && /Load failed|fetch/i.test(err.message)) {
|
|
4157
4547
|
throw Object.assign(new AxiosError('Network Error', AxiosError.ERR_NETWORK, config, request, err && err.response), {
|
|
4158
4548
|
cause: err.cause || err
|
|
@@ -4207,13 +4597,17 @@ const knownAdapters = {
|
|
|
4207
4597
|
utils$1.forEach(knownAdapters, (fn, value) => {
|
|
4208
4598
|
if (fn) {
|
|
4209
4599
|
try {
|
|
4600
|
+
// Null-proto descriptors so a polluted Object.prototype.get cannot turn
|
|
4601
|
+
// these data descriptors into accessor descriptors on the way in.
|
|
4210
4602
|
Object.defineProperty(fn, 'name', {
|
|
4603
|
+
__proto__: null,
|
|
4211
4604
|
value
|
|
4212
4605
|
});
|
|
4213
4606
|
} catch (e) {
|
|
4214
4607
|
// eslint-disable-next-line no-empty
|
|
4215
4608
|
}
|
|
4216
4609
|
Object.defineProperty(fn, 'adapterName', {
|
|
4610
|
+
__proto__: null,
|
|
4217
4611
|
value
|
|
4218
4612
|
});
|
|
4219
4613
|
}
|
|
@@ -4328,8 +4722,15 @@ function dispatchRequest(config) {
|
|
|
4328
4722
|
return adapter(config).then(function onAdapterResolution(response) {
|
|
4329
4723
|
throwIfCancellationRequested(config);
|
|
4330
4724
|
|
|
4331
|
-
//
|
|
4332
|
-
|
|
4725
|
+
// Expose the current response on config so that transformResponse can
|
|
4726
|
+
// attach it to any AxiosError it throws (e.g. on JSON parse failure).
|
|
4727
|
+
// We clean it up afterwards to avoid polluting the config object.
|
|
4728
|
+
config.response = response;
|
|
4729
|
+
try {
|
|
4730
|
+
response.data = transformData.call(config, config.transformResponse, response);
|
|
4731
|
+
} finally {
|
|
4732
|
+
delete config.response;
|
|
4733
|
+
}
|
|
4333
4734
|
response.headers = AxiosHeaders.from(response.headers);
|
|
4334
4735
|
return response;
|
|
4335
4736
|
}, function onAdapterRejection(reason) {
|
|
@@ -4338,7 +4739,12 @@ function dispatchRequest(config) {
|
|
|
4338
4739
|
|
|
4339
4740
|
// Transform response data
|
|
4340
4741
|
if (reason && reason.response) {
|
|
4341
|
-
|
|
4742
|
+
config.response = reason.response;
|
|
4743
|
+
try {
|
|
4744
|
+
reason.response.data = transformData.call(config, config.transformResponse, reason.response);
|
|
4745
|
+
} finally {
|
|
4746
|
+
delete config.response;
|
|
4747
|
+
}
|
|
4342
4748
|
reason.response.headers = AxiosHeaders.from(reason.response.headers);
|
|
4343
4749
|
}
|
|
4344
4750
|
}
|
|
@@ -4409,7 +4815,9 @@ function assertOptions(options, schema, allowUnknown) {
|
|
|
4409
4815
|
let i = keys.length;
|
|
4410
4816
|
while (i-- > 0) {
|
|
4411
4817
|
const opt = keys[i];
|
|
4412
|
-
|
|
4818
|
+
// Use hasOwnProperty so a polluted Object.prototype.<opt> cannot supply
|
|
4819
|
+
// a non-function validator and cause a TypeError.
|
|
4820
|
+
const validator = Object.prototype.hasOwnProperty.call(schema, opt) ? schema[opt] : undefined;
|
|
4413
4821
|
if (validator) {
|
|
4414
4822
|
const value = options[opt];
|
|
4415
4823
|
const result = value === undefined || validator(value, opt, options);
|
|
@@ -4541,7 +4949,7 @@ class Axios {
|
|
|
4541
4949
|
|
|
4542
4950
|
// Flatten headers
|
|
4543
4951
|
let contextHeaders = headers && utils$1.merge(headers.common, headers[config.method]);
|
|
4544
|
-
headers && utils$1.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], method => {
|
|
4952
|
+
headers && utils$1.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'query', 'common'], method => {
|
|
4545
4953
|
delete headers[method];
|
|
4546
4954
|
});
|
|
4547
4955
|
config.headers = AxiosHeaders.concat(contextHeaders, headers);
|
|
@@ -4622,7 +5030,7 @@ utils$1.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoDa
|
|
|
4622
5030
|
}));
|
|
4623
5031
|
};
|
|
4624
5032
|
});
|
|
4625
|
-
utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
|
|
5033
|
+
utils$1.forEach(['post', 'put', 'patch', 'query'], function forEachMethodWithData(method) {
|
|
4626
5034
|
function generateHTTPMethod(isForm) {
|
|
4627
5035
|
return function httpMethod(url, data, config) {
|
|
4628
5036
|
return this.request(mergeConfig(config || {}, {
|
|
@@ -4636,7 +5044,12 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
|
|
|
4636
5044
|
};
|
|
4637
5045
|
}
|
|
4638
5046
|
Axios.prototype[method] = generateHTTPMethod();
|
|
4639
|
-
|
|
5047
|
+
|
|
5048
|
+
// QUERY is a safe/idempotent read method; multipart form bodies don't fit
|
|
5049
|
+
// its semantics, so no queryForm shorthand is generated.
|
|
5050
|
+
if (method !== 'query') {
|
|
5051
|
+
Axios.prototype[method + 'Form'] = generateHTTPMethod(true);
|
|
5052
|
+
}
|
|
4640
5053
|
});
|
|
4641
5054
|
|
|
4642
5055
|
/**
|