aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLorenz Diener <[email protected]>2017-05-19 10:07:47 +0200
committerGitHub <[email protected]>2017-05-19 10:07:47 +0200
commitdd77dff7ba8581bdf36035ac91fd556acd9e2a50 (patch)
tree1f358dc437b201ed482558d8d70d0138ca072288
parent893ff2e1348d3be512f27120ae3fd1ef55fadb95 (diff)
parentc57ad7f6b949f31b288f2676f0a30e745c732ca0 (diff)
downloadmastodon.py-dd77dff7ba8581bdf36035ac91fd556acd9e2a50.tar.gz
Merge pull request #49 from fumi-san/master
Add local_stream method for getting local streaming timeline.
-rw-r--r--mastodon/Mastodon.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/mastodon/Mastodon.py b/mastodon/Mastodon.py
index 3b00f37..fc3af85 100644
--- a/mastodon/Mastodon.py
+++ b/mastodon/Mastodon.py
@@ -735,6 +735,16 @@ class Mastodon:
735 """ 735 """
736 return self.__stream('/api/v1/streaming/public', listener) 736 return self.__stream('/api/v1/streaming/public', listener)
737 737
738 def local_stream(self, listener):
739 """
740 Streams local events. 'listener' should be a subclass of
741 StreamListener.
742
743 This method blocks forever, calling callbacks on 'listener' for
744 incoming events.
745 """
746 return self.__stream('/api/v1/streaming/public/local', listener)
747
738 def hashtag_stream(self, tag, listener): 748 def hashtag_stream(self, tag, listener):
739 """ 749 """
740 Returns all public statuses for the hashtag 'tag'. 'listener' should be 750 Returns all public statuses for the hashtag 'tag'. 'listener' should be
Powered by cgit v1.2.3 (git 2.41.0)