Skip to content
T

trigger-tasks

Covers writing backend Trigger.dev tasks

by triggerdotdevFree

#7966in AI Skills
0In stores

Description

dev/sdk package. Tasks are functions that can run for a long time and are resilient to failure. You define them in files under your /trigger…

Highlights

  • task() and schemaTask() definitions
  • Run function with payload and context
  • Retries, waits and queues
  • Always import from @trigger.dev/sdk
  • Hello-world setup example

Ratings & Reviews

No ratings yet

Be the first to rate trigger-tasks.

People also visit

T

trigger-setup

Bootstrap Trigger.dev into an existing project

AI Skills
Get
T

trigger-config

Configure Trigger.dev projects with trigger.config.ts

AI Skills
Get
T

Trigger.dev

The open source platform for durable AI agents

Developer Tools
Launch
P

python-background-jobs

Python background job patterns including task queues, workers

AI Skills
Get
U

upstash-workflow

Upstash Workflow/QStash handlers, triggers, durable steps and async fan-out

AI Skills
Get
U

upstash-qstash-js

Work with the @upstash/qstash TypeScript/JavaScript SDK

AI Skills
Get

trigger-tasks FAQ

What is a Trigger.dev task?

A function that can run for a long time with strong resilience to failure, defined in a file under your /trigger directory.

What does the run function receive?

The payload and a context object. The context includes the attempt number, for example.

What must the return value be?

JSON serialisable.

Which package should I import from?

@trigger.dev/sdk. The skill says not to import from @trigger.dev/sdk/v3, a deprecated alias, or from @trigger.dev/core.

Does it cover retries and queues?

Yes. It covers retries, waits, queues and the related task options.

What are the best trigger-tasks alternatives?

Popular alternatives to trigger-tasks include trigger-setup, trigger-config and python-background-jobs. See all trigger-tasks alternatives

Developer Stuff

Badges