Skip to content

Documentation

How to use each part of QAIA, step by step: running analyses, reading the results, tests, audits and your account.

Categories

Run a test suite from CI

Create a workspace API key, add the step for GitHub Actions, GitLab CI or any CI, read the result and the JUnit report, and revoke the key.

Updated December 2, 2026

Use this when a collection should run on every push or release, and the pipeline should fail when a scenario fails. You need Pro or Enterprise, a collection with at least one scenario, and access to your CI's secret settings.

What happens

Your pipeline starts the collection with a workspace API key, checks every 15 seconds until the run has finished (for up to 30 minutes), keeps a JUnit report, and passes only when every scenario passed. A run started from CI counts toward your plan like any other run, and appears in History with the collection's name and (CI).

1. Open Run from CI

  1. Open Tests & Suites, select Test Suites and open the collection.
  2. Select Run from CI. The dialog is named after the collection and has two parts.

2. Create a workspace API key

  1. Under 1. A workspace API key, type a Key name after the pipeline that will use it, for example GitHub Actions, and select Create key.
  2. Copy this key now: QAIA shows it only once. Select Copy key.
  3. Store it in your CI as a secret named QAIA_API_KEY: on GitHub under Settings, Secrets and variables, Actions; on GitLab as a masked CI/CD variable. Never write the key in the pipeline file.

Make one key per pipeline, so you can revoke one without stopping the others. The same keys are listed on the API keys tab of your account (CI API Keys in the account menu). They are not AI keys: QAIA's AI needs no key from you.

3. Add the step to your pipeline

  1. Under 2. Add it to your pipeline, choose the collection if you have several (Which collection should your pipeline run?).
  2. Choose GitHub Actions, GitLab CI or Any CI (curl), and select Copy.
  3. Paste it into your pipeline: on GitHub as a new file, .github/workflows/qaia.yml; on GitLab as a job in .gitlab-ci.yml; anywhere else, run the shell lines. The step needs curl and jq: GitHub's Ubuntu runners have both, and the GitLab example installs them.
  4. Commit and push. The GitHub example runs on every push, and from the Actions tab.

What the step does

  1. Starts the run: POST https://qaia.io/api/v1/suites/<collection id>/trigger with the header Authorization: Bearer $QAIA_API_KEY. QAIA answers with a runId.
  2. Reads the run every 15 seconds: GET https://qaia.io/api/v1/suite-runs/<runId>. The answer holds status, finished, passed, the counts (total, passed, failed, skipped) and each scenario with its result.
  3. Once finished is true, saves the report: the same address with ?format=junit, into qaia-junit.xml.
  4. Passes the job only when passed is true.

The copied step already holds your collection's id and QAIA's address; you only add the secret.

Read the result

  • Passed: the run completed and every scenario passed.
  • Failed: at least one scenario failed. The JUnit report names it, with the reason as the failure message; open the run in History for its proof.
  • Cancelled: someone cancelled the run in QAIA. The scenarios that did not run are skipped, and the job fails: a cancelled run is not a pass.
  • Not finished within 30 minutes: the job stops waiting and says so; the run may still finish in QAIA. Make the collection smaller, or split it into several.

The JUnit report holds one test case per scenario. GitHub keeps it as the qaia-junit artifact; GitLab shows it as the job's test report.

When the step does not start a run

The job stops at the first line, with the status QAIA answered:

  • 401: the key is missing, mistyped or revoked. Check the secret's name and value.
  • 403: your plan does not include Test Suites, or a monthly limit is reached.
  • 404: the collection is not in your workspace; copy the step again from its own Run from CI.
  • 400: the collection has no scenarios (This test suite has no scenarios to run), or a scenario points to a private address.
  • 429: a fair-use window or the limit of runs a key can start per hour; try again later.

Revoke a key

In Run from CI, or on the API keys tab of your account, select Revoke beside the key and confirm. A pipeline that uses it stops working at its next run; the others carry on. To keep that pipeline, create a new key and update its secret.

Following a journey all the way to CI: Tutorial: from a journey to a check in your CI.