Using KwikQA
Running in CI
analyze can run unattended, so every red build arrives with a diagnosis. fix can't, because applying a patch always needs a person at a terminal.
1. Create a CI token
In the dashboard, open Account, name a token after where it will live (for example "GitHub Actions"), and create it. Copy it right away: it is shown once. Store it as a secret named KWIKQA_TOKEN in your CI system.
2. Add a step after your tests
# .github/workflows/e2e.yml (excerpt)
- name: Run Playwright tests
run: npx playwright test
- name: Diagnose failures
if: failure()
run: npx kwikqa analyze --yes
env:
KWIKQA_TOKEN: ${{ secrets.KWIKQA_TOKEN }}
- name: Keep the KwikQA record
if: failure()
uses: actions/upload-artifact@v4
with:
name: kwikqa-records
path: .kwikqa/runs/
--yes approves the request preview, which is still printed to the log so every run shows what was sent. Each run counts one analysis. On a team plan, CI tokens created by anyone on the team draw from the team's shared pool.
Without an account
npx kwikqa analyze --local needs no token and sends nothing. It builds and records the local evidence summary only.
Tips
- Use a separate token for each CI system so you can revoke one without affecting the others.
- A diagnosis made in CI isn't reused by a later
fixon your machine, because the run and checkout differ. Download the report and runanalyzeandfixlocally. - Exit code
3means a sign-in or plan limit problem, so CI can tell it apart from a failed repair.