Skip to content

Commit

Permalink
Set up trigger.dev (#231)
Browse files Browse the repository at this point in the history
  • Loading branch information
DinerIsmail authored Oct 21, 2024
1 parent fa462a7 commit 0a1c76e
Show file tree
Hide file tree
Showing 7 changed files with 2,064 additions and 115 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,5 @@ yarn-error.log*
/test-results/
/playwright-report/
/playwright/.cache/

.trigger
12 changes: 12 additions & 0 deletions app/api/hello-world/route.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import type { helloWorldTask } from '@trigger/example'
import { tasks } from '@trigger.dev/sdk/v3'
import { NextResponse } from 'next/server'

export async function GET() {
const handle = await tasks.trigger<typeof helloWorldTask>(
'hello-world',
'James',
)

return NextResponse.json(handle)
}
Loading

0 comments on commit 0a1c76e

Please sign in to comment.