|
24 | 24 |
|
25 | 25 | from __future__ import annotations
|
26 | 26 |
|
27 |
| -from datetime import datetime |
28 |
| -from typing import Literal, Optional, TypedDict, Union |
| 27 | +from typing import Literal, Optional, TypedDict |
29 | 28 |
|
30 |
| -from .channel import StageChannel, VoiceChannel |
31 |
| -from .guild import Guild |
32 | 29 | from .member import Member
|
33 | 30 | from .snowflake import Snowflake
|
34 | 31 | from .user import User
|
|
38 | 35 | ScheduledEventPrivacyLevel = Literal[2]
|
39 | 36 |
|
40 | 37 |
|
41 |
| -class ScheduledEventLocation(TypedDict): |
42 |
| - value: Union[StageChannel, VoiceChannel, str] |
43 |
| - type: ScheduledEventLocationType |
44 |
| - |
45 |
| - |
46 | 38 | class ScheduledEvent(TypedDict):
|
47 | 39 | id: Snowflake
|
48 |
| - guild: Guild |
| 40 | + guild_id: Snowflake |
| 41 | + channel_id: Snowflake |
| 42 | + creator_id: Snowflake |
49 | 43 | name: str
|
50 | 44 | description: str
|
51 | 45 | image: Optional[str]
|
52 |
| - start_time: datetime |
53 |
| - end_time: Optional[datetime] |
54 |
| - status: ScheduledEventStatus |
55 |
| - subscriber_count: Optional[int] |
56 |
| - creator_id: Snowflake |
57 |
| - creator: Optional[User] |
58 |
| - location: ScheduledEventLocation |
| 46 | + scheduled_start_time: str |
| 47 | + scheduled_end_time: Optional[str] |
59 | 48 | privacy_level: ScheduledEventPrivacyLevel
|
| 49 | + status: ScheduledEventStatus |
| 50 | + entity_type: ScheduledEventLocationType |
| 51 | + entity_id: Snowflake |
| 52 | + entity_metadata: ScheduledEventEntityMetadata |
| 53 | + creator: User |
| 54 | + user_count: Optional[int] |
| 55 | + |
| 56 | + |
| 57 | +class ScheduledEventEntityMetadata(TypedDict): |
| 58 | + location: str |
60 | 59 |
|
61 | 60 |
|
62 |
| -class ScheduledEventSubscriber(User): |
| 61 | +class ScheduledEventSubscriber(TypedDict): |
| 62 | + guild_scheduled_event_id: Snowflake |
| 63 | + user: User |
63 | 64 | member: Optional[Member]
|
0 commit comments