Results
Get a matched web file
Fetches the stored content of an external/web match. location and source come verbatim from a match object in /check/results - do not construct them by hand. You may only read a stored file that one of your own submissions matched against: a file that exists but belongs to another account returns 403, and a location/source pair that matches nothing returns 404.
post/check/getRemoteFile
Request
- Base URL: https://codequiry.com/api/v1
- URL: https://codequiry.com/api/v1/check/getRemoteFile
- Auth: API key in header apikey
Request body
Example request
{
"location": "src/BankAccount.java",
"source": "https://github.com/example-org/banking-utils/blob/main/src/BankAccount.java"
}Response
Stored web file
Example response
{
"file": {
"id": 1148302,
"filedir": "src/BankAccount.java",
"filename": "BankAccount.java",
"content": "package banking;\n\nimport java.util.ArrayList;\nimport java.util.List;\n\npublic class BankAccount {\n private final List<String> ledger = new ArrayList<>();\n private double balance;\n\n public void deposit(double amount) {\n if (amount <= 0) throw new IllegalArgumentException(\"amount must be positive\");\n balance += amount;\n ledger.add(\"deposit \" + amount);\n }\n}\n",
"language_id": 13,
"location": "src/BankAccount.java",
"source": "https://github.com/example-org/banking-utils/blob/main/src/BankAccount.java"
}
}Changes
No recorded changes to this operation across all 1 revision of this API.