Skip to content

Models

TokenLoginResponse pydantic-model

Response model for token-based authentication.

Fields:

success pydantic-field

Whether the authentication was successful.

token pydantic-field

The authentication token returned by the platform.

Attachment pydantic-model

Represents a downloadable attachment file for a challenge.

Fields:

name = None pydantic-field

The display name of the attachment file, if known.

local_path = None pydantic-field

Local file path after download, if available.

size_bytes = None pydantic-field

Size of the file in bytes, if known.

download_info = None pydantic-field

How to obtain this attachment.

is_pending property

True if no metadata is known yet.

Challenge pydantic-model

Represents a challenge.

Config:

  • validate_assignment: True

Fields:

id pydantic-field

The unique identifier of the challenge, typically a number or short string.

name pydantic-field

The display name of the challenge.

categories pydantic-field

A list of raw categories the challenge belongs to as provided by the platform.

normalized_categories pydantic-field

A list of normalized categories (e.g., 'rev' for 'Reverse Engineering').

subcategory = None pydantic-field

A more specific category under the main category, if the platform defines one.

value = None pydantic-field

The point value awarded for solving the challenge. Can be None if points are dynamic or not applicable.

description = None pydantic-field

The main description, prompt, or story for the challenge. May contain HTML or Markdown.

attachments pydantic-field

A collection of downloadable files associated with the challenge.

services pydantic-field

A list of network services (e.g., netcat listeners, web servers, databases) associated with the challenge.

tags pydantic-field

A list of tags or keywords categorizing the challenge.

solved = False pydantic-field

Indicates if the challenge has been solved by the current user/team. Can be None if status is unknown.

authors pydantic-field

The authors or creators of the challenge.

difficulty = None pydantic-field

The perceived difficulty of the challenge (e.g., 'Easy', 'Medium', 'Hard'), if specified.

flag_format = None pydantic-field

The flag format of the challenge.

category property

The primary category of the challenge. Returns the first category from the categories list, or None if no categories are present.

normalized_category property

The primary normalized category of the challenge. Returns the first category from the normalized_categories list, or None.

has_attachments property

Returns True if the challenge has one or more attachments, False otherwise.

has_services property

Returns True if the challenge has one or more network services, False otherwise.

service property

Returns the first service.

author property

Returns the first author.

FilterOptions pydantic-model

Filtering parameters used to retrieve specific challenges.

Fields:

solved = None pydantic-field

If True, only solved; if False, only unsolved; if None, no filter.

min_points = None pydantic-field

Minimum point value a challenge must have.

max_points = None pydantic-field

Maximum point value a challenge can have.

category = None pydantic-field

Only include challenges from this specific category.

categories = None pydantic-field

Only include challenges from any of these categories.

tags = None pydantic-field

Only include challenges that have all of these tags.

has_attachments = None pydantic-field

Filter by whether challenges have attachments.

has_services = None pydantic-field

Filter by whether challenges have services.

name_contains = None pydantic-field

Filter by whether challenge name contains this substring.

CTFConfig pydantic-model

Represents the configuration settings of a CTF platform.

Fields:

ctf_name pydantic-field

The name of the CTF event or platform.

user_mode pydantic-field

The participation mode (e.g., 'teams', 'users').

theme = None pydantic-field

The UI theme name, if customizable.

version = None pydantic-field

The platform version identifier.

ErrorResponse pydantic-model

Represents an error response from the CTF platform.

Fields:

success pydantic-field

Always False for error responses.

message pydantic-field

The error message describing what went wrong.

ScoreboardEntry pydantic-model

Represents a single entry (team/user) on the CTF scoreboard.

Fields:

id = None pydantic-field

The ID of the team or user.

name pydantic-field

The name of the team or user.

score pydantic-field

The total points earned by the team/user.

rank pydantic-field

The current position on the scoreboard.

total_solves = None pydantic-field

The total number of challenges solved.

last_solve_time = None pydantic-field

Timestamp of the team's/user's most recent solve.

country_code = None pydantic-field

Two-letter ISO 3166-1 alpha-2 country code (e.g., 'US', 'KR').

SubmissionResult pydantic-model

Represents the result of a flag submission attempt.

Fields:

correct pydantic-field

Whether the submitted flag was correct.

message pydantic-field

The response message from the platform (e.g., 'Correct!' or 'Wrong flag').

Team pydantic-model

Represents a team participating in the CTF.

Fields:

id pydantic-field

The unique identifier of the team.

name pydantic-field

The team's display name.

score pydantic-field

The team's total score.

rank pydantic-field

The team's current position on the scoreboard.

User pydantic-model

Represents a user participating in the CTF.

Fields:

id pydantic-field

The unique identifier of the user.

name pydantic-field

The username or display name of the user.

team_id = None pydantic-field

The ID of the team the user belongs to, if any.

score = None pydantic-field

The user's individual score, if applicable.

rank = None pydantic-field

The user's individual rank, if applicable.