hackerrank 2026.5.12.2__py2.py3-none-any.whl
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.
- hackerrank/__init__.py +1 -0
- hackerrank/_dict_types.py +324 -0
- hackerrank/async_client.py +1044 -0
- hackerrank/client.py +2446 -0
- hackerrank/exceptions.py +129 -0
- hackerrank/py.typed +0 -0
- hackerrank/transports.py +263 -0
- hackerrank/types.py +1012 -0
- hackerrank-2026.5.12.2.dist-info/METADATA +117 -0
- hackerrank-2026.5.12.2.dist-info/RECORD +13 -0
- hackerrank-2026.5.12.2.dist-info/WHEEL +6 -0
- hackerrank-2026.5.12.2.dist-info/licenses/LICENSE +21 -0
- hackerrank-2026.5.12.2.dist-info/top_level.txt +1 -0
hackerrank/__init__.py
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""A library for the HackerRank for Work API."""
|
|
@@ -0,0 +1,324 @@
|
|
|
1
|
+
"""TypedDict types describing raw HackerRank API response shapes."""
|
|
2
|
+
|
|
3
|
+
from typing import Any, NotRequired, TypedDict
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class InterviewDict(TypedDict):
|
|
7
|
+
"""A HackerRank interview."""
|
|
8
|
+
|
|
9
|
+
id: str
|
|
10
|
+
status: str
|
|
11
|
+
url: str
|
|
12
|
+
title: NotRequired[str]
|
|
13
|
+
feedback: NotRequired[str]
|
|
14
|
+
thumbs_up: NotRequired[int]
|
|
15
|
+
notes: NotRequired[str]
|
|
16
|
+
resume_url: NotRequired[str]
|
|
17
|
+
interviewers: NotRequired[list[str]]
|
|
18
|
+
result_url: NotRequired[str]
|
|
19
|
+
candidate: NotRequired[dict[str, Any]]
|
|
20
|
+
metadata: NotRequired[dict[str, Any]]
|
|
21
|
+
report_url: NotRequired[str]
|
|
22
|
+
ended_at: NotRequired[str]
|
|
23
|
+
interview_template_id: NotRequired[int]
|
|
24
|
+
created_at: NotRequired[str]
|
|
25
|
+
updated_at: NotRequired[str]
|
|
26
|
+
user: NotRequired[int]
|
|
27
|
+
send_email: NotRequired[bool]
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class InterviewTranscriptMessageDict(TypedDict):
|
|
31
|
+
"""A single message from an interview transcript."""
|
|
32
|
+
|
|
33
|
+
author: str
|
|
34
|
+
timestamp: int
|
|
35
|
+
text: str
|
|
36
|
+
candidate: bool
|
|
37
|
+
messageId: str
|
|
38
|
+
email: NotRequired[str]
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
class InterviewTranscriptDict(TypedDict):
|
|
42
|
+
"""The transcript for an interview."""
|
|
43
|
+
|
|
44
|
+
messages: list[InterviewTranscriptMessageDict]
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class InterviewTemplateDict(TypedDict):
|
|
48
|
+
"""A HackerRank interview template."""
|
|
49
|
+
|
|
50
|
+
id: int
|
|
51
|
+
name: str
|
|
52
|
+
created_at: NotRequired[str]
|
|
53
|
+
status: NotRequired[int]
|
|
54
|
+
user: NotRequired[int]
|
|
55
|
+
roles: NotRequired[list[str]]
|
|
56
|
+
team_share: NotRequired[int]
|
|
57
|
+
questions: NotRequired[list[str]]
|
|
58
|
+
scorecard: NotRequired[int]
|
|
59
|
+
import_template: NotRequired[bool]
|
|
60
|
+
editor_access: NotRequired[bool]
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
class QuestionDict(TypedDict):
|
|
64
|
+
"""A HackerRank question."""
|
|
65
|
+
|
|
66
|
+
id: str
|
|
67
|
+
unique_id: NotRequired[str]
|
|
68
|
+
type: str
|
|
69
|
+
owner: NotRequired[str]
|
|
70
|
+
created_at: NotRequired[str]
|
|
71
|
+
status: NotRequired[str]
|
|
72
|
+
internal_notes: NotRequired[str]
|
|
73
|
+
name: str
|
|
74
|
+
languages: NotRequired[list[str]]
|
|
75
|
+
problem_statement: NotRequired[str]
|
|
76
|
+
recommended_duration: NotRequired[int]
|
|
77
|
+
tags: NotRequired[list[str]]
|
|
78
|
+
max_score: NotRequired[float]
|
|
79
|
+
options: NotRequired[list[str]]
|
|
80
|
+
answer: NotRequired[int | list[int]]
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
class TestDict(TypedDict):
|
|
84
|
+
"""A HackerRank test."""
|
|
85
|
+
|
|
86
|
+
id: str
|
|
87
|
+
unique_id: NotRequired[str]
|
|
88
|
+
name: str
|
|
89
|
+
starttime: NotRequired[str]
|
|
90
|
+
endtime: NotRequired[str]
|
|
91
|
+
duration: NotRequired[int]
|
|
92
|
+
owner: NotRequired[str]
|
|
93
|
+
instructions: NotRequired[str]
|
|
94
|
+
starred: NotRequired[bool]
|
|
95
|
+
created_at: NotRequired[str]
|
|
96
|
+
state: NotRequired[str]
|
|
97
|
+
locked: NotRequired[bool]
|
|
98
|
+
draft: NotRequired[bool]
|
|
99
|
+
languages: NotRequired[list[str]]
|
|
100
|
+
candidate_details: NotRequired[list[str]]
|
|
101
|
+
custom_acknowledge_text: NotRequired[str]
|
|
102
|
+
cutoff_score: NotRequired[int]
|
|
103
|
+
master_password: NotRequired[str]
|
|
104
|
+
hide_compile_test: NotRequired[bool]
|
|
105
|
+
tags: NotRequired[list[str]]
|
|
106
|
+
role_ids: NotRequired[list[str]]
|
|
107
|
+
experience: NotRequired[list[str]]
|
|
108
|
+
questions: NotRequired[list[str]]
|
|
109
|
+
sections: NotRequired[list[dict[str, Any]]]
|
|
110
|
+
mcq_incorrect_score: NotRequired[int]
|
|
111
|
+
mcq_correct_score: NotRequired[int]
|
|
112
|
+
locked_by: NotRequired[str]
|
|
113
|
+
short_login_url: NotRequired[str]
|
|
114
|
+
public_login_url: NotRequired[str]
|
|
115
|
+
shuffle_questions: NotRequired[bool]
|
|
116
|
+
test_admins: NotRequired[list[str]]
|
|
117
|
+
hide_template: NotRequired[bool]
|
|
118
|
+
enable_acknowledgement: NotRequired[bool]
|
|
119
|
+
enable_proctoring: NotRequired[bool]
|
|
120
|
+
enable_advanced_proctoring: NotRequired[bool]
|
|
121
|
+
enable_secure_assessment_mode: NotRequired[bool]
|
|
122
|
+
enable_ml_plagiarism_analysis: NotRequired[bool]
|
|
123
|
+
enable_photo_identification: NotRequired[bool]
|
|
124
|
+
ide_config: NotRequired[str]
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
class CandidateDetailDict(TypedDict):
|
|
128
|
+
"""A custom candidate detail field."""
|
|
129
|
+
|
|
130
|
+
field_name: str
|
|
131
|
+
title: str
|
|
132
|
+
value: str
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
class TestCandidateDict(TypedDict):
|
|
136
|
+
"""A candidate associated with a test."""
|
|
137
|
+
|
|
138
|
+
id: str
|
|
139
|
+
full_name: NotRequired[str]
|
|
140
|
+
email: str
|
|
141
|
+
score: NotRequired[float]
|
|
142
|
+
test: NotRequired[str]
|
|
143
|
+
user: NotRequired[str]
|
|
144
|
+
attempt_starttime: NotRequired[str]
|
|
145
|
+
attempt_endtime: NotRequired[str]
|
|
146
|
+
attempt_events: NotRequired[list[str]]
|
|
147
|
+
status: NotRequired[int]
|
|
148
|
+
ats_state: NotRequired[int]
|
|
149
|
+
integrity_status: NotRequired[str]
|
|
150
|
+
integrity_summary: NotRequired[str]
|
|
151
|
+
invite_email_done: NotRequired[bool]
|
|
152
|
+
invite_valid: NotRequired[bool]
|
|
153
|
+
invited_on: NotRequired[str]
|
|
154
|
+
invite_valid_from: NotRequired[str]
|
|
155
|
+
invite_valid_to: NotRequired[str]
|
|
156
|
+
invite_link: NotRequired[str]
|
|
157
|
+
invite_metadata: NotRequired[dict[str, Any]]
|
|
158
|
+
evaluator_email: NotRequired[str]
|
|
159
|
+
test_finish_url: NotRequired[str]
|
|
160
|
+
test_result_url: NotRequired[str]
|
|
161
|
+
accept_result_updates: NotRequired[bool]
|
|
162
|
+
tags: NotRequired[list[str]]
|
|
163
|
+
report_url: NotRequired[str]
|
|
164
|
+
authenticated_report_url: NotRequired[str]
|
|
165
|
+
pdf_url: NotRequired[str]
|
|
166
|
+
scores_tags_split: NotRequired[dict[str, Any]]
|
|
167
|
+
scores_skills_split: NotRequired[dict[str, Any]]
|
|
168
|
+
added_time: NotRequired[int]
|
|
169
|
+
unclaimed_added_time: NotRequired[int]
|
|
170
|
+
comments: NotRequired[dict[str, Any]]
|
|
171
|
+
performance_summary: NotRequired[str]
|
|
172
|
+
ip_address: NotRequired[str]
|
|
173
|
+
questions: NotRequired[dict[str, Any]]
|
|
174
|
+
plagiarism: NotRequired[dict[str, Any]]
|
|
175
|
+
plagiarism_status: NotRequired[bool]
|
|
176
|
+
max_code_similarity: NotRequired[dict[str, Any]]
|
|
177
|
+
feedback: NotRequired[str]
|
|
178
|
+
percentage_score: NotRequired[float]
|
|
179
|
+
candidate_details: NotRequired[list[CandidateDetailDict]]
|
|
180
|
+
out_of_window_events: NotRequired[int]
|
|
181
|
+
out_of_window_duration: NotRequired[float]
|
|
182
|
+
editor_paste_count: NotRequired[int]
|
|
183
|
+
proctor_images: NotRequired[list[str]]
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
class InviterDict(TypedDict):
|
|
187
|
+
"""A user permitted to invite candidates to a test."""
|
|
188
|
+
|
|
189
|
+
id: str
|
|
190
|
+
email: str
|
|
191
|
+
firstname: NotRequired[str]
|
|
192
|
+
lastname: NotRequired[str]
|
|
193
|
+
role: NotRequired[str]
|
|
194
|
+
status: NotRequired[str]
|
|
195
|
+
phone: NotRequired[str]
|
|
196
|
+
timezone: NotRequired[str]
|
|
197
|
+
questions_permission: NotRequired[int]
|
|
198
|
+
tests_permission: NotRequired[int]
|
|
199
|
+
interviews_permission: NotRequired[int]
|
|
200
|
+
candidates_permission: NotRequired[int]
|
|
201
|
+
teams: NotRequired[list[str]]
|
|
202
|
+
candidates_invited: NotRequired[int]
|
|
203
|
+
activated: NotRequired[bool]
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
class UserDict(TypedDict):
|
|
207
|
+
"""A HackerRank user."""
|
|
208
|
+
|
|
209
|
+
id: str
|
|
210
|
+
email: str
|
|
211
|
+
firstname: NotRequired[str]
|
|
212
|
+
lastname: NotRequired[str]
|
|
213
|
+
country: NotRequired[str]
|
|
214
|
+
role: NotRequired[str]
|
|
215
|
+
status: NotRequired[str]
|
|
216
|
+
phone: NotRequired[str]
|
|
217
|
+
timezone: NotRequired[str]
|
|
218
|
+
questions_permission: NotRequired[int]
|
|
219
|
+
tests_permission: NotRequired[int]
|
|
220
|
+
interviews_permission: NotRequired[int]
|
|
221
|
+
candidates_permission: NotRequired[int]
|
|
222
|
+
shared_questions_permission: NotRequired[int]
|
|
223
|
+
shared_tests_permission: NotRequired[int]
|
|
224
|
+
shared_interviews_permission: NotRequired[int]
|
|
225
|
+
shared_candidates_permission: NotRequired[int]
|
|
226
|
+
company_admin: NotRequired[bool]
|
|
227
|
+
team_admin: NotRequired[bool]
|
|
228
|
+
teams: NotRequired[list[str]]
|
|
229
|
+
activated: NotRequired[bool]
|
|
230
|
+
last_activity_time: NotRequired[str]
|
|
231
|
+
|
|
232
|
+
|
|
233
|
+
class TeamDict(TypedDict):
|
|
234
|
+
"""A HackerRank team."""
|
|
235
|
+
|
|
236
|
+
id: str
|
|
237
|
+
name: str
|
|
238
|
+
owner: NotRequired[str]
|
|
239
|
+
created_at: NotRequired[str]
|
|
240
|
+
recruiter_count: NotRequired[int]
|
|
241
|
+
developer_count: NotRequired[int]
|
|
242
|
+
recruiter_cap: NotRequired[int]
|
|
243
|
+
developer_cap: NotRequired[int]
|
|
244
|
+
invite_as: NotRequired[str]
|
|
245
|
+
locations: NotRequired[list[str]]
|
|
246
|
+
departments: NotRequired[list[str]]
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
class UserTeamMembershipDict(TypedDict):
|
|
250
|
+
"""A membership of a user in a team."""
|
|
251
|
+
|
|
252
|
+
team: str
|
|
253
|
+
user: str
|
|
254
|
+
|
|
255
|
+
|
|
256
|
+
class TemplateDict(TypedDict):
|
|
257
|
+
"""An invite-email template."""
|
|
258
|
+
|
|
259
|
+
id: str
|
|
260
|
+
name: str
|
|
261
|
+
subject: NotRequired[str]
|
|
262
|
+
content: NotRequired[str]
|
|
263
|
+
default: NotRequired[bool]
|
|
264
|
+
created_at: NotRequired[str]
|
|
265
|
+
updated_at: NotRequired[str]
|
|
266
|
+
user: NotRequired[str]
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
class AuditLogDict(TypedDict):
|
|
270
|
+
"""An audit log entry."""
|
|
271
|
+
|
|
272
|
+
source_id: int
|
|
273
|
+
source_type: str
|
|
274
|
+
user: NotRequired[str]
|
|
275
|
+
action: str
|
|
276
|
+
modified_fields: NotRequired[list[str]]
|
|
277
|
+
modified_values: NotRequired[dict[str, Any]]
|
|
278
|
+
ip_address: NotRequired[str]
|
|
279
|
+
created_at: NotRequired[str]
|
|
280
|
+
|
|
281
|
+
|
|
282
|
+
class ATSCodePairDict(TypedDict):
|
|
283
|
+
"""Result of an ATS Codepair invite."""
|
|
284
|
+
|
|
285
|
+
title: NotRequired[str]
|
|
286
|
+
requisition_id: NotRequired[str]
|
|
287
|
+
candidate_id: NotRequired[str]
|
|
288
|
+
candidate: NotRequired[dict[str, Any]]
|
|
289
|
+
send_email: NotRequired[bool]
|
|
290
|
+
interview_metadata: NotRequired[dict[str, Any]]
|
|
291
|
+
|
|
292
|
+
|
|
293
|
+
class ATSCodeScreenDict(TypedDict):
|
|
294
|
+
"""Result of an ATS CodeScreen invite."""
|
|
295
|
+
|
|
296
|
+
test_id: NotRequired[str]
|
|
297
|
+
requisition_id: NotRequired[str]
|
|
298
|
+
candidate_id: NotRequired[str]
|
|
299
|
+
email: NotRequired[str]
|
|
300
|
+
test_result_url: NotRequired[str]
|
|
301
|
+
accept_result_updates: NotRequired[bool]
|
|
302
|
+
|
|
303
|
+
|
|
304
|
+
class SCIMUserDict(TypedDict):
|
|
305
|
+
"""A SCIM v2 user."""
|
|
306
|
+
|
|
307
|
+
id: str
|
|
308
|
+
userName: str
|
|
309
|
+
name: NotRequired[dict[str, Any]]
|
|
310
|
+
active: NotRequired[bool]
|
|
311
|
+
role: NotRequired[str]
|
|
312
|
+
team_admin: NotRequired[bool]
|
|
313
|
+
company_admin: NotRequired[bool]
|
|
314
|
+
emails: NotRequired[list[dict[str, Any]]]
|
|
315
|
+
schemas: NotRequired[list[str]]
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
class SCIMTeamDict(TypedDict):
|
|
319
|
+
"""A SCIM v2 team."""
|
|
320
|
+
|
|
321
|
+
id: str
|
|
322
|
+
displayName: NotRequired[str]
|
|
323
|
+
diplayName: NotRequired[str]
|
|
324
|
+
schemas: NotRequired[list[str]]
|