Comment on page
Node JS
Learn how to publish a job with NodeJS Library
To get the most out of this guide, you’ll need to:
Get the NextCron Node.js SDK.
yarn add nextcron
Start by send a job
import { NextCron } from 'nextcron';
const nextcron = new NextCron('YOUR_API_KEY')
await nextcron.publish({
topic: 'send-welcome-email',
target: 'http://localhost:3000/jobs/send-welcome-email',
method: 'POST',
data: { name, email },
})
Last modified 9mo ago