pyhtb 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pyhtb-0.1.0/PKG-INFO +139 -0
- pyhtb-0.1.0/README.md +126 -0
- pyhtb-0.1.0/pyhtb/__init__.py +139 -0
- pyhtb-0.1.0/pyhtb/experience/__init__.py +0 -0
- pyhtb-0.1.0/pyhtb/experience/v1/__init__.py +8 -0
- pyhtb-0.1.0/pyhtb/experience/v1/api/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/experience/v1/api/account/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/experience/v1/api/account/get_account_account_id.py +168 -0
- pyhtb-0.1.0/pyhtb/experience/v1/client.py +282 -0
- pyhtb-0.1.0/pyhtb/experience/v1/errors.py +16 -0
- pyhtb-0.1.0/pyhtb/experience/v1/models/__init__.py +11 -0
- pyhtb-0.1.0/pyhtb/experience/v1/models/account_response.py +148 -0
- pyhtb-0.1.0/pyhtb/experience/v1/models/generic_error_response.py +70 -0
- pyhtb-0.1.0/pyhtb/experience/v1/models/streak_data.py +126 -0
- pyhtb-0.1.0/pyhtb/experience/v1/types.py +54 -0
- pyhtb-0.1.0/pyhtb/v4/__init__.py +8 -0
- pyhtb-0.1.0/pyhtb/v4/api/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/badges/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/badges/get_badges.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_activity.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_categories_list.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_changelog.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_download.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_info.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_recommended.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_suggested.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_writeup.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenge_writeup_official.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/get_challenges.py +348 -0
- pyhtb-0.1.0/pyhtb/v4/api/challenges/post_challenge_own.py +182 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/get_access_ovpnfile_vpn_id_tcp.py +172 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/get_access_ovpnfile_vpn_id_udp.py +172 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/get_connection_status.py +150 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/get_connections_servers.py +175 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/get_connections_servers_prolab.py +170 -0
- pyhtb-0.1.0/pyhtb/v4/api/connection/post_connections_servers_switch.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/containers/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/containers/post_container_start.py +183 -0
- pyhtb-0.1.0/pyhtb/v4/api/containers/post_container_stop.py +177 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/get_fortress.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/get_fortress_flags.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/get_fortresses.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/post_fortress_flag.py +198 -0
- pyhtb-0.1.0/pyhtb/v4/api/fortresses/post_fortress_reset.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/home/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/home/get_home_banner.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_active.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_activity.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_adventure.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_changelog.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_graph_matrix.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_profile.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_recommended.py +135 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_tags.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_tasks.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_walkthrough_random.py +143 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_walkthroughs.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_walkthroughs_language_list.py +145 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/get_machine_writeup.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/machines/post_todo_update.py +183 -0
- pyhtb-0.1.0/pyhtb/v4/api/platform/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/platform/get_navigation_main.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/platform/get_notices.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/platform/get_search_fetch.py +196 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_changelogs.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_faq.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_flags.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_info.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_machines.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_overview.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolab_progress.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/get_prolabs.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/prolabs/post_prolab_flag.py +198 -0
- pyhtb-0.1.0/pyhtb/v4/api/pwn_box/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/pwn_box/get_pwnbox_status.py +160 -0
- pyhtb-0.1.0/pyhtb/v4/api/pwn_box/get_pwnbox_usage.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/pwn_box/post_pwnbox_start.py +184 -0
- pyhtb-0.1.0/pyhtb/v4/api/pwn_box/post_pwnbox_terminate.py +139 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings_countries.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings_country_us_members.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings_teams.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings_universities.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/ranking/get_rankings_users.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/review/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/review/get_review_paginated.py +183 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_leaderboard.py +192 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_leaderboard_top.py +210 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_list.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_machine_active.py +135 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_machines.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_rewards.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_user_rank.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/season/get_season_user_user_id_rank.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_downloadlink.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_info.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_play.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_progress.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_tasks.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_writeup.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlock_writeup_official.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlocks.py +328 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/get_sherlocks_categories_list.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/sherlocks/post_sherlock_tasks_flag.py +217 -0
- pyhtb-0.1.0/pyhtb/v4/api/starting_point/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/starting_point/get_sp_tiers_progress.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/tags/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/tags/get_tags_list.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/delete_team_invite_reject.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/get_team_activity.py +198 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/get_team_info.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/get_team_invitations.py +172 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/get_team_members.py +175 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/post_team_invite_accept.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/team/post_team_kick_user.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/tracks/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/tracks/get_tracks.py +148 -0
- pyhtb-0.1.0/pyhtb/v4/api/tracks/get_tracks_id.py +189 -0
- pyhtb-0.1.0/pyhtb/v4/api/tracks/post_tracks_enroll.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/tracks/post_tracks_like.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/universities/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/universities/get_university_members.py +175 -0
- pyhtb-0.1.0/pyhtb/v4/api/universities/get_university_profile.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_achievement.py +200 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_anonymized_id.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_apptoken_list.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_connection_status.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_followers.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_info.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_badges.py +189 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_basic.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_progress_challenges.py +170 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_progress_fortress.py +170 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_progress_prolab.py +168 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_progress_sherlocks.py +170 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_profile_summary.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_settings.py +141 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/get_user_tracks.py +148 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_apptoken_create.py +175 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_apptoken_delete.py +169 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_disrespect.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_follow.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_respect.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/user/post_user_unfollow.py +162 -0
- pyhtb-0.1.0/pyhtb/v4/api/vm/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v4/api/vm/post_vm_extend.py +176 -0
- pyhtb-0.1.0/pyhtb/v4/api/vm/post_vm_reset.py +117 -0
- pyhtb-0.1.0/pyhtb/v4/api/vm/post_vm_spawn.py +181 -0
- pyhtb-0.1.0/pyhtb/v4/api/vm/post_vm_terminate.py +181 -0
- pyhtb-0.1.0/pyhtb/v4/client.py +282 -0
- pyhtb-0.1.0/pyhtb/v4/errors.py +16 -0
- pyhtb-0.1.0/pyhtb/v4/models/__init__.py +613 -0
- pyhtb-0.1.0/pyhtb/v4/models/academy_difficulty.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/academy_module.py +138 -0
- pyhtb-0.1.0/pyhtb/v4/models/academy_tiers.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/active_machine_info.py +248 -0
- pyhtb-0.1.0/pyhtb/v4/models/active_machine_response.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/assigned_server.py +107 -0
- pyhtb-0.1.0/pyhtb/v4/models/bad_request_error.py +62 -0
- pyhtb-0.1.0/pyhtb/v4/models/badge.py +136 -0
- pyhtb-0.1.0/pyhtb/v4/models/badge_category.py +110 -0
- pyhtb-0.1.0/pyhtb/v4/models/badges_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/base_task.py +202 -0
- pyhtb-0.1.0/pyhtb/v4/models/blood_info.py +109 -0
- pyhtb-0.1.0/pyhtb/v4/models/categories_item.py +92 -0
- pyhtb-0.1.0/pyhtb/v4/models/categories_list_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge.py +816 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_activity.py +135 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_activity_info.py +87 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_activity_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_categories.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_categories_items.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_change_log_id_response.py +121 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_difficulties.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_id_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_list.py +382 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_list_response.py +120 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_recommended_response.py +149 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_retires_type_0.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_suggested_data.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_suggested_response.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/challenge_writeups.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/company.py +98 -0
- pyhtb-0.1.0/pyhtb/v4/models/connection.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/connection_data_machine_type_0.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/connection_server.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/connection_status_item.py +119 -0
- pyhtb-0.1.0/pyhtb/v4/models/connections_server_data.py +120 -0
- pyhtb-0.1.0/pyhtb/v4/models/connections_server_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/connections_servers_prolab_data.py +111 -0
- pyhtb-0.1.0/pyhtb/v4/models/connections_servers_prolab_response.py +85 -0
- pyhtb-0.1.0/pyhtb/v4/models/container_start_response.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/designated_level.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/difficulty_chart_type_1.py +142 -0
- pyhtb-0.1.0/pyhtb/v4/models/faq_item.py +82 -0
- pyhtb-0.1.0/pyhtb/v4/models/flag.py +89 -0
- pyhtb-0.1.0/pyhtb/v4/models/flag_rating_task.py +213 -0
- pyhtb-0.1.0/pyhtb/v4/models/flag_rating_task_extension.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/flags_to_next_rank_type_0.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/fortress.py +127 -0
- pyhtb-0.1.0/pyhtb/v4/models/fortress_data.py +244 -0
- pyhtb-0.1.0/pyhtb/v4/models/fortress_id_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/fortresses_response.py +89 -0
- pyhtb-0.1.0/pyhtb/v4/models/game_reset_response.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/generic_400_message.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_difficulty_item.py +12 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_sort_by.py +13 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_sort_type.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_state_item.py +10 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_status.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_challenges_todo.py +8 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_connections_servers_product.py +11 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_prolab_changelogs_response_200.py +94 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_prolab_changelogs_response_200_data_item.py +46 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_review_paginated_product.py +10 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_search_fetch_tags_item.py +11 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_season_leaderboard_leaderboard.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_season_leaderboard_top_leaderboard.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_season_leaderboard_top_period.py +12 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_sherlocks_difficulty_item.py +12 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_sherlocks_sort_by.py +11 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_sherlocks_sort_type.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_sherlocks_state_item.py +10 -0
- pyhtb-0.1.0/pyhtb/v4/models/get_sherlocks_status.py +9 -0
- pyhtb-0.1.0/pyhtb/v4/models/growths.py +123 -0
- pyhtb-0.1.0/pyhtb/v4/models/helpful_reviews.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/home_banner_item.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/home_banner_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/item.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/keyed_pro_lab_mile_stone.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/lab_master.py +101 -0
- pyhtb-0.1.0/pyhtb/v4/models/label.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/latest_season.py +89 -0
- pyhtb-0.1.0/pyhtb/v4/models/links.py +111 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine.py +90 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_acitivty_item.py +147 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_activity_id_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_activity_info.py +94 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_card.py +240 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_change_log_item.py +133 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_changelog_id_response.py +86 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_graph_matrix_id_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_graph_matrix_info.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_profile_info.py +790 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_profile_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_tag_id_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_tag_items.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_tag_list_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_tasks_response.py +118 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_id_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_message.py +153 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_message_official.py +138 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_message_writeups_item.py +204 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_random_response.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthrough_video.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthroughs_language_list_item.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/machine_walkthroughs_language_list_response.py +94 -0
- pyhtb-0.1.0/pyhtb/v4/models/machines_adventure_item.py +181 -0
- pyhtb-0.1.0/pyhtb/v4/models/machines_adventure_response.py +85 -0
- pyhtb-0.1.0/pyhtb/v4/models/maker.py +143 -0
- pyhtb-0.1.0/pyhtb/v4/models/matrix_info.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/message.py +62 -0
- pyhtb-0.1.0/pyhtb/v4/models/meta.py +147 -0
- pyhtb-0.1.0/pyhtb/v4/models/navigation_main_data.py +103 -0
- pyhtb-0.1.0/pyhtb/v4/models/navigation_main_ranking.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/navigation_main_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/navigation_nmain_season_ranking.py +119 -0
- pyhtb-0.1.0/pyhtb/v4/models/new_rank.py +81 -0
- pyhtb-0.1.0/pyhtb/v4/models/next_rank.py +113 -0
- pyhtb-0.1.0/pyhtb/v4/models/notices_item.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/notices_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/object_array_item.py +46 -0
- pyhtb-0.1.0/pyhtb/v4/models/official_writeup.py +110 -0
- pyhtb-0.1.0/pyhtb/v4/models/options.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/options_additional_property.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/own_machine_error_response.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/own_request.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/own_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/pagination_link.py +111 -0
- pyhtb-0.1.0/pyhtb/v4/models/pesentation_detail.py +277 -0
- pyhtb-0.1.0/pyhtb/v4/models/play_info.py +173 -0
- pyhtb-0.1.0/pyhtb/v4/models/play_info_alt.py +156 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_container_start_data_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_container_start_json_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_container_stop_data_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_container_stop_json_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_fortress_flag_data_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_fortress_flag_json_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_prolab_flag_data_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_prolab_flag_json_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_sherlock_tasks_flag_data_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_sherlock_tasks_flag_json_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_todo_update_product.py +10 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_user_apptoken_create_body.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/post_user_apptoken_delete_body.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/product_flags_response.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_badges_id_repsonse.py +86 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_badges_item.py +110 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_badges_item_pivot.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_id_repsonse.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_challenge_owns.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_challenges_id_repsonse.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_fortress_id_repsonse.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_fortress_profile.py +95 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_fortress_profile_item.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_pro_lab_profile.py +87 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_pro_lab_response.py +77 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_profile.py +166 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_progress_prolab_item.py +154 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_user_stats.py +301 -0
- pyhtb-0.1.0/pyhtb/v4/models/profile_user_team_info.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab.py +289 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_data.py +382 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_id_faq_response.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_id_info_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_id_machine_response.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_id_overview_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_overview_data.py +279 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_progress_data.py +124 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolab_progress_response.py +83 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolabs_data.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/prolabs_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_request.py +64 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_request_location.py +14 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_start_data.py +247 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_start_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_status_not_running_response.py +62 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_status_r_unning_data.py +209 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_status_running_response.py +68 -0
- pyhtb-0.1.0/pyhtb/v4/models/pwnbox_usage_response.py +116 -0
- pyhtb-0.1.0/pyhtb/v4/models/ranking_country_member_data.py +96 -0
- pyhtb-0.1.0/pyhtb/v4/models/ranking_data_team_properties.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/ranking_data_user_properties.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/ranking_graph_stats.py +111 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_countries.py +94 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_countries_item.py +160 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_country_members_response.py +83 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_data.py +92 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_item.py +210 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_response.py +83 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_team_item.py +200 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_team_response.py +103 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_universities_item.py +189 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_universities_response.py +94 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_user_data.py +221 -0
- pyhtb-0.1.0/pyhtb/v4/models/rankings_users_response.py +95 -0
- pyhtb-0.1.0/pyhtb/v4/models/recommended_card.py +152 -0
- pyhtb-0.1.0/pyhtb/v4/models/review_message_item.py +288 -0
- pyhtb-0.1.0/pyhtb/v4/models/review_user.py +133 -0
- pyhtb-0.1.0/pyhtb/v4/models/reviews.py +138 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_challenge_item.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_fetch_machines_item.py +108 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_fetch_response.py +198 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_sherlock_item.py +119 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_team_item.py +99 -0
- pyhtb-0.1.0/pyhtb/v4/models/search_user_item.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_list_data_item.py +257 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_list_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_machines.py +86 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_machines_data_item.py +240 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_platers_leaderboard_top_data_item.py +223 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_players_leaderboard_data_item.py +229 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_players_leaderboard_response.py +129 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_players_leaderboard_top_response.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_reward_group_item.py +200 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_reward_item.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_reward_types.py +119 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_rewards_data_item.py +74 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_rewards_resposne.py +85 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_user_rank.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_user_rank_data.py +240 -0
- pyhtb-0.1.0/pyhtb/v4/models/season_user_rank_data_total_season_flags.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/server.py +98 -0
- pyhtb-0.1.0/pyhtb/v4/models/server_group.py +93 -0
- pyhtb-0.1.0/pyhtb/v4/models/server_group_servers.py +59 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_blood.py +99 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_detail.py +139 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_download_link.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_info.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_item.py +332 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_item_list.py +120 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_named_item.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_named_item_data.py +312 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_play.py +185 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_play_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_progress.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_progress_data.py +97 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_retires_type_0.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_task.py +212 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_tasks_list.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/sherlock_writeup.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/social_links.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/sp_tiers_progress_item.py +101 -0
- pyhtb-0.1.0/pyhtb/v4/models/sp_tiers_progress_response.py +86 -0
- pyhtb-0.1.0/pyhtb/v4/models/spawn_request.py +62 -0
- pyhtb-0.1.0/pyhtb/v4/models/tag.py +80 -0
- pyhtb-0.1.0/pyhtb/v4/models/tag_category.py +102 -0
- pyhtb-0.1.0/pyhtb/v4/models/task_flag_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/task_type.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_activity_item.py +170 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_activity_user.py +99 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_information_profile_data.py +293 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_information_profile_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_invitations_id_response.py +123 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_invitations_id_response_headers.py +46 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_member.py +233 -0
- pyhtb-0.1.0/pyhtb/v4/models/team_member_team.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/track_error_response.py +71 -0
- pyhtb-0.1.0/pyhtb/v4/models/track_error_response_status.py +8 -0
- pyhtb-0.1.0/pyhtb/v4/models/track_success_items_item.py +203 -0
- pyhtb-0.1.0/pyhtb/v4/models/tracks_creator.py +85 -0
- pyhtb-0.1.0/pyhtb/v4/models/tracks_enroll_response.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/tracks_id_response.py +285 -0
- pyhtb-0.1.0/pyhtb/v4/models/tracks_items.py +123 -0
- pyhtb-0.1.0/pyhtb/v4/models/tracks_like_response.py +61 -0
- pyhtb-0.1.0/pyhtb/v4/models/university_members_response.py +233 -0
- pyhtb-0.1.0/pyhtb/v4/models/upcoming_season.py +133 -0
- pyhtb-0.1.0/pyhtb/v4/models/update_response.py +84 -0
- pyhtb-0.1.0/pyhtb/v4/models/url_response.py +74 -0
- pyhtb-0.1.0/pyhtb/v4/models/user.py +180 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_achievement_machine_type_user.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_achievement_tar_type_user_own.py +105 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_achievement_target_type_user_id_target_id_response.py +135 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_anonymized_id_response.py +80 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_apptoken_create_response.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_apptoken_list_item.py +99 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_apptoken_list_response.py +85 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_availability.py +91 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_basic_info_with_respect.py +100 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_connection_status_response.py +109 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_connection_status_response_connection_type_0.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_entry.py +110 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_info.py +383 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_info_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile.py +629 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_basic_id_response.py +75 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_progress_sherlock_profile.py +156 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_progress_sherlock_profile_challenge_owns.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_progress_sherlocks_response.py +78 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_team.py +106 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_profile_university_team_type_0.py +88 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_rank.py +83 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_ranking.py +256 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_ranking_type_1.py +8 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_settings_response.py +100 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_task.py +79 -0
- pyhtb-0.1.0/pyhtb/v4/models/user_track_item.py +70 -0
- pyhtb-0.1.0/pyhtb/v4/models/writeup_data.py +74 -0
- pyhtb-0.1.0/pyhtb/v4/types.py +54 -0
- pyhtb-0.1.0/pyhtb/v5/__init__.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/api/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/connections/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/connections/get_connections.py +141 -0
- pyhtb-0.1.0/pyhtb/v5/api/machines/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/machines/get_machines.py +392 -0
- pyhtb-0.1.0/pyhtb/v5/api/machines/post_machine_own.py +182 -0
- pyhtb-0.1.0/pyhtb/v5/api/university/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/university/get_universities.py +188 -0
- pyhtb-0.1.0/pyhtb/v5/api/university/get_university_stats.py +168 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_dashboard_favorites.py +141 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_dashboard_in_progress.py +141 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_dashboard_recommended.py +141 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_profile_activity.py +204 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_profile_content.py +221 -0
- pyhtb-0.1.0/pyhtb/v5/api/user/get_user_profile_content_counts.py +170 -0
- pyhtb-0.1.0/pyhtb/v5/api/vm/__init__.py +1 -0
- pyhtb-0.1.0/pyhtb/v5/api/vm/get_virtual_machine_active.py +141 -0
- pyhtb-0.1.0/pyhtb/v5/client.py +282 -0
- pyhtb-0.1.0/pyhtb/v5/errors.py +16 -0
- pyhtb-0.1.0/pyhtb/v5/models/__init__.py +135 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_assigned_server_type_0.py +88 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_base.py +131 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_competitive_entry.py +158 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_competitive_entry_type.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_lab_entry.py +132 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_lab_entry_type.py +10 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_machine.py +79 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_pro_lab_entry.py +142 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_pro_lab_entry_type.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/connection_prolab.py +79 -0
- pyhtb-0.1.0/pyhtb/v5/models/connections_response.py +152 -0
- pyhtb-0.1.0/pyhtb/v5/models/feedback_for_chart.py +142 -0
- pyhtb-0.1.0/pyhtb/v5/models/generic_error_response.py +70 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_difficulty_item.py +11 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_free.py +9 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_os_item.py +12 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_show_completed.py +9 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_sort_by.py +13 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_sort_type.py +9 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_sp_tier.py +10 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_state_item.py +10 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_machines_todo.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/get_user_profile_content_type.py +10 -0
- pyhtb-0.1.0/pyhtb/v5/models/links.py +111 -0
- pyhtb-0.1.0/pyhtb/v5/models/machine_creator.py +119 -0
- pyhtb-0.1.0/pyhtb/v5/models/machine_label.py +70 -0
- pyhtb-0.1.0/pyhtb/v5/models/machine_play_info.py +186 -0
- pyhtb-0.1.0/pyhtb/v5/models/machine_retiring_type_0.py +97 -0
- pyhtb-0.1.0/pyhtb/v5/models/machines_item.py +445 -0
- pyhtb-0.1.0/pyhtb/v5/models/machines_response.py +100 -0
- pyhtb-0.1.0/pyhtb/v5/models/meta.py +169 -0
- pyhtb-0.1.0/pyhtb/v5/models/meta_alt.py +77 -0
- pyhtb-0.1.0/pyhtb/v5/models/new_rank.py +81 -0
- pyhtb-0.1.0/pyhtb/v5/models/own_error_response.py +70 -0
- pyhtb-0.1.0/pyhtb/v5/models/own_request.py +81 -0
- pyhtb-0.1.0/pyhtb/v5/models/own_response.py +191 -0
- pyhtb-0.1.0/pyhtb/v5/models/own_response_own_type.py +9 -0
- pyhtb-0.1.0/pyhtb/v5/models/pagination_link.py +91 -0
- pyhtb-0.1.0/pyhtb/v5/models/rank_update.py +83 -0
- pyhtb-0.1.0/pyhtb/v5/models/universities_item.py +125 -0
- pyhtb-0.1.0/pyhtb/v5/models/universities_response.py +100 -0
- pyhtb-0.1.0/pyhtb/v5/models/university_stats_response.py +118 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_challenge.py +206 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_collections.py +186 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_fortress.py +126 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_machine.py +224 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_prolab.py +192 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_sherlock.py +194 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_starting_point.py +142 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_dashboard_track.py +142 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_base.py +125 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_fortress.py +142 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_fortress_type.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_prolab.py +150 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_prolab_type.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_response.py +209 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_sherlock.py +126 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_activity_sherlock_type.py +8 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_content_counts_response.py +86 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_content_item_challenge.py +119 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_content_item_machine.py +135 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_content_item_sherlock.py +127 -0
- pyhtb-0.1.0/pyhtb/v5/models/user_profile_content_response.py +171 -0
- pyhtb-0.1.0/pyhtb/v5/models/virtual_machine_active_info.py +148 -0
- pyhtb-0.1.0/pyhtb/v5/models/virtual_machine_active_response.py +88 -0
- pyhtb-0.1.0/pyhtb/v5/types.py +54 -0
- pyhtb-0.1.0/pyhtb.egg-info/PKG-INFO +139 -0
- pyhtb-0.1.0/pyhtb.egg-info/SOURCES.txt +553 -0
- pyhtb-0.1.0/pyhtb.egg-info/dependency_links.txt +1 -0
- pyhtb-0.1.0/pyhtb.egg-info/requires.txt +2 -0
- pyhtb-0.1.0/pyhtb.egg-info/top_level.txt +1 -0
- pyhtb-0.1.0/pyproject.toml +26 -0
- pyhtb-0.1.0/setup.cfg +4 -0
pyhtb-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pyhtb
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Unofficial Hack The Box Python SDK
|
|
5
|
+
Author: Hack The Box Community
|
|
6
|
+
Classifier: Programming Language :: Python :: 3
|
|
7
|
+
Classifier: License :: OSI Approved :: The Unlicense (Unlicense)
|
|
8
|
+
Classifier: Operating System :: OS Independent
|
|
9
|
+
Requires-Python: >=3.8
|
|
10
|
+
Description-Content-Type: text/markdown
|
|
11
|
+
Requires-Dist: httpx>=0.28.1
|
|
12
|
+
Requires-Dist: attrs>=26.1.0
|
|
13
|
+
|
|
14
|
+
# Unofficial Hack The Box (HTB) Python SDK & API Client (`pyhtb`)
|
|
15
|
+
|
|
16
|
+
[](https://pypi.org/project/pyhtb/)
|
|
17
|
+
[](https://pypi.org/project/pyhtb/)
|
|
18
|
+
[](LICENSE)
|
|
19
|
+
[](https://github.com/astral-sh/ruff)
|
|
20
|
+
|
|
21
|
+
An unofficial, modern, and type-safe Python SDK and API client wrapper for the **Hack The Box (HTB)** platform. This library exposes fully type-hinted synchronous and asynchronous interfaces to interact programmatically with HTB APIs.
|
|
22
|
+
|
|
23
|
+
Whether you are automating machine status checking, managing teams, tracking starting point progression, or scripting challenge submissions, `pyhtb` provides a single unified interface.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Key Features
|
|
28
|
+
|
|
29
|
+
* **Complete API Coverage**: Seamlessly combines the HTB API `v4`, `v5`, and `experience/v1` specifications.
|
|
30
|
+
* **Cookie-Simple Developer Experience**: No deep package imports or manually passing connection objects. Endpoints are dynamically bound directly onto the version clients.
|
|
31
|
+
* **Modern Async & Sync Backend**: Powered by `httpx` for fast, lightweight HTTP execution with full async support out of the box.
|
|
32
|
+
* **Type Safety & IDE Autocomplete**: Generated with strict model definitions utilizing `attrs` and type hints for robust code completion.
|
|
33
|
+
* **Zero Overhead Boilerplate**: Authenticate once, and credentials automatically propagate across all supported API versions.
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
Install the package via `pip` from PyPI:
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
pip install pyhtb
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
For local development or running modifications, clone the repository and install in editable mode:
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
pip install -e .
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Quick Start
|
|
54
|
+
|
|
55
|
+
### 1. Basic Client Initialization
|
|
56
|
+
|
|
57
|
+
Initialize the `PyHTB` client wrapper. If you want to access protected endpoints, provide your Hack The Box API token (generated on the app.hackthebox.com settings page).
|
|
58
|
+
|
|
59
|
+
```python
|
|
60
|
+
from pyhtb import PyHTB
|
|
61
|
+
|
|
62
|
+
# Initialize authenticated SDK
|
|
63
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
64
|
+
|
|
65
|
+
# The unified client organizes endpoints by API version:
|
|
66
|
+
# - client.v4
|
|
67
|
+
# - client.v5
|
|
68
|
+
# - client.experience_v1
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
### 2. Accessing Endpoints (v5 Example)
|
|
72
|
+
|
|
73
|
+
All OpenAPI operations are dynamically bound as callable methods directly on the version clients.
|
|
74
|
+
|
|
75
|
+
#### Synchronous Call
|
|
76
|
+
```python
|
|
77
|
+
from pyhtb import PyHTB
|
|
78
|
+
|
|
79
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
80
|
+
|
|
81
|
+
# Call any endpoint directly. Client authentication parameters are injected automatically!
|
|
82
|
+
machines_response = client.v5.get_machines()
|
|
83
|
+
|
|
84
|
+
for machine in machines_response.data:
|
|
85
|
+
print(f"Machine: {machine.name} | OS: {machine.os} | Difficulty: {machine.difficulty}")
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
#### Asynchronous Call
|
|
89
|
+
All asynchronous methods share the same name as sync ones but are postfixed with `_async`.
|
|
90
|
+
|
|
91
|
+
```python
|
|
92
|
+
import asyncio
|
|
93
|
+
from pyhtb import PyHTB
|
|
94
|
+
|
|
95
|
+
async def main():
|
|
96
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
97
|
+
|
|
98
|
+
# Asynchronous endpoint invocation
|
|
99
|
+
machines_response = await client.v5.get_machines_async()
|
|
100
|
+
|
|
101
|
+
for machine in machines_response.data:
|
|
102
|
+
print(f"Async loaded: {machine.name}")
|
|
103
|
+
|
|
104
|
+
asyncio.run(main())
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
#### Accessing Detailed Responses (Metadata & Headers)
|
|
108
|
+
If you need to inspect HTTP status codes or response headers, append `_detailed` or `_async_detailed` to the method name:
|
|
109
|
+
|
|
110
|
+
```python
|
|
111
|
+
response = client.v5.get_machines_detailed()
|
|
112
|
+
print(f"HTTP Status: {response.status_code}")
|
|
113
|
+
print(f"Response Headers: {response.headers}")
|
|
114
|
+
print(f"Parsed Body Model: {response.parsed}")
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
119
|
+
## Supported APIs and Specs
|
|
120
|
+
|
|
121
|
+
The SDK is compiled from official and community-maintained reverse-engineered OpenAPI specifications:
|
|
122
|
+
|
|
123
|
+
| Version | Description | Target Submodule |
|
|
124
|
+
| :--- | :--- | :--- |
|
|
125
|
+
| **API v4** | Primary platform endpoints (User, Teams, Challenges, Tracks, etc.) | `client.v4` |
|
|
126
|
+
| **API v5** | Modern dashboard & user activity endpoints (Machines status, University, User dashboard) | `client.v5` |
|
|
127
|
+
| **Experience v1** | Experience, Levels, and Streak endpoints | `client.experience_v1` |
|
|
128
|
+
|
|
129
|
+
---
|
|
130
|
+
|
|
131
|
+
## Code Regeneration
|
|
132
|
+
|
|
133
|
+
The SDK contains a build pipeline to automatically compile clients from raw OpenAPI YAML specs. To regenerate the submodules after modifying any specification, execute:
|
|
134
|
+
|
|
135
|
+
```bash
|
|
136
|
+
./api/regen.sh
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
This requires `openapi-python-client` to be installed in your active Python environment.
|
pyhtb-0.1.0/README.md
ADDED
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
# Unofficial Hack The Box (HTB) Python SDK & API Client (`pyhtb`)
|
|
2
|
+
|
|
3
|
+
[](https://pypi.org/project/pyhtb/)
|
|
4
|
+
[](https://pypi.org/project/pyhtb/)
|
|
5
|
+
[](LICENSE)
|
|
6
|
+
[](https://github.com/astral-sh/ruff)
|
|
7
|
+
|
|
8
|
+
An unofficial, modern, and type-safe Python SDK and API client wrapper for the **Hack The Box (HTB)** platform. This library exposes fully type-hinted synchronous and asynchronous interfaces to interact programmatically with HTB APIs.
|
|
9
|
+
|
|
10
|
+
Whether you are automating machine status checking, managing teams, tracking starting point progression, or scripting challenge submissions, `pyhtb` provides a single unified interface.
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## Key Features
|
|
15
|
+
|
|
16
|
+
* **Complete API Coverage**: Seamlessly combines the HTB API `v4`, `v5`, and `experience/v1` specifications.
|
|
17
|
+
* **Cookie-Simple Developer Experience**: No deep package imports or manually passing connection objects. Endpoints are dynamically bound directly onto the version clients.
|
|
18
|
+
* **Modern Async & Sync Backend**: Powered by `httpx` for fast, lightweight HTTP execution with full async support out of the box.
|
|
19
|
+
* **Type Safety & IDE Autocomplete**: Generated with strict model definitions utilizing `attrs` and type hints for robust code completion.
|
|
20
|
+
* **Zero Overhead Boilerplate**: Authenticate once, and credentials automatically propagate across all supported API versions.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Installation
|
|
25
|
+
|
|
26
|
+
Install the package via `pip` from PyPI:
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
pip install pyhtb
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
For local development or running modifications, clone the repository and install in editable mode:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
pip install -e .
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
## Quick Start
|
|
41
|
+
|
|
42
|
+
### 1. Basic Client Initialization
|
|
43
|
+
|
|
44
|
+
Initialize the `PyHTB` client wrapper. If you want to access protected endpoints, provide your Hack The Box API token (generated on the app.hackthebox.com settings page).
|
|
45
|
+
|
|
46
|
+
```python
|
|
47
|
+
from pyhtb import PyHTB
|
|
48
|
+
|
|
49
|
+
# Initialize authenticated SDK
|
|
50
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
51
|
+
|
|
52
|
+
# The unified client organizes endpoints by API version:
|
|
53
|
+
# - client.v4
|
|
54
|
+
# - client.v5
|
|
55
|
+
# - client.experience_v1
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### 2. Accessing Endpoints (v5 Example)
|
|
59
|
+
|
|
60
|
+
All OpenAPI operations are dynamically bound as callable methods directly on the version clients.
|
|
61
|
+
|
|
62
|
+
#### Synchronous Call
|
|
63
|
+
```python
|
|
64
|
+
from pyhtb import PyHTB
|
|
65
|
+
|
|
66
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
67
|
+
|
|
68
|
+
# Call any endpoint directly. Client authentication parameters are injected automatically!
|
|
69
|
+
machines_response = client.v5.get_machines()
|
|
70
|
+
|
|
71
|
+
for machine in machines_response.data:
|
|
72
|
+
print(f"Machine: {machine.name} | OS: {machine.os} | Difficulty: {machine.difficulty}")
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
#### Asynchronous Call
|
|
76
|
+
All asynchronous methods share the same name as sync ones but are postfixed with `_async`.
|
|
77
|
+
|
|
78
|
+
```python
|
|
79
|
+
import asyncio
|
|
80
|
+
from pyhtb import PyHTB
|
|
81
|
+
|
|
82
|
+
async def main():
|
|
83
|
+
client = PyHTB(token="YOUR_HTB_API_TOKEN")
|
|
84
|
+
|
|
85
|
+
# Asynchronous endpoint invocation
|
|
86
|
+
machines_response = await client.v5.get_machines_async()
|
|
87
|
+
|
|
88
|
+
for machine in machines_response.data:
|
|
89
|
+
print(f"Async loaded: {machine.name}")
|
|
90
|
+
|
|
91
|
+
asyncio.run(main())
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
#### Accessing Detailed Responses (Metadata & Headers)
|
|
95
|
+
If you need to inspect HTTP status codes or response headers, append `_detailed` or `_async_detailed` to the method name:
|
|
96
|
+
|
|
97
|
+
```python
|
|
98
|
+
response = client.v5.get_machines_detailed()
|
|
99
|
+
print(f"HTTP Status: {response.status_code}")
|
|
100
|
+
print(f"Response Headers: {response.headers}")
|
|
101
|
+
print(f"Parsed Body Model: {response.parsed}")
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
## Supported APIs and Specs
|
|
107
|
+
|
|
108
|
+
The SDK is compiled from official and community-maintained reverse-engineered OpenAPI specifications:
|
|
109
|
+
|
|
110
|
+
| Version | Description | Target Submodule |
|
|
111
|
+
| :--- | :--- | :--- |
|
|
112
|
+
| **API v4** | Primary platform endpoints (User, Teams, Challenges, Tracks, etc.) | `client.v4` |
|
|
113
|
+
| **API v5** | Modern dashboard & user activity endpoints (Machines status, University, User dashboard) | `client.v5` |
|
|
114
|
+
| **Experience v1** | Experience, Levels, and Streak endpoints | `client.experience_v1` |
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## Code Regeneration
|
|
119
|
+
|
|
120
|
+
The SDK contains a build pipeline to automatically compile clients from raw OpenAPI YAML specs. To regenerate the submodules after modifying any specification, execute:
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
./api/regen.sh
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
This requires `openapi-python-client` to be installed in your active Python environment.
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
import pkgutil
|
|
2
|
+
import importlib
|
|
3
|
+
import functools
|
|
4
|
+
from typing import Optional
|
|
5
|
+
import httpx
|
|
6
|
+
|
|
7
|
+
from .v4.client import AuthenticatedClient as AuthenticatedClientV4Gen, Client as ClientV4Gen
|
|
8
|
+
from .v5.client import AuthenticatedClient as AuthenticatedClientV5Gen, Client as ClientV5Gen
|
|
9
|
+
from .experience.v1.client import AuthenticatedClient as AuthenticatedClientV1Gen, Client as ClientV1Gen
|
|
10
|
+
|
|
11
|
+
# Import the API modules for binding
|
|
12
|
+
from .v4 import api as api_v4
|
|
13
|
+
from .v5 import api as api_v5
|
|
14
|
+
from .experience.v1 import api as api_exp_v1
|
|
15
|
+
|
|
16
|
+
# Subclass the generated clients so they support dynamic attribute/method binding
|
|
17
|
+
# (since attrs classes with slots=True don't have a __dict__ by default)
|
|
18
|
+
class ClientV4(ClientV4Gen):
|
|
19
|
+
pass
|
|
20
|
+
|
|
21
|
+
class AuthenticatedClientV4(AuthenticatedClientV4Gen):
|
|
22
|
+
pass
|
|
23
|
+
|
|
24
|
+
class ClientV5(ClientV5Gen):
|
|
25
|
+
pass
|
|
26
|
+
|
|
27
|
+
class AuthenticatedClientV5(AuthenticatedClientV5Gen):
|
|
28
|
+
pass
|
|
29
|
+
|
|
30
|
+
class ClientV1(ClientV1Gen):
|
|
31
|
+
pass
|
|
32
|
+
|
|
33
|
+
class AuthenticatedClientV1(AuthenticatedClientV1Gen):
|
|
34
|
+
pass
|
|
35
|
+
|
|
36
|
+
def _bind_api_methods(client_instance, api_package):
|
|
37
|
+
"""
|
|
38
|
+
Dynamically scans an API subpackage and attaches its endpoints as methods
|
|
39
|
+
directly on the client instance, automatically injecting the client parameter.
|
|
40
|
+
"""
|
|
41
|
+
for _, module_name, is_pkg in pkgutil.walk_packages(api_package.__path__, api_package.__name__ + "."):
|
|
42
|
+
if is_pkg:
|
|
43
|
+
continue
|
|
44
|
+
try:
|
|
45
|
+
mod = importlib.import_module(module_name)
|
|
46
|
+
except Exception:
|
|
47
|
+
continue
|
|
48
|
+
|
|
49
|
+
endpoint_name = module_name.split(".")[-1]
|
|
50
|
+
|
|
51
|
+
# We bind the following:
|
|
52
|
+
# - sync -> client.endpoint_name()
|
|
53
|
+
# - sync_detailed -> client.endpoint_name_detailed()
|
|
54
|
+
# - asyncio -> client.endpoint_name_async()
|
|
55
|
+
# - asyncio_detailed -> client.endpoint_name_async_detailed()
|
|
56
|
+
for attr_name, bound_name in [
|
|
57
|
+
("sync", endpoint_name),
|
|
58
|
+
("asyncio", f"{endpoint_name}_async"),
|
|
59
|
+
("sync_detailed", f"{endpoint_name}_detailed"),
|
|
60
|
+
("asyncio_detailed", f"{endpoint_name}_async_detailed"),
|
|
61
|
+
]:
|
|
62
|
+
func = getattr(mod, attr_name, None)
|
|
63
|
+
if func and callable(func):
|
|
64
|
+
def make_wrapper(f):
|
|
65
|
+
@functools.wraps(f)
|
|
66
|
+
def wrapper(*args, **kwargs):
|
|
67
|
+
kwargs["client"] = client_instance
|
|
68
|
+
return f(*args, **kwargs)
|
|
69
|
+
return wrapper
|
|
70
|
+
|
|
71
|
+
setattr(client_instance, bound_name, make_wrapper(func))
|
|
72
|
+
|
|
73
|
+
class PyHTB:
|
|
74
|
+
"""
|
|
75
|
+
Main entrypoint wrapper for the Hack The Box Python SDK.
|
|
76
|
+
Manages API clients for:
|
|
77
|
+
- v4 (via client.v4)
|
|
78
|
+
- v5 (via client.v5)
|
|
79
|
+
- experience/v1 (via client.experience_v1)
|
|
80
|
+
|
|
81
|
+
All generated endpoints are bound directly as methods on the client instances
|
|
82
|
+
so you don't need to import them manually or pass the client parameter.
|
|
83
|
+
For example:
|
|
84
|
+
client = PyHTB(token="my_token")
|
|
85
|
+
machines = client.v5.get_machines()
|
|
86
|
+
"""
|
|
87
|
+
def __init__(
|
|
88
|
+
self,
|
|
89
|
+
token: Optional[str] = None,
|
|
90
|
+
base_url_v4: str = "https://labs.hackthebox.com/api/v4",
|
|
91
|
+
base_url_v5: str = "https://labs.hackthebox.com/api/v5",
|
|
92
|
+
base_url_experience_v1: str = "https://labs.hackthebox.com/api/experience/v1",
|
|
93
|
+
timeout: Optional[float] = None,
|
|
94
|
+
verify_ssl: bool = True,
|
|
95
|
+
):
|
|
96
|
+
httpx_timeout = httpx.Timeout(timeout) if timeout is not None else None
|
|
97
|
+
|
|
98
|
+
if token:
|
|
99
|
+
self.v4 = AuthenticatedClientV4(
|
|
100
|
+
base_url=base_url_v4,
|
|
101
|
+
token=token,
|
|
102
|
+
timeout=httpx_timeout,
|
|
103
|
+
verify_ssl=verify_ssl,
|
|
104
|
+
)
|
|
105
|
+
self.v5 = AuthenticatedClientV5(
|
|
106
|
+
base_url=base_url_v5,
|
|
107
|
+
token=token,
|
|
108
|
+
timeout=httpx_timeout,
|
|
109
|
+
verify_ssl=verify_ssl,
|
|
110
|
+
)
|
|
111
|
+
self.experience_v1 = AuthenticatedClientV1(
|
|
112
|
+
base_url=base_url_experience_v1,
|
|
113
|
+
token=token,
|
|
114
|
+
timeout=httpx_timeout,
|
|
115
|
+
verify_ssl=verify_ssl,
|
|
116
|
+
)
|
|
117
|
+
else:
|
|
118
|
+
self.v4 = ClientV4(
|
|
119
|
+
base_url=base_url_v4,
|
|
120
|
+
timeout=httpx_timeout,
|
|
121
|
+
verify_ssl=verify_ssl,
|
|
122
|
+
)
|
|
123
|
+
self.v5 = ClientV5(
|
|
124
|
+
base_url=base_url_v5,
|
|
125
|
+
timeout=httpx_timeout,
|
|
126
|
+
verify_ssl=verify_ssl,
|
|
127
|
+
)
|
|
128
|
+
self.experience_v1 = ClientV1(
|
|
129
|
+
base_url=base_url_experience_v1,
|
|
130
|
+
timeout=httpx_timeout,
|
|
131
|
+
verify_ssl=verify_ssl,
|
|
132
|
+
)
|
|
133
|
+
|
|
134
|
+
# Bind API methods directly to client instances for ultimate developer simplicity
|
|
135
|
+
_bind_api_methods(self.v4, api_v4)
|
|
136
|
+
_bind_api_methods(self.v5, api_v5)
|
|
137
|
+
_bind_api_methods(self.experience_v1, api_exp_v1)
|
|
138
|
+
|
|
139
|
+
__all__ = ["PyHTB"]
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Contains methods for accessing the API"""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Contains endpoint functions for accessing the API"""
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
from http import HTTPStatus
|
|
2
|
+
from typing import Any
|
|
3
|
+
from urllib.parse import quote
|
|
4
|
+
|
|
5
|
+
import httpx
|
|
6
|
+
|
|
7
|
+
from ... import errors
|
|
8
|
+
from ...client import AuthenticatedClient, Client
|
|
9
|
+
from ...models.account_response import AccountResponse
|
|
10
|
+
from ...models.generic_error_response import GenericErrorResponse
|
|
11
|
+
from ...types import Response
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def _get_kwargs(
|
|
15
|
+
account_id: str,
|
|
16
|
+
) -> dict[str, Any]:
|
|
17
|
+
_kwargs: dict[str, Any] = {
|
|
18
|
+
"method": "get",
|
|
19
|
+
"url": "/account/{account_id}".format(
|
|
20
|
+
account_id=quote(str(account_id), safe=""),
|
|
21
|
+
),
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
return _kwargs
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def _parse_response(
|
|
28
|
+
*, client: AuthenticatedClient | Client, response: httpx.Response
|
|
29
|
+
) -> AccountResponse | GenericErrorResponse | None:
|
|
30
|
+
if response.status_code == 200:
|
|
31
|
+
response_200 = AccountResponse.from_dict(response.json())
|
|
32
|
+
|
|
33
|
+
return response_200
|
|
34
|
+
|
|
35
|
+
if response.status_code == 400:
|
|
36
|
+
response_400 = GenericErrorResponse.from_dict(response.json())
|
|
37
|
+
|
|
38
|
+
return response_400
|
|
39
|
+
|
|
40
|
+
if client.raise_on_unexpected_status:
|
|
41
|
+
raise errors.UnexpectedStatus(response.status_code, response.content)
|
|
42
|
+
else:
|
|
43
|
+
return None
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
def _build_response(
|
|
47
|
+
*, client: AuthenticatedClient | Client, response: httpx.Response
|
|
48
|
+
) -> Response[AccountResponse | GenericErrorResponse]:
|
|
49
|
+
return Response(
|
|
50
|
+
status_code=HTTPStatus(response.status_code),
|
|
51
|
+
content=response.content,
|
|
52
|
+
headers=response.headers,
|
|
53
|
+
parsed=_parse_response(client=client, response=response),
|
|
54
|
+
)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
def sync_detailed(
|
|
58
|
+
account_id: str,
|
|
59
|
+
*,
|
|
60
|
+
client: AuthenticatedClient | Client,
|
|
61
|
+
) -> Response[AccountResponse | GenericErrorResponse]:
|
|
62
|
+
"""Get Account
|
|
63
|
+
|
|
64
|
+
Account
|
|
65
|
+
|
|
66
|
+
Args:
|
|
67
|
+
account_id (str):
|
|
68
|
+
|
|
69
|
+
Raises:
|
|
70
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
71
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
72
|
+
|
|
73
|
+
Returns:
|
|
74
|
+
Response[AccountResponse | GenericErrorResponse]
|
|
75
|
+
"""
|
|
76
|
+
|
|
77
|
+
kwargs = _get_kwargs(
|
|
78
|
+
account_id=account_id,
|
|
79
|
+
)
|
|
80
|
+
|
|
81
|
+
response = client.get_httpx_client().request(
|
|
82
|
+
**kwargs,
|
|
83
|
+
)
|
|
84
|
+
|
|
85
|
+
return _build_response(client=client, response=response)
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
def sync(
|
|
89
|
+
account_id: str,
|
|
90
|
+
*,
|
|
91
|
+
client: AuthenticatedClient | Client,
|
|
92
|
+
) -> AccountResponse | GenericErrorResponse | None:
|
|
93
|
+
"""Get Account
|
|
94
|
+
|
|
95
|
+
Account
|
|
96
|
+
|
|
97
|
+
Args:
|
|
98
|
+
account_id (str):
|
|
99
|
+
|
|
100
|
+
Raises:
|
|
101
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
102
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
103
|
+
|
|
104
|
+
Returns:
|
|
105
|
+
AccountResponse | GenericErrorResponse
|
|
106
|
+
"""
|
|
107
|
+
|
|
108
|
+
return sync_detailed(
|
|
109
|
+
account_id=account_id,
|
|
110
|
+
client=client,
|
|
111
|
+
).parsed
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
async def asyncio_detailed(
|
|
115
|
+
account_id: str,
|
|
116
|
+
*,
|
|
117
|
+
client: AuthenticatedClient | Client,
|
|
118
|
+
) -> Response[AccountResponse | GenericErrorResponse]:
|
|
119
|
+
"""Get Account
|
|
120
|
+
|
|
121
|
+
Account
|
|
122
|
+
|
|
123
|
+
Args:
|
|
124
|
+
account_id (str):
|
|
125
|
+
|
|
126
|
+
Raises:
|
|
127
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
128
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
129
|
+
|
|
130
|
+
Returns:
|
|
131
|
+
Response[AccountResponse | GenericErrorResponse]
|
|
132
|
+
"""
|
|
133
|
+
|
|
134
|
+
kwargs = _get_kwargs(
|
|
135
|
+
account_id=account_id,
|
|
136
|
+
)
|
|
137
|
+
|
|
138
|
+
response = await client.get_async_httpx_client().request(**kwargs)
|
|
139
|
+
|
|
140
|
+
return _build_response(client=client, response=response)
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
async def asyncio(
|
|
144
|
+
account_id: str,
|
|
145
|
+
*,
|
|
146
|
+
client: AuthenticatedClient | Client,
|
|
147
|
+
) -> AccountResponse | GenericErrorResponse | None:
|
|
148
|
+
"""Get Account
|
|
149
|
+
|
|
150
|
+
Account
|
|
151
|
+
|
|
152
|
+
Args:
|
|
153
|
+
account_id (str):
|
|
154
|
+
|
|
155
|
+
Raises:
|
|
156
|
+
errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
|
|
157
|
+
httpx.TimeoutException: If the request takes longer than Client.timeout.
|
|
158
|
+
|
|
159
|
+
Returns:
|
|
160
|
+
AccountResponse | GenericErrorResponse
|
|
161
|
+
"""
|
|
162
|
+
|
|
163
|
+
return (
|
|
164
|
+
await asyncio_detailed(
|
|
165
|
+
account_id=account_id,
|
|
166
|
+
client=client,
|
|
167
|
+
)
|
|
168
|
+
).parsed
|