Set it up
GitLab CI
Store the token as a CI/CD variable and call
POST /v1/run.Blocking mode
Poll the run and fail the job when the result is not passed.
Mobile build
Upload the build and run the plan against it.
1
Create an API token
Go to Organization Settings → API Keys, create a key, and copy it when it is shown. It is not displayed again. Project-scoped keys are bound to one project. Org-scoped keys need
projectShortId on API calls.2
Store the token in GitLab
Go to Settings → CI/CD → Variables and add:
- Key:
QA_TECH_API_TOKEN - Value: Your API token
- Protected: ✅
- Masked: ✅
3
Get the project short ID
Copy
proj_… from the project URL or Settings (for example proj_abc123).
Org-scoped keys need this on POST /v1/run. See Understanding Different
IDs.4
Get the test plan short ID
Open the plan under Test Plans and copy
pln_… from the URL (for example pln_abc123). See Find the test plan short ID.What works on GitLab
What this does not do
- This path does not post a merge request review. Use GitLab pull request testing for that.
- GitLab cannot promote review tests into the suite. That agent exists on GitHub pull request testing only.
- Envoyer is not required. Use it only when the deploy itself is what should start the plan. See Envoyer.
Patterns
Basic setup
pln_abc123 with your test plan short ID (from your test plan page). The runner image must provide curl and jq.
The GITLAB trigger and repository metadata attribute the run to GitLab in QA.tech. The results page links the commit to $CI_PROJECT_URL/-/commit/$CI_COMMIT_SHA, including for self-hosted GitLab projects. Requests without this metadata remain generic API runs.
Run test plans on merge requests
Test preview deployments via API
Pass dynamic URLs between jobs using dotenv artifacts:The
environment object also accepts optional customHeaders to persist auth
or protection-bypass headers on that environment. Omit the field to leave
stored headers unchanged; pass [] to clear them. Add devicePresetShortId
on each application object in the same request. See Environment custom
headers and
Start Run API.Mobile build
Native apps have no preview URL. Upload the APK or simulator.app, then pass applicationBuildShortId instead of url. How application builds work is on Mobile regression testing. The shared upload script is on API pull request testing.
pln_abc123, app_gXeBl2, and set BUILD_SHORT_ID from the upload response.