Quick Start
Get up and running in under 5 minutes. This guide walks you through creating a workspace, connecting your first repository, and running your first workflow.
Prerequisites
- A Stackflow account (sign up free)
- Node.js 18 or later
- A GitHub, GitLab, or Bitbucket account
1. Install the CLI
bash
1
npm install -g @stackflow/cli
Verify the installation:
bash
1
stackflow --version
2. Authenticate
bash
1
stackflow login
This opens your browser for OAuth authentication. Once complete, your CLI session is active.
Note: You can also authenticate with an API token using stackflow login --token <YOUR_TOKEN>. This is recommended for CI environments.
3. Create a workspace
bash
1
stackflow workspace create my-team
A workspace is the top-level container for your projects, workflows, and team members.
4. Connect a repository
bash
1
stackflow repo connect github:my-org/my-repo
Stackflow will request the necessary permissions and begin syncing issues, PRs, and build status.
5. Create your first workflow
typescript
1
// workflow.ts
2
import { workflow, triggers } from '@stackflow/sdk';
3
4
export default workflow('notify-on-deploy', {
5
trigger: triggers.deploy.success(),
6
steps: [
7
{
8
name: 'Send Slack notification',
9
action: 'slack.send',
10
params: {
11
channel: '#deployments',
12
message: 'Deploy to production succeeded! {{deploy.sha}}',
13
},
14
},
15
],
16
});
Push the workflow:
bash
1
stackflow workflow push ./workflow.ts
6. Trigger a test run
bash
1
stackflow workflow run notify-on-deploy --test
Tip: Use --test to dry-run a workflow without sending real notifications or triggering external services.
Next steps
- Explore the workflow builder — visual pipeline creation
- Set up integrations — connect your existing tools
- Configure your dashboard — custom views and widgets
- Invite your team — set up permissions