Skip to main content
The Workflow Client lets you programmatically interact with your workflow runs. You can use it from the same application that hosts your workflows, or from any external service.

Initialization

Initialize a new client with your credentials:
import { Client } from "@upstash/workflow"

const client = new Client({
  baseUrl: process.env.QSTASH_URL!,
  token: process.env.QSTASH_TOKEN!
})
The client is lightweight and stateless. You can safely reuse a single instance across your application.

Functionality

The client exposes a set of functions to manage workflow runs and inspect their state: