firecrawl 4.31.0 → 4.31.1
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/{chunk-PSTSUWZW.js → chunk-BEF2NAMB.js} +1 -17
- package/dist/index.cjs +1 -17
- package/dist/index.d.cts +12 -6
- package/dist/index.d.ts +12 -6
- package/dist/index.js +2 -2
- package/dist/{package-Q3WPQZ6Q.js → package-GIVYQAT4.js} +1 -1
- package/package.json +1 -1
- package/pnpm-workspace.yaml +13 -0
- package/src/__tests__/unit/v2/audit-metadata.unit.test.ts +1 -1
- package/src/v1/index.ts +6 -2
- package/src/v2/methods/agent.ts +2 -2
- package/src/v2/types.ts +6 -2
|
@@ -12,7 +12,7 @@ var require_package = __commonJS({
|
|
|
12
12
|
"package.json"(exports, module) {
|
|
13
13
|
module.exports = {
|
|
14
14
|
name: "@mendable/firecrawl-js",
|
|
15
|
-
version: "4.31.
|
|
15
|
+
version: "4.31.1",
|
|
16
16
|
description: "JavaScript SDK for Firecrawl API",
|
|
17
17
|
main: "dist/index.js",
|
|
18
18
|
types: "dist/index.d.ts",
|
|
@@ -73,22 +73,6 @@ var require_package = __commonJS({
|
|
|
73
73
|
],
|
|
74
74
|
engines: {
|
|
75
75
|
node: ">=22.0.0"
|
|
76
|
-
},
|
|
77
|
-
pnpm: {
|
|
78
|
-
overrides: {
|
|
79
|
-
"@isaacs/brace-expansion@<=5.0.0": ">=5.0.1",
|
|
80
|
-
"minimatch@<10.2.3": ">=10.2.3",
|
|
81
|
-
"rollup@<4.59.0": ">=4.59.0",
|
|
82
|
-
"picomatch@<4.0.4": ">=4.0.4",
|
|
83
|
-
handlebars: ">=4.7.9",
|
|
84
|
-
"brace-expansion@>=5.0.0 <5.0.7": "5.0.7",
|
|
85
|
-
"js-yaml@>=3.0.0 <3.15.0": "3.15.0",
|
|
86
|
-
"axios@>=1.0.0 <1.16.0": "1.16.1",
|
|
87
|
-
"follow-redirects@<1.16.0": ">=1.16.0 <2.0.0",
|
|
88
|
-
"form-data@>=4.0.0 <4.0.6": "4.0.6",
|
|
89
|
-
"@babel/core@>=7.0.0 <7.29.6": "7.29.7",
|
|
90
|
-
"esbuild@>=0.17.0 <0.28.1": "0.28.1"
|
|
91
|
-
}
|
|
92
76
|
}
|
|
93
77
|
};
|
|
94
78
|
}
|
package/dist/index.cjs
CHANGED
|
@@ -39,7 +39,7 @@ var require_package = __commonJS({
|
|
|
39
39
|
"package.json"(exports2, module2) {
|
|
40
40
|
module2.exports = {
|
|
41
41
|
name: "@mendable/firecrawl-js",
|
|
42
|
-
version: "4.31.
|
|
42
|
+
version: "4.31.1",
|
|
43
43
|
description: "JavaScript SDK for Firecrawl API",
|
|
44
44
|
main: "dist/index.js",
|
|
45
45
|
types: "dist/index.d.ts",
|
|
@@ -100,22 +100,6 @@ var require_package = __commonJS({
|
|
|
100
100
|
],
|
|
101
101
|
engines: {
|
|
102
102
|
node: ">=22.0.0"
|
|
103
|
-
},
|
|
104
|
-
pnpm: {
|
|
105
|
-
overrides: {
|
|
106
|
-
"@isaacs/brace-expansion@<=5.0.0": ">=5.0.1",
|
|
107
|
-
"minimatch@<10.2.3": ">=10.2.3",
|
|
108
|
-
"rollup@<4.59.0": ">=4.59.0",
|
|
109
|
-
"picomatch@<4.0.4": ">=4.0.4",
|
|
110
|
-
handlebars: ">=4.7.9",
|
|
111
|
-
"brace-expansion@>=5.0.0 <5.0.7": "5.0.7",
|
|
112
|
-
"js-yaml@>=3.0.0 <3.15.0": "3.15.0",
|
|
113
|
-
"axios@>=1.0.0 <1.16.0": "1.16.1",
|
|
114
|
-
"follow-redirects@<1.16.0": ">=1.16.0 <2.0.0",
|
|
115
|
-
"form-data@>=4.0.0 <4.0.6": "4.0.6",
|
|
116
|
-
"@babel/core@>=7.0.0 <7.29.6": "7.29.7",
|
|
117
|
-
"esbuild@>=0.17.0 <0.28.1": "0.28.1"
|
|
118
|
-
}
|
|
119
103
|
}
|
|
120
104
|
};
|
|
121
105
|
}
|
package/dist/index.d.cts
CHANGED
|
@@ -114,6 +114,9 @@ interface PDFAction {
|
|
|
114
114
|
scale?: number;
|
|
115
115
|
}
|
|
116
116
|
type ActionOption = WaitAction | ScreenshotAction | ClickAction | WriteAction | PressAction | ScrollAction | ScrapeAction | ExecuteJavascriptAction | PDFAction;
|
|
117
|
+
interface AuditMetadata$1 {
|
|
118
|
+
username: string;
|
|
119
|
+
}
|
|
117
120
|
interface ScrapeOptions {
|
|
118
121
|
formats?: FormatOption[];
|
|
119
122
|
headers?: Record<string, string>;
|
|
@@ -142,7 +145,7 @@ interface ScrapeOptions {
|
|
|
142
145
|
lockdown?: boolean;
|
|
143
146
|
redactPII?: boolean | RedactPIIOptions;
|
|
144
147
|
threatProtection?: ThreatProtectionOptions;
|
|
145
|
-
auditMetadata?:
|
|
148
|
+
auditMetadata?: AuditMetadata$1;
|
|
146
149
|
profile?: {
|
|
147
150
|
name: string;
|
|
148
151
|
saveChanges?: boolean;
|
|
@@ -636,7 +639,7 @@ interface MapOptions {
|
|
|
636
639
|
origin?: string;
|
|
637
640
|
location?: LocationConfig$1;
|
|
638
641
|
threatProtection?: ThreatProtectionOptions;
|
|
639
|
-
auditMetadata?:
|
|
642
|
+
auditMetadata?: AuditMetadata$1;
|
|
640
643
|
}
|
|
641
644
|
type FeedbackRating = "good" | "partial" | "bad";
|
|
642
645
|
type EndpointFeedbackEndpoint = "search" | "scrape" | "parse" | "map";
|
|
@@ -1296,7 +1299,7 @@ declare function prepareAgentPayload(args: {
|
|
|
1296
1299
|
model?: "spark-1-pro" | "spark-1-mini";
|
|
1297
1300
|
webhook?: string | AgentWebhookConfig;
|
|
1298
1301
|
threatProtection?: ThreatProtectionOptions;
|
|
1299
|
-
auditMetadata?:
|
|
1302
|
+
auditMetadata?: AuditMetadata$1;
|
|
1300
1303
|
}): Record<string, unknown>;
|
|
1301
1304
|
declare function startAgent(http: HttpClient, args: Parameters<typeof prepareAgentPayload>[0]): Promise<AgentResponse>;
|
|
1302
1305
|
|
|
@@ -1839,6 +1842,9 @@ interface LocationConfig {
|
|
|
1839
1842
|
country?: string;
|
|
1840
1843
|
languages?: string[];
|
|
1841
1844
|
}
|
|
1845
|
+
interface AuditMetadata {
|
|
1846
|
+
username: string;
|
|
1847
|
+
}
|
|
1842
1848
|
/**
|
|
1843
1849
|
* Parameters for scraping operations.
|
|
1844
1850
|
* Defines the options and configurations available for scraping web content.
|
|
@@ -1860,7 +1866,7 @@ interface CrawlScrapeOptions {
|
|
|
1860
1866
|
storeInCache?: boolean;
|
|
1861
1867
|
maxAge?: number;
|
|
1862
1868
|
parsePDF?: boolean;
|
|
1863
|
-
auditMetadata?:
|
|
1869
|
+
auditMetadata?: AuditMetadata;
|
|
1864
1870
|
}
|
|
1865
1871
|
type Action = {
|
|
1866
1872
|
type: "wait";
|
|
@@ -2026,7 +2032,7 @@ interface MapParams {
|
|
|
2026
2032
|
timeout?: number;
|
|
2027
2033
|
useIndex?: boolean;
|
|
2028
2034
|
location?: LocationConfig;
|
|
2029
|
-
auditMetadata?:
|
|
2035
|
+
auditMetadata?: AuditMetadata;
|
|
2030
2036
|
}
|
|
2031
2037
|
/**
|
|
2032
2038
|
* Response interface for mapping operations.
|
|
@@ -2661,4 +2667,4 @@ declare class Firecrawl extends FirecrawlClient {
|
|
|
2661
2667
|
get v1(): FirecrawlApp;
|
|
2662
2668
|
}
|
|
2663
2669
|
|
|
2664
|
-
export { type ActionOption, type ActiveCrawl, type ActiveCrawlsResponse, type AgentOptions$1 as AgentOptions, type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type AgentWebhookEvent, type AttributesFormat, type BatchScrapeJob, type BatchScrapeOptions, type BatchScrapeResponse$1 as BatchScrapeResponse, type BrandingProfile, type BrowserCreateResponse, type BrowserDeleteResponse, type BrowserExecuteResponse, type BrowserListResponse, type BrowserSession, type CategoryOption, type ChangeTrackingFormat, type ClickAction, type ConcurrencyCheck, type CrawlErrorsResponse$1 as CrawlErrorsResponse, type CrawlJob, type CrawlOptions, type CrawlResponse$1 as CrawlResponse, type CreateMonitorRequest, type CreditUsage, type CreditUsageHistoricalPeriod, type CreditUsageHistoricalResponse, type Document, type DocumentMetadata, type EndpointFeedbackEndpoint, type EndpointFeedbackRequest, type ErrorDetails, type ExecuteJavascriptAction, type ExtractResponse$1 as ExtractResponse, type FeedbackMissingContent, type FeedbackRating, type FeedbackResponse, type FeedbackValuableSource, Firecrawl, FirecrawlApp as FirecrawlAppV1, FirecrawlClient, type FirecrawlClientInput, type FirecrawlClientOptions, type Format, type FormatOption, type FormatString, type GetMonitorCheckOptions, type GetPaperOptions, type GitHubScoreBreakdown, type GitHubSearchItem, type GitHubSearchResponse, type HighlightsFormat, type IdMap, JobTimeoutError, type JsonFormat, type ListMonitorChecksOptions, type ListMonitorsOptions, type LocationConfig$1 as LocationConfig, type MapData, type MapOptions, type MenuAvailability, type MenuImage, type MenuItem, type MenuItemIdentifiers, type MenuMerchant, type MenuPrice, type MenuProfile, type MenuSection, type Monitor, type MonitorCheck, type MonitorCheckDetail, type MonitorCheckPage, type MonitorCrawlTarget, type MonitorCrawlTargetResult, type MonitorEmailNotification, type MonitorEmailRecipientSubscription, type MonitorJsonFieldDiff, type MonitorNotification, type MonitorPageDiff, type MonitorPageJudgment, type MonitorPageSnapshot, type MonitorSchedule, type MonitorScrapeTarget, type MonitorScrapeTargetResult, type MonitorSearchTarget, type MonitorSearchTargetResult, type MonitorSummary, type MonitorTarget, type MonitorTargetResult, type MonitorWebhookConfig, type PDFAction, type PaginationConfig, type PaperMetadata, type PaperMetadataResponse, type PaperResult, type PaperSignals, type ParseFile, type ParseFileData, type ParseFormat, type ParseFormatOption, type ParseFormatString, type ParseOptions, type Passage, type PressAction, type ProductAvailability, type ProductImage, type ProductPrice, type ProductProfile, type ProductSale, type ProductVariant, type QueryFormat, type QuestionFormat, type QueueStatusResponse$1 as QueueStatusResponse, type ReadPaperResponse, type RedactPIIEntity, type RedactPIIOptions, ResearchClient, type ScrapeAction, type ScrapeBrowserDeleteResponse, type ScrapeExecuteRequest, type ScrapeExecuteResponse, type ScrapeOptions, type ScreenshotAction, type ScreenshotFormat, type ScrollAction, SdkError, type SearchData, type SearchFeedbackRequest, type SearchGithubOptions, type SearchPapersOptions, type SearchPapersResponse, type SearchRequest, type SearchResultImages, type SearchResultNews, type SearchResultWeb, type SimilarPapersOptions, type SimilarPapersResponse, type ThreatProtectionOptions, type TokenUsage, type TokenUsageHistoricalPeriod, type TokenUsageHistoricalResponse, type UpdateMonitorRequest, type Viewport, type WaitAction, Watcher, type WatcherOptions, type WebhookConfig, type WriteAction, Firecrawl as default };
|
|
2670
|
+
export { type ActionOption, type ActiveCrawl, type ActiveCrawlsResponse, type AgentOptions$1 as AgentOptions, type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type AgentWebhookEvent, type AttributesFormat, type AuditMetadata$1 as AuditMetadata, type BatchScrapeJob, type BatchScrapeOptions, type BatchScrapeResponse$1 as BatchScrapeResponse, type BrandingProfile, type BrowserCreateResponse, type BrowserDeleteResponse, type BrowserExecuteResponse, type BrowserListResponse, type BrowserSession, type CategoryOption, type ChangeTrackingFormat, type ClickAction, type ConcurrencyCheck, type CrawlErrorsResponse$1 as CrawlErrorsResponse, type CrawlJob, type CrawlOptions, type CrawlResponse$1 as CrawlResponse, type CreateMonitorRequest, type CreditUsage, type CreditUsageHistoricalPeriod, type CreditUsageHistoricalResponse, type Document, type DocumentMetadata, type EndpointFeedbackEndpoint, type EndpointFeedbackRequest, type ErrorDetails, type ExecuteJavascriptAction, type ExtractResponse$1 as ExtractResponse, type FeedbackMissingContent, type FeedbackRating, type FeedbackResponse, type FeedbackValuableSource, Firecrawl, FirecrawlApp as FirecrawlAppV1, FirecrawlClient, type FirecrawlClientInput, type FirecrawlClientOptions, type Format, type FormatOption, type FormatString, type GetMonitorCheckOptions, type GetPaperOptions, type GitHubScoreBreakdown, type GitHubSearchItem, type GitHubSearchResponse, type HighlightsFormat, type IdMap, JobTimeoutError, type JsonFormat, type ListMonitorChecksOptions, type ListMonitorsOptions, type LocationConfig$1 as LocationConfig, type MapData, type MapOptions, type MenuAvailability, type MenuImage, type MenuItem, type MenuItemIdentifiers, type MenuMerchant, type MenuPrice, type MenuProfile, type MenuSection, type Monitor, type MonitorCheck, type MonitorCheckDetail, type MonitorCheckPage, type MonitorCrawlTarget, type MonitorCrawlTargetResult, type MonitorEmailNotification, type MonitorEmailRecipientSubscription, type MonitorJsonFieldDiff, type MonitorNotification, type MonitorPageDiff, type MonitorPageJudgment, type MonitorPageSnapshot, type MonitorSchedule, type MonitorScrapeTarget, type MonitorScrapeTargetResult, type MonitorSearchTarget, type MonitorSearchTargetResult, type MonitorSummary, type MonitorTarget, type MonitorTargetResult, type MonitorWebhookConfig, type PDFAction, type PaginationConfig, type PaperMetadata, type PaperMetadataResponse, type PaperResult, type PaperSignals, type ParseFile, type ParseFileData, type ParseFormat, type ParseFormatOption, type ParseFormatString, type ParseOptions, type Passage, type PressAction, type ProductAvailability, type ProductImage, type ProductPrice, type ProductProfile, type ProductSale, type ProductVariant, type QueryFormat, type QuestionFormat, type QueueStatusResponse$1 as QueueStatusResponse, type ReadPaperResponse, type RedactPIIEntity, type RedactPIIOptions, ResearchClient, type ScrapeAction, type ScrapeBrowserDeleteResponse, type ScrapeExecuteRequest, type ScrapeExecuteResponse, type ScrapeOptions, type ScreenshotAction, type ScreenshotFormat, type ScrollAction, SdkError, type SearchData, type SearchFeedbackRequest, type SearchGithubOptions, type SearchPapersOptions, type SearchPapersResponse, type SearchRequest, type SearchResultImages, type SearchResultNews, type SearchResultWeb, type SimilarPapersOptions, type SimilarPapersResponse, type ThreatProtectionOptions, type TokenUsage, type TokenUsageHistoricalPeriod, type TokenUsageHistoricalResponse, type UpdateMonitorRequest, type Viewport, type WaitAction, Watcher, type WatcherOptions, type WebhookConfig, type WriteAction, Firecrawl as default };
|
package/dist/index.d.ts
CHANGED
|
@@ -114,6 +114,9 @@ interface PDFAction {
|
|
|
114
114
|
scale?: number;
|
|
115
115
|
}
|
|
116
116
|
type ActionOption = WaitAction | ScreenshotAction | ClickAction | WriteAction | PressAction | ScrollAction | ScrapeAction | ExecuteJavascriptAction | PDFAction;
|
|
117
|
+
interface AuditMetadata$1 {
|
|
118
|
+
username: string;
|
|
119
|
+
}
|
|
117
120
|
interface ScrapeOptions {
|
|
118
121
|
formats?: FormatOption[];
|
|
119
122
|
headers?: Record<string, string>;
|
|
@@ -142,7 +145,7 @@ interface ScrapeOptions {
|
|
|
142
145
|
lockdown?: boolean;
|
|
143
146
|
redactPII?: boolean | RedactPIIOptions;
|
|
144
147
|
threatProtection?: ThreatProtectionOptions;
|
|
145
|
-
auditMetadata?:
|
|
148
|
+
auditMetadata?: AuditMetadata$1;
|
|
146
149
|
profile?: {
|
|
147
150
|
name: string;
|
|
148
151
|
saveChanges?: boolean;
|
|
@@ -636,7 +639,7 @@ interface MapOptions {
|
|
|
636
639
|
origin?: string;
|
|
637
640
|
location?: LocationConfig$1;
|
|
638
641
|
threatProtection?: ThreatProtectionOptions;
|
|
639
|
-
auditMetadata?:
|
|
642
|
+
auditMetadata?: AuditMetadata$1;
|
|
640
643
|
}
|
|
641
644
|
type FeedbackRating = "good" | "partial" | "bad";
|
|
642
645
|
type EndpointFeedbackEndpoint = "search" | "scrape" | "parse" | "map";
|
|
@@ -1296,7 +1299,7 @@ declare function prepareAgentPayload(args: {
|
|
|
1296
1299
|
model?: "spark-1-pro" | "spark-1-mini";
|
|
1297
1300
|
webhook?: string | AgentWebhookConfig;
|
|
1298
1301
|
threatProtection?: ThreatProtectionOptions;
|
|
1299
|
-
auditMetadata?:
|
|
1302
|
+
auditMetadata?: AuditMetadata$1;
|
|
1300
1303
|
}): Record<string, unknown>;
|
|
1301
1304
|
declare function startAgent(http: HttpClient, args: Parameters<typeof prepareAgentPayload>[0]): Promise<AgentResponse>;
|
|
1302
1305
|
|
|
@@ -1839,6 +1842,9 @@ interface LocationConfig {
|
|
|
1839
1842
|
country?: string;
|
|
1840
1843
|
languages?: string[];
|
|
1841
1844
|
}
|
|
1845
|
+
interface AuditMetadata {
|
|
1846
|
+
username: string;
|
|
1847
|
+
}
|
|
1842
1848
|
/**
|
|
1843
1849
|
* Parameters for scraping operations.
|
|
1844
1850
|
* Defines the options and configurations available for scraping web content.
|
|
@@ -1860,7 +1866,7 @@ interface CrawlScrapeOptions {
|
|
|
1860
1866
|
storeInCache?: boolean;
|
|
1861
1867
|
maxAge?: number;
|
|
1862
1868
|
parsePDF?: boolean;
|
|
1863
|
-
auditMetadata?:
|
|
1869
|
+
auditMetadata?: AuditMetadata;
|
|
1864
1870
|
}
|
|
1865
1871
|
type Action = {
|
|
1866
1872
|
type: "wait";
|
|
@@ -2026,7 +2032,7 @@ interface MapParams {
|
|
|
2026
2032
|
timeout?: number;
|
|
2027
2033
|
useIndex?: boolean;
|
|
2028
2034
|
location?: LocationConfig;
|
|
2029
|
-
auditMetadata?:
|
|
2035
|
+
auditMetadata?: AuditMetadata;
|
|
2030
2036
|
}
|
|
2031
2037
|
/**
|
|
2032
2038
|
* Response interface for mapping operations.
|
|
@@ -2661,4 +2667,4 @@ declare class Firecrawl extends FirecrawlClient {
|
|
|
2661
2667
|
get v1(): FirecrawlApp;
|
|
2662
2668
|
}
|
|
2663
2669
|
|
|
2664
|
-
export { type ActionOption, type ActiveCrawl, type ActiveCrawlsResponse, type AgentOptions$1 as AgentOptions, type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type AgentWebhookEvent, type AttributesFormat, type BatchScrapeJob, type BatchScrapeOptions, type BatchScrapeResponse$1 as BatchScrapeResponse, type BrandingProfile, type BrowserCreateResponse, type BrowserDeleteResponse, type BrowserExecuteResponse, type BrowserListResponse, type BrowserSession, type CategoryOption, type ChangeTrackingFormat, type ClickAction, type ConcurrencyCheck, type CrawlErrorsResponse$1 as CrawlErrorsResponse, type CrawlJob, type CrawlOptions, type CrawlResponse$1 as CrawlResponse, type CreateMonitorRequest, type CreditUsage, type CreditUsageHistoricalPeriod, type CreditUsageHistoricalResponse, type Document, type DocumentMetadata, type EndpointFeedbackEndpoint, type EndpointFeedbackRequest, type ErrorDetails, type ExecuteJavascriptAction, type ExtractResponse$1 as ExtractResponse, type FeedbackMissingContent, type FeedbackRating, type FeedbackResponse, type FeedbackValuableSource, Firecrawl, FirecrawlApp as FirecrawlAppV1, FirecrawlClient, type FirecrawlClientInput, type FirecrawlClientOptions, type Format, type FormatOption, type FormatString, type GetMonitorCheckOptions, type GetPaperOptions, type GitHubScoreBreakdown, type GitHubSearchItem, type GitHubSearchResponse, type HighlightsFormat, type IdMap, JobTimeoutError, type JsonFormat, type ListMonitorChecksOptions, type ListMonitorsOptions, type LocationConfig$1 as LocationConfig, type MapData, type MapOptions, type MenuAvailability, type MenuImage, type MenuItem, type MenuItemIdentifiers, type MenuMerchant, type MenuPrice, type MenuProfile, type MenuSection, type Monitor, type MonitorCheck, type MonitorCheckDetail, type MonitorCheckPage, type MonitorCrawlTarget, type MonitorCrawlTargetResult, type MonitorEmailNotification, type MonitorEmailRecipientSubscription, type MonitorJsonFieldDiff, type MonitorNotification, type MonitorPageDiff, type MonitorPageJudgment, type MonitorPageSnapshot, type MonitorSchedule, type MonitorScrapeTarget, type MonitorScrapeTargetResult, type MonitorSearchTarget, type MonitorSearchTargetResult, type MonitorSummary, type MonitorTarget, type MonitorTargetResult, type MonitorWebhookConfig, type PDFAction, type PaginationConfig, type PaperMetadata, type PaperMetadataResponse, type PaperResult, type PaperSignals, type ParseFile, type ParseFileData, type ParseFormat, type ParseFormatOption, type ParseFormatString, type ParseOptions, type Passage, type PressAction, type ProductAvailability, type ProductImage, type ProductPrice, type ProductProfile, type ProductSale, type ProductVariant, type QueryFormat, type QuestionFormat, type QueueStatusResponse$1 as QueueStatusResponse, type ReadPaperResponse, type RedactPIIEntity, type RedactPIIOptions, ResearchClient, type ScrapeAction, type ScrapeBrowserDeleteResponse, type ScrapeExecuteRequest, type ScrapeExecuteResponse, type ScrapeOptions, type ScreenshotAction, type ScreenshotFormat, type ScrollAction, SdkError, type SearchData, type SearchFeedbackRequest, type SearchGithubOptions, type SearchPapersOptions, type SearchPapersResponse, type SearchRequest, type SearchResultImages, type SearchResultNews, type SearchResultWeb, type SimilarPapersOptions, type SimilarPapersResponse, type ThreatProtectionOptions, type TokenUsage, type TokenUsageHistoricalPeriod, type TokenUsageHistoricalResponse, type UpdateMonitorRequest, type Viewport, type WaitAction, Watcher, type WatcherOptions, type WebhookConfig, type WriteAction, Firecrawl as default };
|
|
2670
|
+
export { type ActionOption, type ActiveCrawl, type ActiveCrawlsResponse, type AgentOptions$1 as AgentOptions, type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type AgentWebhookEvent, type AttributesFormat, type AuditMetadata$1 as AuditMetadata, type BatchScrapeJob, type BatchScrapeOptions, type BatchScrapeResponse$1 as BatchScrapeResponse, type BrandingProfile, type BrowserCreateResponse, type BrowserDeleteResponse, type BrowserExecuteResponse, type BrowserListResponse, type BrowserSession, type CategoryOption, type ChangeTrackingFormat, type ClickAction, type ConcurrencyCheck, type CrawlErrorsResponse$1 as CrawlErrorsResponse, type CrawlJob, type CrawlOptions, type CrawlResponse$1 as CrawlResponse, type CreateMonitorRequest, type CreditUsage, type CreditUsageHistoricalPeriod, type CreditUsageHistoricalResponse, type Document, type DocumentMetadata, type EndpointFeedbackEndpoint, type EndpointFeedbackRequest, type ErrorDetails, type ExecuteJavascriptAction, type ExtractResponse$1 as ExtractResponse, type FeedbackMissingContent, type FeedbackRating, type FeedbackResponse, type FeedbackValuableSource, Firecrawl, FirecrawlApp as FirecrawlAppV1, FirecrawlClient, type FirecrawlClientInput, type FirecrawlClientOptions, type Format, type FormatOption, type FormatString, type GetMonitorCheckOptions, type GetPaperOptions, type GitHubScoreBreakdown, type GitHubSearchItem, type GitHubSearchResponse, type HighlightsFormat, type IdMap, JobTimeoutError, type JsonFormat, type ListMonitorChecksOptions, type ListMonitorsOptions, type LocationConfig$1 as LocationConfig, type MapData, type MapOptions, type MenuAvailability, type MenuImage, type MenuItem, type MenuItemIdentifiers, type MenuMerchant, type MenuPrice, type MenuProfile, type MenuSection, type Monitor, type MonitorCheck, type MonitorCheckDetail, type MonitorCheckPage, type MonitorCrawlTarget, type MonitorCrawlTargetResult, type MonitorEmailNotification, type MonitorEmailRecipientSubscription, type MonitorJsonFieldDiff, type MonitorNotification, type MonitorPageDiff, type MonitorPageJudgment, type MonitorPageSnapshot, type MonitorSchedule, type MonitorScrapeTarget, type MonitorScrapeTargetResult, type MonitorSearchTarget, type MonitorSearchTargetResult, type MonitorSummary, type MonitorTarget, type MonitorTargetResult, type MonitorWebhookConfig, type PDFAction, type PaginationConfig, type PaperMetadata, type PaperMetadataResponse, type PaperResult, type PaperSignals, type ParseFile, type ParseFileData, type ParseFormat, type ParseFormatOption, type ParseFormatString, type ParseOptions, type Passage, type PressAction, type ProductAvailability, type ProductImage, type ProductPrice, type ProductProfile, type ProductSale, type ProductVariant, type QueryFormat, type QuestionFormat, type QueueStatusResponse$1 as QueueStatusResponse, type ReadPaperResponse, type RedactPIIEntity, type RedactPIIOptions, ResearchClient, type ScrapeAction, type ScrapeBrowserDeleteResponse, type ScrapeExecuteRequest, type ScrapeExecuteResponse, type ScrapeOptions, type ScreenshotAction, type ScreenshotFormat, type ScrollAction, SdkError, type SearchData, type SearchFeedbackRequest, type SearchGithubOptions, type SearchPapersOptions, type SearchPapersResponse, type SearchRequest, type SearchResultImages, type SearchResultNews, type SearchResultWeb, type SimilarPapersOptions, type SimilarPapersResponse, type ThreatProtectionOptions, type TokenUsage, type TokenUsageHistoricalPeriod, type TokenUsageHistoricalResponse, type UpdateMonitorRequest, type Viewport, type WaitAction, Watcher, type WatcherOptions, type WebhookConfig, type WriteAction, Firecrawl as default };
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
require_package
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-BEF2NAMB.js";
|
|
4
4
|
|
|
5
5
|
// src/v2/utils/httpClient.ts
|
|
6
6
|
import axios from "axios";
|
|
@@ -2316,7 +2316,7 @@ var FirecrawlApp = class {
|
|
|
2316
2316
|
if (typeof process !== "undefined" && process.env && process.env.npm_package_version) {
|
|
2317
2317
|
return process.env.npm_package_version;
|
|
2318
2318
|
}
|
|
2319
|
-
const packageJson = await import("./package-
|
|
2319
|
+
const packageJson = await import("./package-GIVYQAT4.js");
|
|
2320
2320
|
return packageJson.default.version;
|
|
2321
2321
|
} catch (error) {
|
|
2322
2322
|
const isTest = typeof process !== "undefined" && (process.env.JEST_WORKER_ID != null || false);
|
package/package.json
CHANGED
package/pnpm-workspace.yaml
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
1
|
allowBuilds:
|
|
2
2
|
esbuild: true
|
|
3
3
|
unrs-resolver: true
|
|
4
|
+
overrides:
|
|
5
|
+
"@isaacs/brace-expansion@<=5.0.0": ">=5.0.1"
|
|
6
|
+
"minimatch@<10.2.3": ">=10.2.3"
|
|
7
|
+
"rollup@<4.59.0": ">=4.59.0"
|
|
8
|
+
"picomatch@<4.0.4": ">=4.0.4"
|
|
9
|
+
handlebars: ">=4.7.9"
|
|
10
|
+
"brace-expansion@>=5.0.0 <5.0.8": "5.0.8"
|
|
11
|
+
"js-yaml@>=3.0.0 <3.15.0": "3.15.0"
|
|
12
|
+
"axios@>=1.0.0 <1.16.0": "1.16.1"
|
|
13
|
+
"follow-redirects@<1.16.0": ">=1.16.0 <2.0.0"
|
|
14
|
+
"form-data@>=4.0.0 <4.0.6": "4.0.6"
|
|
15
|
+
"@babel/core@>=7.0.0 <7.29.6": "7.29.7"
|
|
16
|
+
"esbuild@>=0.17.0 <0.28.1": "0.28.1"
|
|
@@ -7,7 +7,7 @@ import { map } from "../../../v2/methods/map";
|
|
|
7
7
|
import { startExtract } from "../../../v2/methods/extract";
|
|
8
8
|
import { startAgent } from "../../../v2/methods/agent";
|
|
9
9
|
|
|
10
|
-
const auditMetadata = {
|
|
10
|
+
const auditMetadata = { username: "alice@example.com" };
|
|
11
11
|
|
|
12
12
|
function makeHttp(data: Record<string, unknown>) {
|
|
13
13
|
const post = jest.fn(async () => ({ status: 200, data }));
|
package/src/v1/index.ts
CHANGED
|
@@ -114,6 +114,10 @@ export interface LocationConfig {
|
|
|
114
114
|
languages?: string[];
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
+
export interface AuditMetadata {
|
|
118
|
+
username: string;
|
|
119
|
+
}
|
|
120
|
+
|
|
117
121
|
/**
|
|
118
122
|
* Parameters for scraping operations.
|
|
119
123
|
* Defines the options and configurations available for scraping web content.
|
|
@@ -135,7 +139,7 @@ export interface CrawlScrapeOptions {
|
|
|
135
139
|
storeInCache?: boolean;
|
|
136
140
|
maxAge?: number;
|
|
137
141
|
parsePDF?: boolean;
|
|
138
|
-
auditMetadata?:
|
|
142
|
+
auditMetadata?: AuditMetadata;
|
|
139
143
|
}
|
|
140
144
|
|
|
141
145
|
export type Action = {
|
|
@@ -311,7 +315,7 @@ export interface MapParams {
|
|
|
311
315
|
timeout?: number;
|
|
312
316
|
useIndex?: boolean;
|
|
313
317
|
location?: LocationConfig;
|
|
314
|
-
auditMetadata?:
|
|
318
|
+
auditMetadata?: AuditMetadata;
|
|
315
319
|
}
|
|
316
320
|
|
|
317
321
|
/**
|
package/src/v2/methods/agent.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type ThreatProtectionOptions } from "../types";
|
|
1
|
+
import { type AgentResponse, type AgentStatusResponse, type AgentWebhookConfig, type AuditMetadata, type ThreatProtectionOptions } from "../types";
|
|
2
2
|
import { HttpClient } from "../utils/httpClient";
|
|
3
3
|
import { normalizeAxiosError, throwForBadResponse } from "../utils/errorHandler";
|
|
4
4
|
import { isZodSchema, zodSchemaToJsonSchema } from "../../utils/zodSchemaToJson";
|
|
@@ -15,7 +15,7 @@ function prepareAgentPayload(args: {
|
|
|
15
15
|
model?: "spark-1-pro" | "spark-1-mini";
|
|
16
16
|
webhook?: string | AgentWebhookConfig;
|
|
17
17
|
threatProtection?: ThreatProtectionOptions;
|
|
18
|
-
auditMetadata?:
|
|
18
|
+
auditMetadata?: AuditMetadata;
|
|
19
19
|
}): Record<string, unknown> {
|
|
20
20
|
const body: Record<string, unknown> = {};
|
|
21
21
|
if (args.urls) body.urls = args.urls;
|
package/src/v2/types.ts
CHANGED
|
@@ -183,6 +183,10 @@ export type ActionOption =
|
|
|
183
183
|
| ExecuteJavascriptAction
|
|
184
184
|
| PDFAction;
|
|
185
185
|
|
|
186
|
+
export interface AuditMetadata {
|
|
187
|
+
username: string;
|
|
188
|
+
}
|
|
189
|
+
|
|
186
190
|
export interface ScrapeOptions {
|
|
187
191
|
formats?: FormatOption[];
|
|
188
192
|
headers?: Record<string, string>;
|
|
@@ -209,7 +213,7 @@ export interface ScrapeOptions {
|
|
|
209
213
|
lockdown?: boolean;
|
|
210
214
|
redactPII?: boolean | RedactPIIOptions;
|
|
211
215
|
threatProtection?: ThreatProtectionOptions;
|
|
212
|
-
auditMetadata?:
|
|
216
|
+
auditMetadata?: AuditMetadata;
|
|
213
217
|
profile?: {
|
|
214
218
|
name: string;
|
|
215
219
|
saveChanges?: boolean;
|
|
@@ -797,7 +801,7 @@ export interface MapOptions {
|
|
|
797
801
|
origin?: string;
|
|
798
802
|
location?: LocationConfig;
|
|
799
803
|
threatProtection?: ThreatProtectionOptions;
|
|
800
|
-
auditMetadata?:
|
|
804
|
+
auditMetadata?: AuditMetadata;
|
|
801
805
|
}
|
|
802
806
|
|
|
803
807
|
export type FeedbackRating = "good" | "partial" | "bad";
|