Module genshin.models.starrail.chronicle.events
Classes
class ChallengeStatus (value, names=None, *, module=None, qualname=None, type=None, start=1)
-
Challenge status enum.
Expand source code
class ChallengeStatus(Enum): """Challenge status enum.""" IN_PROGRESS = "challengeStatusInProgress" LOCKED = "challengeStatusUnopened"
Ancestors
- enum.Enum
Class variables
var IN_PROGRESS
var LOCKED
class ChallengeType (value, names=None, *, module=None, qualname=None, type=None, start=1)
-
Challenge type enum.
Expand source code
class ChallengeType(Enum): """Challenge type enum.""" APC_SHADOW = "ChallengeTypeBoss" """Apocalyptic shadow.""" MOC = "ChallengeTypeChasm" """Memory of Chaos.""" PURE_FICTION = "ChallengeTypeStory"
Ancestors
- enum.Enum
Class variables
var APC_SHADOW
-
Apocalyptic shadow.
var MOC
-
Memory of Chaos.
var PURE_FICTION
class EventWarp (**data: Any)
-
Event warp model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class EventWarp(HSRBaseEvent): """Event warp model.""" name: str type: str # Seems to always be 'CardPoolRole' characters: typing.Sequence[EventWarpCharacter] = pydantic.Field(alias="avatar_list") light_cones: typing.Sequence[EventWarpLightCone] = pydantic.Field(alias="equip_list") is_after_version: bool """Whether the event happens after last version's update.""" version: str id: int
Ancestors
- genshin.models.starrail.chronicle.events.HSRBaseEvent
- APIModel
- pydantic.main.BaseModel
Class variables
var characters : Sequence[EventWarpCharacter]
var id : int
var is_after_version : bool
-
Whether the event happens after last version's update.
var light_cones : Sequence[EventWarpLightCone]
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var name : str
var type : str
var version : str
class EventWarpCharacter (**data: Any)
-
Event warp character model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class EventWarpCharacter(HSRBaseEventItem): """Event warp character model.""" icon: str = pydantic.Field(alias="icon_url") large_icon: str = pydantic.Field(alias="item_avatar_icon_path") element: int = pydantic.Field(alias="damage_type")
Ancestors
- HSRBaseEventItem
- APIModel
- pydantic.main.BaseModel
Class variables
var element : int
var icon : str
var large_icon : str
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
class EventWarpLightCone (**data: Any)
-
Event warp light cone model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class EventWarpLightCone(HSRBaseEventItem): """Event warp light cone model.""" icon: str = pydantic.Field(alias="item_url")
Ancestors
- HSRBaseEventItem
- APIModel
- pydantic.main.BaseModel
Class variables
var icon : str
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
class HSRBaseEventItem (**data: Any)
-
Base event item model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class HSRBaseEventItem(APIModel): """Base event item model.""" id: int = pydantic.Field(alias="item_id") name: str = pydantic.Field(alias="item_name") icon: str = pydantic.Field(alias="icon_url") path: int = pydantic.Field(alias="avatar_base_type") rarity: int wiki_url: str is_forward: bool # No clue what this is
Ancestors
- APIModel
- pydantic.main.BaseModel
Subclasses
Class variables
var icon : str
var id : int
var is_forward : bool
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var name : str
var path : int
var rarity : int
var wiki_url : str
class HSRChallenge (**data: Any)
-
HSR challenge model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class HSRChallenge(HSRBaseEvent): """HSR challenge model.""" id: int = pydantic.Field(alias="group_id") name: str = pydantic.Field(alias="name_mi18n") type: typing.Union[ChallengeType, str] = pydantic.Field(alias="challenge_type") status: typing.Union[ChallengeStatus, str] rewards: typing.Sequence[HSREventReward] = pydantic.Field(alias="reward_list") special_reward: typing.Optional[HSREventReward] total_progress: int current_progress: int show_text: str @pydantic.field_validator("special_reward", mode="after") def __validate_special_reward(cls, v: HSREventReward) -> typing.Optional[HSREventReward]: if v.id == 0: return None return v @pydantic.field_validator("type", mode="before") def __validate_type(cls, v: str) -> typing.Union[ChallengeType, str]: try: return ChallengeType(v) except ValueError: return v @pydantic.field_validator("status", mode="before") def __validate_status(cls, v: str) -> typing.Union[ChallengeStatus, str]: try: return ChallengeStatus(v) except ValueError: return v
Ancestors
- genshin.models.starrail.chronicle.events.HSRBaseEvent
- APIModel
- pydantic.main.BaseModel
Class variables
var current_progress : int
var id : int
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var name : str
var rewards : Sequence[HSREventReward]
var show_text : str
var special_reward : Optional[HSREventReward]
var status : Union[ChallengeStatus, str]
var total_progress : int
var type : Union[ChallengeType, str]
class HSREvent (**data: Any)
-
HSR event model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class HSREvent(HSRBaseEvent): """HSR event model.""" id: int version: str name: str description: str = pydantic.Field(alias="panel_desc") type: typing.Union[HSREventType, str] = pydantic.Field(alias="act_type") time_type: typing.Union[HSREventTimeType, str] = pydantic.Field(alias="act_time_type") status: typing.Union[HSREventStatus, str] = pydantic.Field(alias="act_status") rewards: typing.Sequence[HSREventReward] = pydantic.Field(alias="reward_list") total_progress: int current_progress: int special_reward: typing.Optional[HSREventReward] is_after_version: bool """Whether the event happens after last version's update.""" all_finished: bool show_text: str # No clue what these are strategy: str multiple_drop_type: int multiple_drop_type_list: list[int] count_refresh_type: int count_value: int drop_multiple: int panel_id: int sort_weight: int @pydantic.field_validator("special_reward", mode="after") def __validate_special_reward(cls, v: HSREventReward) -> typing.Optional[HSREventReward]: if v.id == 0: return None return v @pydantic.field_validator("type", mode="before") def __validate_type(cls, v: str) -> typing.Union[HSREventType, str]: try: return HSREventType(v) except ValueError: return v @pydantic.field_validator("time_type", mode="before") def __validate_time_type(cls, v: str) -> typing.Union[HSREventTimeType, str]: try: return HSREventTimeType(v) except ValueError: return v @pydantic.field_validator("status", mode="before") def __validate_status(cls, v: str) -> typing.Union[HSREventStatus, str]: try: return HSREventStatus(v) except ValueError: return v
Ancestors
- genshin.models.starrail.chronicle.events.HSRBaseEvent
- APIModel
- pydantic.main.BaseModel
Class variables
var all_finished : bool
var count_refresh_type : int
var count_value : int
var current_progress : int
var description : str
var drop_multiple : int
var id : int
var is_after_version : bool
-
Whether the event happens after last version's update.
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var multiple_drop_type : int
var multiple_drop_type_list : list[int]
var name : str
var panel_id : int
var rewards : Sequence[HSREventReward]
var show_text : str
var sort_weight : int
var special_reward : Optional[HSREventReward]
var status : Union[HSREventStatus, str]
var strategy : str
var time_type : Union[HSREventTimeType, str]
var total_progress : int
var type : Union[HSREventType, str]
var version : str
class HSREventCalendar (**data: Any)
-
HSR event calendar model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class HSREventCalendar(APIModel): """HSR event calendar model.""" character_warps: typing.Sequence[EventWarp] = pydantic.Field(alias="avatar_card_pool_list") light_cone_warps: typing.Sequence[EventWarp] = pydantic.Field(alias="equip_card_pool_list") events: typing.Sequence[HSREvent] = pydantic.Field(alias="act_list") challenges: typing.Sequence[HSRChallenge] = pydantic.Field(alias="challenge_list") cur_game_version: str """Current game version.""" now: DateTimeField
Ancestors
- APIModel
- pydantic.main.BaseModel
Class variables
var challenges : Sequence[HSRChallenge]
var character_warps : Sequence[EventWarp]
var cur_game_version : str
-
Current game version.
var events : Sequence[HSREvent]
var light_cone_warps : Sequence[EventWarp]
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var now : datetime.datetime
class HSREventReward (**data: Any)
-
HSR event reward model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class HSREventReward(APIModel): """HSR event reward model.""" id: int = pydantic.Field(alias="item_id") name: str icon: str wiki_url: str num: int rarity: int
Ancestors
- APIModel
- pydantic.main.BaseModel
Class variables
var icon : str
var id : int
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var name : str
var num : int
var rarity : int
var wiki_url : str
class HSREventStatus (value, names=None, *, module=None, qualname=None, type=None, start=1)
-
Event status enum.
Expand source code
class HSREventStatus(Enum): """Event status enum.""" OTHER_LOCKED = "OtherActStatusUnopened" OTHER_IN_PROGRESS = "OtherActStatusUnFinish" DOUBLE_REWARDS_LOCKED = "DoubleActStatusUnopened" SIGN_IN_UNCLAIMED = "SignActStatusUnclaimed"
Ancestors
- enum.Enum
Class variables
var DOUBLE_REWARDS_LOCKED
var OTHER_IN_PROGRESS
var OTHER_LOCKED
var SIGN_IN_UNCLAIMED
class HSREventTimeType (value, names=None, *, module=None, qualname=None, type=None, start=1)
-
Event time type enum.
Expand source code
class HSREventTimeType(Enum): """Event time type enum.""" LONG = "ActTimeTypeLong" """Simulated universe.""" DEFAULT = "ActTimeTypeDefault"
Ancestors
- enum.Enum
Class variables
var DEFAULT
var LONG
-
Simulated universe.
class HSREventType (value, names=None, *, module=None, qualname=None, type=None, start=1)
-
Event type enum.
Expand source code
class HSREventType(Enum): """Event type enum.""" SIGN_IN = "ActivityTypeSign" """Daily sign-in event.""" OTHER = "ActivityTypeOther" DOUBLE_REWARDS = "ActivityTypeDouble" """Plannar Fissure, Garden of Plenty, etc."""
Ancestors
- enum.Enum
Class variables
var DOUBLE_REWARDS
-
Plannar Fissure, Garden of Plenty, etc.
var OTHER
var SIGN_IN
-
Daily sign-in event.
class TimeInfo (**data: Any)
-
Time info model.
Create a new model by parsing and validating input data from keyword arguments.
Raises [
ValidationError
][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.self
is explicitly positional-only to allowself
as a field name.Expand source code
class TimeInfo(APIModel): """Time info model.""" start: DateTimeField = pydantic.Field(alias="start_ts") end: DateTimeField = pydantic.Field(alias="end_ts") now: DateTimeField
Ancestors
- APIModel
- pydantic.main.BaseModel
Class variables
var end : datetime.datetime
var model_computed_fields
var model_config : pydantic.config.ConfigDict
var model_fields
var now : datetime.datetime
var start : datetime.datetime