@@ -330,52 +330,98 @@ def unban_user(
330330 def accept_invite (
331331 self , user_id : str , ** data : Any
332332 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
333+ """
334+ Accepts an invitation to this channel.
335+ """
333336 pass
334337
335338 @abc .abstractmethod
336339 def reject_invite (
337340 self , user_id : str , ** data : Any
338341 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
342+ """
343+ Rejects an invitation to this channel.
344+ """
339345 pass
340346
341347 @abc .abstractmethod
342348 def send_file (
343349 self , url : str , name : str , user : Dict , content_type : str = None
344350 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
351+ """
352+ Uploads a file.
353+ This functionality defaults to using the Stream CDN. If you would like, you can
354+ easily change the logic to upload to your own CDN of choice.
355+ """
345356 pass
346357
347358 @abc .abstractmethod
348359 def send_image (
349360 self , url : str , name : str , user : Dict , content_type : str = None
350361 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
362+ """
363+ Uploads an image.
364+ Stream supported image types are: image/bmp, image/gif, image/jpeg, image/png, image/webp,
365+ image/heic, image/heic-sequence, image/heif, image/heif-sequence, image/svg+xml.
366+ You can set a more restrictive list for your application if needed.
367+ The maximum file size is 100MB.
368+ """
351369 pass
352370
353371 @abc .abstractmethod
354372 def delete_file (self , url : str ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
373+ """
374+ Deletes a file by file url.
375+ """
355376 pass
356377
357378 @abc .abstractmethod
358379 def delete_image (
359380 self , url : str
360381 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
382+ """
383+ Deletes an image by image url.
384+ """
361385 pass
362386
363387 @abc .abstractmethod
364388 def hide (self , user_id : str ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
389+ """
390+ Removes a channel from query channel requests for that user until a new message is added.
391+ Use `show` to cancel this operation.
392+ """
365393 pass
366394
367395 @abc .abstractmethod
368396 def show (self , user_id : str ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
397+ """
398+ Shows a previously hidden channel.
399+ Use `hide` to hide a channel.
400+ """
369401 pass
370402
371403 @abc .abstractmethod
372404 def mute (
373405 self , user_id : str , expiration : int = None
374406 ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
407+ """
408+ Mutes a channel.
409+ Messages added to a muted channel will not trigger push notifications, nor change the
410+ unread count for the users that muted it. By default, mutes stay in place indefinitely
411+ until the user removes it; however, you can optionally set an expiration time. The list
412+ of muted channels and their expiration time is returned when the user connects.
413+ """
375414 pass
376415
377416 @abc .abstractmethod
378417 def unmute (self , user_id : str ) -> Union [StreamResponse , Awaitable [StreamResponse ]]:
418+ """
419+ Unmutes a channel.
420+ Messages added to a muted channel will not trigger push notifications, nor change the
421+ unread count for the users that muted it. By default, mutes stay in place indefinitely
422+ until the user removes it; however, you can optionally set an expiration time. The list
423+ of muted channels and their expiration time is returned when the user connects.
424+ """
379425 pass
380426
381427
0 commit comments