Skip to main content
Check test run status and retrieve detailed results programmatically. This endpoint enables blocking mode in CI/CD pipelines, custom post-run automation, and integration with your existing tooling.

When to Use This API

  • Test result analysis – Build dashboards or generate reports from test results
  • Custom post-run automation – Trigger webhooks, custom alerting, or auto-create tickets
  • CI/CD blocking mode – Wait for test completion before proceeding with deployments (GitLab, CircleCI, Jenkins, etc.)
For detailed examples, see:

Quick Example: Polling Script

Basic polling example:
RESPONSE=$(curl -s "https://api.qa.tech/v1/run/$SHORT_ID" \
  -H "Authorization: Bearer $QATECH_API_TOKEN")

STATUS=$(echo "$RESPONSE" | jq -r '.status')

if [[ "$STATUS" == "COMPLETED" || "$STATUS" == "ERROR" || "$STATUS" == "CANCELLED" ]]; then
  RESULT=$(echo "$RESPONSE" | jq -r '.result')
  if [[ "$RESULT" == "PASSED" ]]; then
    echo "Tests passed!"
  else
    echo "Tests failed: $RESULT"
  fi
else
  echo "Status: $STATUS - still running"
fi
Variables:
  • $SHORT_ID – The run short ID (returned from Start Run API response: run.shortId)
  • $QATECH_API_TOKEN – Your project’s API token (found in Settings → Integrations → API)

API Reference

Endpoint

GET /run/{shortId}
Base URL: https://api.qa.tech/v1

Query Parameters

ParameterTypeRequiredDescription
testCasesstringNoControls which test cases are run. Use failed to include only failed/skipped/error test cases, or all to include all test cases with full details. When omitted, runTestCases is returned as an empty array.

Authentication

Bearer token authentication. Include your project’s API token in the Authorization header:
Authorization: Bearer YOUR_API_TOKEN
You can obtain your project’s API token from the QA.tech dashboard in Settings → Integrations → API.

Path Parameters

ParameterTypeRequiredDescription
shortIdstringYesThe short ID of the run (returned from Start Run API: run.shortId)

Response Format

Success Response (200)

With ?testCases=all or ?testCases=failed:
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "shortId": "abc123",
  "status": "COMPLETED",
  "result": "FAILED",
  "runTestCases": [
    {
      "id": "test-case-uuid",
      "shortId": "xyz789",
      "name": "Login flow test",
      "status": "COMPLETED",
      "result": "FAILED",
      "resultTitle": "Could not find login button",
      "evaluationThought": "The test failed because the login button was not visible on the page.",
      "promptGoal": "Test the login flow",
      "promptExamples": null
    }
  ]
}
Without testCases query param, the response has the same top-level fields but no runTestCases array (or it is empty).

Response Fields

FieldTypeDescription
idstring (UUID)Internal run identifier
shortIdstringRun short ID used in URLs
statusstringCurrent run status (see Status Values below)
resultstring | nullTest result when status is COMPLETED (see Result Values below)
runTestCasesarrayPresent when ?testCases=failed or ?testCases=all. Array of test case results.

Run Test Case Fields

FieldTypeDescription
idstring (UUID)Test case identifier
shortIdstringTest case short ID
namestringTest case name
statusstringTest case status
resultstring | nullTest result (e.g. FAILED, PASSED)
resultTitlestring | nullBrief failure/summary title
evaluationThoughtstring | nullDetailed explanation
promptGoalstring | nullOriginal test goal
promptExamplesstring | nullExample scenarios used

Status Values

StatusDescription
INITIATEDRun has been created but not started
RUNNINGTests are currently executing
COMPLETEDAll tests have finished
ERRORRun encountered an error
CANCELLEDRun was cancelled

Result Values

ResultDescription
PASSEDAll tests passed
FAILEDOne or more tests failed
SKIPPEDTests were skipped
nullRun is still in progress (status is INITIATED or RUNNING)

Error Handling

StatusDescription
400Invalid query parameters.
401Missing or invalid API key.
403Organization suspended.
404Run or project not found.
Responses can include a body such as: { "message": "..." }.
  • Start Run API – Trigger test runs programmatically
  • Rerun Tests – Rerun all or failed tests from a run
  • CI/CD Integration – Overview of integration modes and advanced use cases
  • GitLab CI – GitLab-specific integration examples with blocking mode