Skip to content

Supercharge your AI agents with data from the web and beyond. Building the library for superintelligence. 🔥

feat(log_job): allow use of api key if specified

Gergő Móricz37b13ba146d3
diff --git a/apps/api/src/services/logging/log_job.ts b/apps/api/src/services/logging/log_job.ts
index 5432687f8..d1751a6c8 100644
--- a/apps/api/src/services/logging/log_job.ts
+++ b/apps/api/src/services/logging/log_job.ts
@@ -24,7 +24,9 @@ function cleanOfNull<T>(x: T): T {
async function saveJobToGCS(job: FirecrawlJob, bucketName: string): Promise<void> {
try {
- const storage = new Storage();
+ const storage = new Storage({
+ apiKey: process.env.GCS_API_KEY,
+ });
const bucket = storage.bucket(bucketName);
const blob = bucket.file(`${job.job_id}.json`);
await blob.save(JSON.stringify(job.docs), {