---
title: "Create test run result"
method: POST
path: "/result/{code}/{id}"
tags: ["results"]
---

# Create test run result

`POST /result/{code}/{id}`

This method allows to create test run result by Run Id.

## Path parameters

- `code` string, required
- `id` integer, required

## Request body

- ResultCreate
  - `case_id` integer
  - `case` object — Could be used instead of `case_id`.
    - `title` string
    - `suite_title` string, nullable — Nested suites should be separated with `TAB` symbol.
    - `description` string, nullable
    - `preconditions` string, nullable
    - `postconditions` string, nullable
    - `layer` string — Slug of the layer. You can get it in the System Field settings.
    - `severity` string — Slug of the severity. You can get it in the System Field settings.
    - `priority` string — Slug of the priority. You can get it in the System Field settings.
  - `status` string, required — Can have the following values `passed`, `failed`, `blocked`, `skipped`, `invalid` + custom statuses
  - `start_time` integer, nullable
  - `time` integer, nullable
  - `time_ms` integer, nullable
  - `defect` boolean, nullable
  - `attachments` string[], nullable
  - `stacktrace` string, nullable
  - `comment` string, nullable
  - `param` object, nullable — A map of parameters (name => value)
  - `param_groups` array[], nullable — List parameter groups by name only. Add their values in the 'param' field
    - string[] — A list of parameters in group
  - `steps` TestStepResultCreate[], nullable
    - `position` integer
    - `status` 'passed' | 'failed' | 'blocked' | 'in_progress', required
    - `comment` string, nullable
    - `attachments` string[], nullable
    - `action` string
    - `expected_result` string, nullable
    - `data` string, nullable
    - `steps` object[] — Nested steps results may be passed here. Use same structure for them.
  - `author_id` integer, nullable

## Response `200`

A result.

- object
  - `status` boolean
  - `result` object
    - `case_id` integer
    - `hash` string

## Other responses

- `400` — Bad Request.
- `401` — Unauthorized.
- `403` — Forbidden.
- `404` — Not Found.
- `422` — Unprocessable Entity.
- `429` — Too Many Requests.

---

[API](https://skmtc.dev/qase/apis/qase-io-testops-api-v1.md) · [All operations](https://skmtc.dev/qase/apis/qase-io-testops-api-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/qase/qase-io-testops-api-v1/revisions/12ddc644fac5/schema)
