@openclaw/feishu 2026.8.1 → 2026.8.33
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/dist/{accounts-RwSyseKr.js → .setup/accounts-DCZXPMf6.mjs} +1 -1
- package/dist/{app-registration-BpfUzS9m.js → .setup/app-registration-Bv4mvauR.mjs} +12 -9
- package/dist/{channel-CnpfeyYb.js → .setup/channel-CO5F5WkL.mjs} +51 -38
- package/dist/{channel.runtime-BhBg13ML.js → .setup/channel.runtime-DWzq4CVp.mjs} +6 -6
- package/dist/{chat-BjgJQ9dk.js → .setup/chat-V7-Beo2B.mjs} +12 -9
- package/dist/{client-DalLmpMf.js → .setup/client-CUQ4wWhw.mjs} +3 -2
- package/dist/{doctor-contract-DpQKxB7B.js → .setup/doctor-contract-CQAuBotF.mjs} +3 -2
- package/dist/{json-response-CheljwGr.js → .setup/json-response-DXajw_FU.mjs} +1 -1
- package/dist/{monitor.startup-D-gL82OO.js → .setup/monitor-BKZ_54VY.mjs} +63 -3
- package/dist/{monitor.account-B6Fv45B2.js → .setup/monitor.account-ODF3HwGB.mjs} +82 -74
- package/dist/{probe-CfhhR_0a.js → .setup/probe-pM5QNz98.mjs} +4 -4
- package/dist/{reply-delivery-result-7Jezz03B.js → .setup/reply-delivery-result-I4WJJxN8.mjs} +24 -18
- package/dist/.setup/runtime-setter-api-CG-RC4_r.mjs +3 -0
- package/dist/.setup/secret-contract-api-jmCkqVLc.mjs +3 -0
- package/dist/{security-audit-D6Fz2h6p.js → .setup/security-audit-CmiKKfU-.mjs} +1 -1
- package/dist/{security-audit-shared-BgpY7AiJ.js → .setup/security-audit-shared-CK5rVR-1.mjs} +2 -1
- package/dist/{session-conversation-DFCIvQK-.js → .setup/session-conversation-ept8rWxJ.mjs} +1 -1
- package/dist/.setup/setup-api-B5hgT1EV.mjs +3 -0
- package/dist/{subagent-hooks-DOwDqgg7.js → .setup/subagent-hooks-CDN4TAXr.mjs} +4 -4
- package/dist/{thread-bindings-DlDOHuiJ.js → .setup/thread-bindings-BiL1wGqK.mjs} +19 -8
- package/dist/api.js +32 -28
- package/dist/channel-plugin-api.js +1 -1
- package/dist/contract-api.js +3 -3
- package/dist/doctor-contract-api.js +1 -1
- package/dist/runtime-api.js +1 -1
- package/dist/runtime-setter-api.js +1 -1
- package/dist/secret-contract-api.js +1 -1
- package/dist/security-contract-api.js +1 -1
- package/dist/session-binding-contract-api.js +1 -1
- package/dist/session-key-api.js +1 -1
- package/dist/setup-api.js +1 -1
- package/dist/setup-entry.js +4 -3
- package/dist/subagent-hooks-api.js +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/CHANGELOG.md +62 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/README.md +233 -5
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/axios.js +387 -89
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/axios.min.js +3 -3
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/axios.min.js.map +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/browser/axios.cjs +458 -98
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/esm/axios.js +458 -98
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/esm/axios.min.js +2 -2
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/esm/axios.min.js.map +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/dist/node/axios.cjs +568 -116
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/index.d.cts +4 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/index.d.ts +4 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/adapters/fetch.js +64 -11
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/adapters/http.js +134 -50
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/adapters/xhr.js +52 -3
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/Axios.js +19 -14
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/InterceptorManager.js +107 -8
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/buildFullPath.js +1 -13
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/dispatchRequest.js +8 -2
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/mergeConfig.js +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/core/methodList.js +17 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/defaults/index.js +2 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/env/data.js +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/Http2Sessions.js +2 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/HttpStatusCode.js +11 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/fromDataURI.js +5 -4
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/normalizeURLForProtocolCheck.js +24 -0
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/progressEventReducer.js +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/resolveConfig.js +4 -2
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/shouldBypassProxy.js +182 -6
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/throttle.js +3 -2
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/helpers/toFormData.js +14 -21
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/lib/utils.js +134 -13
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/axios/package.json +1 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/ws/lib/permessage-deflate.js +3 -1
- package/node_modules/@larksuiteoapi/node-sdk/node_modules/ws/package.json +1 -1
- package/node_modules/typebox/build/format/email.mjs +1 -1
- package/node_modules/typebox/build/format/idna/idn-hostname.mjs +19 -1
- package/node_modules/typebox/package.json +1 -1
- package/package.json +5 -5
- package/dist/monitor-DRVC2e_W.js +0 -62
- /package/dist/{audio-preflight.runtime-BBfC9elv.js → .setup/audio-preflight.runtime-BBfC9elv.mjs} +0 -0
- /package/dist/{conversation-id-VYgGQ-GX.js → .setup/conversation-id-VYgGQ-GX.mjs} +0 -0
- /package/dist/{rolldown-runtime-8H4AJuhK.js → .setup/rolldown-runtime-8H4AJuhK.mjs} +0 -0
- /package/dist/{runtime-C5JxBWZp.js → .setup/runtime-C5JxBWZp.mjs} +0 -0
- /package/dist/{secret-contract-BCpDLdg9.js → .setup/secret-contract-BCpDLdg9.mjs} +0 -0
- /package/dist/{targets-BUjQ1TcA.js → .setup/targets-BUjQ1TcA.mjs} +0 -0
package/dist/api.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { a as setFeishuNamedAccountEnabled, i as feishuSetupAdapter, n as feishuSetupWizard, r as runFeishuLogin, t as feishuPlugin } from "
|
|
2
|
-
import { B as resolveFeishuToolAccount, F as feishuExternalToolResult, I as toolExecutionErrorResult, L as unknownToolActionResult, P as registerFeishuDriveTools, R as createFeishuToolClient, et as chunkFeishuMarkdown, rt as parseFeishuMarkdown, z as resolveAnyEnabledFeishuToolsConfig } from "
|
|
3
|
-
import { a as parseFeishuTargetId, i as parseFeishuDirectConversationId, n as buildFeishuModelOverrideParentCandidates, r as parseFeishuConversationId, t as buildFeishuConversationId } from "
|
|
4
|
-
import { s as resolveConfiguredHttpTimeoutMs } from "
|
|
5
|
-
import { t as getFeishuRuntime } from "
|
|
6
|
-
import { o as registerFeishuChatTools } from "
|
|
7
|
-
import { n as getFeishuThreadBindingManager, t as createFeishuThreadBindingManager } from "
|
|
8
|
-
import { n as handleFeishuSubagentEnded, t as handleFeishuSubagentDeliveryTarget } from "
|
|
1
|
+
import { a as setFeishuNamedAccountEnabled, i as feishuSetupAdapter, n as feishuSetupWizard, r as runFeishuLogin, t as feishuPlugin } from "./.setup/channel-CO5F5WkL.mjs";
|
|
2
|
+
import { B as resolveFeishuToolAccount, F as feishuExternalToolResult, I as toolExecutionErrorResult, L as unknownToolActionResult, P as registerFeishuDriveTools, R as createFeishuToolClient, et as chunkFeishuMarkdown, rt as parseFeishuMarkdown, z as resolveAnyEnabledFeishuToolsConfig } from "./.setup/reply-delivery-result-I4WJJxN8.mjs";
|
|
3
|
+
import { a as parseFeishuTargetId, i as parseFeishuDirectConversationId, n as buildFeishuModelOverrideParentCandidates, r as parseFeishuConversationId, t as buildFeishuConversationId } from "./.setup/conversation-id-VYgGQ-GX.mjs";
|
|
4
|
+
import { s as resolveConfiguredHttpTimeoutMs } from "./.setup/client-CUQ4wWhw.mjs";
|
|
5
|
+
import { t as getFeishuRuntime } from "./.setup/runtime-C5JxBWZp.mjs";
|
|
6
|
+
import { o as registerFeishuChatTools } from "./.setup/chat-V7-Beo2B.mjs";
|
|
7
|
+
import { n as getFeishuThreadBindingManager, t as createFeishuThreadBindingManager } from "./.setup/thread-bindings-BiL1wGqK.mjs";
|
|
8
|
+
import { n as handleFeishuSubagentEnded, t as handleFeishuSubagentDeliveryTarget } from "./.setup/subagent-hooks-CDN4TAXr.mjs";
|
|
9
9
|
import { optionalPositiveIntegerSchema } from "openclaw/plugin-sdk/channel-actions";
|
|
10
10
|
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
|
|
11
11
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalString, readStringValue, uniqueStrings } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -902,7 +902,8 @@ function normalizeConvertedBlockTree(blocks, firstLevelIds) {
|
|
|
902
902
|
const parentId = typeof block?.parent_id === "string" ? block.parent_id : "";
|
|
903
903
|
return !childIds.has(blockId) && (!parentId || !byId.has(parentId));
|
|
904
904
|
}).toSorted((a, b) => (originalOrder.get(a.block_id ?? "__missing__") ?? 0) - (originalOrder.get(b.block_id ?? "__missing__") ?? 0)).map((block) => block.block_id).filter((blockId) => typeof blockId === "string");
|
|
905
|
-
const
|
|
905
|
+
const rootIds = (firstLevelIds && firstLevelIds.length > 0 ? firstLevelIds : inferredTopLevelIds).filter((id) => typeof id === "string" && byId.has(id));
|
|
906
|
+
const uniqueRootIds = uniqueStrings(rootIds);
|
|
906
907
|
const orderedBlocks = [];
|
|
907
908
|
const visited = /* @__PURE__ */ new Set();
|
|
908
909
|
const visit = (blockId) => {
|
|
@@ -1244,23 +1245,25 @@ async function createDoc(client, title, folderToken, options) {
|
|
|
1244
1245
|
let requesterPermissionAdded = false;
|
|
1245
1246
|
let requesterPermissionSkippedReason;
|
|
1246
1247
|
let requesterPermissionError;
|
|
1247
|
-
if (shouldGrantToRequester)
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1248
|
+
if (shouldGrantToRequester) {
|
|
1249
|
+
if (!requesterOpenId) requesterPermissionSkippedReason = "trusted requester identity unavailable";
|
|
1250
|
+
else try {
|
|
1251
|
+
await client.drive.permissionMember.create({
|
|
1252
|
+
path: { token: docToken },
|
|
1253
|
+
params: {
|
|
1254
|
+
type: "docx",
|
|
1255
|
+
need_notification: false
|
|
1256
|
+
},
|
|
1257
|
+
data: {
|
|
1258
|
+
member_type: "openid",
|
|
1259
|
+
member_id: requesterOpenId,
|
|
1260
|
+
perm: requesterPermType
|
|
1261
|
+
}
|
|
1262
|
+
});
|
|
1263
|
+
requesterPermissionAdded = true;
|
|
1264
|
+
} catch (err) {
|
|
1265
|
+
requesterPermissionError = formatErrorMessage(err);
|
|
1266
|
+
}
|
|
1264
1267
|
}
|
|
1265
1268
|
return {
|
|
1266
1269
|
document_id: docToken,
|
|
@@ -1627,14 +1630,15 @@ function registerFeishuDocTools(api) {
|
|
|
1627
1630
|
parameters: Type.Object({}),
|
|
1628
1631
|
async execute() {
|
|
1629
1632
|
try {
|
|
1630
|
-
|
|
1633
|
+
const result = await listAppScopes(createFeishuToolClient({
|
|
1631
1634
|
api,
|
|
1632
1635
|
defaultAccountId: ctx.agentAccountId,
|
|
1633
1636
|
requiredTool: {
|
|
1634
1637
|
family: "scopes",
|
|
1635
1638
|
label: "App Scopes"
|
|
1636
1639
|
}
|
|
1637
|
-
}))
|
|
1640
|
+
}));
|
|
1641
|
+
return feishuExternalToolResult(result);
|
|
1638
1642
|
} catch (err) {
|
|
1639
1643
|
return feishuExternalToolResult({ error: formatErrorMessage(err) });
|
|
1640
1644
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as feishuPlugin } from "
|
|
1
|
+
import { t as feishuPlugin } from "./.setup/channel-CO5F5WkL.mjs";
|
|
2
2
|
export { feishuPlugin };
|
package/dist/contract-api.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as parseFeishuTargetId, i as parseFeishuDirectConversationId, r as parseFeishuConversationId, t as buildFeishuConversationId } from "
|
|
2
|
-
import { t as messageActionTargetAliases } from "
|
|
3
|
-
import { t as collectFeishuSecurityAuditFindings } from "
|
|
1
|
+
import { a as parseFeishuTargetId, i as parseFeishuDirectConversationId, r as parseFeishuConversationId, t as buildFeishuConversationId } from "./.setup/conversation-id-VYgGQ-GX.mjs";
|
|
2
|
+
import { t as messageActionTargetAliases } from "./.setup/security-audit-CmiKKfU-.mjs";
|
|
3
|
+
import { t as collectFeishuSecurityAuditFindings } from "./.setup/security-audit-shared-CK5rVR-1.mjs";
|
|
4
4
|
export { buildFeishuConversationId, collectFeishuSecurityAuditFindings, messageActionTargetAliases, parseFeishuConversationId, parseFeishuDirectConversationId, parseFeishuTargetId };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "
|
|
1
|
+
import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./.setup/doctor-contract-CQAuBotF.mjs";
|
|
2
2
|
export { legacyConfigRules, normalizeCompatibilityConfig };
|
package/dist/runtime-api.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as setFeishuRuntime } from "
|
|
1
|
+
import { n as setFeishuRuntime } from "./.setup/runtime-C5JxBWZp.mjs";
|
|
2
2
|
import { createReplyPrefixContext } from "openclaw/plugin-sdk/channel-outbound";
|
|
3
3
|
import { createChannelPairingController } from "openclaw/plugin-sdk/channel-pairing";
|
|
4
4
|
import { PAIRING_APPROVED_MESSAGE, buildProbeChannelStatusSummary, createDefaultChannelRuntimeState } from "openclaw/plugin-sdk/channel-status";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as setFeishuRuntime } from "
|
|
1
|
+
import { n as setFeishuRuntime } from "./.setup/runtime-C5JxBWZp.mjs";
|
|
2
2
|
export { setFeishuRuntime };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "
|
|
1
|
+
import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "./.setup/secret-contract-BCpDLdg9.mjs";
|
|
2
2
|
export { channelSecrets, collectRuntimeConfigAssignments, secretTargetRegistryEntries };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as collectFeishuSecurityAuditFindings } from "
|
|
1
|
+
import { t as collectFeishuSecurityAuditFindings } from "./.setup/security-audit-shared-CK5rVR-1.mjs";
|
|
2
2
|
export { collectFeishuSecurityAuditFindings };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as createFeishuThreadBindingManager } from "
|
|
1
|
+
import { t as createFeishuThreadBindingManager } from "./.setup/thread-bindings-BiL1wGqK.mjs";
|
|
2
2
|
export { createFeishuThreadBindingManager };
|
package/dist/session-key-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as resolveFeishuSessionConversation } from "
|
|
1
|
+
import { t as resolveFeishuSessionConversation } from "./.setup/session-conversation-ept8rWxJ.mjs";
|
|
2
2
|
export { resolveFeishuSessionConversation as resolveSessionConversation };
|
package/dist/setup-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as feishuSetupAdapter, n as feishuSetupWizard, t as feishuPlugin } from "
|
|
1
|
+
import { i as feishuSetupAdapter, n as feishuSetupWizard, t as feishuPlugin } from "./.setup/channel-CO5F5WkL.mjs";
|
|
2
2
|
export { feishuPlugin, feishuSetupAdapter, feishuSetupWizard };
|
package/dist/setup-entry.js
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { defineBundledChannelSetupEntry } from "openclaw/plugin-sdk/channel-entry-contract";
|
|
2
|
+
import { fileURLToPath } from "node:url";
|
|
2
3
|
//#region extensions/feishu/setup-entry.ts
|
|
3
4
|
var setup_entry_default = defineBundledChannelSetupEntry({
|
|
4
5
|
importMetaUrl: import.meta.url,
|
|
5
6
|
plugin: {
|
|
6
|
-
specifier: "
|
|
7
|
+
specifier: fileURLToPath(new URL(".setup/setup-api-B5hgT1EV.mjs", import.meta.url).href),
|
|
7
8
|
exportName: "feishuPlugin"
|
|
8
9
|
},
|
|
9
10
|
secrets: {
|
|
10
|
-
specifier: "
|
|
11
|
+
specifier: fileURLToPath(new URL(".setup/secret-contract-api-jmCkqVLc.mjs", import.meta.url).href),
|
|
11
12
|
exportName: "channelSecrets"
|
|
12
13
|
},
|
|
13
14
|
runtime: {
|
|
14
|
-
specifier: "
|
|
15
|
+
specifier: fileURLToPath(new URL(".setup/runtime-setter-api-CG-RC4_r.mjs", import.meta.url).href),
|
|
15
16
|
exportName: "setFeishuRuntime"
|
|
16
17
|
}
|
|
17
18
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
|
|
2
2
|
//#region extensions/feishu/subagent-hooks-api.ts
|
|
3
|
-
const loadFeishuSubagentHooksModule = createLazyRuntimeModule(() => import("
|
|
3
|
+
const loadFeishuSubagentHooksModule = createLazyRuntimeModule(() => import("./.setup/subagent-hooks-CDN4TAXr.mjs").then((n) => n.r));
|
|
4
4
|
function registerFeishuSubagentHooks(api) {
|
|
5
5
|
api.on("subagent_delivery_target", async (event) => {
|
|
6
6
|
const { handleFeishuSubagentDeliveryTarget } = await loadFeishuSubagentHooksModule();
|
|
@@ -1,5 +1,67 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## v1.19.0 — July 22, 2026
|
|
4
|
+
|
|
5
|
+
This release raises the form-data security floor, adds configuration and type-system capabilities, and fixes NO_PROXY matching, interceptor errors, progress reporting, and serialization edge cases.
|
|
6
|
+
|
|
7
|
+
## 🔒 Security Fixes
|
|
8
|
+
|
|
9
|
+
- Multipart Form Data: Raised the form-data dependency floor to ^4.0.6, preventing fresh installations from resolving versions affected by the CRLF injection vulnerability GHSA-hmw2-7cc7-3qxx (https://github.com/advisories/GHSA-hmw2-7cc7-3qxx). (#11028)
|
|
10
|
+
|
|
11
|
+
## 🚀 New Features
|
|
12
|
+
|
|
13
|
+
- Configuration Extensibility: Preserved own-enumerable symbol-keyed fields through mergeConfig and added a generic params type across public TypeScript declarations, responses, errors,
|
|
14
|
+
adapters, and serializers. (#11043, #11081)
|
|
15
|
+
- Header Parameter Parsing: Added the opt-in AxiosHeaders.parseParameters() parser for quote-aware, RFC-style HTTP parameter parsing while preserving legacy parsing behavior. (#11051)
|
|
16
|
+
- HTTP Status Codes: Added the missing Cloudflare 520 WebServerReturnsAnUnknownError status and matching ESM/CJS declarations. (#11067)
|
|
17
|
+
|
|
18
|
+
## 🐛 Bug Fixes
|
|
19
|
+
|
|
20
|
+
- Form Data Conversion: Limited formDataToJSON path splitting to dot and bracket notation, preserving literal punctuation in keys, and removed browser-facing Buffer.from usage from toFormData to avoid unnecessary polyfills. (#11006, #11018)
|
|
21
|
+
- Proxy Bypass: Canonicalized IPv4 shorthand, octal, and hexadecimal forms during NO_PROXY matching and honored * entries within comma- or space-separated bypass lists. (#11029, #11053)
|
|
22
|
+
- Cancellation: Propagated already-aborted input signals immediately when composing abort signals. (#11035)
|
|
23
|
+
- Header Handling: Preserved empty first values for duplicate singleton headers and made AxiosHeaders#getSetCookie() consistently return arrays for present values. (#11036, #11037)
|
|
24
|
+
- URL Handling: Included normalized, safely redacted offending URLs in malformed-protocol errors and removed repeated trailing slashes when combining base URLs. (#11008, #11038)
|
|
25
|
+
|
|
26
|
+
- Progress Events: Clamped malformed negative progress values to zero and ensured final Node.js download progress events are delivered before streamed responses close. (#11039, #11040)
|
|
27
|
+
- Error and JSON Serialization: Serialized Set values as arrays in JSON-compatible snapshots and synthesized useful AxiosError messages from otherwise-empty AggregateError instances. (#11044, #11059)
|
|
28
|
+
- Content-Length Enforcement: Corrected base64 data: URL size estimation so maxContentLength is enforced consistently by the HTTP and Fetch adapters. (#11061)
|
|
29
|
+
- Synchronous Interceptors: Prevented requests from being dispatched after synchronous request interceptors fail unless their paired rejection handler resolves successfully. (#11071)
|
|
30
|
+
|
|
31
|
+
## 🔧 Maintenance & Chores
|
|
32
|
+
|
|
33
|
+
- Dependencies: Updated development and test tooling, the docs fixture's Axios version, and GitHub Actions integrations including Checkout, Setup Node, Setup Deno, and Zizmor. (#11031, #11055, #11056, #11058, #11079, #11080, #11088, #11089, #11090)
|
|
34
|
+
- Build Outputs: Limited sourcemap generation to published minified bundles, removing broken map references from non-minified builds. (#11054)
|
|
35
|
+
- Form Data Internals: Centralized FormData header handling and made the Node.js adapter tolerate getHeaders() returning undefined under the content-only policy. (#11062)
|
|
36
|
+
- Developer Experience: Ignored common local AI-tooling directories and fixed a constant-reassignment crash when the development sandbox serves its root path. (#11032, #11073)
|
|
37
|
+
- Documentation: Updated sponsor information, clarified that baseURL is not a path-security boundary, scoped provenance claims to attested releases, and corrected the configuration-defaults documentation. (#11041, #11068, #11076, #11078)
|
|
38
|
+
- Publishing: Simplified v1 publishing to use the npm version bundled with Node.js 26 and updated package metadata for the 1.19.0 release. (#11083, #11095)
|
|
39
|
+
|
|
40
|
+
## 🌟 New Contributors
|
|
41
|
+
|
|
42
|
+
We are thrilled to welcome our new contributors. Thank you for helping improve Axios:
|
|
43
|
+
|
|
44
|
+
- @afonsojramos (#11028)
|
|
45
|
+
- @MahinAnowar (#11006)
|
|
46
|
+
- @yassertawfik4 (#11024)
|
|
47
|
+
- @AnandSundar (#11029)
|
|
48
|
+
- @lin-hongkuan (#11035)
|
|
49
|
+
- @Wali007-lab (#11054)
|
|
50
|
+
- @magicdawn (#11043)
|
|
51
|
+
- @andrewkernel (#11053)
|
|
52
|
+
- @Sagargupta16 (#11059)
|
|
53
|
+
- @Rpaudel379 (#11078)
|
|
54
|
+
- @kobihikri (#11076)
|
|
55
|
+
- @spokodev (#11061)
|
|
56
|
+
- @shaedrich (#11081)
|
|
57
|
+
- @QodeXcli (#11062)
|
|
58
|
+
- @akahoshi1421 (#11067)
|
|
59
|
+
- @TheHonoredOne914 (#11071)
|
|
60
|
+
- @Ahsan1Murtaza (#11073)
|
|
61
|
+
|
|
62
|
+
[Full Changelog](https://github.com/axios/axios/compare/v1.18.1...v1.19.0)
|
|
63
|
+
|
|
64
|
+
|
|
3
65
|
## v1.18.0 — June 13, 2026
|
|
4
66
|
|
|
5
67
|
This release hardens redirect and URL handling, improves the validateStatus configuration semantics, and includes updates to documentation, dependencies, and release metadata.
|
|
@@ -349,6 +349,67 @@
|
|
|
349
349
|
>
|
|
350
350
|
</p>
|
|
351
351
|
</td>
|
|
352
|
+
<td align="center" width="33.333333333333336%">
|
|
353
|
+
<a
|
|
354
|
+
href="https://kasyno.us.com/?utm_source=axios_docs_website&utm_medium=website&utm_campaign=axios_open_collective_sponsorship"
|
|
355
|
+
style="padding: 10px; display: inline-block"
|
|
356
|
+
target="_blank"
|
|
357
|
+
>
|
|
358
|
+
<img
|
|
359
|
+
width="71px"
|
|
360
|
+
height="70px"
|
|
361
|
+
src="https://images.opencollective.com/polskie-kasyno-online/c25e456/avatar.png"
|
|
362
|
+
alt="polskie kasyno online"
|
|
363
|
+
/>
|
|
364
|
+
</a>
|
|
365
|
+
<p
|
|
366
|
+
align="center"
|
|
367
|
+
>
|
|
368
|
+
Kasyno.us.com to niezależny portal o tematyce kasyno online Polska, który pomaga graczom znaleźć bezpieczne i sprawdzone kasyna internetowe.
|
|
369
|
+
</p>
|
|
370
|
+
<p align="center">
|
|
371
|
+
<a
|
|
372
|
+
href="https://kasyno.us.com/?utm_source=axios_docs_website&utm_medium=website&utm_campaign=axios_open_collective_sponsorship"
|
|
373
|
+
target="_blank"
|
|
374
|
+
><b>kasyno.us.com</b></a
|
|
375
|
+
>
|
|
376
|
+
</p>
|
|
377
|
+
</td>
|
|
378
|
+
</tr>
|
|
379
|
+
<tr width="33.333333333333336%">
|
|
380
|
+
<td align="center" width="33.333333333333336%">
|
|
381
|
+
<a
|
|
382
|
+
href="https://www.scrapingbee.com/?utm_source=axios_docs_website&utm_medium=website&utm_campaign=axios_open_collective_sponsorship"
|
|
383
|
+
style="padding: 10px; display: inline-block"
|
|
384
|
+
target="_blank"
|
|
385
|
+
>
|
|
386
|
+
<img
|
|
387
|
+
width="90px"
|
|
388
|
+
height="90px"
|
|
389
|
+
src="https://images.opencollective.com/scrapingbee/6d5dc95/logo.png"
|
|
390
|
+
alt="ScrapingBee"
|
|
391
|
+
/>
|
|
392
|
+
</a>
|
|
393
|
+
<p
|
|
394
|
+
align="center"
|
|
395
|
+
>
|
|
396
|
+
Scrape websites with a powerful web scraping API without managing proxies, browsers, or anti-bot defenses.
|
|
397
|
+
</p>
|
|
398
|
+
<p align="center">
|
|
399
|
+
<a
|
|
400
|
+
href="https://www.scrapingbee.com/?utm_source=axios_docs_website&utm_medium=website&utm_campaign=axios_open_collective_sponsorship"
|
|
401
|
+
target="_blank"
|
|
402
|
+
><b>scrapingbee.com</b></a
|
|
403
|
+
>
|
|
404
|
+
</p>
|
|
405
|
+
</td>
|
|
406
|
+
<td align="center" width="33.333333333333336%">
|
|
407
|
+
<a
|
|
408
|
+
href="https://opencollective.com/axios/contribute"
|
|
409
|
+
target="_blank"
|
|
410
|
+
>💜 Become a sponsor</a
|
|
411
|
+
>
|
|
412
|
+
</td>
|
|
352
413
|
<td align="center" width="33.333333333333336%">
|
|
353
414
|
<a
|
|
354
415
|
href="https://opencollective.com/axios/contribute"
|
|
@@ -648,6 +709,7 @@ axios({
|
|
|
648
709
|
|
|
649
710
|
```js
|
|
650
711
|
// GET request for remote image in node.js
|
|
712
|
+
import fs from 'fs';
|
|
651
713
|
const response = await axios({
|
|
652
714
|
method: 'get',
|
|
653
715
|
url: 'https://bit.ly/2mTM3nY',
|
|
@@ -763,6 +825,8 @@ These config options are available for requests. Only `url` is required. Request
|
|
|
763
825
|
// `baseURL` is not a security boundary. If `url` is attacker-controlled, validate it
|
|
764
826
|
// before passing it to axios. Relative URLs can contain `..` segments that resolve
|
|
765
827
|
// outside an intended path prefix after the final URL is parsed.
|
|
828
|
+
// HTTP(S) URLs must include `//` after the protocol. Values such as
|
|
829
|
+
// `https:example.com` and `https:/example.com` are rejected with ERR_INVALID_URL.
|
|
766
830
|
baseURL: 'https://some-domain.com/api/',
|
|
767
831
|
|
|
768
832
|
// `allowAbsoluteUrls` determines whether or not absolute URLs will override a configured `baseUrl`.
|
|
@@ -1371,6 +1435,40 @@ axios.interceptors.request.use(
|
|
|
1371
1435
|
);
|
|
1372
1436
|
```
|
|
1373
1437
|
|
|
1438
|
+
If a synchronous request interceptor throws, Axios calls that interceptor's paired rejection handler and stops running the remaining request interceptors. A rejection handler that returns normally, including one that returns `undefined` or a fulfilled Promise, treats the error as handled: Axios dispatches the request with the last valid config, and ignores the handler's return value. To block dispatch, omit the rejection handler or throw/return a rejected Promise from it. The final error then continues through response rejection interceptors.
|
|
1439
|
+
|
|
1440
|
+
Use a rejected Promise when validation must prevent the request:
|
|
1441
|
+
|
|
1442
|
+
```js
|
|
1443
|
+
axios.interceptors.request.use(
|
|
1444
|
+
function validate(config) {
|
|
1445
|
+
if (!config.headers.has('Authorization')) {
|
|
1446
|
+
throw new Error('Authorization is required');
|
|
1447
|
+
}
|
|
1448
|
+
return config;
|
|
1449
|
+
},
|
|
1450
|
+
function rejectInvalidRequest(error) {
|
|
1451
|
+
return Promise.reject(error);
|
|
1452
|
+
},
|
|
1453
|
+
{ synchronous: true }
|
|
1454
|
+
);
|
|
1455
|
+
```
|
|
1456
|
+
|
|
1457
|
+
A logging-only rejection handler can return normally to preserve the existing request-continuation behavior:
|
|
1458
|
+
|
|
1459
|
+
```js
|
|
1460
|
+
axios.interceptors.request.use(
|
|
1461
|
+
function prepare(config) {
|
|
1462
|
+
throw new Error('Optional preparation failed');
|
|
1463
|
+
},
|
|
1464
|
+
function logPreparationFailure(error) {
|
|
1465
|
+
console.warn(error);
|
|
1466
|
+
// Returning normally dispatches with the last valid config.
|
|
1467
|
+
},
|
|
1468
|
+
{ synchronous: true }
|
|
1469
|
+
);
|
|
1470
|
+
```
|
|
1471
|
+
|
|
1374
1472
|
If you want to execute a particular interceptor based on a runtime check,
|
|
1375
1473
|
you can add a `runWhen` function to the options object. The request interceptor will not run **if and only if** the return
|
|
1376
1474
|
of `runWhen` is `false`. Axios calls the function with the config
|
|
@@ -1438,7 +1536,7 @@ When a response is fulfilled and multiple response interceptors are registered:
|
|
|
1438
1536
|
- If a fulfillment interceptor throws, Axios skips the next fulfillment interceptor and calls the next rejection interceptor.
|
|
1439
1537
|
- After the error is caught, later fulfillment interceptors run again, just like in a promise chain.
|
|
1440
1538
|
|
|
1441
|
-
Read [the interceptor tests](./
|
|
1539
|
+
Read [the interceptor tests](./tests/browser/interceptors.browser.test.js) to see all this in code.
|
|
1442
1540
|
|
|
1443
1541
|
## Error types
|
|
1444
1542
|
|
|
@@ -1496,6 +1594,10 @@ axios.get('/user/12345').catch(function (error) {
|
|
|
1496
1594
|
});
|
|
1497
1595
|
```
|
|
1498
1596
|
|
|
1597
|
+
Axios rejects an `http:` or `https:` request `url` or `baseURL` that omits `//` after the protocol. For example, `https:example.com` and `https:/example.com` reject with `AxiosError` code `ERR_INVALID_URL` instead of being silently normalized. Pass a well-formed URL such as `https://example.com`.
|
|
1598
|
+
|
|
1599
|
+
The error identifies the malformed URL, for example `Invalid URL "https:example.com": missing "//" after protocol`. To keep logs useful without leaking secrets, Axios reports the control-character-normalized URL with credentials, query parameter values, and fragment contents redacted; the scheme, host, path, and query parameter names remain visible.
|
|
1600
|
+
|
|
1499
1601
|
Use `validateStatus` to override the default condition (`status >= 200 && status < 300`) and choose which HTTP status codes should reject.
|
|
1500
1602
|
|
|
1501
1603
|
```js
|
|
@@ -1931,6 +2033,24 @@ formData.append('users[1][surname]', 'Anderson');
|
|
|
1931
2033
|
formData.append('obj2{}', '[{"x":1}]');
|
|
1932
2034
|
```
|
|
1933
2035
|
|
|
2036
|
+
### Converting FormData to JSON
|
|
2037
|
+
|
|
2038
|
+
`axios.formToJSON()` converts `FormData` field names that use dot or bracket notation into nested objects and arrays. Only `.`, `[`, and `]` are structural separators. Other characters, including `-`, spaces, `+`, `*`, and `&`, remain part of the literal key.
|
|
2039
|
+
|
|
2040
|
+
```js
|
|
2041
|
+
const form = new FormData();
|
|
2042
|
+
form.append('user-name', 'johndoe');
|
|
2043
|
+
form.append('user.name', 'john');
|
|
2044
|
+
|
|
2045
|
+
console.log(axios.formToJSON(form));
|
|
2046
|
+
// {
|
|
2047
|
+
// 'user-name': 'johndoe',
|
|
2048
|
+
// user: { name: 'john' }
|
|
2049
|
+
// }
|
|
2050
|
+
```
|
|
2051
|
+
|
|
2052
|
+
`user[name]` also creates `{ user: { name: ... } }`, while `items[]` creates an array.
|
|
2053
|
+
|
|
1934
2054
|
Axios supports `postForm`, `putForm`, and `patchForm` as shortcuts for the matching HTTP methods with the `Content-Type` header preset to `multipart/form-data`.
|
|
1935
2055
|
|
|
1936
2056
|
## Posting files
|
|
@@ -2004,10 +2124,9 @@ submits this JSON object:
|
|
|
2004
2124
|
{
|
|
2005
2125
|
"foo": "1",
|
|
2006
2126
|
"deep": {
|
|
2007
|
-
"prop":
|
|
2008
|
-
"spaced": "3"
|
|
2009
|
-
}
|
|
2127
|
+
"prop": "2"
|
|
2010
2128
|
},
|
|
2129
|
+
"deep prop spaced": "3",
|
|
2011
2130
|
"baz": [
|
|
2012
2131
|
"4",
|
|
2013
2132
|
"5"
|
|
@@ -2018,6 +2137,8 @@ submits this JSON object:
|
|
|
2018
2137
|
}
|
|
2019
2138
|
```
|
|
2020
2139
|
|
|
2140
|
+
Only dot and bracket notation create nested paths when a form is converted to JSON. Spaces and other punctuation remain part of literal field names.
|
|
2141
|
+
|
|
2021
2142
|
Sending `Blobs`/`Files` as JSON (`base64`) is not currently supported.
|
|
2022
2143
|
|
|
2023
2144
|
## Progress capturing
|
|
@@ -2246,8 +2367,9 @@ Returns `this`.
|
|
|
2246
2367
|
### AxiosHeaders#get(header)
|
|
2247
2368
|
|
|
2248
2369
|
```
|
|
2249
|
-
get(headerName: string,
|
|
2370
|
+
get(headerName: string, parser: typeof AxiosHeaders.parseParameters): AxiosHeaderParameters;
|
|
2250
2371
|
get(headerName: string, parser: RegExp): RegExpExecArray | null;
|
|
2372
|
+
get(headerName: string, matcher?: true | AxiosHeaderParser): AxiosHeaderValue;
|
|
2251
2373
|
```
|
|
2252
2374
|
|
|
2253
2375
|
Returns the internal value of the header. It can take an extra argument to parse the header's value with `RegExp.exec`,
|
|
@@ -2267,6 +2389,15 @@ console.log(headers.get('Content-Type', true)); // parse key-value pairs from a
|
|
|
2267
2389
|
// boundary: 'Asrf456BGe4h'
|
|
2268
2390
|
// }
|
|
2269
2391
|
|
|
2392
|
+
const quotedHeaders = new AxiosHeaders({
|
|
2393
|
+
'Content-Type': 'multipart/form-data; boundary="a,b"',
|
|
2394
|
+
});
|
|
2395
|
+
|
|
2396
|
+
console.log({
|
|
2397
|
+
...quotedHeaders.get('Content-Type', AxiosHeaders.parseParameters),
|
|
2398
|
+
});
|
|
2399
|
+
// { boundary: 'a,b' }
|
|
2400
|
+
|
|
2270
2401
|
console.log(
|
|
2271
2402
|
headers.get('Content-Type', (value, name, headers) => {
|
|
2272
2403
|
return String(value).replace(/a/g, 'ZZZ');
|
|
@@ -2278,6 +2409,10 @@ console.log(headers.get('Content-Type', /boundary=(\w+)/)?.[0]);
|
|
|
2278
2409
|
// boundary=Asrf456BGe4h
|
|
2279
2410
|
```
|
|
2280
2411
|
|
|
2412
|
+
`AxiosHeaders.parseParameters` is the opt-in parser for normalized HTTP parameter values. It returns a null-prototype map, matches parameter names case-insensitively, removes quoted-string delimiters, decodes escaped quotes and backslashes, preserves commas and semicolons inside quoted values, and removes only HTTP optional whitespace around unquoted values. It omits the unsafe keys `__proto__`, `constructor`, and `prototype`.
|
|
2413
|
+
|
|
2414
|
+
Passing `true` remains the legacy tokenizer and keeps its existing output for backward compatibility.
|
|
2415
|
+
|
|
2281
2416
|
Returns the value of the header.
|
|
2282
2417
|
|
|
2283
2418
|
### AxiosHeaders#has(header, matcher?)
|
|
@@ -2562,6 +2697,99 @@ try {
|
|
|
2562
2697
|
}
|
|
2563
2698
|
```
|
|
2564
2699
|
|
|
2700
|
+
### Typing request data and query params
|
|
2701
|
+
|
|
2702
|
+
`AxiosRequestConfig<D = any, P = any>` uses `D` for the request body and `P` for query parameters. The params serializer receives the same `P`, and both types are preserved on the default response config:
|
|
2703
|
+
|
|
2704
|
+
```typescript
|
|
2705
|
+
import axios, {
|
|
2706
|
+
type AxiosPromise,
|
|
2707
|
+
type AxiosRequestConfig,
|
|
2708
|
+
type InternalAxiosRequestConfig,
|
|
2709
|
+
} from 'axios';
|
|
2710
|
+
|
|
2711
|
+
interface RequestBody {
|
|
2712
|
+
includeArchived: boolean;
|
|
2713
|
+
}
|
|
2714
|
+
|
|
2715
|
+
interface SearchParams {
|
|
2716
|
+
query: string;
|
|
2717
|
+
page?: number;
|
|
2718
|
+
}
|
|
2719
|
+
|
|
2720
|
+
interface SearchResponse {
|
|
2721
|
+
results: string[];
|
|
2722
|
+
}
|
|
2723
|
+
|
|
2724
|
+
const config: AxiosRequestConfig<RequestBody, SearchParams> = {
|
|
2725
|
+
data: { includeArchived: false },
|
|
2726
|
+
params: { query: 'axios', page: 1 },
|
|
2727
|
+
paramsSerializer: (params) => `${params.query}:${params.page ?? 1}`,
|
|
2728
|
+
};
|
|
2729
|
+
|
|
2730
|
+
const response = await axios.get('/search', config);
|
|
2731
|
+
response.config.data; // RequestBody | undefined
|
|
2732
|
+
response.config.params; // SearchParams | undefined
|
|
2733
|
+
|
|
2734
|
+
const invalidConfig: AxiosRequestConfig<RequestBody, SearchParams> = {
|
|
2735
|
+
// @ts-expect-error `query` must be a string
|
|
2736
|
+
params: { query: 123 },
|
|
2737
|
+
};
|
|
2738
|
+
|
|
2739
|
+
const adapter = (
|
|
2740
|
+
adapterConfig: InternalAxiosRequestConfig<RequestBody, SearchParams>
|
|
2741
|
+
): AxiosPromise<SearchResponse, RequestBody, SearchParams> =>
|
|
2742
|
+
Promise.resolve({
|
|
2743
|
+
data: { results: [] },
|
|
2744
|
+
status: 200,
|
|
2745
|
+
statusText: 'OK',
|
|
2746
|
+
headers: {},
|
|
2747
|
+
config: adapterConfig,
|
|
2748
|
+
});
|
|
2749
|
+
```
|
|
2750
|
+
|
|
2751
|
+
The request methods place `P` last—`<T, R, D, P>`—so the existing response data (`T`), custom response (`R`), and request data (`D`) positions do not change. Explicit custom response types still determine the resolved value. `RawAxiosRequestConfig`, `InternalAxiosRequestConfig`, defaults, `AxiosResponse`, `AxiosPromise<T, D, P>`, `AxiosError`, `CanceledError`, callable instances, adapters, and `mergeConfig()` also carry `P`. The default is `any` for backward compatibility.
|
|
2752
|
+
|
|
2753
|
+
Use all three public error generics when cancellation narrowing must retain the response, request body, and params types:
|
|
2754
|
+
|
|
2755
|
+
```typescript
|
|
2756
|
+
declare const error: unknown;
|
|
2757
|
+
|
|
2758
|
+
if (axios.isCancel<SearchResponse, RequestBody, SearchParams>(error)) {
|
|
2759
|
+
error.config?.data; // RequestBody | undefined
|
|
2760
|
+
error.config?.params; // SearchParams | undefined
|
|
2761
|
+
}
|
|
2762
|
+
```
|
|
2763
|
+
|
|
2764
|
+
### Symbol-keyed custom request config
|
|
2765
|
+
|
|
2766
|
+
Own enumerable symbol properties survive config merging, so module-augmented options can reach request interceptors and adapters:
|
|
2767
|
+
|
|
2768
|
+
```typescript
|
|
2769
|
+
import axios from 'axios';
|
|
2770
|
+
|
|
2771
|
+
export const someFlag: unique symbol = Symbol(
|
|
2772
|
+
'some flag used in request interceptor'
|
|
2773
|
+
);
|
|
2774
|
+
|
|
2775
|
+
declare module 'axios' {
|
|
2776
|
+
interface AxiosRequestConfig<D = any, P = any> {
|
|
2777
|
+
[someFlag]?: boolean;
|
|
2778
|
+
}
|
|
2779
|
+
}
|
|
2780
|
+
|
|
2781
|
+
axios.interceptors.request.use((config) => {
|
|
2782
|
+
if (config[someFlag]) {
|
|
2783
|
+
config.headers.set('X-Some-Flag', 'enabled');
|
|
2784
|
+
}
|
|
2785
|
+
return config;
|
|
2786
|
+
});
|
|
2787
|
+
|
|
2788
|
+
await axios.get('/users', { [someFlag]: true });
|
|
2789
|
+
```
|
|
2790
|
+
|
|
2791
|
+
Only own enumerable symbol properties are copied; inherited and non-enumerable symbol properties are not.
|
|
2792
|
+
|
|
2565
2793
|
Because axios publishes an ESM default export and a CJS `module.exports`, TypeScript has a few caveats.
|
|
2566
2794
|
The recommended setting is `"moduleResolution": "node16"`, which is implied by `"module": "node16"`. This requires TypeScript 4.7 or greater.
|
|
2567
2795
|
If you use ESM, your settings should be fine.
|