API Reference

CoderPad Interview API client.

class coderpad.client.LanguagesNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Discover available environments and their starter code.

Return catalog JSON unchanged, retaining new environment metadata.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

list() → JsonValue

Retrieve the available language and project environments.

get(*, language: str) → JsonValue

Retrieve starter code and environment context for an identifier.

class coderpad.client.UserNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Information about the Interview API key owner.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

get() → User

Retrieve the key owner’s display name and capabilities.

class coderpad.client.PadsNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for pad operations.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

list(*, sort: SortOrder | None = None, page: int | None = None, cursor: str | None = None) → PaginatedList[Pad]

Retrieve a list of pads.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • cursor – Opaque cursor; overrides page and sort.

Returns:

The list of pads with pagination metadata.

all(*, sort: SortOrder | None = None) → Iterator[Pad]

Yield all pads across paginated responses.

Parameters:

sort – Sort order.

Yields:

Each pad from successive pages until next_page is absent.

create(*, title: str | None = None, language: Language | str | None = None, contents: str | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None, notes: str | None = None, question_id: str | int | None = None, private: bool | None = None, execution_enabled: bool | None = None, user_email: str | None = None, restrict_interviewer_access: bool | None = None, allowed_interviewer_emails: Sequence[str] | None = None, disable_coaching_tips: bool | None = None, team_id: str | None = None, take_home: bool | None = None, take_home_time_limit: int | None = None, ai_assist_enabled: bool | None = None) → Pad

Create a new pad.

Parameters:
  • title – Title for the pad.

  • language – Programming language for the pad.

  • contents – Initial contents of a single-file pad.

  • file_contents – Project starter files layered over the template.

  • zip_file – Project ZIP archive replacing the template files.

  • directory – Project directory uploaded as a ZIP archive. Content sources and question_id are mutually exclusive. ZIP and directory uploads cannot set an interviewer access list; use file_contents when setting that list.

  • notes – Private notes for the interviewer.

  • question_id – Id of an existing question to seed the pad from.

  • private – Enable the waiting room.

  • execution_enabled – Allow code execution; sent as a string.

  • user_email – Organization user to make the owner.

  • restrict_interviewer_access – Restrict joining as an interviewer.

  • allowed_interviewer_emails – Replace the allowed list; an empty list clears it.

  • disable_coaching_tips – Disable coaching tips.

  • team_id – Team for the new pad.

  • take_home – Create a take-home pad.

  • take_home_time_limit – Time limit in minutes.

  • ai_assist_enabled – Enable AI Assist.

Returns:

The created pad.

get(*, pad_id: str) → Pad

Retrieve a pad by id.

Parameters:

pad_id – The id of the pad.

Returns:

The pad.

update(*, pad_id: str, title: str | None = None, language: Language | str | None = None, contents: str | None = None, notes: str | None = None, ended: bool | None = None, deleted: bool | None = None, private: bool | None = None, execution_enabled: bool | None = None, user_email: str | None = None, restrict_interviewer_access: bool | None = None, allowed_interviewer_emails: Sequence[str] | None = None, disable_coaching_tips: bool | None = None) → None

Modify an existing pad.

Parameters:
  • pad_id – The id of the pad.

  • title – New title for the pad.

  • language – New programming language.

  • contents – New contents of the pad editor.

  • notes – New private notes.

  • ended – Set to True to end the interview.

  • deleted – Set to True to delete the pad.

  • private – Enable the waiting room.

  • execution_enabled – Allow code execution; sent as a string.

  • user_email – Organization user to make the owner.

  • restrict_interviewer_access – Restrict joining as an interviewer.

  • allowed_interviewer_emails – Replace the allowed list; an empty list clears it.

  • disable_coaching_tips – Disable coaching tips.

get_events(*, pad_id: str, sort: SortOrder | None = None, page: int | None = None) → PaginatedList[PadEvent]

Retrieve a list of pad events.

Parameters:
  • pad_id – The id of the pad.

  • sort – Sort order.

  • page – Page number for pagination.

Returns:

The list of pad events with pagination metadata.

get_environment(*, environment_id: str) → PadEnvironment

Retrieve pad environment information.

Parameters:

environment_id – The id of the pad environment.

Returns:

The pad environment.

get_history(*, history_url: str) → PadHistory

Retrieve editor history from a Firebase history URL.

The URL is available as FileContent.history. The CoderPad API key is deliberately not sent to the Firebase host.

Parameters:

history_url – The history URL returned for a file in a pad environment.

Returns:

The chronologically ordered editor history. An empty history is returned when Firebase responds with null.

class coderpad.client.QuestionVariantsNamespace(*, transport: JSONTransport, base_url: str, headers: dict[str, str])

JSON operations on variants nested under a question.

The Interview transport must support JSON request bodies.

Use the Interview client’s transport, origin, and credentials.

list(*, question_id: str | int) → list[QuestionVariant]

List the question’s language and project-template variants.

get(*, question_id: str | int, variant_id: str | int) → QuestionVariant

Fetch a variant belonging to the question.

create(*, question_id: str | int, language: Language | str, contents: str | QuestionVariantUnset | None = QuestionVariantUnset.OMITTED, file_contents: Sequence[QuestionVariantFileContent] | str | None = None, solution: str | None = None) → QuestionVariant

Create a variant, layering project files over the template.

Omit contents to use the default, pass an empty string for blank code, or None to drop the variant’s own code. File contents may be a sequence or a JSON string and cannot accompany contents.

update(*, question_id: str | int, variant_id: str | int, language: Language | str | None = None, contents: str | QuestionVariantUnset | None = QuestionVariantUnset.OMITTED, file_contents: Sequence[QuestionVariantFileContent] | str | None = None, solution: str | None = None) → QuestionVariant

Update supplied fields and return the updated variant.

Omitted code is preserved; None restores the language default. Changing environment clears code unless replacement code is sent. Files replace the variant’s files; [] restores template files.

delete(*, question_id: str | int, variant_id: str | int) → None

Delete a variant without requiring a JSON response body.

class coderpad.client.QuestionsNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for question operations.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

property variants: QuestionVariantsNamespace

Access JSON operations on this question library’s variants.

list(*, sort: QuestionSortOrder | SortOrder | None = None, page: int | None = None, text: str | None = None, pad_types: Sequence[Literal['any', 'live', 'take_home']] | None = None) → PaginatedList[Question]

Retrieve a list of questions.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • text – Search question text.

  • pad_types – Repeatable usage filters.

Returns:

The list of questions with pagination metadata.

all(*, sort: QuestionSortOrder | SortOrder | None = None, text: str | None = None, pad_types: Sequence[Literal['any', 'live', 'take_home']] | None = None) → Iterator[Question]

Yield questions incrementally with filters on every page.

create(*, title: str, language: Language | str, description: str | None = None, contents: str | None = None, solution: str | None = None, ai_assist_custom_system_prompt: str | None = None, shared: bool | None = None, custom_database_id: int | None = None, candidate_instructions: Sequence[CandidateInstruction] | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None) → Question

Create a new question.

Parameters:
  • title – Title for the question.

  • language – Programming language for the question.

  • description – Notes about the question.

  • contents – Text inserted into the interview session. Cannot be combined with file_contents.

  • solution – The solution to the question.

  • ai_assist_custom_system_prompt – Custom system prompt for AI Assist.

  • shared – Whether to share the question with your organization.

  • custom_database_id – The custom database to attach.

  • candidate_instructions – Progressively-revealed instruction blocks shown to the candidate.

  • file_contents – Files for a multi-file question. Cannot be combined with contents or zip_file.

  • zip_file – Path to a zip archive containing files for a multi-file question. Cannot be combined with file_contents.

  • directory – Directory to upload using the ZIP importer. Cannot be combined with other content sources. Includes hidden files and rejects symbolic links within the directory. Uploads all files in the directory.

Returns:

The created question.

get(*, question_id: str) → Question

Retrieve a question by id.

Parameters:

question_id – The id of the question.

Returns:

The question.

update(*, question_id: str, title: str | None = None, language: Language | str | None = None, description: str | None = None, contents: str | None = None, solution: str | None = None, ai_assist_custom_system_prompt: str | None = None, shared: bool | None = None, custom_database_id: int | None = None, candidate_instructions: Sequence[CandidateInstruction] | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None) → None

Modify an existing question.

Parameters:
  • question_id – The id of the question.

  • title – New title for the question.

  • language – New programming language.

  • description – New description.

  • contents – New contents. Cannot be combined with file_contents.

  • solution – New solution.

  • ai_assist_custom_system_prompt – Custom system prompt for AI Assist.

  • shared – Whether to share the question with your organization.

  • custom_database_id – The custom database to attach.

  • candidate_instructions – Progressively-revealed instruction blocks shown to the candidate.

  • file_contents – Files for a multi-file question. Cannot be combined with contents or zip_file.

  • zip_file – Path to a zip archive containing files for a multi-file question. Cannot be combined with file_contents.

  • directory – Directory to upload using the ZIP importer. Cannot be combined with other content sources. Includes hidden files and rejects symbolic links within the directory. Uploads all files in the directory.

delete(*, question_id: str) → None

Delete a question.

Parameters:

question_id – The id of the question.

class coderpad.client.OrganizationPadsNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for organization pad operations.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

list(*, sort: SortOrder | None = None, page: int | None = None) → PaginatedList[Pad]

Retrieve pads for the entire organization.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

Returns:

The list of pads with pagination metadata.

class coderpad.client.OrganizationQuestionsNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for organization question operations.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

list(*, sort: QuestionSortOrder | SortOrder | None = None, page: int | None = None, pad_type: Literal['live', 'take_home'] | None = None, language: Language | str | None = None) → PaginatedList[Question]

Retrieve questions for the entire organization.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • pad_type – Filter live or take-home questions.

  • language – Filter question language.

Returns:

The list of questions with pagination metadata.

all(*, sort: QuestionSortOrder | SortOrder | None = None, pad_type: Literal['live', 'take_home'] | None = None, language: Language | str | None = None) → Iterator[Question]

Yield questions incrementally with filters on every page.

class coderpad.client.OrganizationUsersNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for organization user operations.

Create a new namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

list(*, email: str | None = None) → list[OrganizationUser]

Retrieve users in the organization.

Parameters:

email – Return only the user with this email address.

Returns:

The organization users matching the filter.

class coderpad.client.OrganizationNamespace(*, transport: Transport, base_url: str, headers: dict[str, str])

Namespace for organization operations.

Create a new organization namespace.

Parameters:
  • transport – The HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

get() → Organization

Retrieve organization information.

Returns:

The organization details.

get_stats(*, start_time: str | None = None, end_time: str | None = None) → OrganizationStats

Retrieve pad usage stats for the organization.

Parameters:
  • start_time – ISO 8601 start of the search window.

  • end_time – ISO 8601 end of the search window.

Returns:

The usage statistics.

get_quota() → Quota

Retrieve quota information.

Returns:

The quota details.

class coderpad.client.CoderPad(*, api_key: str, base_url: str = 'https://app.coderpad.io', screen_api_key: str | None = None, screen_base_url: str = 'https://screen.coderpad.io', transport: Transport | None = None, screen_transport: JSONTransport | None = None, default_headers: dict[str, str] | None = None, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

A client for the CoderPad Interview API.

Create a new CoderPad client.

Parameters:
  • api_key – The API key for authentication.

  • base_url – The base URL for the API.

  • screen_api_key – The independent Screen API key.

  • screen_base_url – The US, EU, or custom Screen base URL.

  • transport – The HTTP transport. Defaults to HTTPXTransport().

  • screen_transport – The independent Screen HTTP transport.

  • default_headers – Extra headers merged into every Interview and Screen request. Authorization and API-Key values from these headers are overwritten by the client keys.

  • limits – Optional connection pool limits for default transports.

  • proxy – Optional proxy for the default httpx transports.

  • timeout – Optional timeout for the default httpx transports.

property screen: ScreenNamespace

Screen API namespace, created on first access.

Raises:

ValueError – If screen_api_key was not provided.

classmethod from_env() → Self

Create a client using CODERPAD_API_KEY and optional Screen key.

Reads CODERPAD_API_KEY (required) and CODERPAD_SCREEN_API_KEY (optional) from the environment.

Returns:

A new client configured from environment variables.

Raises:

KeyError – If CODERPAD_API_KEY is not set.

close() → None

Close the underlying transport if it supports closing.

Async CoderPad Interview API client.

class coderpad.async_client.AsyncLanguagesNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Discover available environments and their starter code.

Return catalog JSON unchanged, retaining new environment metadata.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async list() → JsonValue

Retrieve the available language and project environments.

async get(*, language: str) → JsonValue

Retrieve starter code and environment context for an identifier.

class coderpad.async_client.AsyncUserNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Information about the Interview API key owner.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async get() → User

Retrieve the key owner’s display name and capabilities.

class coderpad.async_client.AsyncPadsNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async pad operations.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async list(*, sort: SortOrder | None = None, page: int | None = None, cursor: str | None = None) → PaginatedList[Pad]

Retrieve a list of pads.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • cursor – Opaque cursor; overrides page and sort.

Returns:

The list of pads with pagination metadata.

async all(*, sort: SortOrder | None = None) → AsyncIterator[Pad]

Yield all pads across paginated responses.

Parameters:

sort – Sort order.

Yields:

Each pad from successive pages until next_page is absent.

async create(*, title: str | None = None, language: Language | str | None = None, contents: str | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None, notes: str | None = None, question_id: str | int | None = None, private: bool | None = None, execution_enabled: bool | None = None, user_email: str | None = None, restrict_interviewer_access: bool | None = None, allowed_interviewer_emails: Sequence[str] | None = None, disable_coaching_tips: bool | None = None, team_id: str | None = None, take_home: bool | None = None, take_home_time_limit: int | None = None, ai_assist_enabled: bool | None = None) → Pad

Create a new pad.

Parameters:
  • title – Title for the pad.

  • language – Programming language for the pad.

  • contents – Initial contents of a single-file pad.

  • file_contents – Project starter files layered over the template.

  • zip_file – Project ZIP archive replacing the template files.

  • directory – Project directory uploaded as a ZIP archive. Content sources and question_id are mutually exclusive. ZIP and directory uploads cannot set an interviewer access list; use file_contents when setting that list.

  • notes – Private notes for the interviewer.

  • question_id – Id of an existing question to seed the pad from.

  • private – Enable the waiting room.

  • execution_enabled – Allow code execution; sent as a string.

  • user_email – Organization user to make the owner.

  • restrict_interviewer_access – Restrict joining as an interviewer.

  • allowed_interviewer_emails – Replace the allowed list; an empty list clears it.

  • disable_coaching_tips – Disable coaching tips.

  • team_id – Team for the new pad.

  • take_home – Create a take-home pad.

  • take_home_time_limit – Time limit in minutes.

  • ai_assist_enabled – Enable AI Assist.

Returns:

The created pad.

async get(*, pad_id: str) → Pad

Retrieve a pad by id.

Parameters:

pad_id – The id of the pad.

Returns:

The pad.

async update(*, pad_id: str, title: str | None = None, language: Language | str | None = None, contents: str | None = None, notes: str | None = None, ended: bool | None = None, deleted: bool | None = None, private: bool | None = None, execution_enabled: bool | None = None, user_email: str | None = None, restrict_interviewer_access: bool | None = None, allowed_interviewer_emails: Sequence[str] | None = None, disable_coaching_tips: bool | None = None) → None

Modify an existing pad.

Parameters:
  • pad_id – The id of the pad.

  • title – New title for the pad.

  • language – New programming language.

  • contents – New contents of the pad editor.

  • notes – New private notes.

  • ended – Set to True to end the interview.

  • deleted – Set to True to delete the pad.

  • private – Enable the waiting room.

  • execution_enabled – Allow code execution; sent as a string.

  • user_email – Organization user to make the owner.

  • restrict_interviewer_access – Restrict joining as an interviewer.

  • allowed_interviewer_emails – Replace the allowed list; an empty list clears it.

  • disable_coaching_tips – Disable coaching tips.

async get_events(*, pad_id: str, sort: SortOrder | None = None, page: int | None = None) → PaginatedList[PadEvent]

Retrieve a list of pad events.

Parameters:
  • pad_id – The id of the pad.

  • sort – Sort order.

  • page – Page number for pagination.

Returns:

The list of pad events with pagination metadata.

async get_environment(*, environment_id: str) → PadEnvironment

Retrieve pad environment information.

Parameters:

environment_id – The id of the pad environment.

Returns:

The pad environment.

async get_history(*, history_url: str) → PadHistory

Retrieve editor history from a Firebase history URL.

The URL is available as FileContent.history. The CoderPad API key is deliberately not sent to the Firebase host.

Parameters:

history_url – The history URL returned for a file in a pad environment.

Returns:

The chronologically ordered editor history. An empty history is returned when Firebase responds with null.

class coderpad.async_client.AsyncQuestionVariantsNamespace(*, transport: AsyncJSONTransport, base_url: str, headers: dict[str, str])

JSON operations on variants nested under a question.

The Interview transport must support JSON request bodies.

Use the Interview client’s transport, origin, and credentials.

async list(*, question_id: str | int) → list[QuestionVariant]

List the question’s language and project-template variants.

async get(*, question_id: str | int, variant_id: str | int) → QuestionVariant

Fetch a variant belonging to the question.

async create(*, question_id: str | int, language: Language | str, contents: str | QuestionVariantUnset | None = QuestionVariantUnset.OMITTED, file_contents: Sequence[QuestionVariantFileContent] | str | None = None, solution: str | None = None) → QuestionVariant

Create a variant, layering project files over the template.

Omit contents to use the default, pass an empty string for blank code, or None to drop the variant’s own code. File contents may be a sequence or a JSON string and cannot accompany contents.

async update(*, question_id: str | int, variant_id: str | int, language: Language | str | None = None, contents: str | QuestionVariantUnset | None = QuestionVariantUnset.OMITTED, file_contents: Sequence[QuestionVariantFileContent] | str | None = None, solution: str | None = None) → QuestionVariant

Update supplied fields and return the updated variant.

Omitted code is preserved; None restores the language default. Changing environment clears code unless replacement code is sent. Files replace the variant’s files; [] restores template files.

async delete(*, question_id: str | int, variant_id: str | int) → None

Delete a variant without requiring a JSON response body.

class coderpad.async_client.AsyncQuestionsNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async question operations.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

property variants: AsyncQuestionVariantsNamespace

Access JSON operations on this question library’s variants.

async list(*, sort: QuestionSortOrder | SortOrder | None = None, page: int | None = None, text: str | None = None, pad_types: Sequence[Literal['any', 'live', 'take_home']] | None = None) → PaginatedList[Question]

Retrieve a list of questions.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • text – Search question text.

  • pad_types – Repeatable usage filters.

Returns:

The list of questions with pagination metadata.

async all(*, sort: QuestionSortOrder | SortOrder | None = None, text: str | None = None, pad_types: Sequence[Literal['any', 'live', 'take_home']] | None = None) → AsyncIterator[Question]

Yield questions incrementally with filters on every page.

async create(*, title: str, language: Language | str, description: str | None = None, contents: str | None = None, solution: str | None = None, ai_assist_custom_system_prompt: str | None = None, shared: bool | None = None, custom_database_id: int | None = None, candidate_instructions: Sequence[CandidateInstruction] | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None) → Question

Create a new question.

Parameters:
  • title – Title for the question.

  • language – Programming language for the question.

  • description – Notes about the question.

  • contents – Text inserted into the interview session. Cannot be combined with file_contents.

  • solution – The solution to the question.

  • ai_assist_custom_system_prompt – Custom system prompt for AI Assist.

  • shared – Whether to share the question with your organization.

  • custom_database_id – The custom database to attach.

  • candidate_instructions – Progressively-revealed instruction blocks shown to the candidate.

  • file_contents – Files for a multi-file question. Cannot be combined with contents or zip_file.

  • zip_file – Path to a zip archive containing files for a multi-file question. Cannot be combined with file_contents.

  • directory – Directory to upload using the ZIP importer. Cannot be combined with other content sources. Includes hidden files and rejects symbolic links within the directory. Uploads all files in the directory.

Returns:

The created question.

async get(*, question_id: str) → Question

Retrieve a question by id.

Parameters:

question_id – The id of the question.

Returns:

The question.

async update(*, question_id: str, title: str | None = None, language: Language | str | None = None, description: str | None = None, contents: str | None = None, solution: str | None = None, ai_assist_custom_system_prompt: str | None = None, shared: bool | None = None, custom_database_id: int | None = None, candidate_instructions: Sequence[CandidateInstruction] | None = None, file_contents: Sequence[QuestionFileContent] | None = None, zip_file: Path | None = None, directory: Path | None = None) → None

Modify an existing question.

Parameters:
  • question_id – The id of the question.

  • title – New title for the question.

  • language – New programming language.

  • description – New description.

  • contents – New contents. Cannot be combined with file_contents.

  • solution – New solution.

  • ai_assist_custom_system_prompt – Custom system prompt for AI Assist.

  • shared – Whether to share the question with your organization.

  • custom_database_id – The custom database to attach.

  • candidate_instructions – Progressively-revealed instruction blocks shown to the candidate.

  • file_contents – Files for a multi-file question. Cannot be combined with contents or zip_file.

  • zip_file – Path to a zip archive containing files for a multi-file question. Cannot be combined with file_contents.

  • directory – Directory to upload using the ZIP importer. Cannot be combined with other content sources. Includes hidden files and rejects symbolic links within the directory. Uploads all files in the directory.

async delete(*, question_id: str) → None

Delete a question.

Parameters:

question_id – The id of the question.

class coderpad.async_client.AsyncOrganizationPadsNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async organization pad operations.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async list(*, sort: SortOrder | None = None, page: int | None = None) → PaginatedList[Pad]

Retrieve pads for the entire organization.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

Returns:

The list of pads with pagination metadata.

class coderpad.async_client.AsyncOrganizationQuestionsNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async organization question operations.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async list(*, sort: QuestionSortOrder | SortOrder | None = None, page: int | None = None, pad_type: Literal['live', 'take_home'] | None = None, language: Language | str | None = None) → PaginatedList[Question]

Retrieve questions for the entire organization.

Parameters:
  • sort – Sort order.

  • page – Page number for pagination.

  • pad_type – Filter live or take-home questions.

  • language – Filter question language.

Returns:

The list of questions with pagination metadata.

async all(*, sort: QuestionSortOrder | SortOrder | None = None, pad_type: Literal['live', 'take_home'] | None = None, language: Language | str | None = None) → AsyncIterator[Question]

Yield questions incrementally with filters on every page.

class coderpad.async_client.AsyncOrganizationUsersNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async organization user operations.

Create a new async namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async list(*, email: str | None = None) → list[OrganizationUser]

Retrieve users in the organization.

Parameters:

email – Return only the user with this email address.

Returns:

The organization users matching the filter.

class coderpad.async_client.AsyncOrganizationNamespace(*, transport: AsyncTransport, base_url: str, headers: dict[str, str])

Namespace for async organization operations.

Create a new async organization namespace.

Parameters:
  • transport – The async HTTP transport.

  • base_url – The base URL for the API.

  • headers – Headers to send with every request.

async get() → Organization

Retrieve organization information.

Returns:

The organization details.

async get_stats(*, start_time: str | None = None, end_time: str | None = None) → OrganizationStats

Retrieve pad usage stats for the organization.

Parameters:
  • start_time – ISO 8601 start of the search window.

  • end_time – ISO 8601 end of the search window.

Returns:

The usage statistics.

async get_quota() → Quota

Retrieve quota information.

Returns:

The quota details.

class coderpad.async_client.AsyncCoderPad(*, api_key: str, base_url: str = 'https://app.coderpad.io', screen_api_key: str | None = None, screen_base_url: str = 'https://screen.coderpad.io', transport: AsyncTransport | None = None, screen_transport: AsyncJSONTransport | None = None, default_headers: dict[str, str] | None = None, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

An async client for the CoderPad Interview API.

Create a new async CoderPad client.

Parameters:
  • api_key – The API key for authentication.

  • base_url – The base URL for the API.

  • screen_api_key – The independent Screen API key.

  • screen_base_url – The US, EU, or custom Screen base URL.

  • transport – The async HTTP transport. Defaults to AsyncHTTPXTransport().

  • screen_transport – The independent Screen HTTP transport.

  • default_headers – Extra headers merged into every Interview and Screen request. Authorization and API-Key values from these headers are overwritten by the client keys.

  • limits – Optional connection pool limits for default transports.

  • proxy – Optional proxy for the default httpx transports.

  • timeout – Optional timeout for the default httpx transports.

property screen: AsyncScreenNamespace

Screen API namespace, created on first access.

Raises:

ValueError – If screen_api_key was not provided.

classmethod from_env() → Self

Create a client using CODERPAD_API_KEY and optional Screen key.

Reads CODERPAD_API_KEY (required) and CODERPAD_SCREEN_API_KEY (optional) from the environment.

Returns:

A new async client configured from environment variables.

Raises:

KeyError – If CODERPAD_API_KEY is not set.

async aclose() → None

Close the underlying transport.

Synchronous CoderPad Screen API namespaces.

class coderpad.screen.ScreenCampaignsNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Screen campaign operations.

Create shared Screen request state.

list() → list[ScreenCampaign]

List assessment campaigns.

get(*, campaign_id: int) → ScreenCampaignDetails

Retrieve a campaign’s ordered questions, settings, and team.

create(*, name: str, questions: Sequence[ScreenCampaignQuestion | ScreenRandomQuestionSet], settings: ScreenCampaignSettings | None = None, team_id: str | None = None) → ScreenCreatedCampaign

Create a campaign once, preserving omitted team defaults.

Account feature restrictions and incompatible settings are reported by the service. Creation is never automatically retried.

send_invitation(*, campaign_id: int, invitation: ScreenInvitation) → ScreenInvitationResult

Create a test session and optionally email the candidate.

class coderpad.screen.ScreenTestsNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Screen test-session operations.

Create shared Screen request state.

list(*, campaign_id: int | None = None, status: str | None = None, tag: str | None = None, search: str | None = None, product: str | None = None, candidate_email: str | None = None, from_time: int | None = None, to_time: int | None = None, start: int | None = None, limit: int | None = None) → ScreenTestsPage

List one offset-paginated page of tests.

Pass page.pagination.next_start to start while has_more_items is true to traverse subsequent pages.

all(*, campaign_id: int | None = None, status: str | None = None, tag: str | None = None, search: str | None = None, product: str | None = None, candidate_email: str | None = None, from_time: int | None = None, to_time: int | None = None, limit: int | None = None) → Iterator[ScreenTest]

Yield all tests across offset-paginated responses.

Parameters:
  • campaign_id – Filter by campaign id.

  • status – Filter by status.

  • tag – Filter by tag.

  • search – Free-text search.

  • product – Filter by product.

  • candidate_email – Filter by candidate email.

  • from_time – Lower bound timestamp.

  • to_time – Upper bound timestamp.

  • limit – Page size.

Yields:

Each test until pagination.has_more_items is false.

get(*, test_id: int, with_community_stats: bool = False) → ScreenTest

Retrieve one test session.

cancel(*, test_id: int) → None

Cancel a test invitation.

resend(*, test_id: int) → None

Resend a test invitation.

delete(*, test_id: int) → None

Delete a test session.

ai_assist_conversations(*, test_id: int, question_id: str | UUID) → list[ScreenAIConversation]

Retrieve PROJECT question conversations after completion or review.

Conversation and message order and structured output are preserved. A missing project question raises the normal 404 error, and a test that is still running raises the normal 409 error.

project_archive(*, test_id: int, question_id: str | UUID) → bytes

Download a compressed project archive with the candidate’s changes applied.

Returns the original binary archive without extracting it or writing files. Configure the client transport timeout for slow generation. HTTP and transport errors use the same contract as report downloads.

report(*, test_id: int, report_type: str | None = None, anonymous: bool | None = None, include_rank: bool | None = None, include_comparative_score: bool | None = None) → bytes

Download a test report without writing it to disk.

report_json(*, test_id: int, with_community_stats: bool = False) → ScreenReport

Return the typed JSON report embedded in a test session.

The Screen /tests/{id}/report endpoint serves PDF bytes. Scored report fields are returned on GET /tests/{id} as ScreenTest.report; this helper fetches that payload and returns the typed report.

Parameters:
  • test_id – The Screen test session id.

  • with_community_stats – Whether to include community statistics on the report.

Returns:

The typed scored report.

Raises:

LookupError – If the test exists but has no report yet.

class coderpad.screen.ScreenQuestionsNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Screen question library reads and statistics.

Create shared Screen request state.

list(*, filters: ScreenQuestionFilters | None = None, start: int | None = None, limit: int | None = None) → ScreenQuestionsPage

List summaries with offset pagination and explicit filters.

all(*, filters: ScreenQuestionFilters | None = None, start: int = 0, limit: int | None = None) → Iterator[ScreenQuestionSummary]

Iterate summaries while retaining filters and rejecting repeated offsets.

get(*, question_id: str | UUID) → ScreenQuestionDetails

Retrieve a complete question by UUID.

create(*, question: ScreenQuestionSave) → ScreenCreatedQuestion

Create a question once, returning details and the Location header.

update(*, question_id: str | UUID, question: ScreenQuestionSave) → ScreenQuestionDetails

Save new content using only explicit writable fields, without retries.

insights(*, question_id: str | UUID, programming_language: str | None = None) → ScreenQuestionInsights

Retrieve usage, answer, test-case, and score statistics.

class coderpad.screen.ScreenTemporaryFilesNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Raw temporary uploads for Screen project questions.

Create shared Screen request state.

upload(*, content: bytes) → ScreenTemporaryFile

Upload raw bytes once and return their temporary identifier.

class coderpad.screen.ScreenWebhookNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Screen webhook operations.

Create shared Screen request state.

get() → ScreenWebhook

Retrieve webhook configuration.

set(*, url: str) → None

Set or replace the webhook URL.

delete() → None

Delete the webhook configuration.

class coderpad.screen.ScreenNamespace(*, transport: JSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None = None)

Root namespace for the synchronous Screen API.

Create the root Screen namespace.

me() → ScreenAccount

Retrieve the Screen key owner and available teams.

Asynchronous CoderPad Screen API namespaces.

class coderpad.async_screen.AsyncScreenCampaignsNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Asynchronous Screen campaign operations.

Create shared asynchronous Screen request state.

async list() → list[ScreenCampaign]

List assessment campaigns.

async get(*, campaign_id: int) → ScreenCampaignDetails

Retrieve a campaign’s ordered questions, settings, and team.

async create(*, name: str, questions: Sequence[ScreenCampaignQuestion | ScreenRandomQuestionSet], settings: ScreenCampaignSettings | None = None, team_id: str | None = None) → ScreenCreatedCampaign

Create a campaign once, preserving omitted team defaults.

Account feature restrictions and incompatible settings are reported by the service. Creation is never automatically retried.

async send_invitation(*, campaign_id: int, invitation: ScreenInvitation) → ScreenInvitationResult

Create a test session and optionally email the candidate.

class coderpad.async_screen.AsyncScreenTestsNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Asynchronous Screen test-session operations.

Create shared asynchronous Screen request state.

async list(*, campaign_id: int | None = None, status: str | None = None, tag: str | None = None, search: str | None = None, product: str | None = None, candidate_email: str | None = None, from_time: int | None = None, to_time: int | None = None, start: int | None = None, limit: int | None = None) → ScreenTestsPage

List one offset-paginated page of tests.

Pass page.pagination.next_start to start while has_more_items is true to traverse subsequent pages.

async all(*, campaign_id: int | None = None, status: str | None = None, tag: str | None = None, search: str | None = None, product: str | None = None, candidate_email: str | None = None, from_time: int | None = None, to_time: int | None = None, limit: int | None = None) → AsyncIterator[ScreenTest]

Yield all tests across offset-paginated responses.

Parameters:
  • campaign_id – Filter by campaign id.

  • status – Filter by status.

  • tag – Filter by tag.

  • search – Free-text search.

  • product – Filter by product.

  • candidate_email – Filter by candidate email.

  • from_time – Lower bound timestamp.

  • to_time – Upper bound timestamp.

  • limit – Page size.

Yields:

Each test until pagination.has_more_items is false.

async get(*, test_id: int, with_community_stats: bool = False) → ScreenTest

Retrieve one test session.

async cancel(*, test_id: int) → None

Cancel a test invitation.

async resend(*, test_id: int) → None

Resend a test invitation.

async delete(*, test_id: int) → None

Delete a test session.

async ai_assist_conversations(*, test_id: int, question_id: str | UUID) → list[ScreenAIConversation]

Retrieve PROJECT question conversations after completion or review.

Conversation and message order and structured output are preserved. A missing project question raises the normal 404 error, and a test that is still running raises the normal 409 error.

async project_archive(*, test_id: int, question_id: str | UUID) → bytes

Download a compressed project archive with the candidate’s changes applied.

Returns the original binary archive without extracting it or writing files. Configure the client transport timeout for slow generation. HTTP and transport errors use the same contract as report downloads.

async report(*, test_id: int, report_type: str | None = None, anonymous: bool | None = None, include_rank: bool | None = None, include_comparative_score: bool | None = None) → bytes

Download a test report without writing it to disk.

async report_json(*, test_id: int, with_community_stats: bool = False) → ScreenReport

Return the typed JSON report embedded in a test session.

The Screen /tests/{id}/report endpoint serves PDF bytes. Scored report fields are returned on GET /tests/{id} as ScreenTest.report; this helper fetches that payload and returns the typed report.

Parameters:
  • test_id – The Screen test session id.

  • with_community_stats – Whether to include community statistics on the report.

Returns:

The typed scored report.

Raises:

LookupError – If the test exists but has no report yet.

class coderpad.async_screen.AsyncScreenQuestionsNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Screen question library reads and statistics.

Create shared asynchronous Screen request state.

async list(*, filters: ScreenQuestionFilters | None = None, start: int | None = None, limit: int | None = None) → ScreenQuestionsPage

List summaries with offset pagination and explicit filters.

async all(*, filters: ScreenQuestionFilters | None = None, start: int = 0, limit: int | None = None) → AsyncIterator[ScreenQuestionSummary]

Iterate summaries while retaining filters and rejecting repeated offsets.

async get(*, question_id: str | UUID) → ScreenQuestionDetails

Retrieve a complete question by UUID.

async create(*, question: ScreenQuestionSave) → ScreenCreatedQuestion

Create a question once, returning details and the Location header.

async update(*, question_id: str | UUID, question: ScreenQuestionSave) → ScreenQuestionDetails

Save new content using only explicit writable fields, without retries.

async insights(*, question_id: str | UUID, programming_language: str | None = None) → ScreenQuestionInsights

Retrieve usage, answer, test-case, and score statistics.

class coderpad.async_screen.AsyncScreenTemporaryFilesNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Raw temporary uploads for Screen project questions.

Create shared asynchronous Screen request state.

async upload(*, content: bytes) → ScreenTemporaryFile

Upload raw bytes once and return their temporary identifier.

class coderpad.async_screen.AsyncScreenWebhookNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str, default_headers: dict[str, str] | None)

Asynchronous Screen webhook operations.

Create shared asynchronous Screen request state.

async get() → ScreenWebhook

Retrieve webhook configuration.

async set(*, url: str) → None

Set or replace the webhook URL.

async delete() → None

Delete the webhook configuration.

class coderpad.async_screen.AsyncScreenNamespace(*, transport: AsyncJSONTransport, api_key: str, base_url: str = 'https://screen.coderpad.io', default_headers: dict[str, str] | None = None)

Root namespace for the asynchronous Screen API.

Create the root asynchronous Screen namespace.

async me() → ScreenAccount

Retrieve the Screen key owner and available teams.

Types for the CoderPad Screen API.

class coderpad.screen_types.ScreenCampaign(*, id: int, name: str, languages: list[str] = <factory>, pinned: bool = False, archived: bool = False)

A reusable Screen assessment campaign.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
name: str
languages: list[str]
pinned: bool
archived: bool
classmethod list_from_value(value: JsonValue) → list[Self]

Create campaigns from an API response value.

classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a campaign from an API response.

class coderpad.screen_types.ScreenInvitation(*, candidate_email: str | None = None, candidate_name: str | None = None, recruiter_email: str | None = None, tags: str | None = None, send_invitation_email: bool | None = None, send_notification_email_on_bounce: bool | None = None, allow_duplicate_invitations: bool | None = None)

An invitation to a Screen campaign.

Omit candidate identity to create a link the recruiter can share manually. Email delivery requires candidate_email. Unspecified delivery uses the server default, which sends email only when an address is supplied.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

candidate_email: str | None
candidate_name: str | None
recruiter_email: str | None
tags: str | None
send_invitation_email: bool | None
send_notification_email_on_bounce: bool | None
allow_duplicate_invitations: bool | None
require_delivery_address() → Self

Require an address when email delivery is explicitly enabled.

class coderpad.screen_types.ScreenInvitationResult(*, id: int | None, test_url: str | None)

The result of creating a Screen test invitation.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int | None
test_url: str | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create an invitation result from an API response.

class coderpad.screen_types.ScreenTestQuestion(*, id: int, last_activity_time: int | None)

A question included in a Screen test.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
last_activity_time: int | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a question from an API response.

class coderpad.screen_types.ScreenQuestionWarning(*, type: str | None = None, level: Literal['WARNING', 'UNUSUAL_ACTIVITY'] | None = None, message: str | None = None)

A warning with an open identifier and a severity level.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

type: str | None
level: Literal['WARNING', 'UNUSUAL_ACTIVITY'] | None
message: str | None
class coderpad.screen_types.ScreenAIReview(*, rationale: str | None = None, recommended_outcome: Literal['PASSED', 'FAILED'] | None = None, no_recommendation_reason: Literal['CONFIDENCE_SCORE_TOO_LOW', 'EMPTY_SUBMISSION', 'TRANSCRIPT_NOT_AVAILABLE', 'AI_REVIEW_FAILED'] | None = None)

An AI recommendation or the reason no recommendation was produced.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

rationale: str | None
recommended_outcome: Literal['PASSED', 'FAILED'] | None
no_recommendation_reason: Literal['CONFIDENCE_SCORE_TOO_LOW', 'EMPTY_SUBMISSION', 'TRANSCRIPT_NOT_AVAILABLE', 'AI_REVIEW_FAILED'] | None
class coderpad.screen_types.ScreenRubricCriterionResult(*, label: str | None = None, description: str | None = None, skill: str | None = None, outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None = None, max_points: int | None = None, awarded_points: int | None = None, result_message: str | None = None, result_overridden_by_recruiter: bool | None = None, review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None = None, ai_review: ScreenAIReview | None = None)

A rubric verdict, awarded points, and optional AI recommendation.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: str | None
description: str | None
skill: str | None
outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None
max_points: int | None
awarded_points: int | None
result_message: str | None
result_overridden_by_recruiter: bool | None
review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None
ai_review: ScreenAIReview | None
class coderpad.screen_types.ScreenRubricResult(*, criteria: list[ScreenRubricCriterionResult] | None = None)

Ordered criterion results from a rubric review.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

criteria: list[ScreenRubricCriterionResult] | None
class coderpad.screen_types.ScreenTestReportCaseResult(*, key: str | None = None, label: str | None = None, skill: str | None = None, outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None = None, output: str | None = None, test_identifier: str | None = None, max_points: int | None = None, awarded_points: int | None = None, result_overridden_by_recruiter: bool | None = None)

A project test verdict with its stable key and output.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

key: str | None
label: str | None
skill: str | None
outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None
output: str | None
test_identifier: str | None
max_points: int | None
awarded_points: int | None
result_overridden_by_recruiter: bool | None
class coderpad.screen_types.ScreenTestReportResult(*, test_cases: list[ScreenTestReportCaseResult] | None = None)

Ordered results from the project test suite.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenTestReportCaseResult] | None
class coderpad.screen_types.ScreenValidationCodeCaseResult(*, label: str | None = None, skill: str | None = None, outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None = None, test_identifier: str | None = None, max_points: int | None = None, awarded_points: int | None = None, result_message: str | None = None, result_overridden_by_recruiter: bool | None = None, timed_out: bool | None = None)

A validation method result with timing and override indicators.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: str | None
skill: str | None
outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None
test_identifier: str | None
max_points: int | None
awarded_points: int | None
result_message: str | None
result_overridden_by_recruiter: bool | None
timed_out: bool | None
class coderpad.screen_types.ScreenValidationCodeResult(*, test_cases: list[ScreenValidationCodeCaseResult] | None = None)

Ordered validation results, including flattened nested cases.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenValidationCodeCaseResult] | None
class coderpad.screen_types.ScreenInputOutputCaseResult(*, label: str | None = None, skill: str | None = None, outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None = None, max_points: int | None = None, awarded_points: int | None = None, result_message: str | None = None, result_overridden_by_recruiter: bool | None = None, timed_out: bool | None = None)

An output comparison result with points and a display message.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: str | None
skill: str | None
outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None
max_points: int | None
awarded_points: int | None
result_message: str | None
result_overridden_by_recruiter: bool | None
timed_out: bool | None
class coderpad.screen_types.ScreenInputOutputResult(*, test_cases: list[ScreenInputOutputCaseResult] | None = None)

Ordered results comparing program output with expected output.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenInputOutputCaseResult] | None
class coderpad.screen_types.ScreenSQLComparisonResult(*, outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None = None, max_points: int | None = None, awarded_points: int | None = None, result_message: str | None = None, result_overridden_by_recruiter: bool | None = None, timed_out: bool | None = None)

A database query comparison verdict and its points.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

outcome: Literal['PASSED', 'FAILED', 'NOT_RUN', 'PENDING_MANUAL_REVIEW'] | None
max_points: int | None
awarded_points: int | None
result_message: str | None
result_overridden_by_recruiter: bool | None
timed_out: bool | None
class coderpad.screen_types.ScreenAcceptedAnswer(*, value: str | None = None, match_type: Literal['EXACT', 'REGEX'] | None = None)

An accepted text value with exact or regular expression matching.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

value: str | None
match_type: Literal['EXACT', 'REGEX'] | None
class coderpad.screen_types.ScreenTextAnswerMatchingResult(*, accepted_answers: list[ScreenAcceptedAnswer] | None = None)

Accepted values used to match the submitted text.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

accepted_answers: list[ScreenAcceptedAnswer] | None
class coderpad.screen_types.ScreenChoiceSelectionResult(*, correct_choice_indexes: list[int] | None = None)

Correct indexes into the question choices.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

correct_choice_indexes: list[int] | None
class coderpad.screen_types.ScreenQuestionEvaluation(*, rubric: ScreenRubricResult | None = None, test_report: ScreenTestReportResult | None = None, validation_code: ScreenValidationCodeResult | None = None, input_output: ScreenInputOutputResult | None = None, sql_query_result_comparison: ScreenSQLComparisonResult | None = None, text_answer_matching: ScreenTextAnswerMatchingResult | None = None, choice_selection: ScreenChoiceSelectionResult | None = None)

Optional grading methods and their individual results.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

rubric: ScreenRubricResult | None
test_report: ScreenTestReportResult | None
validation_code: ScreenValidationCodeResult | None
input_output: ScreenInputOutputResult | None
sql_query_result_comparison: ScreenSQLComparisonResult | None
text_answer_matching: ScreenTextAnswerMatchingResult | None
choice_selection: ScreenChoiceSelectionResult | None
class coderpad.screen_types.ScreenCodeAnswer(*, code: str | None = None, programming_language_id: str | None = None)

Submitted code and the chosen programming language.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

code: str | None
programming_language_id: str | None
class coderpad.screen_types.ScreenGameAnswer(*, code: str | None = None, programming_language_id: str | None = None)

Submitted game code and the chosen programming language.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

code: str | None
programming_language_id: str | None
class coderpad.screen_types.ScreenMCQAnswer(*, selected_choice_indexes: list[int] | None = None)

Selected indexes into the ordered question choices.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

selected_choice_indexes: list[int] | None
class coderpad.screen_types.ScreenTextAnswer(*, text: str | None = None)

The candidate’s submitted free text.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

text: str | None
class coderpad.screen_types.ScreenFileUploadAnswer(*, filename: str | None = None, download_url: str | None = None, candidate_comment: str | None = None)

An uploaded file, a temporary URL, and an optional comment.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

filename: str | None
download_url: str | None
candidate_comment: str | None
class coderpad.screen_types.ScreenProjectAnswer(*, download_url: str | None = None, ai_assist_conversation_count: int | None = None)

An authenticated archive endpoint and an AI conversation count.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

download_url: str | None
ai_assist_conversation_count: int | None
class coderpad.screen_types.ScreenRecording(*, id: str | None = None, url: str | None = None, transcript_url: str | None = None, duration_seconds: int | None = None)

A recording with temporary media and transcript URLs.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str | None
url: str | None
transcript_url: str | None
duration_seconds: int | None
class coderpad.screen_types.ScreenVideoAnswer(*, recordings: list[ScreenRecording] | None = None, recording_availability: Literal['AVAILABLE', 'DELETED_BY_CANDIDATE', 'DELETED_BY_RECRUITER', 'UNAVAILABLE'] | None = None, candidate_comment: str | None = None)

Recording availability, ordered recordings, and a candidate comment.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

recordings: list[ScreenRecording] | None
recording_availability: Literal['AVAILABLE', 'DELETED_BY_CANDIDATE', 'DELETED_BY_RECRUITER', 'UNAVAILABLE'] | None
candidate_comment: str | None
class coderpad.screen_types.ScreenQuestionAnswer(*, code_answer: ScreenCodeAnswer | None = None, game_answer: ScreenGameAnswer | None = None, mcq_answer: ScreenMCQAnswer | None = None, text_answer: ScreenTextAnswer | None = None, file_upload_answer: ScreenFileUploadAnswer | None = None, project_answer: ScreenProjectAnswer | None = None, video_answer: ScreenVideoAnswer | None = None)

Candidate submissions grouped by question type.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

code_answer: ScreenCodeAnswer | None
game_answer: ScreenGameAnswer | None
mcq_answer: ScreenMCQAnswer | None
text_answer: ScreenTextAnswer | None
file_upload_answer: ScreenFileUploadAnswer | None
project_answer: ScreenProjectAnswer | None
video_answer: ScreenVideoAnswer | None
class coderpad.screen_types.ScreenMCQChoice(*, label: str | None = None)

A choice label in the language used by the candidate.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: str | None
class coderpad.screen_types.ScreenMCQResultDetails(*, choices: list[ScreenMCQChoice] | None = None, selection_mode: Literal['SINGLE', 'MULTIPLE'] | None = None, randomize_choices: bool | None = None)

Ordered choices and selection settings for the answered question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

choices: list[ScreenMCQChoice] | None
selection_mode: Literal['SINGLE', 'MULTIPLE'] | None
randomize_choices: bool | None
class coderpad.screen_types.ScreenDetailedQuestion(*, id: str, version: int | None = None, type: Literal['CODE', 'MCQ', 'TEXT', 'GAME', 'FILE_UPLOAD', 'PROJECT', 'VIDEO', 'MULTI'] | None = None, title: str | None = None, domain: str | None = None, warnings: list[ScreenQuestionWarning] | None = None, evaluation: ScreenQuestionEvaluation | None = None, answer: ScreenQuestionAnswer | None = None, max_points: int | None = None, awarded_points: int | None = None, time_limit_seconds: int | None = None, time_spent_seconds: int | None = None, first_access_time: int | None = None, submission_time: int | None = None, last_activity_time: int | None = None, answer_status: Literal['NOT_STARTED', 'NOT_SUBMITTED', 'EMPTY', 'STARTER_CODE_UNCHANGED', 'ANSWERED'] | None = None, grading_status: Literal['GRADED', 'PENDING_MANUAL_REVIEW', 'NOT_GRADED'] | None = None, timed_out: bool | None = None, result_overridden_by_recruiter: bool | None = None, marked_as_cheated_by_recruiter: bool | None = None, time_spent_outside_environment_seconds: int | None = None, environment_exit_count: int | None = None, mcq_details: ScreenMCQResultDetails | None = None)

A UUID question with candidate answers, grading, and activity data.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
version: int | None
type: Literal['CODE', 'MCQ', 'TEXT', 'GAME', 'FILE_UPLOAD', 'PROJECT', 'VIDEO', 'MULTI'] | None
title: str | None
domain: str | None
warnings: list[ScreenQuestionWarning] | None
evaluation: ScreenQuestionEvaluation | None
answer: ScreenQuestionAnswer | None
max_points: int | None
awarded_points: int | None
time_limit_seconds: int | None
time_spent_seconds: int | None
first_access_time: int | None
submission_time: int | None
last_activity_time: int | None
answer_status: Literal['NOT_STARTED', 'NOT_SUBMITTED', 'EMPTY', 'STARTER_CODE_UNCHANGED', 'ANSWERED'] | None
grading_status: Literal['GRADED', 'PENDING_MANUAL_REVIEW', 'NOT_GRADED'] | None
timed_out: bool | None
result_overridden_by_recruiter: bool | None
marked_as_cheated_by_recruiter: bool | None
time_spent_outside_environment_seconds: int | None
environment_exit_count: int | None
mcq_details: ScreenMCQResultDetails | None
class coderpad.screen_types.ScreenSkillResult(*, points: int | None, score: float | None, total_points: int | None)

A scored skill within a Screen report.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

points: int | None
score: float | None
total_points: int | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a skill result from an API response.

class coderpad.screen_types.ScreenTechnologyResult(*, points: int | None, score: float | None, skills: dict[str, ScreenSkillResult], total_points: int | None, comparative_score: float | None)

A scored technology within a Screen report.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

points: int | None
score: float | None
skills: dict[str, ScreenSkillResult]
total_points: int | None
comparative_score: float | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a technology result from an API response.

class coderpad.screen_types.ScreenReport(*, duration: int | None, warnings: list[str], points: int | None, score: float | None, technologies: dict[str, ScreenTechnologyResult], total_duration: int | None, total_points: int | None, comparative_score: float | None, community_stats: list[int] | None, marked_as_cheated_by_recruiter: bool | None = None, time_spent_outside_environment_seconds: int | None = None, environment_exit_count: int | None = None)

A candidate’s scored Screen report.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

duration: int | None
warnings: list[str]
points: int | None
score: float | None
technologies: dict[str, ScreenTechnologyResult]
total_duration: int | None
total_points: int | None
comparative_score: float | None
community_stats: list[int] | None
marked_as_cheated_by_recruiter: bool | None
time_spent_outside_environment_seconds: int | None
environment_exit_count: int | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a report from an API response.

class coderpad.screen_types.ScreenTest(*, id: int, status: str, campaign_id: int | None, candidate_name: str | None, candidate_email: str | None, tags: list[str], send_time: int | None, start_time: int | None, end_time: int | None, last_activity_time: int | None, url: str | None, test_url: str | None, report: ScreenReport | None, questions: list[ScreenTestQuestion | ScreenDetailedQuestion], timer_type: Literal['PER_QUESTION', 'GLOBAL', 'UNLIMITED'] | None = None, organization_id: str | None = None, candidate_language: str | None = None, approval_status: str | None = None)

A candidate’s Screen test session.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
status: str
campaign_id: int | None
candidate_name: str | None
candidate_email: str | None
tags: list[str]
send_time: int | None
start_time: int | None
end_time: int | None
last_activity_time: int | None
url: str | None
test_url: str | None
report: ScreenReport | None
questions: list[ScreenTestQuestion | ScreenDetailedQuestion]
timer_type: Literal['PER_QUESTION', 'GLOBAL', 'UNLIMITED'] | None
organization_id: str | None
candidate_language: str | None
approval_status: str | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a test session from an API response.

class coderpad.screen_types.ScreenPagination(*, start: int | None, limit: int | None, total: int | None, has_more_items: bool, next_start: int | None)

Offset pagination metadata returned by Screen.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

start: int | None
limit: int | None
total: int | None
has_more_items: bool
next_start: int | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create pagination metadata from an API response.

class coderpad.screen_types.ScreenTestsPage(*, tests: list[ScreenTest], pagination: ScreenPagination | None)

One page of Screen test sessions.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

tests: list[ScreenTest]
pagination: ScreenPagination | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create a tests page from an API response.

class coderpad.screen_types.ScreenWebhook(*, url: str | None)

The configured Screen webhook.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

url: str | None
classmethod from_dict(data: dict[str, JsonValue]) → Self

Create webhook configuration from an API response.

class coderpad.screen_types.ScreenTeam(*, id: str, name: str, is_default: bool)

A team available to the Screen API key owner.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
name: str
is_default: bool
class coderpad.screen_types.ScreenAccount(*, organization_id: str, recruiter_id: str, teams: list[ScreenTeam])

Organization, recruiter, and team identity for a Screen API key.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

organization_id: str
recruiter_id: str
teams: list[ScreenTeam]
class coderpad.screen_types.ScreenRandomQuestionConfiguration(*, domain: str | None = None, skills: list[str] | None = None, question_type: Literal['QUIZ', 'CODE'] | None = None, target_duration_minutes: int | None = None, target_experience_level: Literal['JUNIOR', 'SENIOR', 'EXPERT'] | None = None, included_question_ids: list[str] | None = None, excluded_question_ids: list[str] | None = None)

Criteria for a randomly selected set of Screen questions.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

domain: str | None
skills: list[str] | None
question_type: Literal['QUIZ', 'CODE'] | None
target_duration_minutes: int | None
target_experience_level: Literal['JUNIOR', 'SENIOR', 'EXPERT'] | None
included_question_ids: list[str] | None
excluded_question_ids: list[str] | None
validate_question_selection() → Self

Keep inclusion and exclusion lists mutually exclusive.

class coderpad.screen_types.ScreenCampaignQuestion(*, type: Literal['QUESTION'] = 'QUESTION', question_id: str)

One explicitly selected question, identified by UUID.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

type: Literal['QUESTION']
question_id: str
class coderpad.screen_types.ScreenRandomQuestionSet(*, type: Literal['RANDOM_QUESTION_SET'] = 'RANDOM_QUESTION_SET', configuration: ScreenRandomQuestionConfiguration)

A random set of questions in campaign order.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

type: Literal['RANDOM_QUESTION_SET']
configuration: ScreenRandomQuestionConfiguration
class coderpad.screen_types.ScreenCampaignTimer(*, mode: Literal['PER_QUESTION', 'GLOBAL', 'UNLIMITED'] | None = None, duration_minutes: int | None = None)

An optional campaign timer override.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

mode: Literal['PER_QUESTION', 'GLOBAL', 'UNLIMITED'] | None
duration_minutes: int | None
class coderpad.screen_types.ScreenCampaignAccessPeriod(*, min_start_time: str | None = None, max_end_time: str | None = None)

An optional access window using ISO 8601 instants.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

min_start_time: str | None
max_end_time: str | None
class coderpad.screen_types.ScreenCampaignFollowUpQuestions(*, enabled: bool | None = None, answer_format: Literal['TEXT', 'VIDEO', 'AUDIO'] | None = None)

Optional follow-up questions and their answer format.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

enabled: bool | None
answer_format: Literal['TEXT', 'VIDEO', 'AUDIO'] | None
class coderpad.screen_types.ScreenCampaignWebcamProctoring(*, enabled: bool | None = None, ai_analysis_enabled: bool | None = None)

Optional webcam recording and AI analysis settings.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

enabled: bool | None
ai_analysis_enabled: bool | None
class coderpad.screen_types.ScreenCampaignSettings(*, languages: list[str] | None = None, timer: ScreenCampaignTimer | None = None, invitation_expiration_days: int | None = None, access_period: ScreenCampaignAccessPeriod | None = None, send_candidate_simplified_report: bool | None = None, copy_paste_blocked: bool | None = None, follow_up_questions: ScreenCampaignFollowUpQuestions | None = None, webcam_proctoring: ScreenCampaignWebcamProctoring | None = None, full_screen_required: bool | None = None, ai_assist_enabled: bool | None = None, enabled_coding_agents: str | None = None)

Campaign overrides, with omitted values inheriting team defaults.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

languages: list[str] | None
timer: ScreenCampaignTimer | None
invitation_expiration_days: int | None
access_period: ScreenCampaignAccessPeriod | None
send_candidate_simplified_report: bool | None
copy_paste_blocked: bool | None
follow_up_questions: ScreenCampaignFollowUpQuestions | None
webcam_proctoring: ScreenCampaignWebcamProctoring | None
full_screen_required: bool | None
ai_assist_enabled: bool | None
enabled_coding_agents: str | None
class coderpad.screen_types.ScreenCampaignCreation(*, name: Annotated[str, MinLen(min_length=3), MaxLen(max_length=64)], questions: Annotated[list[Annotated[ScreenCampaignQuestion | ScreenRandomQuestionSet, FieldInfo(annotation=NoneType, required=True, discriminator='type')]], MinLen(min_length=1)], settings: ScreenCampaignSettings | None = None, team_id: str | None = None)

A new Screen campaign with ordered question entries.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str
questions: list[Annotated[ScreenCampaignQuestion | ScreenRandomQuestionSet, FieldInfo(annotation=NoneType, required=True, discriminator='type')]]
settings: ScreenCampaignSettings | None
team_id: str | None
class coderpad.screen_types.ScreenCreatedCampaign(*, id: int)

The integer ID returned after campaign creation.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
class coderpad.screen_types.ScreenAIMessage(*, id: str, role: Literal['USER', 'ASSISTANT'], creation_time: str | None = None, output_items: list[JsonValue] | None = None)

An ordered candidate or assistant message with original JSON output.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
role: Literal['USER', 'ASSISTANT']
creation_time: str | None
output_items: list[JsonValue] | None
class coderpad.screen_types.ScreenAIConversation(*, id: str, subject: str | None = None, creation_time: str | None = None, messages: list[ScreenAIMessage] = <factory>)

A candidate PROJECT question conversation with AI Assist.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
subject: str | None
creation_time: str | None
messages: list[ScreenAIMessage]
class coderpad.screen_types.ScreenQuestionUsageInsights(*, view_count: int | None = None, last_view_time: str | None = None, average_answer_duration_seconds: int | None = None, timeout_rate: float | None = None, average_score: float | None = None)

Usage metrics and score ratios returned by Screen.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

view_count: int | None
last_view_time: str | None
average_answer_duration_seconds: int | None
timeout_rate: float | None
average_score: float | None
class coderpad.screen_types.ScreenQuestionRepartitionInsights(*, label: str | None = None, count: int | None = None, percentage: float | None = None, correct: bool | None = None)

A frequent answer or test-case success count and ratio.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: str | None
count: int | None
percentage: float | None
correct: bool | None
class coderpad.screen_types.ScreenQuestionScoreRangeInsights(*, score_range: Literal['ZERO_SCORE', 'PARTIAL_SCORE', 'FULL_SCORE'] | None = None, candidate_count: int | None = None)

The candidate count in a zero, partial, or full score bucket.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

score_range: Literal['ZERO_SCORE', 'PARTIAL_SCORE', 'FULL_SCORE'] | None
candidate_count: int | None
class coderpad.screen_types.ScreenQuestionScoresDistributionInsights(*, distribution: list[ScreenQuestionScoreRangeInsights] | None = None, total_candidates: int | None = None)

Score buckets and the total number of candidates represented.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

distribution: list[ScreenQuestionScoreRangeInsights] | None
total_candidates: int | None
class coderpad.screen_types.ScreenQuestionInsights(*, id: str | None = None, usage: ScreenQuestionUsageInsights | None = None, frequent_answers: list[ScreenQuestionRepartitionInsights] | None = None, testcases_success: list[ScreenQuestionRepartitionInsights] | None = None, scores_distribution: ScreenQuestionScoresDistributionInsights | None = None)

Optional question statistics with absent and empty values preserved.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str | None
usage: ScreenQuestionUsageInsights | None
frequent_answers: list[ScreenQuestionRepartitionInsights] | None
testcases_success: list[ScreenQuestionRepartitionInsights] | None
scores_distribution: ScreenQuestionScoresDistributionInsights | None
class coderpad.screen_types.ScreenTemporaryFile(*, id: str)

A temporary upload identifier to use promptly when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str

Question variants

Use client.questions.variants (also available on AsyncCoderPad): list(question_id=...), get(question_id=..., variant_id=...), create(question_id=..., language=...), update(question_id=..., variant_id=...) and delete(question_id=..., variant_id=...). All five operations use JSON endpoints nested under the question. Custom Interview transports must accept the json keyword.

Create accepts a language key such as ruby or a project template slug such as react. Project variant responses have language=None. Use project_template_slug and project_template_id to identify their environment. Omitting contents preserves code on update, contents="" writes a blank starter file, and contents=None restores the language default. Changing environment clears code unless replacement code or files are supplied.

file_contents accepts a sequence of QuestionVariantFileContent models or a JSON string. File paths are already decoded in responses. hidden and deleted flags are preserved. Files overlay the template on create and replace variant files on update. To reset a template variant on update, pass file_contents=[]. The server prevents deleting .cpad and requires at least one remaining file. contents and file_contents cannot be combined, including explicit null code. solution sets the variant’s reference solution.

Transport abstractions for the CoderPad Interview API.

exception coderpad.transports.HTTPStatusError(*, status_code: int, content: bytes)

Raised when an HTTP response has an error status code.

Create a new HTTP status error.

Parameters:
  • status_code – The HTTP status code.

  • content – The response body.

class coderpad.transports.TransportResponse(*, status_code: int, headers: dict[str, str], content: bytes)

A response from a transport.

status_code: int
headers: dict[str, str]
content: bytes
json() → JsonValue

Parse the response body as JSON.

Returns:

The parsed JSON data.

raise_for_status() → None

Raise an error if the response has an error status.

Raises:

HTTPStatusError – If the status code is 400 or above.

class coderpad.transports.Transport(*args, **kwargs)

Protocol for HTTP transports.

A transport is a callable that makes an HTTP request and returns a TransportResponse.

class coderpad.transports.JSONTransport(*args, **kwargs)

Protocol for transports supporting JSON request bodies.

class coderpad.transports.BinaryTransport(*args, **kwargs)

Optional transport capability for raw binary Screen uploads.

class coderpad.transports.AsyncBinaryTransport(*args, **kwargs)

Optional async transport capability for raw binary Screen uploads.

class coderpad.transports.HTTPXTransport(*, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

HTTP transport using the httpx library.

This is the default transport. It uses a shared httpx.Client for connection pooling.

Create a new HTTPX transport.

Parameters:
  • limits – Optional connection pool limits for httpx.Client.

  • proxy – Optional proxy passed to httpx.Client.

  • timeout – Optional timeout passed to httpx.Client. When omitted, the default httpx timeout is used.

close() → None

Close the underlying HTTP client.

class coderpad.transports.HTTPX2Transport(*, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

HTTP transport using the httpx2 library.

This transport uses a shared httpx2.Client for connection pooling. Configuration objects must come from httpx2, not httpx.

Create a new HTTPX2 transport.

Parameters:
  • limits – Optional connection pool limits for httpx2.Client.

  • proxy – Optional proxy passed to httpx2.Client.

  • timeout – Optional timeout passed to httpx2.Client. When omitted, the default httpx2 timeout is used.

close() → None

Close the underlying HTTP client.

class coderpad.transports.AsyncTransport(*args, **kwargs)

Protocol for async HTTP transports.

An async transport is a callable that makes an async HTTP request and returns a TransportResponse.

class coderpad.transports.AsyncJSONTransport(*args, **kwargs)

Protocol for async transports supporting JSON request bodies.

class coderpad.transports.AsyncHTTPXTransport(*, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

Async HTTP transport using the httpx library.

This is the default async transport. It uses a shared httpx.AsyncClient for connection pooling.

Create a new async HTTPX transport.

Parameters:
  • limits – Optional connection pool limits for httpx.AsyncClient.

  • proxy – Optional proxy passed to httpx.AsyncClient.

  • timeout – Optional timeout passed to httpx.AsyncClient. When omitted, the default httpx timeout is used.

async aclose() → None

Close the underlying async HTTP client.

class coderpad.transports.AsyncHTTPX2Transport(*, limits: Limits | None = None, proxy: str | Proxy | None = None, timeout: Timeout | float | None = None)

Async HTTP transport using the httpx2 library.

This transport uses a shared httpx2.AsyncClient for connection pooling. Configuration objects must come from httpx2, not httpx.

Create a new asynchronous HTTPX2 transport.

Parameters:
  • limits – Optional connection pool limits for httpx2.AsyncClient.

  • proxy – Optional proxy passed to httpx2.AsyncClient.

  • timeout – Optional timeout passed to httpx2.AsyncClient. When omitted, the default httpx2 timeout is used.

async aclose() → None

Close the underlying asynchronous HTTP client.

Types for the CoderPad Interview API.

class coderpad.types.PaginatedList(iterable: Iterable[_T] = (), /, *, total: int, next_page: str | None = None, prev_page: str | None = None)

A list with pagination metadata from the API response.

Create a new paginated list.

Parameters:
  • iterable – The items for the list.

  • total – Total number of items across all pages.

  • next_page – URL for the next page, or None.

  • prev_page – URL for the previous page, or None.

class coderpad.types.SortOrder(*values)

Sort order for list endpoints.

CREATED_AT_ASC = 'created_at,asc'
CREATED_AT_DESC = 'created_at,desc'
UPDATED_AT_ASC = 'updated_at,asc'
UPDATED_AT_DESC = 'updated_at,desc'
class coderpad.types.QuestionSortOrder(*values)

Question sorting, including title and usage count.

CREATED_AT_ASC = 'created_at,asc'
CREATED_AT_DESC = 'created_at,desc'
UPDATED_AT_ASC = 'updated_at,asc'
UPDATED_AT_DESC = 'updated_at,desc'
TITLE_ASC = 'title,asc'
TITLE_DESC = 'title,desc'
USED_ASC = 'used,asc'
USED_DESC = 'used,desc'
class coderpad.types.Language(*values)

Programming language for pads and questions.

Single-file languages use a simple editor. Multi-file and framework languages support file_contents and zip_file uploads.

BASH = 'bash'
C = 'c'
CLOJURE = 'clojure'
COFFEESCRIPT = 'coffeescript'
CPP = 'cpp'
CSHARP = 'csharp'
DART = 'dart'
ELIXIR = 'elixir'
ERLANG = 'erlang'
FSHARP = 'fsharp'
GO = 'go'
GSHEETS = 'gsheets'
HACK = 'hack'
HASKELL = 'haskell'
HTML = 'html'
JAVA = 'java'
JAVASCRIPT = 'javascript'
JULIA = 'julia'
KOTLIN = 'kotlin'
LUA = 'lua'
MARKDOWN = 'markdown'
MYSQL = 'mysql'
OBJC = 'objc'
OCAML = 'ocaml'
PERL = 'perl'
PHP = 'php'
PLAINTEXT = 'plaintext'
POSTGRESQL = 'postgresql'
POWERSHELL = 'powershell'
PYTHON = 'python'
PYTHON3 = 'python3'
R = 'r'
RUBY = 'ruby'
RUST = 'rust'
SCALA = 'scala'
SOLIDITY = 'solidity'
SWIFT = 'swift'
TCL = 'tcl'
TYPESCRIPT = 'typescript'
VB = 'vb'
VERILOG = 'verilog'
ANGULAR = 'angular'
DJANGO = 'django'
GIN = 'gin'
KUBERNETES = 'kubernetes'
MULTIFILE_C = 'multifile_c'
MULTIFILE_CPP = 'multifile_cpp'
MULTIFILE_CSHARP = 'multifile_csharp'
MULTIFILE_GO = 'multifile_go'
MULTIFILE_JAVA = 'multifile_java'
MULTIFILE_KOTLIN = 'multifile_kotlin'
MULTIFILE_PHP = 'multifile_php'
MULTIFILE_PYTHON = 'multifile_python'
MULTIFILE_RUBY = 'multifile_ruby'
MULTIFILE_RUST = 'multifile_rust'
MULTIFILE_SCALA = 'multifile_scala'
MULTIFILE_SWIFT = 'multifile_swift'
MULTIFILE_TERRAFORM = 'multifile_terraform'
MULTIFILE_TYPESCRIPT = 'multifile_typescript'
NEXTJS = 'nextjs'
NODEJS = 'nodejs'
RAILS = 'rails'
REACT = 'react'
REACT_NATIVE_WEB = 'react-native-web'
SPRING = 'spring'
SVELTE = 'svelte'
UNIVERSAL = 'universal'
VUE = 'vue'
class coderpad.types.Team(*, id: str, name: str)

A team within an organization.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
name: str
classmethod from_dict(data: TeamDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.PadInterviewerNotification(*, id: int, title: str, message: str, priority: str, request_id: str, auto_dismissed: bool, dismissed_at: str | None = None, useful: bool | None = None, created_at: str, updated_at: str)

An interviewer notification associated with a pad.

This structure is empirically observed in live API responses and is not currently described by the published CoderPad API specification.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
title: str
message: str
priority: str
request_id: str
auto_dismissed: bool
dismissed_at: str | None
useful: bool | None
created_at: str
updated_at: str
classmethod from_dict(data: PadInterviewerNotificationDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.TranscriptEntry(*, id: str, kind: str, text: str, timestamp: int, speaker_name: str | None = None, speaker_role: str | None = None)

A transcript or system message with a Unix millisecond timestamp.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
kind: str
text: str
timestamp: int
speaker_name: str | None
speaker_role: str | None
class coderpad.types.ReviewReport(*, id: str, status: str, created_at: str, updated_at: str, title: str | None = None, prompt: str | None = None, report: str | None = None, summary: str | None = None, icon: str | None = None, error: str | None = None, user_id: int | None = None, file_paths: list[str] = <factory>)

An Interview review report and its processing status.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
status: str
created_at: str
updated_at: str
title: str | None
prompt: str | None
report: str | None
summary: str | None
icon: str | None
error: str | None
user_id: int | None
file_paths: list[str]
class coderpad.types.Pad(*, id: str, title: str, state: str, owner_email: str, language: str | None = None, private: bool, execution_enabled: bool, contents: str | None = None, participants: list[str], events: str, notes: str | None = None, created_at: str, updated_at: str, ended_at: str | None = None, url: str, playback: str, drawing: str | None = None, type: str, question_ids: list[int], pad_environment_ids: list[int], active_environment_id: int | None = None, team: ~coderpad.types.Team, history: str | None = None, interview_highlights: str | None = None, interview_outline: ~pydantic.types.JsonValue = None, transcript: list[~coderpad.types.TranscriptEntry] | None = None, transcript_source_unavailable: bool | None = None, review_reports: list[~coderpad.types.ReviewReport] | None = None, allowed_interviewer_emails: list[str] | None = None, restrict_interviewer_access: bool | None = None, pad_interviewer_notifications: list[~coderpad.types.PadInterviewerNotification] = <factory>)

A CoderPad interview pad.

Not every field here can be written via create or update. See the “Writable and read-only fields” reference for the matrix.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
title: str
state: str
owner_email: str
language: str | None
private: bool
execution_enabled: bool
contents: str | None
participants: list[str]
events: str
notes: str | None
created_at: str
updated_at: str
ended_at: str | None
url: str
playback: str
drawing: str | None
type: str
question_ids: list[int]
pad_environment_ids: list[int]
active_environment_id: int | None
team: Team
history: str | None
interview_highlights: str | None
interview_outline: JsonValue
transcript: list[TranscriptEntry] | None
transcript_source_unavailable: bool | None
review_reports: list[ReviewReport] | None
allowed_interviewer_emails: list[str] | None
restrict_interviewer_access: bool | None
pad_interviewer_notifications: list[PadInterviewerNotification]
classmethod from_dict(data: PadDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.PadEvent(*, message: str, kind: str, metadata: str | None = None, user_name: str | None = None, user_email: str | None = None, created_at: str)

An event associated with a pad.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

message: str
kind: str
metadata: str | None
user_name: str | None
user_email: str | None
created_at: str
classmethod from_dict(data: PadEventDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.PadHistoryEntry(*, id: str, author: str, operations: list[int | str], timestamp: int)

An editor operation from a pad’s Firebase history.

Positive integer operations retain existing characters, negative integers delete characters, and strings insert text.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
author: str
operations: list[int | str]
timestamp: int
classmethod from_dict(*, entry_id: str, data: PadHistoryEntryDict) → Self

Create from a Firebase history entry.

Parameters:
  • entry_id – The Firebase key for the entry.

  • data – The dictionary to convert.

Returns:

A new instance.

apply(*, contents: str) → str

Apply this operation to existing file contents.

Parameters:

contents – The contents immediately before this operation.

Returns:

The updated contents.

class coderpad.types.PadHistory(iterable=(), /)

Chronologically ordered editor history for a pad file.

classmethod from_dict(*, data: dict[str, PadHistoryEntryDict]) → Self

Create from a Firebase history response.

Parameters:

data – Firebase keys mapped to editor operations.

Returns:

A chronologically ordered history.

replay(*, initial_contents: str = '') → str

Replay all operations and return the resulting contents.

Parameters:

initial_contents – Contents before the first operation.

Returns:

The contents after all operations.

class coderpad.types.FileContent(*, path: str, contents: str | None, history: str | None = None, binary: bool = False)

A file within a pad environment.

Binary files are empirically observed with binary set to True and contents set to None; these fields are not fully described by the published API specification.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

path: str
contents: str | None
history: str | None
binary: bool
classmethod from_dict(data: FileContentDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.PadEnvironment(*, id: int, pad_id: int, question_id: int | None = None, example_question_id: int | None = None, language: str, file_contents: list[FileContent], created_at: str, updated_at: str)

A pad environment.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
pad_id: int
question_id: int | None
example_question_id: int | None
language: str
file_contents: list[FileContent]
created_at: str
updated_at: str
classmethod from_dict(data: PadEnvironmentDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.QuestionFileContent(*, path: str, contents: str | None = None, hidden: bool | None = None, deleted: bool | None = None)

A file for a multi-file question.

Used when creating or updating questions with multi-file languages.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

path: str
contents: str | None
hidden: bool | None
deleted: bool | None
class coderpad.types.QuestionVariantSummary(*, id: int, language: str | None = None, project_template_id: int | None = None, project_template_slug: str | None = None, display: str | None = None)

A variant summary without code or creation timestamps.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
language: str | None
project_template_id: int | None
project_template_slug: str | None
display: str | None
class coderpad.types.QuestionVariantUnset(*values)

An omitted variant attribute, distinct from explicit JSON null.

OMITTED = 'unset'
class coderpad.types.QuestionVariantFileContent(*, path: str, contents: str = '', hidden: bool | None = None, deleted: bool | None = None)

A variant starter file, including template overlay flags.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

path: str
contents: str
hidden: bool | None
deleted: bool | None
class coderpad.types.QuestionVariant(*, id: int, question_id: int, language: str | None, project_template_id: int | None = None, project_template_slug: str | None = None, display: str | None = None, contents: str | None = None, file_contents: list[QuestionVariantFileContent] | None = None, solution: str | None = None, created_at: str, updated_at: str)

A language or project-template variant of a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
question_id: int
language: str | None
project_template_id: int | None
project_template_slug: str | None
display: str | None
contents: str | None
file_contents: list[QuestionVariantFileContent] | None
solution: str | None
created_at: str
updated_at: str
class coderpad.types.CandidateInstruction(*, instructions: str, name: str | None = None, default_visible: bool = False)

Instructions shown to a candidate.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

instructions: str
name: str | None
default_visible: bool
classmethod from_dict(data: CandidateInstructionDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.TestCase(*, id: int, return_value: str, visible: bool, arguments: list[str])

A test case for a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
return_value: str
visible: bool
arguments: list[str]
classmethod from_dict(data: TestCaseDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.CustomFile(*, id: str, title: str, description: str, filename: str, filesize: str)

A custom file attached to a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
title: str
description: str
filename: str
filesize: str
classmethod from_dict(data: CustomFileDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.CustomDatabaseColumn(*, name: str, type: str, pk: bool, nn: bool)

A column in a question’s custom database schema.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str
type: str
pk: bool
nn: bool
classmethod from_dict(data: CustomDatabaseColumnDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.CustomDatabaseTable(*, name: str, columns: list[CustomDatabaseColumn])

A table in a question’s custom database schema.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str
columns: list[CustomDatabaseColumn]
classmethod from_dict(data: CustomDatabaseTableDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.CustomDatabaseSchema(*, arrangement: str, tables: list[CustomDatabaseTable])

The structured schema for a question’s custom database.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

arrangement: str
tables: list[CustomDatabaseTable]
classmethod from_dict(data: CustomDatabaseSchemaDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.CustomDatabase(*, id: int, title: str, description: str, language: str, schema: str, schema_json: CustomDatabaseSchema)

A custom database attached to a question.

This structure is empirically observed in live API responses and is not currently described by the published CoderPad API specification.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
title: str
description: str
language: str
classmethod from_dict(data: CustomDatabaseDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.Question(*, id: int, title: str, owner_email: str, language: str | None = None, description: str | None = None, candidate_instructions: list[CandidateInstruction], contents: str | None = None, shared: bool, used: int, take_home: bool, test_cases_enabled: bool, solution: str | None = None, pad_type: str, is_draft: bool, author_name: str, organization_name: str, custom_files: list[CustomFile], file_contents: list[QuestionFileContent] | None = None, question_variants: list[QuestionVariantSummary] | None = None, created_at: str, updated_at: str, public_take_home_setting_id: int | None = None, contents_for_test_cases: str | None = None, test_cases: list[TestCase] | None = None, custom_database: CustomDatabase | None = None, ai_assist_custom_system_prompt: str | None = None)

A CoderPad question.

Not every field here can be written via create or update. See the “Writable and read-only fields” reference for the matrix.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: int
title: str
owner_email: str
language: str | None
description: str | None
candidate_instructions: list[CandidateInstruction]
contents: str | None
shared: bool
used: int
take_home: bool
test_cases_enabled: bool
solution: str | None
pad_type: str
is_draft: bool
author_name: str
organization_name: str
custom_files: list[CustomFile]
file_contents: list[QuestionFileContent] | None
question_variants: list[QuestionVariantSummary] | None
created_at: str
updated_at: str
public_take_home_setting_id: int | None
contents_for_test_cases: str | None
test_cases: list[TestCase] | None
custom_database: CustomDatabase | None
ai_assist_custom_system_prompt: str | None
classmethod from_dict(data: QuestionDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.OrganizationUser(*, email: str, name: str, teams: list[str])

A user within an organization.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

email: str
name: str
teams: list[str]
classmethod from_dict(data: OrganizationUserDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.OrganizationStatsUser(*, email: str, name: str, pads_created: int)

A user’s pad usage statistics.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

email: str
name: str
pads_created: int
classmethod from_dict(data: OrganizationStatsUserDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.Quota(*, trial_expires_at: str, pads_used: int, quota_reset_at: str, unlimited: bool, overages_enabled: bool)

Quota information.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

trial_expires_at: str
pads_used: int
quota_reset_at: str
unlimited: bool
overages_enabled: bool
classmethod from_dict(data: QuotaDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.Organization(*, organization_name: str, user_count: int, users: list[~coderpad.types.OrganizationUser], organization_default_language: str, single_sign_on_supported: bool, teams: list[~coderpad.types.Team], single_sign_in_url: str | None = None, id: int | None = None, child_organizations: list[dict[str, ~pydantic.types.JsonValue]] = <factory>)

Organization information.

id and child_organizations are empirically observed fields that are not currently described by the published API specification. Child organizations remain raw mappings until their non-empty shape is known.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

organization_name: str
user_count: int
users: list[OrganizationUser]
organization_default_language: str
single_sign_on_supported: bool
teams: list[Team]
single_sign_in_url: str | None
id: int | None
child_organizations: list[dict[str, JsonValue]]
classmethod from_dict(data: OrganizationDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.OrganizationStats(*, start_time: str, end_time: str, pads_created: int, users: list[OrganizationStatsUser])

Organization usage statistics.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

start_time: str
end_time: str
pads_created: int
users: list[OrganizationStatsUser]
classmethod from_dict(data: OrganizationStatsDict) → Self

Create from an API response dictionary.

Parameters:

data – The dictionary to convert.

Returns:

A new instance.

class coderpad.types.User(*, name: str | None = None, allow_pad_creation: bool, analytics_id: str)

The Interview API key owner’s display name and capabilities.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str | None
allow_pad_creation: bool
analytics_id: str

Shared JSON type definitions.

coderpad.json_types.JsonValue

A JSON value as defined by pydantic.types.JsonValue.

Custom exception hierarchy for the CoderPad API.

exception coderpad.exceptions.CoderPadError(*, response: TransportResponse)

Base exception for all CoderPad API errors.

response

The full transport response for debugging.

status_code

The HTTP status code.

content

The response body.

code

Optional API error code from a JSON body.

message

Optional API error message from a JSON body.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

classmethod from_response(*, response: TransportResponse) → CoderPadError

Create the appropriate exception for a response.

Uses the registry to find a specific exception class for the response’s status code, falling back to CoderPadError.

Parameters:

response – The transport response.

Returns:

The appropriate exception instance.

exception coderpad.exceptions.BadRequestError(*, response: TransportResponse)

Raised for 400 Bad Request responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.AuthenticationError(*, response: TransportResponse)

Raised for 401 Unauthorized responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.ForbiddenError(*, response: TransportResponse)

Raised for 403 Forbidden responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.NotFoundError(*, response: TransportResponse)

Raised for 404 Not Found responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.RateLimitError(*, response: TransportResponse)

Raised for 429 Too Many Requests responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.ServerError(*, response: TransportResponse)

Raised for 500 Internal Server Error responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.BadGatewayError(*, response: TransportResponse)

Raised for 502 Bad Gateway responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.ServiceUnavailableError(*, response: TransportResponse)

Raised for 503 Service Unavailable responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

exception coderpad.exceptions.GatewayTimeoutError(*, response: TransportResponse)

Raised for 504 Gateway Timeout responses.

Create a new CoderPad error.

Parameters:

response – The transport response that caused the error.

Screen question library models

Typed Screen question library responses.

class coderpad.screen_question_types.ScreenQuestionSummary(*, id: str, version: int | None = None, title: dict[str, str] | None = None, type: Literal['MCQ', 'CODE', 'TEXT', 'MULTI', 'GAME', 'CLASH', 'COURSE', 'FILE_UPLOAD', 'PROJECT', 'VIDEO'] | None = None, difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None = None, domain: str | None = None, skill: str | None = None, product: Literal['SCREEN', 'QUALIFY'] | None = None, duration_seconds: int | None = None, programming_language_id: str | None = None, modification_time: str | None = None, from_coderpad_question_bank: bool | None = None)

Typed question summary returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
version: int | None
title: dict[str, str] | None
type: Literal['MCQ', 'CODE', 'TEXT', 'MULTI', 'GAME', 'CLASH', 'COURSE', 'FILE_UPLOAD', 'PROJECT', 'VIDEO'] | None
difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None
domain: str | None
skill: str | None
product: Literal['SCREEN', 'QUALIFY'] | None
duration_seconds: int | None
programming_language_id: str | None
modification_time: str | None
from_coderpad_question_bank: bool | None
class coderpad.screen_question_types.ScreenQuestionResourceDetails(*, filename: str | None = None, mime_type: str | None = None, download_url: str | None = None)

Typed question resource details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

filename: str | None
mime_type: str | None
download_url: str | None
class coderpad.screen_question_types.ScreenRubricCriterionDetails(*, label: dict[str, str] | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None = None, description: str | None = None)

Typed rubric criterion details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
skill: str | None
points: int | None
weight: int | None
review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None
description: str | None
class coderpad.screen_question_types.ScreenRubricDetails(*, criteria: list[ScreenRubricCriterionDetails] | None = None)

Typed rubric details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

criteria: list[ScreenRubricCriterionDetails] | None
class coderpad.screen_question_types.ScreenTestReportTestCaseDetails(*, key: str | None = None, test_identifier: str | None = None, label: dict[str, str] | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None)

Typed test report test case details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

key: str | None
test_identifier: str | None
label: dict[str, str] | None
skill: str | None
points: int | None
weight: int | None
class coderpad.screen_question_types.ScreenTestReportDetails(*, test_cases: list[ScreenTestReportTestCaseDetails] | None = None)

Typed test report details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenTestReportTestCaseDetails] | None
class coderpad.screen_question_types.ScreenValidationCodeTestCaseDetails(*, label: dict[str, str] | None = None, test_identifier: str | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, difficulty: int | None = None, contributes_to_score: bool | None = None, visible_to_candidate: bool | None = None)

Typed validation code test case details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
test_identifier: str | None
skill: str | None
points: int | None
weight: int | None
difficulty: int | None
contributes_to_score: bool | None
visible_to_candidate: bool | None
class coderpad.screen_question_types.ScreenValidationCodeDetails(*, test_cases: list[ScreenValidationCodeTestCaseDetails] | None = None)

Typed validation code details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenValidationCodeTestCaseDetails] | None
class coderpad.screen_question_types.ScreenInputOutputTestCaseDetails(*, label: dict[str, str] | None = None, input: str | None = None, output: str | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, difficulty: int | None = None, contributes_to_score: bool | None = None, visible_to_candidate: bool | None = None, timeout_ms_by_programming_language_id: dict[str, int] | None = None)

Typed input output test case details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
input: str | None
output: str | None
skill: str | None
points: int | None
weight: int | None
difficulty: int | None
contributes_to_score: bool | None
visible_to_candidate: bool | None
timeout_ms_by_programming_language_id: dict[str, int] | None
class coderpad.screen_question_types.ScreenInputOutputDetails(*, test_cases: list[ScreenInputOutputTestCaseDetails] | None = None)

Typed input output details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenInputOutputTestCaseDetails] | None
class coderpad.screen_question_types.ScreenQueryComparisonRulesDetails(*, row_order_matters: bool | None = None, column_order_matters: bool | None = None, compare_all_tables: bool | None = None)

Typed query comparison rules details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

row_order_matters: bool | None
column_order_matters: bool | None
compare_all_tables: bool | None
class coderpad.screen_question_types.ScreenSQLQueryResultComparisonDetails(*, reference_query: str | None = None, comparison: ScreenQueryComparisonRulesDetails | None = None)

Typed SQL query result comparison details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

reference_query: str | None
comparison: ScreenQueryComparisonRulesDetails | None
class coderpad.screen_question_types.ScreenEvaluationAcceptedAnswerDetails(*, value: str | None = None, match_type: Literal['EXACT', 'REGEX'] | None = None)

Typed evaluation accepted answer details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

value: str | None
match_type: Literal['EXACT', 'REGEX'] | None
class coderpad.screen_question_types.ScreenTextAnswerMatchingDetails(*, accepted_answers: list[ScreenEvaluationAcceptedAnswerDetails] | None = None)

Typed text answer matching details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

accepted_answers: list[ScreenEvaluationAcceptedAnswerDetails] | None
class coderpad.screen_question_types.ScreenChoiceSelectionDetails(*, correct_choice_indexes: list[int] | None = None)

Typed choice selection details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

correct_choice_indexes: list[int] | None
class coderpad.screen_question_types.ScreenEvaluationDetails(*, rubric: ScreenRubricDetails | None = None, test_report: ScreenTestReportDetails | None = None, validation_code: ScreenValidationCodeDetails | None = None, input_output: ScreenInputOutputDetails | None = None, sql_query_result_comparison: ScreenSQLQueryResultComparisonDetails | None = None, text_answer_matching: ScreenTextAnswerMatchingDetails | None = None, choice_selection: ScreenChoiceSelectionDetails | None = None)

Typed evaluation details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

rubric: ScreenRubricDetails | None
test_report: ScreenTestReportDetails | None
validation_code: ScreenValidationCodeDetails | None
input_output: ScreenInputOutputDetails | None
sql_query_result_comparison: ScreenSQLQueryResultComparisonDetails | None
text_answer_matching: ScreenTextAnswerMatchingDetails | None
choice_selection: ScreenChoiceSelectionDetails | None
class coderpad.screen_question_types.ScreenQuestionChoiceDetails(*, label: dict[str, str] | None = None)

Typed question choice details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
class coderpad.screen_question_types.ScreenMCQDetails(*, choices: list[ScreenQuestionChoiceDetails] | None = None, selection_mode: Literal['SINGLE', 'MULTIPLE'] | None = None, randomize_choices: bool | None = None)

Typed multiple choice details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

choices: list[ScreenQuestionChoiceDetails] | None
selection_mode: Literal['SINGLE', 'MULTIPLE'] | None
randomize_choices: bool | None
class coderpad.screen_question_types.ScreenEnvironmentDetails(*, version: str | None = None, environment_id: str | None = None)

Typed environment details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
environment_id: str | None
class coderpad.screen_question_types.ScreenDatabaseEngineDetails(*, version: str | None = None, engine_id: str | None = None)

Typed database engine details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
engine_id: str | None
class coderpad.screen_question_types.ScreenFunctionSignatureDetails(*, name: str | None = None, parameters: list[dict[str, JsonValue]] | None = None, return_type: dict[str, JsonValue] | None = None)

Typed function signature details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str | None
parameters: list[dict[str, JsonValue]] | None
return_type: dict[str, JsonValue] | None
class coderpad.screen_question_types.ScreenPossibleSolutionDetails(*, code: str | None = None, programming_language_id: str | None = None)

Typed possible solution details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

code: str | None
programming_language_id: str | None
class coderpad.screen_question_types.ScreenCodeDetails(*, environment: ScreenEnvironmentDetails | None = None, mode: Literal['SINGLE_LANGUAGE', 'MULTI_LANGUAGE'] | None = None, programming_language_id: str | None = None, candidate_test_code: str | None = None, validator_code: str | None = None, timeout_ms: int | None = None, database_engine: ScreenDatabaseEngineDetails | None = None, database_setup_script: str | None = None, starter_code: str | None = None, function_signature: ScreenFunctionSignatureDetails | None = None, possible_solution: ScreenPossibleSolutionDetails | None = None, show_function_signature_in_statement: bool | None = None, available_programming_language_ids: list[str] | None = None)

Typed code details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

environment: ScreenEnvironmentDetails | None
mode: Literal['SINGLE_LANGUAGE', 'MULTI_LANGUAGE'] | None
programming_language_id: str | None
candidate_test_code: str | None
validator_code: str | None
timeout_ms: int | None
database_engine: ScreenDatabaseEngineDetails | None
database_setup_script: str | None
starter_code: str | None
function_signature: ScreenFunctionSignatureDetails | None
possible_solution: ScreenPossibleSolutionDetails | None
show_function_signature_in_statement: bool | None
available_programming_language_ids: list[str] | None
class coderpad.screen_question_types.ScreenGameDetails(*, available_programming_language_ids: list[str] | None = None)

Typed game details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

available_programming_language_ids: list[str] | None
class coderpad.screen_question_types.ScreenTextDetails(*, evaluation_mode: Literal['MANUAL', 'AUTOMATIC'] | None = None)

Typed text details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

evaluation_mode: Literal['MANUAL', 'AUTOMATIC'] | None
class coderpad.screen_question_types.ScreenFileUploadDetails(*, download_url: str | None = None)

Typed file upload details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

download_url: str | None
class coderpad.screen_question_types.ScreenVideoDetails(*, recording_media: Literal['VIDEO', 'AUDIO'] | None = None)

Typed video details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

recording_media: Literal['VIDEO', 'AUDIO'] | None
class coderpad.screen_question_types.ScreenProjectResourceDetails(*, version: str | None = None, resource_id: str | None = None)

Typed project resource details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
resource_id: str | None
class coderpad.screen_question_types.ScreenProjectDetails(*, environment: ScreenEnvironmentDetails | None = None, resources: list[ScreenProjectResourceDetails] | None = None, ai_assist_additional_instructions: str | None = None, ai_assist_allowed: bool | None = None, download_url: str | None = None)

Typed project details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

environment: ScreenEnvironmentDetails | None
resources: list[ScreenProjectResourceDetails] | None
ai_assist_additional_instructions: str | None
ai_assist_allowed: bool | None
download_url: str | None
class coderpad.screen_question_types.ScreenQuestionDetails(*, id: str, version: int | None = None, type: Literal['MCQ', 'CODE', 'TEXT', 'MULTI', 'GAME', 'CLASH', 'COURSE', 'FILE_UPLOAD', 'PROJECT', 'VIDEO'] | None = None, domain: str | None = None, difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None = None, points: int | None = None, title: dict[str, str] | None = None, statement: dict[str, str] | None = None, locales: list[str] | None = None, skill: str | None = None, resources: list[ScreenQuestionResourceDetails] | None = None, comment: str | None = None, evaluation: ScreenEvaluationDetails | None = None, duration_seconds: int | None = None, creation_time: str | None = None, modification_time: str | None = None, from_coderpad_question_bank: bool | None = None, team_id: str | None = None, automatically_selectable: bool | None = None, mcq_details: ScreenMCQDetails | None = None, code_details: ScreenCodeDetails | None = None, game_details: ScreenGameDetails | None = None, text_details: ScreenTextDetails | None = None, file_upload_details: ScreenFileUploadDetails | None = None, video_details: ScreenVideoDetails | None = None, project_details: ScreenProjectDetails | None = None)

Typed question details returned by the question library.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

id: str
version: int | None
type: Literal['MCQ', 'CODE', 'TEXT', 'MULTI', 'GAME', 'CLASH', 'COURSE', 'FILE_UPLOAD', 'PROJECT', 'VIDEO'] | None
domain: str | None
difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None
points: int | None
title: dict[str, str] | None
statement: dict[str, str] | None
locales: list[str] | None
skill: str | None
resources: list[ScreenQuestionResourceDetails] | None
comment: str | None
evaluation: ScreenEvaluationDetails | None
duration_seconds: int | None
creation_time: str | None
modification_time: str | None
from_coderpad_question_bank: bool | None
team_id: str | None
automatically_selectable: bool | None
mcq_details: ScreenMCQDetails | None
code_details: ScreenCodeDetails | None
game_details: ScreenGameDetails | None
text_details: ScreenTextDetails | None
file_upload_details: ScreenFileUploadDetails | None
video_details: ScreenVideoDetails | None
project_details: ScreenProjectDetails | None
class coderpad.screen_question_types.ScreenQuestionsPage(*, questions: list[ScreenQuestionSummary], pagination: ScreenPagination | None = None)

An offset page of lightweight question summaries.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

questions: list[ScreenQuestionSummary]
pagination: ScreenPagination | None
class coderpad.screen_question_types.ScreenCreatedQuestion(*, question: ScreenQuestionDetails, location: str | None = None)

Created question details and the response Location header.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

question: ScreenQuestionDetails
location: str | None
class coderpad.screen_question_types.ScreenQuestionFilters(*, type: str | None = None, duration_seconds_min: int | None = None, duration_seconds_max: int | None = None, difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None = None, domain: str | None = None, skill: str | None = None, programming_language: str | None = None, from_coderpad_question_bank: bool | None = None, product: Literal['SCREEN', 'QUALIFY'] | None = None, sort: Literal['id', 'title', 'type', 'duration_seconds', 'difficulty', 'domain', 'skill', 'programming_language', 'modification_time', 'from_coderpad_question_bank', 'product'] | None = None, order: Literal['asc', 'desc'] | None = None)

Optional filters and ordering for every question library page.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

type: str | None
duration_seconds_min: int | None
duration_seconds_max: int | None
difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None
domain: str | None
skill: str | None
programming_language: str | None
from_coderpad_question_bank: bool | None
product: Literal['SCREEN', 'QUALIFY'] | None
sort: Literal['id', 'title', 'type', 'duration_seconds', 'difficulty', 'domain', 'skill', 'programming_language', 'modification_time', 'from_coderpad_question_bank', 'product'] | None
order: Literal['asc', 'desc'] | None

Typed Screen question save payloads.

class coderpad.screen_question_inputs.ScreenRubricCriterionInput(*, label: dict[str, str] | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None = None, description: str | None = None)

Typed rubric criterion input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
skill: str | None
points: int | None
weight: int | None
review_mode: Literal['HUMAN_ONLY', 'AI_SUGGESTIONS', 'AI_GRADING'] | None
description: str | None
class coderpad.screen_question_inputs.ScreenRubricInput(*, criteria: list[ScreenRubricCriterionInput] | None = None)

Typed rubric input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

criteria: list[ScreenRubricCriterionInput] | None
class coderpad.screen_question_inputs.ScreenValidationCodeTestCaseInput(*, label: dict[str, str] | None = None, test_identifier: str | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, difficulty: int | None = None, contributes_to_score: bool | None = None, visible_to_candidate: bool | None = None)

Typed validation code test case input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
test_identifier: str | None
skill: str | None
points: int | None
weight: int | None
difficulty: int | None
contributes_to_score: bool | None
visible_to_candidate: bool | None
class coderpad.screen_question_inputs.ScreenValidationCodeInput(*, test_cases: list[ScreenValidationCodeTestCaseInput] | None = None)

Typed validation code input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenValidationCodeTestCaseInput] | None
class coderpad.screen_question_inputs.ScreenInputOutputTestCaseInput(*, label: dict[str, str] | None = None, input: str | None = None, output: str | None = None, skill: str | None = None, points: int | None = None, weight: int | None = None, difficulty: int | None = None, contributes_to_score: bool | None = None, visible_to_candidate: bool | None = None, timeout_ms_by_programming_language_id: dict[str, int] | None = None)

Typed input output test case input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
input: str | None
output: str | None
skill: str | None
points: int | None
weight: int | None
difficulty: int | None
contributes_to_score: bool | None
visible_to_candidate: bool | None
timeout_ms_by_programming_language_id: dict[str, int] | None
class coderpad.screen_question_inputs.ScreenInputOutputEvaluationInput(*, test_cases: list[ScreenInputOutputTestCaseInput] | None = None)

Typed input output input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

test_cases: list[ScreenInputOutputTestCaseInput] | None
class coderpad.screen_question_inputs.ScreenQueryComparisonRulesInput(*, row_order_matters: bool | None = None, column_order_matters: bool | None = None, compare_all_tables: bool | None = None)

Typed query comparison rules input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

row_order_matters: bool | None
column_order_matters: bool | None
compare_all_tables: bool | None
class coderpad.screen_question_inputs.ScreenSQLQueryResultComparisonInput(*, reference_query: str | None = None, comparison: ScreenQueryComparisonRulesInput | None = None)

Typed SQL query result comparison input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

reference_query: str | None
comparison: ScreenQueryComparisonRulesInput | None
class coderpad.screen_question_inputs.ScreenEvaluationAcceptedAnswerInput(*, value: str | None = None, match_type: Literal['EXACT', 'REGEX'] | None = None)

Typed evaluation accepted answer input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

value: str | None
match_type: Literal['EXACT', 'REGEX'] | None
class coderpad.screen_question_inputs.ScreenTextAnswerMatchingInput(*, accepted_answers: list[ScreenEvaluationAcceptedAnswerInput] | None = None)

Typed text answer matching input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

accepted_answers: list[ScreenEvaluationAcceptedAnswerInput] | None
class coderpad.screen_question_inputs.ScreenChoiceSelectionInput(*, correct_choice_indexes: list[int] | None = None)

Typed choice selection input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

correct_choice_indexes: list[int] | None
class coderpad.screen_question_inputs.ScreenEvaluationInput(*, rubric: ScreenRubricInput | None = None, validation_code: ScreenValidationCodeInput | None = None, input_output: ScreenInputOutputEvaluationInput | None = None, sql_query_result_comparison: ScreenSQLQueryResultComparisonInput | None = None, text_answer_matching: ScreenTextAnswerMatchingInput | None = None, choice_selection: ScreenChoiceSelectionInput | None = None)

Typed evaluation input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

rubric: ScreenRubricInput | None
validation_code: ScreenValidationCodeInput | None
input_output: ScreenInputOutputEvaluationInput | None
sql_query_result_comparison: ScreenSQLQueryResultComparisonInput | None
text_answer_matching: ScreenTextAnswerMatchingInput | None
choice_selection: ScreenChoiceSelectionInput | None
class coderpad.screen_question_inputs.ScreenEnvironmentInput(*, version: str | None = None, environment_id: str | None = None)

Typed environment input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
environment_id: str | None
class coderpad.screen_question_inputs.ScreenDatabaseEngineInput(*, version: str | None = None, engine_id: str | None = None)

Typed database engine input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
engine_id: str | None
class coderpad.screen_question_inputs.ScreenFunctionSignatureInput(*, name: str | None = None, parameters: list[dict[str, JsonValue]] | None = None, return_type: dict[str, JsonValue] | None = None)

Typed function signature input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str | None
parameters: list[dict[str, JsonValue]] | None
return_type: dict[str, JsonValue] | None
class coderpad.screen_question_inputs.ScreenPossibleSolutionInput(*, code: str | None = None, programming_language_id: str | None = None)

Typed possible solution input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

code: str | None
programming_language_id: str | None
class coderpad.screen_question_inputs.ScreenCodeInput(*, environment: ScreenEnvironmentInput | None = None, mode: Literal['SINGLE_LANGUAGE', 'MULTI_LANGUAGE'] | None = None, programming_language_id: str | None = None, candidate_test_code: str | None = None, validator_code: str | None = None, timeout_ms: int | None = None, database_engine: ScreenDatabaseEngineInput | None = None, database_setup_script: str | None = None, starter_code: str | None = None, function_signature: ScreenFunctionSignatureInput | None = None, possible_solution: ScreenPossibleSolutionInput | None = None, show_function_signature_in_statement: bool | None = None)

Typed code input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

environment: ScreenEnvironmentInput | None
mode: Literal['SINGLE_LANGUAGE', 'MULTI_LANGUAGE'] | None
programming_language_id: str | None
candidate_test_code: str | None
validator_code: str | None
timeout_ms: int | None
database_engine: ScreenDatabaseEngineInput | None
database_setup_script: str | None
starter_code: str | None
function_signature: ScreenFunctionSignatureInput | None
possible_solution: ScreenPossibleSolutionInput | None
show_function_signature_in_statement: bool | None
class coderpad.screen_question_inputs.ScreenQuestionChoiceInput(*, label: dict[str, str] | None = None)

Typed question choice input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

label: dict[str, str] | None
class coderpad.screen_question_inputs.ScreenMCQInput(*, choices: list[ScreenQuestionChoiceInput] | None = None, selection_mode: Literal['SINGLE', 'MULTIPLE'] | None = None, randomize_choices: bool | None = None)

Typed multiple choice input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

choices: list[ScreenQuestionChoiceInput] | None
selection_mode: Literal['SINGLE', 'MULTIPLE'] | None
randomize_choices: bool | None
class coderpad.screen_question_inputs.ScreenTextInput(*, evaluation_mode: Literal['MANUAL', 'AUTOMATIC'] | None = None)

Typed text input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

evaluation_mode: Literal['MANUAL', 'AUTOMATIC'] | None
class coderpad.screen_question_inputs.ScreenVideoInput(*, recording_media: Literal['VIDEO', 'AUDIO'] | None = None)

Typed video input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

recording_media: Literal['VIDEO', 'AUDIO'] | None
class coderpad.screen_question_inputs.ScreenProjectResourceInput(*, version: str | None = None, resource_id: str | None = None)

Typed project resource input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

version: str | None
resource_id: str | None
class coderpad.screen_question_inputs.ScreenProjectInput(*, environment: ScreenEnvironmentInput | None = None, resources: list[ScreenProjectResourceInput] | None = None, ai_assist_additional_instructions: str | None = None, ai_assist_allowed: bool | None = None, temporary_file_id: str | None = None)

Typed project input accepted when saving a question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

environment: ScreenEnvironmentInput | None
resources: list[ScreenProjectResourceInput] | None
ai_assist_additional_instructions: str | None
ai_assist_allowed: bool | None
temporary_file_id: str | None
class coderpad.screen_question_inputs.ScreenQuestionSave(*, type: Literal['MCQ', 'CODE', 'TEXT', 'FILE_UPLOAD', 'VIDEO', 'PROJECT'], domain: str | None = None, duration_seconds: int | None = None, difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None = None, points: int | None = None, title: dict[str, str] | None = None, statement: dict[str, str] | None = None, locales: list[str] | None = None, skill: str | None = None, team_id: str | None = None, automatically_selectable: bool | None = None, comment: str | None = None, evaluation: ScreenEvaluationInput | None = None, code_details: ScreenCodeInput | None = None, mcq_details: ScreenMCQInput | None = None, text_details: ScreenTextInput | None = None, video_details: ScreenVideoInput | None = None, project_details: ScreenProjectInput | None = None)

Writable fields for creating or updating a Screen question.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

type: Literal['MCQ', 'CODE', 'TEXT', 'FILE_UPLOAD', 'VIDEO', 'PROJECT']
domain: str | None
duration_seconds: int | None
difficulty: Literal['EASY', 'MEDIUM', 'HARD'] | None
points: int | None
title: dict[str, str] | None
statement: dict[str, str] | None
locales: list[str] | None
skill: str | None
team_id: str | None
automatically_selectable: bool | None
comment: str | None
evaluation: ScreenEvaluationInput | None
code_details: ScreenCodeInput | None
mcq_details: ScreenMCQInput | None
text_details: ScreenTextInput | None
video_details: ScreenVideoInput | None
project_details: ScreenProjectInput | None

Read models for complete Screen assessment campaign definitions.

class coderpad.screen_campaign_details.ScreenRandomQuestionConfigurationDetails(*, domain: str | None = None, skills: list[str] | None = None, question_type: str | None = None, target_duration_minutes: int | None = None, target_experience_level: str | None = None, included_question_ids: list[str] | None = None, excluded_question_ids: list[str] | None = None)

Criteria of a randomly selected question set.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignQuestionDetails(*, type: str, question_id: str | None = None, configuration: ScreenRandomQuestionConfigurationDetails | None = None)

An ordered explicit question or random set in a campaign.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignTimerDetails(*, mode: str | None = None, duration_minutes: int | None = None)

The campaign’s timer mode and optional duration.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignAccessPeriodDetails(*, min_start_time: str | None = None, max_end_time: str | None = None)

Access-window instants, preserved as ISO 8601 strings.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignFollowUpQuestionsDetails(*, enabled: bool | None = None, answer_format: str | None = None)

Follow-up question availability and answer format.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignWebcamProctoringDetails(*, enabled: bool | None = None, ai_analysis_enabled: bool | None = None)

Webcam recording and analysis settings.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignSettingsDetails(*, languages: list[str] | None = None, timer: ScreenCampaignTimerDetails | None = None, invitation_expiration_days: int | None = None, access_period: ScreenCampaignAccessPeriodDetails | None = None, send_candidate_simplified_report: bool | None = None, copy_paste_blocked: bool | None = None, follow_up_questions: ScreenCampaignFollowUpQuestionsDetails | None = None, webcam_proctoring: ScreenCampaignWebcamProctoringDetails | None = None, full_screen_required: bool | None = None, ai_assist_enabled: bool | None = None, enabled_coding_agents: str | None = None)

Returned campaign settings, retaining omission, false, and empty values.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

class coderpad.screen_campaign_details.ScreenCampaignDetails(*, id: int, name: str, questions: list[ScreenCampaignQuestionDetails], settings: ScreenCampaignSettingsDetails | None = None, team_id: str | None = None)

A complete reusable assessment definition, separate from test sessions.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.