MCPcopy Index your code
hub / github.com/triggerdotdev/trigger.dev / featuresForRequest

Function featuresForRequest

apps/webapp/app/features.server.ts:12–26  ·  view source on GitHub ↗
(request: Request)

Source from the content-addressed store, hash-verified

10// If the request host is cloud.trigger.dev then we are on the managed cloud
11// or if env.NODE_ENV is development
12export function featuresForRequest(request: Request): TriggerFeatures {
13 const url = requestUrl(request);
14
15 const isManagedCloud =
16 url.host === "cloud.trigger.dev" ||
17 url.host === "test-cloud.trigger.dev" ||
18 url.host === "internal.trigger.dev" ||
19 process.env.CLOUD_ENV === "development";
20
21 return {
22 isManagedCloud,
23 v3Enabled: env.V3_ENABLED === "true",
24 alertsEnabled: env.ALERT_FROM_EMAIL !== undefined && env.ALERT_RESEND_API_KEY !== undefined,
25 };
26}

Callers 7

loaderFunction · 0.90
loaderFunction · 0.90
loaderFunction · 0.90
loaderFunction · 0.90
loaderFunction · 0.90
callMethod · 0.90
callMethod · 0.90

Calls 1

requestUrlFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…