models
This module contains the models used to represent data returned by the WOM API.
Enums related to specific services are also housed in the module.
Tip
Most of the models here you won't create, but a few you will. Those will be documented as such.
Achievement
Bases: BaseModel
Represents an achievement made by a player.
Source code in wom/models/players/models.py
accuracy
instance-attribute
The margin of error for the achievements creation date.
Note
Can be None
if the achievement hasn't been recalculated since
the addition of this field (~ Feb 2023). It can also be -1 for
achievements with unknown dates.
measure
instance-attribute
The AchievementMeasure
that
the player obtained.
AchievementMeasure
AchievementProgress
Bases: BaseModel
Represents progress made toward an achievement.
Source code in wom/models/players/models.py
accuracy
instance-attribute
The margin of error for the achievements creation date.
Note
Can be None
if the achievement hasn't been recalculated since
the addition of this field (~ Feb 2023). It can also be -1 for
achievements with unknown dates.
created_at
instance-attribute
The date the achievement was achieved, or None
if it has not
been achieved.
measure
instance-attribute
The AchievementMeasure
that
the player obtained.
Activity
Bases: BaseModel
Details regarding a particular activity.
Source code in wom/models/players/models.py
ActivityGains
Bases: BaseModel
Represents activity gains made by a player.
Source code in wom/models/players/models.py
ActivityLeader
Bases: MetricLeader
Represents a leader in a particular activity.
Source code in wom/models/groups/models.py
Archive
Bases: BaseModel
Information detailing a player that has been archived.
Source code in wom/models/players/models.py
archive_username
instance-attribute
The players placeholder username after the archive.
previous_username
instance-attribute
The players previous username before the archive.
restored_at
instance-attribute
The date the player was restored, if they have been.
BaseModel
Bases: Struct
The base model all library models inherit from.
Source code in wom/models/base.py
to_dict
Converts this class into a dictionary.
Returns:
Type | Description |
---|---|
Dict[str, Any]
|
The requested dictionary. |
Boss
BossGains
Bases: BaseModel
Represents boss gains made by a player.
Source code in wom/models/players/models.py
BossLeader
Bases: MetricLeader
Represents a leader in a particular boss.
Source code in wom/models/groups/models.py
Competition
Bases: BaseModel
Represents a competition.
Source code in wom/models/competitions/models.py
group
class-attribute
instance-attribute
The Group
associated with the competition, if
there is one.
group_id
instance-attribute
The optional group id associated with the competition.
participations
class-attribute
instance-attribute
A list containing the CompetitionParticipations
.
CompetitionCSVTableType
CompetitionDetail
Bases: Competition
Represents competition details.
Source code in wom/models/competitions/models.py
participations
class-attribute
instance-attribute
A list of CompetitionParticipationDetail
participations for this
competition.
CompetitionHistoryDataPoint
CompetitionParticipation
Bases: Participation
Represents a competition participation.
Source code in wom/models/competitions/models.py
CompetitionParticipationDetail
Bases: CompetitionParticipation
Represents competition participation details.
Source code in wom/models/competitions/models.py
levels
instance-attribute
The CompetitionProgress
as it relates to
the number of levels gained. Only contains useful information for skilling
competitions.
CompetitionProgress
Bases: BaseModel
Represents progress in a competition.
Source code in wom/models/competitions/models.py
CompetitionStatus
CompetitionType
ComputedGains
Bases: BaseModel
Represents computed gains made by a player.
Source code in wom/models/players/models.py
ComputedMetric
ComputedMetricLeader
Bases: MetricLeader
Represents a leader in a particular computed metric.
Source code in wom/models/groups/models.py
Country
Bases: BaseEnum
Countries in the world.
Source code in wom/models/players/enums.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 |
|
CreatedCompetitionDetail
Bases: BaseModel
Represents a competition that was just created.
Source code in wom/models/competitions/models.py
CreatedGroupDetail
DeltaLeaderboardEntry
Bases: BaseModel
Represents a leaderboard entry over the given delta.
Source code in wom/models/deltas/models.py
Gains
Group
Bases: BaseModel
Represents a group of players on WOM.
Source code in wom/models/groups/models.py
banner_image
instance-attribute
The banner image url for this group, if any.
profile_image
instance-attribute
The profile image url for this group, if any.
GroupActivity
Bases: BaseModel
An activity that occurred in a group.
Source code in wom/models/groups/models.py
created_at
instance-attribute
The datetime indicating when this activity occurred.
player_id
instance-attribute
The unique ID of the player associated with this activity.
previous_role
instance-attribute
The players previous role in the group, if they had one.
GroupActivityType
GroupDetail
GroupHiscoresActivityItem
Bases: BaseModel
Represents a group hiscores item for activities.
Source code in wom/models/groups/models.py
GroupHiscoresBossItem
Bases: BaseModel
Represents a group hiscores item for bosses.
Source code in wom/models/groups/models.py
GroupHiscoresComputedMetricItem
Bases: BaseModel
Represents a group hiscores item for computed metrics.
Source code in wom/models/groups/models.py
GroupHiscoresEntry
Bases: BaseModel
Represents a group hiscores entry.
Source code in wom/models/groups/models.py
GroupHiscoresSkillItem
Bases: BaseModel
Represents a group hiscores item for skills.
Source code in wom/models/groups/models.py
GroupMemberFragment
Bases: BaseModel
Represents a condensed group member.
Tip
This is a model class that you will create in order to send data to some endpoints.
Source code in wom/models/groups/models.py
role
class-attribute
instance-attribute
The optional GroupRole
for the member.
GroupMemberGains
Bases: BaseModel
Represents a leaderboard entry over the given delta.
Source code in wom/models/groups/models.py
GroupMembership
GroupRole
Bases: BaseEnum
Roles that can be assigned to group members.
Source code in wom/models/groups/enums.py
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 |
|
GroupStatistics
Bases: BaseModel
Represents accumulated group statistics.
Source code in wom/models/groups/models.py
average_stats
instance-attribute
The average group statistics in a Snapshot
.
maxed_200ms_count
class-attribute
instance-attribute
The number of maxed 200M xp players in the group.
maxed_combat_count
instance-attribute
The number of maxed combat players in the group.
maxed_total_count
instance-attribute
The number of maxed total level players in the group.
metric_leaders
instance-attribute
The MetricLeaders
in this group for each
metric.
HttpErrorResponse
Bases: BaseModel
Indicates something went wrong during the request.
Source code in wom/models/http.py
HttpSuccessResponse
Membership
Bases: BaseModel
Represents a membership in a group.
Source code in wom/models/groups/models.py
MetricLeader
Bases: BaseModel
Base class used to derive leaders in different metrics.
Source code in wom/models/groups/models.py
MetricLeaders
Bases: BaseModel
The leaders for each metric in a group.
Source code in wom/models/groups/models.py
activities
instance-attribute
A mapping of activity keys to ActivityLeader
values.
bosses
instance-attribute
A mapping of boss keys to BossLeader
values.
computed
instance-attribute
A mapping of computed metric keys to
ComputedMetricLeader
values.
skills
instance-attribute
A mapping of skill keys to SkillLeader
values.
NameChange
Bases: BaseModel
Represents a player name change.
Source code in wom/models/names/models.py
resolved_at
instance-attribute
The date the name change was approved or denied.
review_context
instance-attribute
The review context associated with this name change, if it was denied or skipped.
NameChangeReviewContext
Bases: BaseModel
The review context for a name change that was not approved.
Source code in wom/models/names/models.py
ehb_diff
class-attribute
instance-attribute
The number difference between the old and new names ehb. Only populated
when the reason is ExcessiveGains
.
ehp_diff
class-attribute
instance-attribute
The number difference between the old and new names ehp. Only populated
when the reason is ExcessiveGains
.
hours_diff
class-attribute
instance-attribute
The actual number of hours in the transition period. Only populated when
reason is TransitionTooLong
or ExcessiveGains
.
max_hours_diff
class-attribute
instance-attribute
The max number of hours in the transition period. Only populated when
reason is TransitionTooLong
.
min_total_level
class-attribute
instance-attribute
The minimum total level allowed for this name change. Only populated
when the reason is TotalLevelTooLow
.
negative_gains
class-attribute
instance-attribute
The negative gains that were observed, if there were any. Only populated
when the reason is NegativeGains
.
NameChangeStatus
Participation
Bases: BaseModel
Represents participation in a competition.
Source code in wom/models/competitions/models.py
competition_id
instance-attribute
The ID of the competition associated with this participation.
player_id
instance-attribute
The ID of the player associated with this participation.
team_name
instance-attribute
The optional team name associated with this participation.
Player
Bases: BaseModel
Represents a player on WOM.
Source code in wom/models/players/models.py
country
instance-attribute
The players Country
country of origin, if they
have one set.
display_name
instance-attribute
The players display name, supports capitalization .
last_changed_at
instance-attribute
The date of the players last change (xp gain, boss kc, etc).
last_imported_at
instance-attribute
The date of the last player history import.
registered_at
instance-attribute
The date the player was registered with WOM.
updated_at
instance-attribute
The date the player was last successfully updated with WOM.
PlayerAchievementProgress
Bases: AchievementProgress
Represents a players progress toward an achievement.
Source code in wom/models/players/models.py
absolute_progress
instance-attribute
The players current absolute progress toward the achievement.
Scale of 0-1 with 1 being 100% progress.
PlayerArchive
PlayerBuild
PlayerCompetitionStanding
Bases: PlayerParticipation
Represents a players standing in a competition.
Source code in wom/models/competitions/models.py
levels
instance-attribute
The CompetitionProgress
that was
made. Only contains useful information for skilling competitions.
PlayerDetail
Bases: Player
Represents details about a player.
Source code in wom/models/players/models.py
archive
class-attribute
instance-attribute
The players archive information, if any.
PlayerGains
PlayerGainsData
Bases: BaseModel
Contains all the player gains data.
Source code in wom/models/players/models.py
activities
instance-attribute
A mapping of activity keys to ActivityGains
values.
bosses
instance-attribute
A mapping of boss keys to BossGains
values.
computed
instance-attribute
A mapping of computed metric keys to ComputedGains
values.
skills
instance-attribute
A mapping of skill keys to SkillGains
values.
PlayerMembership
PlayerParticipation
Bases: Participation
Represents a players participation in a competition.
Source code in wom/models/competitions/models.py
competition
instance-attribute
The Competition
that the player participated
in.
PlayerStatus
PlayerType
Record
Bases: BaseModel
Represents a record held by a player.
Source code in wom/models/records/models.py
RecordLeaderboardEntry
Bases: Record
Represents a player's record leaderboard entry.
Source code in wom/models/records/models.py
Skill
Bases: BaseModel
Details regarding a particular skill.
Source code in wom/models/players/models.py
SkillGains
Bases: BaseModel
Represents skill gains made by a player.
Source code in wom/models/players/models.py
SkillLeader
Bases: MetricLeader
Represents a leader in a particular skill.
Source code in wom/models/groups/models.py
Snapshot
Bases: BaseModel
Represents a player snapshot.
Source code in wom/models/players/models.py
imported_at
instance-attribute
The date the snapshot was imported, if it was.
SnapshotData
Bases: BaseModel
The data associated with this snapshot.
Source code in wom/models/players/models.py
activities
instance-attribute
A mapping of activity keys to activity values from this snapshot.
bosses
instance-attribute
A mapping of boss keys to boss values from this snapshot.
computed
instance-attribute
A mapping of computed metric keys to computed metric values from this snapshot.
SnapshotTimelineEntry
Bases: BaseModel
An entry representing a point in time of a players gains.
Source code in wom/models/players/models.py
SocialLinks
Bases: BaseModel
A groups social links.
Source code in wom/models/groups/models.py
discord
class-attribute
instance-attribute
The groups discord invite url.
Team
Bases: BaseModel
Represents a competition team.
Tip
This is a model class that you will create in order to send data to some endpoints.
Source code in wom/models/competitions/models.py
Top5ProgressResult
Bases: BaseModel
A top 5 progress result for a competition.
Source code in wom/models/competitions/models.py
history
instance-attribute
A list of CompetitionHistoryDataPoints making up the history of this top 5 progress result.