From 5169bce9f0250e6eea3a078fe17aad4ffcd52a6f Mon Sep 17 00:00:00 2001 From: Harmon Date: Fri, 17 Mar 2023 09:09:18 -0500 Subject: [PATCH] Reorganize Streaming documentation --- docs/getting_started.rst | 30 ++++++++++++++++++++++++++++++ docs/index.rst | 2 +- docs/streaming.rst | 25 ------------------------- 3 files changed, 31 insertions(+), 26 deletions(-) diff --git a/docs/getting_started.rst b/docs/getting_started.rst index 3a3ea1c..b1e0552 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -64,3 +64,33 @@ The :ref:`authentication` page goes into more detail. More examples can be found on the :ref:`examples` page. +Streaming +========= + +Streams utilize Streaming HTTP protocol to deliver data through +an open, streaming API connection. Rather than delivering data in batches +through repeated requests by your client app, as might be expected from a REST +API, a single connection is opened between your app and the API, with new +results being sent through that connection whenever new matches occur. This +results in a low-latency delivery mechanism that can support very high +throughput. For further information, see +https://developer.twitter.com/en/docs/tutorials/consuming-streaming-data + +The Twitter API v1.1 streaming endpoints, `statuses/filter`_ and +`statuses/sample`_, have been deprecated and retired. + +.. note:: + + ``Stream`` and ``AsyncStream`` were deprecated in v4.13 and removed with + v4.14. + +:class:`StreamingClient` allows `filtering `_ and +`sampling `_ of realtime Tweets using Twitter API v2. + +.. _statuses/filter: https://twittercommunity.com/t/announcing-the-deprecation-of-v1-1-statuses-filter-endpoint/182960 +.. _statuses/sample: https://twittercommunity.com/t/deprecation-announcement-removing-compliance-messages-from-statuses-filter-and-retiring-statuses-sample-from-the-twitter-api-v1-1/170500 +.. _v2 filtering: https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/introduction +.. _v2 sampling: https://developer.twitter.com/en/docs/twitter-api/tweets/volume-streams/introduction + +The :ref:`streaming_guide` page goes into more detail. + diff --git a/docs/index.rst b/docs/index.rst index 5d7f0c3..3e02cbf 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -15,7 +15,6 @@ Contents: getting_started.rst authentication.rst logging.rst - streaming.rst .. toctree:: :caption: Twitter API v1.1 Reference @@ -40,6 +39,7 @@ Contents: expansions_and_fields.rst v2_models.rst v2_pagination.rst + streaming.rst .. toctree:: :caption: Meta diff --git a/docs/streaming.rst b/docs/streaming.rst index d359e35..5e8654e 100644 --- a/docs/streaming.rst +++ b/docs/streaming.rst @@ -6,31 +6,6 @@ Streaming ********* -Streams utilize Streaming HTTP protocol to deliver data through -an open, streaming API connection. Rather than delivering data in batches -through repeated requests by your client app, as might be expected from a REST -API, a single connection is opened between your app and the API, with new -results being sent through that connection whenever new matches occur. This -results in a low-latency delivery mechanism that can support very high -throughput. For further information, see -https://developer.twitter.com/en/docs/tutorials/consuming-streaming-data - -The Twitter API v1.1 streaming endpoints, `statuses/filter`_ and -`statuses/sample`_, have been deprecated and retired. - -.. note:: - - ``Stream`` and ``AsyncStream`` were deprecated in v4.13 and removed with - v4.14. - -:class:`StreamingClient` allows `filtering `_ and -`sampling `_ of realtime Tweets using Twitter API v2. - -.. _statuses/filter: https://twittercommunity.com/t/announcing-the-deprecation-of-v1-1-statuses-filter-endpoint/182960 -.. _statuses/sample: https://twittercommunity.com/t/deprecation-announcement-removing-compliance-messages-from-statuses-filter-and-retiring-statuses-sample-from-the-twitter-api-v1-1/170500 -.. _v2 filtering: https://developer.twitter.com/en/docs/twitter-api/tweets/filtered-stream/introduction -.. _v2 sampling: https://developer.twitter.com/en/docs/twitter-api/tweets/volume-streams/introduction - Using :class:`StreamingClient` ============================== -- 2.25.1