---
title: "List per-test results for a single submission."
method: GET
path: "/api/repos/{owner}/{name}/submissions/{submission_id}/tests"
tags: ["Submissions"]
---

# List per-test results for a single submission.

`GET /api/repos/{owner}/{name}/submissions/{submission_id}/tests`

## Request

- Base URL: `https://platform.buildpulse.io`
- URL: `https://platform.buildpulse.io/api/repos/{owner}/{name}/submissions/{submission_id}/tests`
- Auth: one of:
  - API key in header `Authorization`
  - HTTP bearer

Returns the individual test results recorded against one
submission (one CI run). Use `status=failed` to filter to just
the failures/errors — useful when triaging a red test run.

The submission identifier is the 24-char hex `id` returned by
`GET /api/repos/{owner}/{name}/submissions`. Each row carries
`conclusion` (`passing`/`failure`/`error`/`skipped`),
`duration_us` (per-attempt microseconds), `message` (failure
message, may be null), and the parent test case's name, suite,
file, and classname.

Repository lookup is case-insensitive; `OWNER/REPO` matches
`owner/repo`. The submission must belong to a repository the
caller's token can access — otherwise a 404 is returned (no
information is leaked about cross-tenant submissions).

## Path parameters

- `owner` string, required
- `name` string, required
- `submission_id` string, required

## Query parameters

- `status` 'all' | 'failed' | 'passed' | 'failure' | 'error' | 'skipped'
- `limit` integer
- `after` string

## Response `200`

Paginated test results for the submission.

- SubmissionTestsResponse
  - `count` integer, required: Total matching test results (not just this page).
  - `tests` SubmissionTest[], required
    - `id` string, required: Test result identifier (24-char hex ObjectID).
    - `test_case_id` string, required: Parent test case identifier (24-char hex ObjectID). Two results with the same `test_case_id` are different runs of the same logical test (e.g. retries within one submission).
    - `name` string, required
    - `suite` string, required
    - `class` string, required
    - `file` string, required
    - `conclusion` 'passing' | 'failure' | 'error' | 'skipped' | 'unknown', required: Outcome of this attempt. `failed` in the `status` filter matches both `failure` and `error`.
    - `duration_us` integer, required: Per-attempt duration in microseconds.
    - `message` string, nullable, required: One-line failure or error summary as recorded by the runner; null for passing / skipped.
    - `body` string, nullable, required: Full failure detail (assertion + stack trace); null for passing / skipped. Truncated at 2000 bytes on the wire (UTF-8 safe, never split mid-codepoint); the authoritative copy lives in the underlying testResults row.
    - `ran_at` string, date-time, required
    - `run_count` integer, required: Retry attempt number recorded by the test runner. `1` for the first attempt, `2` for the first retry, etc.
  - `metadata` Metadata, required
    - `after` string, nullable, required: Opaque cursor for the next page; `null` if there is no next page.
    - `limit` integer, required

## Other responses

- `400`: Cursor failed to decode.
- `401`: Missing, malformed, or invalid token; or — for legacy 40-hex tokens only — the organization has no active plan (`marketplacePurchases.unitCount > 0`). The new `bp_<64-hex>` path has no plan gate, so a 401 there means the token shape was wrong, the hash didn't match, or the token has expired. Response body is empty (matches legacy Rails).
- `402`: The organization is over its plan's monthly test-result limit and data-read access is restricted (staged-overage stage `soft` or `hard`). At `soft` the data is locked but safe — ingestion keeps recording. At `hard` ingestion is also paused (raw retained ~30 days) and an upgrade resumes processing. Read `GET /api/v1/usage` for the current stage and usage, and visit `upgradeUrl` to restore access. Only returned for organizations positively identified as over the enforced limit while enforcement is enabled.
- `404`: Resource not found.

---

[API](https://skmtc.dev/buildpulse/apis/buildpulse-platform-api.md) · [All operations](https://skmtc.dev/buildpulse/apis/buildpulse-platform-api/llms.txt) · [OpenAPI document](https://skmtc.dev/buildpulse/apis/buildpulse-platform-api/revisions/2e68b4b2df6a?raw)
