Local CLI Testing
Guide local HumanLayer CLI login and create local test tasks and sessions
Install
npx skills add humanlayer/humanlayer --skill local-cli-testing -g -a claude-code -y- Repository
- humanlayer/humanlayer12.7k
- Category
- Testing
- Updated
- 4d ago
- License
- Apache-2.0
- Context cost
- Lightabout 758 tokens
- Runs scripts
- No, instructions only
What it does
Guide local HumanLayer CLI login and create local test tasks and sessions
Local CLI Testing
Test Riptide API flows through apps/cli without the UI.
Login (Interactive)
The local CLI defaults to WorkOS device auth, so no callback URL is required. Loopback PKCE is opt-in with HUMANLAYER_CLI_AUTH_METHOD=loopback; if using it, add the exact redirect URI http://localhost:39173/callback in WorkOS, or set HUMANLAYER_CLI_AUTH_PORT=<port> and add the matching exact URI.
Ask the user to run:
WORKOS_CLIENT_ID="$(grep '^WORKOS_CLIENT_ID=' .env | cut -d= -f2-)" \
DEV_API_ORIGIN=http://localhost:8700 \
DEV_SYNC_ORIGIN=http://localhost:8888 \
bun --bun apps/cli/src/index.ts --dev login
If 400 invalid client, confirm WORKOS_CLIENT_ID is the public WorkOS client id for the target environment.
Verify:
WORKOS_CLIENT_ID="$(grep '^WORKOS_CLIENT_ID=' .env | cut -d= -f2-)" \
DEV_API_ORIGIN=http://localhost:8700 \
DEV_SYNC_ORIGIN=http://localhost:8888 \
bun --bun apps/cli/src/index.ts --dev api sync online-hosts --limit 5
Create Task
WORKOS_CLIENT_ID="$(grep '^WORKOS_CLIENT_ID=' .env | cut -d= -f2-)" \
DEV_API_ORIGIN=http://localhost:8700 \
DEV_SYNC_ORIGIN=http://localhost:8888 \
bun --bun apps/cli/src/index.ts --dev api tasks create \
--name "Task Name" \
--slug "task-slug" \
--default-working-directory "$PWD" \
--workflow-type outline_only \
--worktree-timing later
Workflow types: rpi, outline_only, prd_tdd, oneshot (omit for freeform)
Worktree timing: now, later, never
Upload Artifact
WORKOS_CLIENT_ID="$(grep '^WORKOS_CLIENT_ID=' .env | cut -d= -f2-)" \
DEV_API_ORIGIN=http://localhost:8700 \
DEV_SYNC_ORIGIN=http://localhost:8888 \
bun --bun apps/cli/src/index.ts --dev api uploads upsert-text \
--task-id "TASK_ID" \
--file-name "ticket.md" \
--content "Ticket content here"


