Run the agent in a GitHub Actions workflow

print mode & automation

// what it does

In CI, install with the same curl script, add ~/.local/bin to GITHUB_PATH so later steps can call the binary, then run in print mode with --force. Authentication comes from CURSOR_API_KEY, which you store as a repository secret and expose through the job's env. Pin a model with --model for reproducible runs.

// shell

$ curl https://cursor.com/install -fsS | bash
$ echo "$HOME/.local/bin" >> "$GITHUB_PATH"
$ cursor-agent -p "update the changelog for the latest release" --force --model gpt-5

// gotcha

Browser login cannot work in CI — if CURSOR_API_KEY is unset the run fails with "Not authenticated," so set env: CURSOR_API_KEY: ${{ secrets.CURSOR_API_KEY }} on the job or step.

// resources