SaveQuestionRequest
Question data to create or update. Same structure as QuestionDetailsResult without the server-owned fields. An unknown property is rejected, so a fetched question cannot be sent back as is: its read-only fields must be stripped first. Top level: 'id', 'version', 'creation_time', 'modification_time', 'from_coderpad_question_bank', 'resources', 'game_details' and 'file_upload_details'. Nested: 'code_details.available_programming_language_ids' and 'project_details.download_url'. 'evaluation.test_report' is read-only too, but it is declared here, so it is refused as a block the question type does not support rather than as an unknown property
Properties
| Name | Type | Description |
|---|---|---|
| type | string | the question type |
| domain | string | the question domain name |
| duration_seconds | integer | the question duration in seconds |
| difficulty | string | difficulty level |
| points | integer | maximum score weight for the question |
| title | object | question title, by locale |
| statement | object | HTML statement, by locale |
| locales | array | locales of the question. Defaults to the locales of 'title'. Every localized field must cover exactly these locales, except the test case labels, whose missing locales are filled from a provided one |
| skill | string | the question skill |
| team_id | string | id of the team owning the question. Defaults to the preferred team of the caller |
| automatically_selectable | boolean | whether the question can be automatically selected in campaigns; omitted, it defaults to true, like every other creation path, so an update omitting it does not unselect the question |
| comment | string | internal comment on the question |
| evaluation | object | |
| code_details | object | |
| mcq_details | object | |
| text_details | object | |
| video_details | object | |
| project_details | object |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://artifacts.apis.io/coderpad/json-schema/coderpad-save-question-request-schema.json",
"title": "SaveQuestionRequest",
"description": "Question data to create or update. Same structure as QuestionDetailsResult without the server-owned fields. An unknown property is rejected, so a fetched question cannot be sent back as is: its read-only fields must be stripped first. Top level: 'id', 'version', 'creation_time', 'modification_time', 'from_coderpad_question_bank', 'resources', 'game_details' and 'file_upload_details'. Nested: 'code_details.available_programming_language_ids' and 'project_details.download_url'. 'evaluation.test_report' is read-only too, but it is declared here, so it is refused as a block the question type does not support rather than as an unknown property",
"x-generated": "2026-11-04",
"x-method": "derived",
"x-generator": "derive-json-schema.py",
"x-source": "openapi/coderpad-questions-api-openapi.yml#/components/schemas/SaveQuestionRequest",
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "the question type",
"enum": [
"MCQ",
"CODE",
"TEXT",
"FILE_UPLOAD",
"VIDEO",
"PROJECT"
]
},
"domain": {
"type": "string",
"description": "the question domain name"
},
"duration_seconds": {
"type": "integer",
"description": "the question duration in seconds",
"format": "int32"
},
"difficulty": {
"type": "string",
"description": "difficulty level",
"enum": [
"EASY",
"MEDIUM",
"HARD"
]
},
"points": {
"type": "integer",
"description": "maximum score weight for the question",
"format": "int32"
},
"title": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "question title, by locale"
},
"description": "question title, by locale"
},
"statement": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "HTML statement, by locale"
},
"description": "HTML statement, by locale"
},
"locales": {
"type": "array",
"description": "locales of the question. Defaults to the locales of 'title'. Every localized field must cover exactly these locales, except the test case labels, whose missing locales are filled from a provided one",
"items": {
"type": "string",
"description": "locales of the question. Defaults to the locales of 'title'. Every localized field must cover exactly these locales, except the test case labels, whose missing locales are filled from a provided one"
}
},
"skill": {
"type": "string",
"description": "the question skill"
},
"team_id": {
"type": "string",
"description": "id of the team owning the question. Defaults to the preferred team of the caller",
"format": "uuid"
},
"automatically_selectable": {
"type": "boolean",
"description": "whether the question can be automatically selected in campaigns; omitted, it defaults to true, like every other creation path, so an update omitting it does not unselect the question"
},
"comment": {
"type": "string",
"description": "internal comment on the question"
},
"evaluation": {
"$ref": "#/$defs/EvaluationDetails"
},
"code_details": {
"$ref": "#/$defs/SaveCodeDetails"
},
"mcq_details": {
"$ref": "#/$defs/McqDetails"
},
"text_details": {
"$ref": "#/$defs/TextDetails"
},
"video_details": {
"$ref": "#/$defs/VideoDetails"
},
"project_details": {
"$ref": "#/$defs/SaveProjectDetails"
}
},
"$defs": {
"ChoiceSelectionDetails": {
"type": "object",
"properties": {
"correct_choice_indexes": {
"type": "array",
"description": "0-based indexes of the correct choices in mcq_details.choices",
"items": {
"type": "integer",
"description": "0-based indexes of the correct choices in mcq_details.choices",
"format": "int32"
}
}
},
"description": "Choices the candidate has to select"
},
"DatabaseEngineDetails": {
"type": "object",
"properties": {
"version": {
"type": "string",
"description": "the database engine version, absent for h2 which has a single version"
},
"engine_id": {
"type": "string",
"description": "the database engine id, or \"h2\" for the default engine"
}
},
"description": "The single database engine a SQL question runs on, H2 when the question declares none. Saving a question without this block means H2 on an update too, so an update meant to keep another engine has to name it"
},
"EnvironmentDetails": {
"type": "object",
"properties": {
"version": {
"type": "string",
"description": "the environment version"
},
"environment_id": {
"type": "string",
"description": "the environment id"
}
},
"description": "Execution environment version a question runs on"
},
"EvaluationAcceptedAnswerDetails": {
"type": "object",
"properties": {
"value": {
"type": "string",
"description": "the accepted answer, as an exact value or a regular expression"
},
"match_type": {
"type": "string",
"description": "how the candidate answer is compared to the value",
"enum": [
"EXACT",
"REGEX"
]
}
},
"description": "One answer accepted as correct"
},
"EvaluationDetails": {
"type": "object",
"properties": {
"rubric": {
"$ref": "#/$defs/RubricDetails"
},
"test_report": {
"$ref": "#/$defs/TestReportDetails"
},
"validation_code": {
"$ref": "#/$defs/ValidationCodeDetails"
},
"input_output": {
"$ref": "#/$defs/InputOutputDetails"
},
"sql_query_result_comparison": {
"$ref": "#/$defs/SqlQueryResultComparisonDetails"
},
"text_answer_matching": {
"$ref": "#/$defs/TextAnswerMatchingDetails"
},
"choice_selection": {
"$ref": "#/$defs/ChoiceSelectionDetails"
}
},
"description": "How the candidate answer is evaluated"
},
"FunctionSignatureDetails": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "the function name"
},
"parameters": {
"type": "array",
"description": "the parameters, in order, each a JSON Schema draft-6 object whose 'title' is the parameter name",
"items": {
"type": "object",
"additionalProperties": true
}
},
"return_type": {
"type": "object",
"additionalProperties": true,
"description": "the return type, as a JSON Schema draft-6 object"
}
},
"description": "Signature of the function the candidate has to implement"
},
"InputOutputDetails": {
"type": "object",
"properties": {
"test_cases": {
"type": "array",
"description": "test cases in the order the editor shows them",
"items": {
"$ref": "#/$defs/InputOutputTestCaseDetails"
}
}
},
"description": "Input and output pairs the candidate code is run on"
},
"InputOutputTestCaseDetails": {
"type": "object",
"properties": {
"label": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "test case label, by locale; a missing question locale is filled from a provided one"
},
"description": "test case label, by locale; a missing question locale is filled from a provided one"
},
"input": {
"type": "string",
"description": "input given to the candidate code"
},
"output": {
"type": "string",
"description": "output expected from the candidate code"
},
"skill": {
"type": "string",
"description": "skill assessed by this test case"
},
"points": {
"type": "integer",
"description": "points awarded by this test case; set on every graded test case or on none, when omitted they are derived from the weights to add up to the question points",
"format": "int32"
},
"weight": {
"type": "integer",
"description": "relative weight of this test case; defaults to 1",
"format": "int32"
},
"difficulty": {
"type": "integer",
"description": "difficulty of this test case",
"format": "int32"
},
"contributes_to_score": {
"type": "boolean",
"description": "whether the test case takes part in the score; defaults to true"
},
"visible_to_candidate": {
"type": "boolean",
"description": "whether the candidate sees the test case; defaults to true"
},
"timeout_ms_by_programming_language_id": {
"type": "object",
"additionalProperties": {
"type": "integer",
"description": "execution timeout in milliseconds, by programming language id, when it overrides the default of that language",
"format": "int32"
},
"description": "execution timeout in milliseconds, by programming language id, when it overrides the default of that language"
}
},
"description": "Test case feeding an input to the candidate code and comparing its output"
},
"McqDetails": {
"type": "object",
"properties": {
"choices": {
"type": "array",
"description": "MCQ choices",
"items": {
"$ref": "#/$defs/QuestionChoiceDetailsResult"
}
},
"selection_mode": {
"type": "string",
"description": "whether the candidate can select one or multiple choices: SINGLE or MULTIPLE",
"enum": [
"SINGLE",
"MULTIPLE"
]
},
"randomize_choices": {
"type": "boolean",
"description": "whether MCQ choices are randomized"
}
},
"description": "MCQ-specific question details"
},
"PossibleSolutionDetails": {
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "the solution source code"
},
"programming_language_id": {
"type": "string",
"description": "the programming language the solution is written in"
}
},
"description": "A working solution of the question, kept for the author"
},
"ProjectResourceDetails": {
"type": "object",
"properties": {
"version": {
"type": "string",
"description": "the resource version"
},
"resource_id": {
"type": "string",
"description": "the resource id"
}
},
"description": "Additional resource a PROJECT runs with, such as a database"
},
"QueryComparisonRulesDetails": {
"type": "object",
"properties": {
"row_order_matters": {
"type": "boolean",
"description": "whether rows must come in the expected order"
},
"column_order_matters": {
"type": "boolean",
"description": "whether columns must come in the expected order"
},
"compare_all_tables": {
"type": "boolean",
"description": "whether every table of the database is compared, not only the query result"
}
},
"description": "Rules applied when comparing the candidate query result to the expected one"
},
"QuestionChoiceDetailsResult": {
"type": "object",
"properties": {
"label": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "choice label, by locale"
},
"description": "choice label, by locale"
}
},
"description": "MCQ choice offered to the candidate"
},
"RubricCriterionDetails": {
"type": "object",
"properties": {
"label": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "criterion label, by locale"
},
"description": "criterion label, by locale"
},
"skill": {
"type": "string",
"description": "skill assessed by this criterion"
},
"points": {
"type": "integer",
"description": "points awarded by this criterion",
"format": "int32"
},
"weight": {
"type": "integer",
"description": "relative weight of this criterion",
"format": "int32"
},
"review_mode": {
"type": "string",
"description": "how this criterion is reviewed",
"enum": [
"HUMAN_ONLY",
"AI_SUGGESTIONS",
"AI_GRADING"
]
},
"description": {
"type": "string",
"description": "reviewer-facing description of the criterion"
}
},
"description": "One criterion the candidate answer is reviewed against"
},
"RubricDetails": {
"type": "object",
"properties": {
"criteria": {
"type": "array",
"description": "criteria of the rubric, in the order the editor shows them",
"items": {
"$ref": "#/$defs/RubricCriterionDetails"
}
}
},
"description": "Rubric the candidate answer is reviewed against"
},
"SaveCodeDetails": {
"type": "object",
"properties": {
"environment": {
"$ref": "#/$defs/EnvironmentDetails"
},
"mode": {
"type": "string",
"description": "SINGLE_LANGUAGE when the question is bound to programming_language, MULTI_LANGUAGE when the candidate picks one of available_programming_language_ids",
"enum": [
"SINGLE_LANGUAGE",
"MULTI_LANGUAGE"
]
},
"programming_language_id": {
"type": "string",
"description": "the programming language id; only set when mode is SINGLE_LANGUAGE"
},
"candidate_test_code": {
"type": "string",
"description": "code the candidate can run against their answer; language-specific questions only"
},
"validator_code": {
"type": "string",
"description": "code defining the tests referenced by evaluation.validation_code.test_cases; language-specific questions only"
},
"timeout_ms": {
"type": "integer",
"description": "execution timeout in milliseconds when it overrides the default of the language",
"format": "int32"
},
"database_engine": {
"$ref": "#/$defs/DatabaseEngineDetails"
},
"database_setup_script": {
"type": "string",
"description": "script creating and filling the tables the query runs against; SQL questions only, mandatory for them"
},
"starter_code": {
"type": "string",
"description": "starter code; only set when mode is SINGLE_LANGUAGE"
},
"function_signature": {
"$ref": "#/$defs/FunctionSignatureDetails"
},
"possible_solution": {
"$ref": "#/$defs/PossibleSolutionDetails"
},
"show_function_signature_in_statement": {
"type": "boolean",
"description": "whether the function signature is shown to the candidate in the statement"
}
},
"description": "CODE-specific question data to create or update"
},
"SaveProjectDetails": {
"type": "object",
"properties": {
"environment": {
"$ref": "#/$defs/EnvironmentDetails"
},
"resources": {
"type": "array",
"description": "additional resources the project runs with; empty if none",
"items": {
"$ref": "#/$defs/ProjectResourceDetails"
}
},
"ai_assist_additional_instructions": {
"type": "string",
"description": "instructions given to the AI assist during the test"
},
"ai_assist_allowed": {
"type": "boolean",
"description": "whether AI assist is allowed"
},
"temporary_file_id": {
"type": "string",
"description": "id returned by POST /v1.1/temporary-file for the tar.gz source archive of the project. Mandatory on creation. On update, optional: omitted, the current source archive is kept; set, it replaces every file of the project, a file missing from the archive being deleted",
"format": "uuid"
}
},
"description": "PROJECT-specific question data to create or update"
},
"SqlQueryResultComparisonDetails": {
"type": "object",
"properties": {
"reference_query": {
"type": "string",
"description": "query producing the expected result"
},
"comparison": {
"$ref": "#/$defs/QueryComparisonRulesDetails"
}
},
"description": "Reference query the candidate query result is compared to"
},
"TestReportDetails": {
"type": "object",
"properties": {
"test_cases": {
"type": "array",
"description": "tests of the report, in the order the editor shows them",
"items": {
"$ref": "#/$defs/TestReportTestCaseDetails"
}
}
},
"description": "Test suite report the candidate project is scored on"
},
"TestReportTestCaseDetails": {
"type": "object",
"properties": {
"key": {
"type": "string",
"description": "stable identifier of the test case"
},
"test_identifier": {
"type": "string",
"description": "identifier of the test in the report"
},
"label": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "test label, by locale"
},
"description": "test label, by locale"
},
"skill": {
"type": "string",
"description": "skill assessed by this test"
},
"points": {
"type": "integer",
"description": "points awarded by this test",
"format": "int32"
},
"weight": {
"type": "integer",
"description": "relative weight of this test",
"format": "int32"
}
},
"description": "Test of the project test suite the answer is scored on"
},
"TextAnswerMatchingDetails": {
"type": "object",
"properties": {
"accepted_answers": {
"type": "array",
"description": "answers accepted as correct; matching any of them is enough",
"items": {
"$ref": "#/$defs/EvaluationAcceptedAnswerDetails"
}
}
},
"description": "Answers the candidate text is matched against"
},
"TextDetails": {
"type": "object",
"properties": {
"evaluation_mode": {
"type": "string",
"description": "how the question is graded: AUTOMATIC uses a text_answer_matching evaluation, MANUAL a rubric one",
"enum": [
"MANUAL",
"AUTOMATIC"
]
}
},
"description": "TEXT-specific question details"
},
"ValidationCodeDetails": {
"type": "object",
"properties": {
"test_cases": {
"type": "array",
"description": "test cases in the order the editor shows them",
"items": {
"$ref": "#/$defs/ValidationCodeTestCaseDetails"
}
}
},
"description": "Validation methods the candidate code is run against"
},
"ValidationCodeTestCaseDetails": {
"type": "object",
"properties": {
"label": {
"type": "object",
"additionalProperties": {
"type": "string",
"description": "test case label, by locale; a missing question locale is filled from a provided one"
},
"description": "test case label, by locale; a missing question locale is filled from a provided one"
},
"test_identifier": {
"type": "string",
"description": "validation method running the test"
},
"skill": {
"type": "string",
"description": "skill assessed by this test case"
},
"points": {
"type": "integer",
"description": "points awarded by this test case; set on every test case or on none, when omitted they are derived from the weights to add up to the question points",
"format": "int32"
},
"weight": {
"type": "integer",
"description": "relative weight of this test case; defaults to 1",
"format": "int32"
},
"difficulty": {
"type": "integer",
"description": "difficulty of this test case",
"format": "int32"
},
"contributes_to_score": {
"type": "boolean",
"description": "whether the test case takes part in the score"
},
"visible_to_candidate": {
"type": "boolean",
"description": "whether the candidate sees the test case"
}
},
"description": "Test case running a validation method against the candidate code"
},
"VideoDetails": {
"type": "object",
"properties": {
"recording_media": {
"type": "string",
"description": "the recording media",
"enum": [
"VIDEO",
"AUDIO"
]
}
},
"description": "VIDEO-specific question details"
}
}
}
Work with this as data
Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for schemas
4 MCP tools reach this
find_json_schemasBrowse and filter every JSON Schema in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
curl "https://apis.io/api/v1/json-schemas/coderpad-save-question-request"
curl "https://apis.io/api/v1/json-schemas?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.