Test
Endpoints for submitting and validating test cases
Handles test requests.
Body
sourcestringOptionalExample:
Source code to be tested
public class Main { public static void main(String[] args) { System.out.println("Hello World"); }}
compilerstringOptionalExample:
Compiler to be used
javac
metastringOptionalExample:
Additional metadata
Test metadata
Responses
200
Successful response
application/json
400
Bad request
500
Internal server error
post
POST /api/v1/test HTTP/1.1
Host: localhost:7070
Content-Type: application/json
Accept: */*
Content-Length: 202
{
"source": "public class Main { public static void main(String[] args) { System.out.println(\"Hello World\"); }}",
"compiler": "javac",
"tests": [
{
"input": "1 2",
"expectedOutput": "3"
}
],
"meta": "Test metadata"
}
{
"message": "Success"
}
Was this helpful?