Update and improve documentation for API.list_direct_messages
authorHarmon <Harmon758@gmail.com>
Thu, 27 May 2021 11:56:35 +0000 (06:56 -0500)
committerHarmon <Harmon758@gmail.com>
Thu, 27 May 2021 11:56:35 +0000 (06:56 -0500)
tweepy/api.py

index 2f33b8c7516ac57ad3b20d83635952c1d5746392..3c0e40c5eeead0c3e3fafd06a979a6436e07e884 100644 (file)
@@ -3183,12 +3183,20 @@ class API:
         Returns all Direct Message events (both sent and received) within the
         last 30 days. Sorted in reverse-chronological order.
 
-        :param count: |count|
-        :param cursor: |cursor|
+        Parameters
+        ----------
+        count
+            |count|
+        cursor
+            |cursor|
 
-        :rtype: list of :class:`DirectMessage` objects
+        Returns
+        -------
+        :py:class:`List`\ [:class:`~tweepy.models.DirectMessage`]
 
-        :reference: https://developer.twitter.com/en/docs/twitter-api/v1/direct-messages/sending-and-receiving/api-reference/list-events
+        References
+        ----------
+        https://developer.twitter.com/en/docs/twitter-api/v1/direct-messages/sending-and-receiving/api-reference/list-events
         """
         return self.request(
             'GET', 'direct_messages/events/list', endpoint_parameters=(