Developer API

Code Plagiarism
Detection API

Build plagiarism detection into your apps. Check code against 20+ billion sources.

const response = await fetch('https://codequiry.com/api/v1/check', { method: 'POST', headers: { 'apikey': 'YOUR_API_KEY' }, body: formData }); // Check created!
DOWNLOAD FILES

Download Files & Reports

Access and download source code files that were matched during plagiarism analysis. This endpoint provides access to individual files from external sources and submitted content for detailed comparison.

POST https://codequiry.com/api/v1/check/getRemoteFile

Available Downloads

The Codequiry API provides access to source code files and external matches for offline analysis and manual review.

File Access: This endpoint allows you to download individual source code files that were flagged as potential matches during analysis.
Download Types
External Match Files

Source code from web matches, GitHub repos, Stack Overflow, database content, and academic sources.

Submission Files

Original uploads, processed source code, individual file content in raw text format.

Request Parameters

Parameter Type Required Description
location string Required File location identifier or URL from match results
source string Required Source type identifier (e.g., "web", "database", "submission")
Example Request
		curl -X POST "https://codequiry.com/api/v1/check/getRemoteFile" \
  -H "apikey: your-api-key-here" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "location": "https://github.com/example/repo/blob/main/algorithm.py",
    "source": "web"
  }'
		
cURL

Response Format

Success Response (200 OK)
		{
  "success": true,
  "file": {
    "filename": "sorting_algorithms.py",
    "content": "def bubble_sort(arr):\n    n = len(arr)\n    for i in range(n):\n        for j in range(0, n-i-1):\n            if arr[j] > arr[j+1]:\n                arr[j], arr[j+1] = arr[j+1], arr[j]\n    return arr\n\ndef quick_sort(arr):\n    if len(arr) <= 1:\n        return arr\n    pivot = arr[len(arr) // 2]\n    left = [x for x in arr if x < pivot]\n    middle = [x for x in arr if x == pivot]\n    right = [x for x in arr if x > pivot]\n    return quick_sort(left) + middle + quick_sort(right)",
    "language_id": 14,
    "file_size": 456,
    "encoding": "utf-8",
    "source_url": "https://github.com/example/repo/blob/main/sorting_algorithms.py"
  }
}
		
JSON Response
Testing Note: Replace the example location and source values with actual data from your check results. The location parameter should come from the match results in your plagiarism analysis.

Response Structure

Field Type Description
filename string Original or derived filename of the source code
content string Raw source code content as plain text
language_id integer Programming language identifier
file_size integer File size in bytes
encoding string Text encoding format (typically UTF-8)
source_url string Original URL or source location (if available)

Error Responses

File Not Found (422 Unprocessable Entity)
		{
  "success": false,
  "error": "File not found or no longer available",
  "code": 422,
  "details": {
    "location": "https://example.com/missing-file.py",
    "reason": "External source no longer accessible"
  }
}
		
Error Response
File Not Found/Expired

External source removed, repo made private, link expired, etc.

Authentication Required

Valid API key, sufficient quota, proper request formatting needed.

Best Practices

File Handling

Cache locally to avoid repeated API calls. Check encoding before processing. Handle failures gracefully as external sources may become unavailable. Respect rate limits and sanitize content before display.

Security Considerations

Validate downloaded content is safe. Restrict file access to authorized users. Handle academic content responsibly. Track file access for audit purposes and remove temporary files after processing.