You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -143,27 +144,31 @@ async function scrapeWebsite(website: string): Promise<string> {
143
144
body: JSON.stringify({
144
145
urls: [website],
145
146
prompt:
146
-
'Extract all text content from this website, including company information, services, mission, vision, and any other relevant business information.',
147
-
scrapeOptions: {
148
-
onlyMainContent: true,
149
-
removeBase64Images: true,
150
-
},
147
+
'Extract all text content from this website, including company information, services, mission, vision, and any other relevant business information. Return the content as plain text or markdown.',
151
148
}),
152
149
});
153
150
154
151
constinitialData=awaitinitialResponse.json();
155
152
156
-
if(!initialData.success||!initialData.id){
153
+
if(!initialData.success){
154
+
logger.error('Failed to start Firecrawl extraction',{ initialData });
157
155
thrownewError('Failed to start Firecrawl extraction');
158
156
}
159
157
158
+
if(!initialData.id){
159
+
logger.error('Firecrawl did not return job ID',{ initialData });
160
+
thrownewError('Firecrawl did not return job ID');
161
+
}
162
+
160
163
constjobId=initialData.id;
161
164
conststartTime=Date.now();
165
+
logger.info('Firecrawl extraction started, polling for completion',{ jobId });
0 commit comments