@openclaw/firecrawl-plugin 2026.8.1 → 2026.8.2
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/api.js +12 -11
- package/dist/{firecrawl-client-7vlACkO2.js → firecrawl-client-BPFpIblh.js} +5 -3
- package/dist/{firecrawl-fetch-provider-dks9C772.js → firecrawl-fetch-provider-CIpxLKLq.js} +1 -1
- package/dist/{firecrawl-free-search-provider-DF-3FKe3.js → firecrawl-free-search-provider-BEyEhOfR.js} +2 -2
- package/dist/index.js +3 -3
- package/dist/web-fetch-contract-api.js +1 -1
- package/dist/web-fetch-provider.js +1 -1
- package/dist/web-search-contract-api.js +1 -1
- package/dist/web-search-provider.js +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/api.js
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
|
-
import { n as runFirecrawlScrape } from "./firecrawl-client-
|
|
1
|
+
import { n as runFirecrawlScrape } from "./firecrawl-client-BPFpIblh.js";
|
|
2
2
|
import { readStringValue } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
3
3
|
//#region extensions/firecrawl/api.ts
|
|
4
4
|
async function fetchFirecrawlContent(params) {
|
|
5
|
+
const cfg = { plugins: { entries: { firecrawl: {
|
|
6
|
+
enabled: true,
|
|
7
|
+
config: { webFetch: {
|
|
8
|
+
apiKey: params.apiKey,
|
|
9
|
+
baseUrl: params.baseUrl,
|
|
10
|
+
onlyMainContent: params.onlyMainContent,
|
|
11
|
+
maxAgeMs: params.maxAgeMs,
|
|
12
|
+
timeoutSeconds: params.timeoutSeconds
|
|
13
|
+
} }
|
|
14
|
+
} } } };
|
|
5
15
|
const result = await runFirecrawlScrape({
|
|
6
|
-
cfg
|
|
7
|
-
enabled: true,
|
|
8
|
-
config: { webFetch: {
|
|
9
|
-
apiKey: params.apiKey,
|
|
10
|
-
baseUrl: params.baseUrl,
|
|
11
|
-
onlyMainContent: params.onlyMainContent,
|
|
12
|
-
maxAgeMs: params.maxAgeMs,
|
|
13
|
-
timeoutSeconds: params.timeoutSeconds
|
|
14
|
-
} }
|
|
15
|
-
} } } },
|
|
16
|
+
cfg,
|
|
16
17
|
url: params.url,
|
|
17
18
|
extractMode: params.extractMode,
|
|
18
19
|
maxChars: params.maxChars,
|
|
@@ -77,7 +77,8 @@ function resolveFirecrawlMaxAgeMs(cfg, override) {
|
|
|
77
77
|
return DEFAULT_FIRECRAWL_MAX_AGE_MS;
|
|
78
78
|
}
|
|
79
79
|
function resolveFirecrawlScrapeTimeoutSeconds(cfg, override) {
|
|
80
|
-
|
|
80
|
+
const fetch = resolveFirecrawlFetchConfig(cfg);
|
|
81
|
+
return resolvePositiveTimeoutSeconds(override, resolvePositiveTimeoutSeconds(fetch?.timeoutSeconds, DEFAULT_FIRECRAWL_SCRAPE_TIMEOUT_SECONDS));
|
|
81
82
|
}
|
|
82
83
|
function resolveFirecrawlSearchTimeoutSeconds(override) {
|
|
83
84
|
return resolvePositiveTimeoutSeconds(override, DEFAULT_FIRECRAWL_SEARCH_TIMEOUT_SECONDS);
|
|
@@ -98,7 +99,7 @@ const FIRECRAWL_SEARCH_MAX_CONTENT_CHARS = 2e4;
|
|
|
98
99
|
const DEFAULT_SCRAPE_MAX_CHARS = 5e4;
|
|
99
100
|
const FIRECRAWL_SCRAPE_METADATA_MAX_CHARS = 4e3;
|
|
100
101
|
const FIRECRAWL_RESULT_URL_MAX_CHARS = 2048;
|
|
101
|
-
const FIRECRAWL_SCRAPE_RESPONSE_MAX_BYTES =
|
|
102
|
+
const FIRECRAWL_SCRAPE_RESPONSE_MAX_BYTES = 67108864;
|
|
102
103
|
const ALLOWED_FIRECRAWL_HOSTS = /* @__PURE__ */ new Set(["api.firecrawl.dev"]);
|
|
103
104
|
const FIRECRAWL_PUBLISHED_DATE_RE = /^\d{4}-\d{2}-\d{2}(?:[T ][\d:.+Z-]{0,20})?$/u;
|
|
104
105
|
const FIRECRAWL_SELF_HOSTED_PRIVATE_ERROR = "Firecrawl custom baseUrl must target a private or internal self-hosted endpoint.";
|
|
@@ -368,7 +369,8 @@ async function runFirecrawlSearch(params) {
|
|
|
368
369
|
}, async (response) => {
|
|
369
370
|
const payloadValue = await readProviderJsonObjectResponse(response, "Firecrawl Search API error");
|
|
370
371
|
if (payloadValue.success === false) {
|
|
371
|
-
const
|
|
372
|
+
const error = typeof payloadValue.error === "string" ? payloadValue.error : typeof payloadValue.message === "string" ? payloadValue.message : "unknown error";
|
|
373
|
+
const safeError = wrapWebContent(truncateSanitizedExternalContent(error, 1e3).text, "web_search");
|
|
372
374
|
throw new Error(`Firecrawl Search API error: ${safeError}`);
|
|
373
375
|
}
|
|
374
376
|
return payloadValue;
|
|
@@ -51,7 +51,7 @@ const FIRECRAWL_WEB_FETCH_PROVIDER_SHARED = {
|
|
|
51
51
|
};
|
|
52
52
|
//#endregion
|
|
53
53
|
//#region extensions/firecrawl/src/firecrawl-fetch-provider.ts
|
|
54
|
-
const loadFirecrawlClientModule = createLazyRuntimeModule(() => import("./firecrawl-client-
|
|
54
|
+
const loadFirecrawlClientModule = createLazyRuntimeModule(() => import("./firecrawl-client-BPFpIblh.js").then((n) => n.t));
|
|
55
55
|
function createFirecrawlWebFetchProvider() {
|
|
56
56
|
return {
|
|
57
57
|
...FIRECRAWL_WEB_FETCH_PROVIDER_SHARED,
|
|
@@ -2,7 +2,7 @@ import { buildFirecrawlFreeWebSearchProviderBase, buildFirecrawlWebSearchProvide
|
|
|
2
2
|
import { createLazyRuntimeModule } from "openclaw/plugin-sdk/lazy-runtime";
|
|
3
3
|
import { readPositiveIntegerParam } from "openclaw/plugin-sdk/param-readers";
|
|
4
4
|
//#region extensions/firecrawl/src/firecrawl-search-provider.ts
|
|
5
|
-
const loadFirecrawlClientModule$1 = createLazyRuntimeModule(() => import("./firecrawl-client-
|
|
5
|
+
const loadFirecrawlClientModule$1 = createLazyRuntimeModule(() => import("./firecrawl-client-BPFpIblh.js").then((n) => n.t));
|
|
6
6
|
const GenericFirecrawlSearchSchema = {
|
|
7
7
|
type: "object",
|
|
8
8
|
properties: {
|
|
@@ -43,7 +43,7 @@ function createFirecrawlWebSearchProvider() {
|
|
|
43
43
|
}
|
|
44
44
|
//#endregion
|
|
45
45
|
//#region extensions/firecrawl/src/firecrawl-free-search-provider.ts
|
|
46
|
-
const loadFirecrawlClientModule = createLazyRuntimeModule(() => import("./firecrawl-client-
|
|
46
|
+
const loadFirecrawlClientModule = createLazyRuntimeModule(() => import("./firecrawl-client-BPFpIblh.js").then((n) => n.t));
|
|
47
47
|
function createFirecrawlFreeWebSearchProvider() {
|
|
48
48
|
return {
|
|
49
49
|
...buildFirecrawlFreeWebSearchProviderBase(),
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as runFirecrawlScrape, r as runFirecrawlSearch } from "./firecrawl-client-
|
|
2
|
-
import { t as createFirecrawlWebFetchProvider } from "./firecrawl-fetch-provider-
|
|
3
|
-
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-
|
|
1
|
+
import { n as runFirecrawlScrape, r as runFirecrawlSearch } from "./firecrawl-client-BPFpIblh.js";
|
|
2
|
+
import { t as createFirecrawlWebFetchProvider } from "./firecrawl-fetch-provider-CIpxLKLq.js";
|
|
3
|
+
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-BEyEhOfR.js";
|
|
4
4
|
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
|
5
5
|
import { optionalStringEnum } from "openclaw/plugin-sdk/channel-actions";
|
|
6
6
|
import { jsonResult, readNonNegativeIntegerParam, readPositiveIntegerParam, readStringArrayParam, readStringParam } from "openclaw/plugin-sdk/provider-web-search";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as createFirecrawlWebFetchProvider } from "./firecrawl-fetch-provider-
|
|
1
|
+
import { t as createFirecrawlWebFetchProvider } from "./firecrawl-fetch-provider-CIpxLKLq.js";
|
|
2
2
|
export { createFirecrawlWebFetchProvider };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-
|
|
1
|
+
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-BEyEhOfR.js";
|
|
2
2
|
import "./web-search-provider.js";
|
|
3
3
|
export { createFirecrawlFreeWebSearchProvider, createFirecrawlWebSearchProvider };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-
|
|
1
|
+
import { n as createFirecrawlWebSearchProvider, t as createFirecrawlFreeWebSearchProvider } from "./firecrawl-free-search-provider-BEyEhOfR.js";
|
|
2
2
|
export { createFirecrawlFreeWebSearchProvider, createFirecrawlWebSearchProvider };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const Email = /^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[^"\\]
|
|
1
|
+
const Email = /^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[^"\\]|\\[\x20-\x7e])*")@(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*|\[(?:IPv6:[a-f0-9:]+|(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])(?:\.(?:25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9]?[0-9])){3})\])$/i;
|
|
2
2
|
/**
|
|
3
3
|
* Returns true if the value is an Email
|
|
4
4
|
* @specification https://datatracker.ietf.org/doc/html/rfc5322
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import * as FormatBidi from './format/bidi.mjs';
|
|
2
2
|
import * as LabelUnicode from './label/unicode.mjs';
|
|
3
3
|
import * as LabelPuny from './label/puny.mjs';
|
|
4
|
+
// ------------------------------------------------------------------
|
|
5
|
+
// IsLabel
|
|
6
|
+
// ------------------------------------------------------------------
|
|
4
7
|
function IsValidLabelLength(value) {
|
|
5
8
|
return value.length > 0 && value.length <= 63;
|
|
6
9
|
}
|
|
@@ -8,9 +11,24 @@ function IsLabel(value) {
|
|
|
8
11
|
return IsValidLabelLength(value) && (LabelPuny.IsPunyLabel(value) ||
|
|
9
12
|
LabelUnicode.IsUnicodeLabel(value));
|
|
10
13
|
}
|
|
14
|
+
// ------------------------------------------------------------------
|
|
15
|
+
// NormalizeHostname
|
|
16
|
+
//
|
|
17
|
+
// Normalizes a hostname for label validation. Normalizes for NFC
|
|
18
|
+
// such that equivalent codepoint sequences can be uniformly
|
|
19
|
+
// compared. It also removes codepoints that IDNA mapping ignores,
|
|
20
|
+
// and converts full stop variants to ASCII '.' so the hostname can
|
|
21
|
+
// be split into labels.
|
|
22
|
+
// ------------------------------------------------------------------
|
|
11
23
|
function NormalizeHostname(value) {
|
|
12
|
-
return value
|
|
24
|
+
return value
|
|
25
|
+
.normalize('NFC')
|
|
26
|
+
.replace(/[\u00ad\u034f\u180b-\u180d\u200b\ufe00-\ufe0f\u{e0100}-\u{e01ef}]/gu, '') // RE_IGNORED_MAPPING
|
|
27
|
+
.replace(/[\u002E\u3002\uFF0E\uFF61]/g, '.'); // RE_FULL_STOP_MAPPING
|
|
13
28
|
}
|
|
29
|
+
// ------------------------------------------------------------------
|
|
30
|
+
// IsIdnHostname
|
|
31
|
+
// ------------------------------------------------------------------
|
|
14
32
|
export function IsIdnHostname(value) {
|
|
15
33
|
if (value.length === 0 || value.includes(' '))
|
|
16
34
|
return false;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/firecrawl-plugin",
|
|
3
|
-
"version": "2026.8.
|
|
3
|
+
"version": "2026.8.2",
|
|
4
4
|
"description": "OpenClaw Firecrawl plugin.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
},
|
|
9
9
|
"type": "module",
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"typebox": "1.3.
|
|
11
|
+
"typebox": "1.3.17",
|
|
12
12
|
"zod": "4.4.3"
|
|
13
13
|
},
|
|
14
14
|
"openclaw": {
|
|
@@ -22,10 +22,10 @@
|
|
|
22
22
|
"minHostVersion": ">=2026.6.8"
|
|
23
23
|
},
|
|
24
24
|
"compat": {
|
|
25
|
-
"pluginApi": ">=2026.8.
|
|
25
|
+
"pluginApi": ">=2026.8.2"
|
|
26
26
|
},
|
|
27
27
|
"build": {
|
|
28
|
-
"openclawVersion": "2026.8.
|
|
28
|
+
"openclawVersion": "2026.8.2",
|
|
29
29
|
"bundledDist": false
|
|
30
30
|
},
|
|
31
31
|
"release": {
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"README.md"
|
|
43
43
|
],
|
|
44
44
|
"peerDependencies": {
|
|
45
|
-
"openclaw": ">=2026.8.
|
|
45
|
+
"openclaw": ">=2026.8.2"
|
|
46
46
|
},
|
|
47
47
|
"peerDependenciesMeta": {
|
|
48
48
|
"openclaw": {
|