These are the docs for Trigger.dev v2 which will be deprecated on January 31st, 2025. You probably want the v3 docs.

Client

A Client is used to connect to a specific Project by using an API Key.

Clients are created using the TriggerClient class.

export const client = new TriggerClient({
  id: "my-webapp",
  apiKey: process.env.TRIGGER_API_KEY!,
});

View the Client API Reference for more information.

Adaptors

Adaptors allows Clients to receive data from the Trigger API. They do this by creating an API endpoint that data can be received at and transforming data into the expected format.

Each platform has one or more adaptors, see the guides below:

PlatformAdaptor
Next.jscreatePagesRoute()
Next.jscreateAppRoute()
NestJSTriggerDevModule
AstrocreateAstroRoute()
RemixcreateRemixRoute()
SveltekitcreateSvelteRoute()
ExpressComing soon