Results

Results viewer: the other side of a match

The code a match was found against: the peer submission's file for a peer match, or the cached copy of the external source for a web match, with the line ranges on both sides so a client can draw the comparison. AI matches have no counterpart. A web entry flagged is_legacy_web carries an id from a different table; send legacy: true for those. 404 means the source's text is simply not stored, which is a normal state for older web sources.

post/check/viewer/counterpart

Request

  • Base URL: https://codequiry.com/api/v1
  • URL: https://codequiry.com/api/v1/check/viewer/counterpart
  • Auth: API key in header apikey

Request body

check_idinteger required
submission_idinteger required
match_idinteger required

The id of an entry in matches or web_files.

legacyboolean

true when the entry's is_legacy_web is true.

Example request

{
  "check_id": 12345,
  "submission_id": 90271,
  "match_id": 1849201
}

Response

Counterpart text and line ranges

successboolean

Example response

{
  "success": true,
  "file": {
    "content": "package banking;\n",
    "filedir": "carter_ben_assignment4/BankAccount.java"
  },
  "match": {
    "line_start": 12,
    "line_end": 58,
    "line_matched_start": 10,
    "line_matched_end": 56,
    "similarity": 82
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.