From: Qin Yu Date: Fri, 11 Nov 2022 22:02:48 +0000 (+0100) Subject: Update Direct Message events' expansions in docs/expansions_and_fields.rst X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=b5cf70381ba72a4e3d4040fcc548c629751f3ce5;p=tweepy.git Update Direct Message events' expansions in docs/expansions_and_fields.rst For consistency, this section should also be taken from the description for the expansions parameter for endpoints that return the object type, e.g. https://developer.twitter.com/en/docs/twitter-api/direct-messages/lookup/api-reference/get-dm_conversations-with-participant_id-dm_events for DM events. Future work: improve this section of the documentation in the future to include information like this from https://developer.twitter.com/en/docs/twitter-api/expansions Co-authored-by: Harmon --- diff --git a/docs/expansions_and_fields.rst b/docs/expansions_and_fields.rst index 3eb19d1..34f1421 100644 --- a/docs/expansions_and_fields.rst +++ b/docs/expansions_and_fields.rst @@ -41,18 +41,13 @@ using this parameter: * Attached place’s object * Any referenced Tweets’ object -For methods that returns DirectMessageEvents, the following data objects can be -expanded using this parameter: +For methods that returns Direct Message conversation events, the following data +objects can be expanded using this parameter: -* ``sender_id`` - The ID of the account that sent the message, or who invited -a participant to a group conversation -* ``partricipants_ids`` - An array of account IDs. For ParticipantsJoin and -ParticipantsLeave events this array will contain a single ID of the account -that created the event -* ``attachments`` - Provides media IDs for content that has been uploaded to -Twitter by the sender -* ``referenced_tweets`` - If a Tweet URL is found in the text field, the ID of -that Tweet is included in the response +* The user object for the message sender. +* Attached media's object. +* Any referenced Tweet's object. +* The user object for who is joining or leaving group conversations. At this time, the only expansion available to endpoints that primarily return user objects is ``expansions=pinned_tweet_id``. You will find the expanded