diff --git a/app/api/cron/automations/route.ts b/app/api/cron/automations/route.ts index c3f81ec6..509003a2 100644 --- a/app/api/cron/automations/route.ts +++ b/app/api/cron/automations/route.ts @@ -15,6 +15,13 @@ const log = createLogger("automations:cron"); const NO_STORE_HEADERS = { "Cache-Control": "private, no-store" }; export async function GET(request: Request) { + if (serverEnv.VERCEL_ENV === "preview") { + return Response.json( + { error: "Not found" }, + { headers: NO_STORE_HEADERS, status: 404 } + ); + } + if ( !isAuthorizedCronRequest(request) && serverEnv.NODE_ENV === "production"