---
title: "Get a check"
method: POST
path: "/check/get"
tags: ["Checks"]
---

# Get a check

`POST /check/get`

## Request

- Base URL: `https://codequiry.com/api/v1`
- URL: `https://codequiry.com/api/v1/check/get`
- Auth: API key in header `apikey`

Returns a check with its status, submission count, and submissions.

## Request body

- object
  - `check_id` integer, required

## Response `200`

Check detail

- object
  - `check` Check: A check (internally an assignment). Endpoints return the full assignment row, so more fields are present than are listed here; only the stable, documented ones are shown.
    - `stats` object, nullable: Present only when the list was requested with with_stats=1. Averages and maxima are over finished submissions and are null when there are none.
      - `submissions` integer
      - `completed` integer
      - `failed` integer
      - `avg_group` number, nullable
      - `max_group` number, nullable
      - `avg_web` number, nullable
      - `max_web` number, nullable
      - `flagged` integer: Finished submissions at or above 75% Group or Web.
      - `avg_ai` number, nullable
      - `max_ai` number, nullable
      - `ai_submissions` integer
      - `ai_flagged` integer: Submissions whose mean AI probability is 75% or more.
      - `matches` integer: Match total as the dashboard counts it: peer fragments, web sources (one per source) and AI blocks.
    - `id` integer
    - `name` string
    - `status_id` integer
    - `language_id` integer
    - `test_type` integer
    - `ai_run` integer: 1 if AI-generated-code detection runs for this check.
    - `base_code_detection` integer: 1 if base/boilerplate-code detection is enabled.
    - `created_at` string
    - `updated_at` string
    - `assignmentstatuses` object: Expanded status, included only by GET/POST /checks. Not returned by /check/create, /check/get or /check/update - use status_id there, or the top-level status string that /check/get returns.
      - `id` integer
      - `status` string
  - `status` string
  - `submission_count` integer
  - `submissions` Submission[]
    - `id` integer
    - `assignment_id` integer
    - `filename` string
    - `status_id` integer
    - `total_result` number
    - `result_web` number
    - `submissionresults` object[]: One row per peer submission this one scored against, highest score first.
      - `id` integer
      - `submission_id` integer
      - `submission_id_compared` integer
      - `score` number: Similarity percentage against that submission.
      - `file` string
      - `file_matched` string
      - `lines` integer: Lines covered by the matched region.
      - `longest` integer: Longest single matched run, in lines.
      - `location` string: Empty for peer matches; the path within the source for web matches.
      - `source` string

## Other responses

- `401`: Missing or invalid API key. The API key is checked before any endpoint logic runs, so this is returned for every operation.
- `402`: The account is suspended for an unpaid invoice. Every endpoint returns this until the invoice is paid from the billing dashboard; it is not retryable and the request was not performed.
- `422`: Request validation failed.
- `429`: Rate limit exceeded: more than 60 requests in one minute from this IP. Retry after the number of seconds in the Retry-After header. Successful responses carry X-RateLimit-Limit and X-RateLimit-Remaining too, so you can pace a client without waiting to be refused.

---

[API](https://skmtc.dev/codequiry/apis/codequiry-api.md) · [All operations](https://skmtc.dev/codequiry/apis/codequiry-api/llms.txt) · [OpenAPI document](https://skmtc.dev/codequiry/apis/codequiry-api/revisions/6297e91d9665?raw)
