@@ -780,12 +780,10 @@ async def edit(
780
780
default_thread_slowmode_delay : int = ...,
781
781
type : ChannelType = ...,
782
782
overwrites : Mapping [Role | Member | Snowflake , PermissionOverwrite ] = ...,
783
- ) -> TextChannel | None :
784
- ...
783
+ ) -> TextChannel | None : ...
785
784
786
785
@overload
787
- async def edit (self ) -> TextChannel | None :
788
- ...
786
+ async def edit (self ) -> TextChannel | None : ...
789
787
790
788
async def edit (self , * , reason = None , ** options ):
791
789
"""|coro|
@@ -868,6 +866,8 @@ async def create_thread(
868
866
message : Snowflake | None = None ,
869
867
auto_archive_duration : ThreadArchiveDuration = MISSING ,
870
868
type : ChannelType | None = None ,
869
+ slowmode_delay : int | None = None ,
870
+ invitable : bool | None = None ,
871
871
reason : str | None = None ,
872
872
) -> Thread :
873
873
"""|coro|
@@ -894,6 +894,12 @@ async def create_thread(
894
894
The type of thread to create. If a ``message`` is passed then this parameter
895
895
is ignored, as a thread created with a message is always a public thread.
896
896
By default, this creates a private thread if this is ``None``.
897
+ slowmode_delay: Optional[:class:`int`]
898
+ Specifies the slowmode rate limit for users in this thread, in seconds.
899
+ A value of ``0`` disables slowmode. The maximum value possible is ``21600``.
900
+ invitable: Optional[:class:`bool`]
901
+ Whether non-moderators can add other non-moderators to this thread.
902
+ Only available for private threads, where it defaults to True.
897
903
reason: :class:`str`
898
904
The reason for creating a new thread. Shows up on the audit log.
899
905
@@ -920,6 +926,8 @@ async def create_thread(
920
926
auto_archive_duration = auto_archive_duration
921
927
or self .default_auto_archive_duration ,
922
928
type = type .value ,
929
+ rate_limit_per_user = slowmode_delay or 0 ,
930
+ invitable = invitable ,
923
931
reason = reason ,
924
932
)
925
933
else :
@@ -929,6 +937,7 @@ async def create_thread(
929
937
name = name ,
930
938
auto_archive_duration = auto_archive_duration
931
939
or self .default_auto_archive_duration ,
940
+ rate_limit_per_user = slowmode_delay or 0 ,
932
941
reason = reason ,
933
942
)
934
943
@@ -1079,12 +1088,10 @@ async def edit(
1079
1088
available_tags : list [ForumTag ] = ...,
1080
1089
require_tag : bool = ...,
1081
1090
overwrites : Mapping [Role | Member | Snowflake , PermissionOverwrite ] = ...,
1082
- ) -> ForumChannel | None :
1083
- ...
1091
+ ) -> ForumChannel | None : ...
1084
1092
1085
1093
@overload
1086
- async def edit (self ) -> ForumChannel | None :
1087
- ...
1094
+ async def edit (self ) -> ForumChannel | None : ...
1088
1095
1089
1096
async def edit (self , * , reason = None , ** options ):
1090
1097
"""|coro|
@@ -1823,12 +1830,10 @@ async def edit(
1823
1830
video_quality_mode : VideoQualityMode = ...,
1824
1831
slowmode_delay : int = ...,
1825
1832
reason : str | None = ...,
1826
- ) -> VoiceChannel | None :
1827
- ...
1833
+ ) -> VoiceChannel | None : ...
1828
1834
1829
1835
@overload
1830
- async def edit (self ) -> VoiceChannel | None :
1831
- ...
1836
+ async def edit (self ) -> VoiceChannel | None : ...
1832
1837
1833
1838
async def edit (self , * , reason = None , ** options ):
1834
1839
"""|coro|
@@ -2448,12 +2453,10 @@ async def edit(
2448
2453
rtc_region : VoiceRegion | None = ...,
2449
2454
video_quality_mode : VideoQualityMode = ...,
2450
2455
reason : str | None = ...,
2451
- ) -> StageChannel | None :
2452
- ...
2456
+ ) -> StageChannel | None : ...
2453
2457
2454
2458
@overload
2455
- async def edit (self ) -> StageChannel | None :
2456
- ...
2459
+ async def edit (self ) -> StageChannel | None : ...
2457
2460
2458
2461
async def edit (self , * , reason = None , ** options ):
2459
2462
"""|coro|
@@ -2627,12 +2630,10 @@ async def edit(
2627
2630
nsfw : bool = ...,
2628
2631
overwrites : Mapping [Role | Member , PermissionOverwrite ] = ...,
2629
2632
reason : str | None = ...,
2630
- ) -> CategoryChannel | None :
2631
- ...
2633
+ ) -> CategoryChannel | None : ...
2632
2634
2633
2635
@overload
2634
- async def edit (self ) -> CategoryChannel | None :
2635
- ...
2636
+ async def edit (self ) -> CategoryChannel | None : ...
2636
2637
2637
2638
async def edit (self , * , reason = None , ** options ):
2638
2639
"""|coro|
0 commit comments