Developer Resources

Quantik Mind™ API

Integrate Quantik Mind™ adaptive test selection into your CI/CD pipeline. Use the API to manage projects, sync test libraries, request selected test subsets, inspect runs, retrieve decision insights, and power custom engineering dashboards.

Base URLhttps://api.quantikmind.com/api/v1

Overview

Quantik Mind™ selects the functional tests that carry the most execution value for the current change and risk context. Your existing test runner executes the returned selectors. The API supports direct CI/CD automation, repository integration, runtime-signal ingestion, run inspection, and custom engineering dashboards without requiring the CLI.

1

Sync test library

2

Request selection

3

Inspect results

Authentication

Authenticated APIs accept either a user-session JWT or a project-scoped service-account API key. Service-account keys are designed for CI/CD and server-to-server automation. Generate them with the credential lifecycle endpoints below or through the Quantik Mind™ app, copy the key when it is created, and store it in CI/CD secrets or a server-side secret manager.

Send credentials with Authorization: Bearer <credential>. Service-account API keys also support the X-QM-API-Key header. Bearer authentication is preferred because it works consistently for both user tokens and API keys.

Show code ↓Hide code ↑
Authenticated request headers
Authorization: Bearer <user-jwt-or-api-key>
Content-Type: application/json
API keys are project-scoped and permission-scoped. Grant only the scopes required by the integration. A revoked key, an inactive key, or a disabled service account returns HTTP 401.

API credentials and service accounts

POST

/auth/login

Authenticates a user and returns an organization-scoped JWT access token. Use service-account API keys for unattended CI/CD automation.

Authentication
Not required.
Request body
email: string password: string
Response fields

access_token, token_type, user, organization, admin. The response also establishes secure refresh cookies for browser sessions.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/auth/login" -H "Content-Type: application/json" -d '{"email":"developer@example.com","password":"<password>"}'
Show code ↓Hide code ↑
JSON response
{"access_token":"<jwt>","token_type":"bearer","user":{"id":"<uuid>","username":"developer","email":"developer@example.com","full_name":"Developer","email_verified":true},"organization":{"id":"<uuid>","name":"Acme Engineering","slug":"acme-engineering"},"admin":true}
GET

/auth/me

Returns the identity and scope context resolved from the current user token or service-account API key.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Response fields

For service accounts: principal_type, user_id, organization_id, project_id, scopes, service_account_id, api_key_id, iss. User credentials return user and organization identity fields.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/auth/me" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"principal_type":"service_account","user_id":null,"organization_id":"<uuid>","project_id":"<uuid>","scopes":["library:read","selection:run","results:read"],"service_account_id":"<uuid>","api_key_id":"<uuid>","iss":"quantikmind"}
GET

/service-accounts/api-key-scopes

Lists grantable API-key scopes and available scope presets.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
None.
Response fields

scopes, presets

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/service-accounts/api-key-scopes" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
{"scopes":["library:read","library:write","selection:run","results:read"],"presets":{"CLI full project workflow":["library:read","library:write","selection:run","results:read"]}}
GET

/service-accounts

Lists service accounts attached to a project.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

Array of id, organization_id, project_id, name, description, is_active, created_at, updated_at, last_used_at.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/service-accounts?project_id=$PROJECT_ID" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
[{"id":"<uuid>","organization_id":"<uuid>","project_id":"<uuid>","name":"ci-production","description":"CI/CD automation","is_active":true,"created_at":"<timestamp>","updated_at":"<timestamp>","last_used_at":null}]
POST

/service-accounts

Creates a project-scoped service account for machine-to-machine automation.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
project_id: string (required) name: string (required) description: string | null
Response fields

Service-account fields: id, organization_id, project_id, name, description, is_active, created_at, updated_at, last_used_at.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/service-accounts" -H "Authorization: Bearer $USER_TOKEN" -H "Content-Type: application/json" -d '{"project_id":"'$PROJECT_ID'","name":"ci-production","description":"CI/CD automation"}'
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","organization_id":"<uuid>","project_id":"<uuid>","name":"ci-production","description":"CI/CD automation","is_active":true,"created_at":"<timestamp>","updated_at":"<timestamp>","last_used_at":null}
PATCH

/service-accounts/{service_account_id}

Updates a service-account name, description, or active state.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
name: string | null description: string | null is_active: boolean | null
Path parameterDescription
service_account_idService-account UUID.
Response fields

Updated service-account fields.

Show code ↓Hide code ↑
curl request
curl -X PATCH "https://api.quantikmind.com/api/v1/service-accounts/$SERVICE_ACCOUNT_ID" -H "Authorization: Bearer $USER_TOKEN" -H "Content-Type: application/json" -d '{"name":"ci-main","is_active":true}'
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","project_id":"<uuid>","name":"ci-main","is_active":true,"updated_at":"<timestamp>"}
DELETE

/service-accounts/{service_account_id}

Deactivates a service account.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
None.
Path parameterDescription
service_account_idService-account UUID.
Response fields

The deactivated service-account record with is_active set to false.

Show code ↓Hide code ↑
curl request
curl -X DELETE "https://api.quantikmind.com/api/v1/service-accounts/$SERVICE_ACCOUNT_ID" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","project_id":"<uuid>","name":"ci-main","is_active":false,"updated_at":"<timestamp>"}
POST

/service-accounts/{service_account_id}/api-keys

Creates an API key. The full key is returned once; copy it immediately and store it as a CI/CD secret.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
name: string | null scopes: string[] (defaults to all grantable project workflow scopes)
Path parameterDescription
service_account_idService-account UUID.
Response fields

api_key, key_prefix, service_account_id, warning.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/service-accounts/$SERVICE_ACCOUNT_ID/api-keys" -H "Authorization: Bearer $USER_TOKEN" -H "Content-Type: application/json" -d '{"name":"github-actions","scopes":["library:read","library:write","selection:read","selection:run","results:read"]}'
Show code ↓Hide code ↑
JSON response
{"api_key":"qm_sk_live_<secret>","key_prefix":"qm_sk_live_<prefix>","service_account_id":"<uuid>","warning":"Copy this key now. It will not be shown again."}
GET

/service-accounts/{service_account_id}/api-keys

Lists API-key metadata without exposing secret key values.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
None.
Path parameterDescription
service_account_idService-account UUID.
Response fields

Array of id, key_prefix, name, scopes, is_active, created_at, last_used_at, revoked_at.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/service-accounts/$SERVICE_ACCOUNT_ID/api-keys" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
[{"id":"<uuid>","key_prefix":"qm_sk_live_<prefix>","name":"github-actions","scopes":["selection:run","results:read"],"is_active":true,"created_at":"<timestamp>","last_used_at":null,"revoked_at":null}]
DELETE

/service-accounts/api-keys/{api_key_id}

Revokes an API key. To rotate a key, create a replacement, update your secret store, then revoke the old key.

Authentication
Required. User JWT with project owner or organization administrator access.
Request body
None.
Path parameterDescription
api_key_idAPI-key UUID.
Response fields

API-key metadata with is_active false and revoked_at populated.

Show code ↓Hide code ↑
curl request
curl -X DELETE "https://api.quantikmind.com/api/v1/service-accounts/api-keys/$API_KEY_ID" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","key_prefix":"qm_sk_live_<prefix>","name":"github-actions","scopes":["selection:run"],"is_active":false,"revoked_at":"<timestamp>"}

Projects

GET

/projects/

Lists projects visible to the user or the single project assigned to a project-scoped API key.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Response fields

Array of id, project_id, name, created_at.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/projects/" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
[{"id":"<uuid>","project_id":"checkout-service","name":"Checkout Service","created_at":"<timestamp>"}]
POST

/projects/

Creates a project in the authenticated organization. Project creation requires a user session.

Authentication
Required. User JWT; service-account keys cannot create projects.
Request body
name: string (required) project_id: string | null (lowercase letters, numbers, and hyphens)
Response fields

id, project_id, name, created_at.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/projects/" -H "Authorization: Bearer $USER_TOKEN" -H "Content-Type: application/json" -d '{"name":"Checkout Service","project_id":"checkout-service"}'
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","project_id":"checkout-service","name":"Checkout Service","created_at":"<timestamp>"}
GET

/projects/{project_id}

Retrieves one project by its internal UUID.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Path parameterDescription
project_idInternal project UUID.
Response fields

id, project_id, name, created_at.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/projects/$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"id":"<uuid>","project_id":"checkout-service","name":"Checkout Service","created_at":"<timestamp>"}

Test Library

POST

/functional/library/upload-library

Bulk upserts a functional test library for a project.

Authentication
Required. library:write scope for API keys.
Request body
JSON array. Each item requires test_id, name, and service. Optional: suite, business_criticality, tags, avg_duration_ms, framework, test_level, timeout_ms, parallelizable, repo_ref, code_mapping, constraints.
Query parameterDescription
project_idRequired project UUID.
Response fields

added, updated, skipped, errors, estimated_durations, duration_estimation_source.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/functional/library/upload-library?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '[{"test_id":"checkout.spec.ts:places-order","name":"places order","service":"checkout","suite":"e2e","framework":"playwright","tags":["checkout"]}]'
Show code ↓Hide code ↑
JSON response
{"added":1,"updated":0,"skipped":0,"errors":[],"estimated_durations":0,"duration_estimation_source":null}
GET

/functional/library

Retrieves all functional tests in a project library.

Authentication
Required. library:read scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

data array of test records and total. Test records include id, project_id, test_id, name, service, suite, business_criticality, tags, duration/framework fields, repository mapping, constraints, library_source, timestamps.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/functional/library?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"data":[{"id":42,"project_id":"<uuid>","test_id":"checkout.spec.ts:places-order","name":"places order","service":"checkout","suite":"e2e","business_criticality":"medium","tags":["checkout"],"framework":"playwright","parallelizable":true,"library_source":"manual","is_sample_library":false,"created_at":"<timestamp>","updated_at":"<timestamp>"}],"total":1}
POST

/functional/library

Creates one functional test definition.

Authentication
Required. library:write scope for API keys.
Request body
test_id, name, service (required); suite, business_criticality, tags, avg_duration_ms, framework, test_level, timeout_ms, parallelizable, repo_ref, code_mapping, constraints (optional).
Query parameterDescription
project_idRequired project UUID.
Response fields

The complete functional test record.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/functional/library?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '{"test_id":"checkout.spec.ts:places-order","name":"places order","service":"checkout","framework":"playwright"}'
Show code ↓Hide code ↑
JSON response
{"id":42,"project_id":"<uuid>","test_id":"checkout.spec.ts:places-order","name":"places order","service":"checkout","suite":"default","business_criticality":"medium","tags":[],"framework":"playwright","parallelizable":true,"library_source":"manual","is_sample_library":false,"created_at":"<timestamp>","updated_at":"<timestamp>"}
DELETE

/functional/library/{id}

Deletes one functional test and its directly related results and selection rows.

Authentication
Required. library:write scope for API keys.
Request body
None.
Path parameterDescription
idNumeric functional-library record ID. This is not the external test_id.
Response fields

message.

Show code ↓Hide code ↑
curl request
curl -X DELETE "https://api.quantikmind.com/api/v1/functional/library/$TEST_RECORD_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"message":"Test deleted"}
DELETE

/functional/library

Deletes every functional test in a project library.

Authentication
Required. library:write scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

deleted, message.

Show code ↓Hide code ↑
curl request
curl -X DELETE "https://api.quantikmind.com/api/v1/functional/library?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"deleted":24,"message":"24 tests deleted"}

Execution History

POST

/functional/history/import

Imports prior test execution history so selection can learn from outcomes and durations.

Authentication
Required. results:write or history:write scope for API keys.
Request body
project_id: string records: array of objects requiring test_id, status, duration_ms, executed_at. Optional: service, component, commit_sha, branch, failure_reason, is_flaky.
Response fields

status, records_imported, records_rejected, first_execution_at, last_execution_at, errors.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/functional/history/import" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '{"project_id":"'$PROJECT_ID'","records":[{"test_id":"checkout.spec.ts:places-order","status":"passed","duration_ms":1240,"executed_at":"2026-04-20T09:15:00Z","service":"checkout"}]}'
Show code ↓Hide code ↑
JSON response
{"status":"imported","records_imported":1,"records_rejected":0,"first_execution_at":"2026-04-20T09:15:00","last_execution_at":"2026-04-20T09:15:00","errors":[]}
GET

/functional/history/summary

Returns the imported execution-history coverage for a project.

Authentication
Required. results:read or history:read scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

status, records_imported, first_execution_at, last_execution_at.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/functional/history/summary?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"status":"imported","records_imported":1250,"first_execution_at":"<timestamp>","last_execution_at":"<timestamp>"}

Adaptive Test Selection

GET

/functional/signal-readiness

Checks whether the project has the library, history, and runtime signals needed for selection.

Authentication
Required. selection:read or selection:run scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired unless the API key is already project-scoped.
Response fields

project_id, state, signal_state, library flags, sample counters, history/runtime flags, feature-enable flags, effective_mode.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/functional/signal-readiness?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"project_id":"<uuid>","state":"ready","signal_state":"ready","has_test_library":true,"has_sample_library":false,"has_real_library":true,"sample_selection_count":0,"sample_selection_limit":3,"sample_limit_reached":false,"has_historical_signal":true,"has_runtime_signal":true,"test_library_enabled":true,"historical_data_enabled":true,"observability_enabled":true,"effective_mode":"ready"}
GET

/functional/select

Creates an adaptive functional selection run and returns the selected test subset for the existing runner to execute.

Authentication
Required. selection:read or selection:run scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired unless the API key is project-scoped.
lookback_commits_hoursCommit lookback window; default 24, use 0 to disable discovery.
changed_filesRepeat for each explicitly changed path; overrides commit discovery.
Response fields

run_id, project_id, tau, library_mode, counts, selected, top_candidates, reduction_percentage, business_metrics, dependency/avoidance counts, impact_snapshot, why_these_tests, commit_consideration. Each selected item includes test_id, internal_test_id, test_name, cli_selector, service, service_instance, origin, execution_value, p_initial, selected, commit_affected, reason.

Show code ↓Hide code ↑
curl request
curl --get "https://api.quantikmind.com/api/v1/functional/select" -H "Authorization: Bearer $QM_API_KEY" --data-urlencode "project_id=$PROJECT_ID" --data-urlencode "changed_files=src/checkout.ts"
Show code ↓Hide code ↑
JSON response
{"run_id":"<uuid>","project_id":"<uuid>","tau":0.5,"library_mode":"real","counts":{"total":120,"selected":31},"selected":[{"test_id":"checkout.spec.ts:places-order","internal_test_id":42,"test_name":"places order","cli_selector":"checkout.spec.ts:places-order","service":"checkout","origin":"adaptive","execution_value":91.4,"p_initial":84.2,"selected":true,"commit_affected":true,"reason":"Changed checkout path"}],"reduction_percentage":74.2,"business_metrics":{"total_tests":120,"selected_tests":31,"risk_coverage":92.4,"residual_risk":7.6,"tests_reduced":74.2},"why_these_tests":{"title":"Why these tests?","bullets":["Selected tests cover high-impact services."],"note":null,"sample_mode":false},"commit_consideration":{"enabled":true,"lookback_hours":24,"affected_tests":8,"tests_with_boost":5}}

Runs and Decision Insights

GET

/runs/

Lists selection runs for history tables and dashboards.

Authentication
Required. results:read or selection:read scope for API keys.
Request body
None.
Query parameterDescription
project_idOptional project UUID filter.
limit1–1000; default 20.
offsetPagination offset; default 0.
run_typeUse functional for the public test-selection workflow.
Response fields

total and data. Each summary includes run identity/source/status/timestamps, execution time, total_experiments, selected_experiments, reduction and coverage fields, risk metrics, high-risk coverage, and avoidance counts.

Show code ↓Hide code ↑
curl request
curl --get "https://api.quantikmind.com/api/v1/runs/" -H "Authorization: Bearer $QM_API_KEY" --data-urlencode "project_id=$PROJECT_ID" --data-urlencode "run_type=functional" --data-urlencode "limit=20"
Show code ↓Hide code ↑
JSON response
{"total":1,"data":[{"run_id":"<uuid>","project_id":"<uuid>","run_type":"functional","run_source":"ci","status":"completed","created_at":"<timestamp>","execution_time_ms":842,"total_experiments":120,"selected_experiments":31,"reduction_percentage":74.2,"risk_coverage":92.4,"top_risk_coverage":96.0,"high_risk_coverage":98.0,"always_green_avoided":18}]}
GET

/runs/{run_id}/status

Returns lightweight lifecycle state for polling an asynchronous run.

Authentication
Required. results:read or selection:read scope for API keys.
Request body
None.
Path parameterDescription
run_idRun UUID.
Response fields

run_id, project_id, run_type, status, lifecycle timestamps, execution_time_ms, error_message, total_tests, selected_tests, reduction_percentage, risk_coverage, result_available, result_url.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/runs/$RUN_ID/status" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"run_id":"<uuid>","project_id":"<uuid>","run_type":"functional","status":"completed","completed_at":"<timestamp>","execution_time_ms":842,"total_tests":120,"selected_tests":31,"reduction_percentage":74.2,"risk_coverage":92.4,"result_available":true,"result_url":"/runs/<uuid>"}
GET

/runs/{run_id}

Retrieves detailed run metrics and selected test rows.

Authentication
Required. results:read or selection:read scope for API keys.
Request body
None.
Path parameterDescription
run_idRun UUID.
Response fields

Run identity/status/timestamps, total_experiments, selected_experiments, reduction_percentage, risk fields, test coverage, efficiency, business_metrics, duration and avoidance fields, contribution summaries, and experiments. Each experiment contains id, service, selection_reason, prediction, selection_causes, risk_score, selected, breakdown, and reasons.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/runs/$RUN_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"run_id":"<uuid>","run_type":"functional","status":"completed","project_id":"<uuid>","created_at":"<timestamp>","total_experiments":120,"selected_experiments":31,"reduction_percentage":74.2,"risk_coverage":92.4,"risk_efficiency":3.58,"business_metrics":{"total_tests":120,"selected_tests":31},"redundant_tests_avoided":12,"dependency_aware_tests_added":4,"experiments":[{"id":"42","service":"checkout","selection_reason":"Changed checkout path","prediction":0.91,"risk_score":0.84,"selected":true,"breakdown":{},"reasons":{}}]}
GET

/runs/{run_id}/skipped-tests

Returns paginated skipped-test analysis and residual-risk context for a functional run.

Authentication
Required. results:read or selection:read scope for API keys.
Request body
None.
Path parameterDescription
run_idFunctional run UUID.
Query parameterDescription
pagePage number; default 1.
page_size1–200; default 50.
risk_bucketOptional risk bucket filter.
reasonOptional skip-reason filter.
serviceOptional service filter.
is_always_greenOptional boolean filter.
is_redundantOptional boolean filter.
Response fields

summary, residual_risk_profile, pagination, rows. Rows expose test identity, service, risk/execution values, risk bucket, skip reason, stability/redundancy flags, coverage relationship, and business_skip_reason.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/runs/$RUN_ID/skipped-tests?page=1&page_size=50" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"summary":{"run_id":"<uuid>","total_candidates":120,"selected_count":31,"skipped_count":89,"total_skipped_count":89,"always_green_avoided_count":18,"redundant_tests_avoided_count":12,"high_risk_skipped_count":1,"medium_risk_skipped_count":14,"low_risk_skipped_count":74,"redundancy_tracking_available":true},"residual_risk_profile":{"high":1.0,"medium":14.0,"low":74.0,"quality_label":"controlled"},"pagination":{"page":1,"page_size":50,"total":89,"filtered_count":89,"total_skipped_count":89,"total_pages":2},"rows":[{"id":88,"test_id":88,"test_case_identifier":"profile.spec.ts:updates-name","service":"profile","dynamic_risk_signal":0.12,"execution_value":0.09,"risk_bucket":"low","skip_reason":"low_signal","is_always_green":true,"is_redundant":false,"business_skip_reason":"Stable low-signal test"}]}
GET

/functional/runs/{run_id}/decision-insight

Returns compact decision KPIs for a functional selection run.

Authentication
Required. results:read or selection:read scope for API keys.
Request body
None.
Path parameterDescription
run_idRun UUID.
Response fields

run_id, project_id, run_type, created_at, tests totals/reduction, selection-state distribution, risk coverage/efficiency/top25_share, and always-green avoidance.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/functional/runs/$RUN_ID/decision-insight" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"run_id":"<uuid>","project_id":"<uuid>","run_type":"functional","created_at":"<timestamp>","tests":{"total":120,"selected":31,"reduction_percentage":74.2},"quantum":{"distribution":{"superposition":12,"entanglement":8,"uncertainty":11}},"risk":{"coverage_percentage":92.4,"efficiency":3.6,"top25_share":76.1},"always_green":{"avoided":18,"avoided_percentage":15.0}}
GET

/runs/{run_id}/analytics

Returns trend and service heatmap data centered on a run. This endpoint requires a user session.

Authentication
Required. User JWT only. Service-account API keys are not supported for this endpoint.
Request body
None.
Path parameterDescription
run_idRun UUID.
Response fields

trendData and heatmapData. Trend points include runId, date, dateLabel, coveragePct, effortPct, efficiencyScore, isCurrent. Heatmap cells include service, runId, avgRisk, color.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/runs/$RUN_ID/analytics" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
{"trendData":[{"runId":"<uuid>","date":"2026-06-28","dateLabel":"28 Jun","coveragePct":92.4,"effortPct":25.8,"efficiencyScore":3.58,"isCurrent":true}],"heatmapData":[[{"service":"checkout","runId":"<uuid>","avgRisk":84.2,"color":"high"}]]}

Build your own dashboard

Use the run and decision insight endpoints to retrieve selection history, selected tests, skipped tests, risk coverage, reduction, and decision rationale for your own internal dashboards.

GET

/metrics/quality

Returns quality, coverage, efficiency, and test-savings KPIs for one project or all visible projects.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
project_idOptional project UUID.
days1–365; default 30.
Response fields

quality_score, risk_coverage, test_efficiency, cost_savings_percentage, total_runs, period_days.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/metrics/quality?project_id=$PROJECT_ID&days=30" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"quality_score":0.88,"risk_coverage":92.4,"test_efficiency":25.8,"cost_savings_percentage":74.2,"total_runs":42,"period_days":30}
GET

/metrics/system

Returns organization-level run and selection totals for an engineering dashboard.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
days1–365; default 30.
Response fields

total_runs, total_tests_executed, total_tests_selected, average_reduction, total_carbon_saved_kg, active_projects, period_days.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/metrics/system?days=30" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"total_runs":84,"total_tests_executed":10080,"total_tests_selected":2640,"average_reduction":73.81,"total_carbon_saved_kg":1.284,"active_projects":3,"period_days":30}
GET

/analytics/efficiency-trend

Returns run-level risk coverage, test effort, and efficiency points for trend charts.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
project_idOptional project UUID.
daysAccepted period parameter. Results are based on available run history and returned with period_days.
run_typeUse functional.
max_runs10–100; default 50.
Response fields

data array with date, risk_coverage, tests_executed_pct, efficiency_score; period_days.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/analytics/efficiency-trend?project_id=$PROJECT_ID&run_type=functional&max_runs=50" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"data":[{"date":"2026-06-28","risk_coverage":92.4,"tests_executed_pct":25.8,"efficiency_score":3.58}],"period_days":30}
GET

/analytics/service-risk-heatmap

Returns recent run columns and ranked service-risk cells for heatmap visualizations.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
project_idOptional project UUID.
num_runs3–20; default 7.
top_services5–15; default 8.
run_typeUse functional.
current_run_idOptional run that must be included.
Response fields

runs array and data cells containing service, run_id, run_number, rank, risk_percentage, risk_level.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/analytics/service-risk-heatmap?project_id=$PROJECT_ID&run_type=functional&num_runs=7&top_services=8" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"runs":[{"run_id":"<uuid>","run_number":1}],"data":[{"service":"checkout","run_id":"<uuid>","run_number":1,"rank":1,"risk_percentage":84.2,"risk_level":"high"}]}
GET

/analytics/what-if-comparison

Returns selection-versus-baseline values for dashboard comparison cards.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
project_idOptional project UUID.
daysAccepted period parameter. Results are based on available run history and returned with period_days.
run_idOptional current run UUID.
Response fields

quantum_tests_pct, quantum_risk_coverage, quantum_time_minutes, random_tests_pct, random_risk_coverage, random_time_minutes, full_suite_tests_pct, full_suite_risk_coverage, full_suite_time_minutes, efficiency_multiplier, baseline_source, baseline_source_label.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/analytics/what-if-comparison?project_id=$PROJECT_ID&run_id=$RUN_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"quantum_tests_pct":25.8,"quantum_risk_coverage":92.4,"quantum_time_minutes":18.2,"random_tests_pct":50.0,"random_risk_coverage":50.0,"random_time_minutes":35.3,"full_suite_tests_pct":100.0,"full_suite_risk_coverage":100.0,"full_suite_time_minutes":70.6,"efficiency_multiplier":3.58,"baseline_source":"project_runs","baseline_source_label":"Project history"}
GET

/analytics/avg-test-duration

Returns the average configured functional test duration for a project.

Authentication
Required. User JWT or service-account API key.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

avg_duration_ms.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/analytics/avg-test-duration?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"avg_duration_ms":1842.5}

Project Settings

GET

/settings

Returns normalized project configuration for an organization administrator or explicit project owner.

Authentication
Required. User JWT only; organization administrator or project owner access.
Request body
None.
Query parameterDescription
project_idRequired internal project UUID.
Response fields

projectName, testedSystemUrl, environment, thresholds, prometheusUrl, inheritedPrometheusUrl, Prometheus profile status/job fields, queryRange, customQueries, testLibraryEnabled, historicalDataEnabled, observabilityEnabled, notificationConfig, versions, canEditSettings.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/settings?project_id=$PROJECT_ID" -H "Authorization: Bearer $USER_TOKEN"
Show code ↓Hide code ↑
JSON response
{"projectName":"Checkout Service","testedSystemUrl":"https://checkout.example.com","environment":"staging","thresholds":{"tau":0.5},"prometheusUrl":"https://prometheus.example.com","inheritedPrometheusUrl":"","prometheusProfileConfigured":true,"prometheusConfigSource":"project","prometheusProfileReady":true,"prometheusDiscoveredJobs":["checkout"],"prometheusValidJobs":["checkout"],"prometheusSelectedJob":"checkout","prometheusJobAmbiguous":false,"prometheusJobValidationError":null,"queryRange":"15m","customQueries":{},"testLibraryEnabled":true,"historicalDataEnabled":true,"observabilityEnabled":true,"notificationConfig":{},"versions":[],"canEditSettings":true}
PUT

/settings

Partially updates project configuration for an organization administrator or explicit project owner.

Authentication
Required. User JWT only; organization administrator or project owner access.
Request body
Any subset of: projectName, testedSystemUrl, environment, thresholds, prometheusUrl, prometheusSelectedJob, queryRange, customQueries, testLibraryEnabled, historicalDataEnabled, observabilityEnabled, notificationConfig, versions.
Query parameterDescription
project_idRequired internal project UUID.
Response fields

message, project_id, and observability readiness fields when a Prometheus profile is updated.

Show code ↓Hide code ↑
curl request
curl -X PUT "https://api.quantikmind.com/api/v1/settings?project_id=$PROJECT_ID" -H "Authorization: Bearer $USER_TOKEN" -H "Content-Type: application/json" -d '{"environment":"staging","testLibraryEnabled":true,"historicalDataEnabled":true,"observabilityEnabled":true}'
Show code ↓Hide code ↑
JSON response
{"message":"Settings updated successfully","project_id":"<uuid>"}

Repository, Webhook, and Runtime Signals

POST

/functional/commits/record

Records build commit metadata for change-aware selection.

Authentication
Required. build:write scope for API keys.
Request body
project_id, commit_hash (required); message, author, branch, files_changed (optional).
Response fields

status and commit. Status is ok or duplicate.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/functional/commits/record" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '{"project_id":"'$PROJECT_ID'","commit_hash":"5f1a3c9","message":"Update checkout","branch":"main","files_changed":["src/checkout.ts"]}'
Show code ↓Hide code ↑
JSON response
{"status":"ok","commit":"5f1a3c9"}
GET

/functional/commits/recent

Lists recently recorded commits for a project.

Authentication
Required. Project access required.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
hours1–720; default 24.
Response fields

project_id and commits. Each commit includes commit_hash, message, author, commit_type, files_changed, timestamp.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/functional/commits/recent?project_id=$PROJECT_ID&hours=24" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"project_id":"<uuid>","commits":[{"commit_hash":"5f1a3c9","message":"Update checkout","author":"developer@example.com","commit_type":"feature","files_changed":["src/checkout.ts"],"timestamp":"<timestamp>"}]}
POST

/functional/commits/webhook

Receives GitHub push events for repositories linked to a project. When a webhook secret is configured, GitHub HMAC signature validation is mandatory.

Authentication
No user token. Send GitHub webhook headers; X-Hub-Signature-256 is required when webhook signing is enabled.
Request body
Native GitHub push payload containing repository and commits.
Response fields

status, project_id, repository, commits_processed. Unlinked repositories return status ignored and a reason.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/functional/commits/webhook" -H "Content-Type: application/json" -H "X-GitHub-Event: push" -H "X-Hub-Signature-256: sha256=<signature>" --data-binary @github-push.json
Show code ↓Hide code ↑
JSON response
{"status":"ok","project_id":"<uuid>","repository":"acme/checkout","commits_processed":2}
PUT

/observability/prometheus

Configures Prometheus runtime signals for adaptive selection.

Authentication
Required. observability:write scope for API keys.
Request body
project_id, url (required); service_label, lookback, job, jobs, job_regex, mode, signals, services (optional). Signal definitions contain query, unit, direction, weight.
Response fields

status, project_id, provider, service_label, configured/validated/detected/missing/invalid signals, profile state/mode/source, effective job fields, readiness details.

Show code ↓Hide code ↑
curl request
curl -X PUT "https://api.quantikmind.com/api/v1/observability/prometheus" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '{"project_id":"'$PROJECT_ID'","url":"https://prometheus.example.com","service_label":"service","lookback":"5m"}'
Show code ↓Hide code ↑
JSON response
{"status":"configured","project_id":"<uuid>","provider":"prometheus","service_label":"service","configured_signals":[],"validated_signals":[],"detected_signals":[],"missing_signals":[],"invalid_signals":[],"profile_state":"ready","mode":"autodiscovered","profile_source":"autodiscovery","selected_job":"application","profile_ready":true,"job_validation_error":null}
GET

/observability/status

Returns runtime-signal readiness and Prometheus profile status for a project.

Authentication
Required. observability:read scope for API keys.
Request body
None.
Query parameterDescription
project_idRequired project UUID.
Response fields

project_id, provider, status, readiness, service_label, configured/validated/detected/missing/invalid signals, mode/source/job fields, enabled/readiness flags, details.

Show code ↓Hide code ↑
curl request
curl "https://api.quantikmind.com/api/v1/observability/status?project_id=$PROJECT_ID" -H "Authorization: Bearer $QM_API_KEY"
Show code ↓Hide code ↑
JSON response
{"project_id":"<uuid>","provider":"prometheus","status":"ready","readiness":"ready","service_label":"service","configured_signals":["error_rate","latency_p95"],"validated_signals":["error_rate","latency_p95"],"missing_signals":[],"invalid_signals":[],"observability_enabled":true,"profile_ready":true,"details":""}
POST

/agent/metrics

Ingests service-level runtime metrics from a customer-operated agent.

Authentication
Required. User JWT or service-account API key.
Request body
project_id: UUID timestamp: ISO timestamp metrics: object keyed by service; each value may include cpu_load, error_rate, request_rate, latency_p95.
Response fields

received, services_processed.

Show code ↓Hide code ↑
curl request
curl -X POST "https://api.quantikmind.com/api/v1/agent/metrics" -H "Authorization: Bearer $QM_API_KEY" -H "Content-Type: application/json" -d '{"project_id":"'$PROJECT_ID'","timestamp":"2026-06-28T12:00:00Z","metrics":{"checkout":{"error_rate":0.02,"request_rate":180,"latency_p95":420}}}'
Show code ↓Hide code ↑
JSON response
{"received":true,"services_processed":1}

Error codes and rate limits

StatusMeaning
400Missing project context, empty library/history input, unsupported run type, or invalid request state.
401Missing, invalid, expired, revoked, or disabled credentials; invalid webhook signature.
403Credential lacks organization, project, ownership, or required scope access.
404Project, run, test, service account, or API key was not found in the caller's tenant scope.
409Project identifier already exists.
422Request validation failed or observability configuration is invalid.
429A configured request limit was exceeded.
500The server could not complete the operation.

Error responses use a detail field. Rate limits may vary by workspace and deployment context. Selection, library reads, signup, and selected high-cost operations enforce configured limits.

Show code ↓Hide code ↑
Error response
{
  "detail": "Project not found"
}