Update with media alternative way
See original GitHub issueHey! Does API.Update_with_media()
works? I’m trying to reply tweets that have mentioned my profile, but isn’t work. My profile send the tweet with image, but not as a reply and just as a normal tweet.
If the method is deprecated, is there another way to reply tweets with a image?
def reply_tweet(tweet, message, img):
api.update_with_media(img, message, in_reply_to_status_id = tweet.id)
store_last_seen(FILE_NAME, tweet.id)
def main():
tweets = api.mentions_timeline(read_last_seen(FILE_NAME), tweet_mode='extended')
for tweet in reversed(tweets):
message = generate_message()
img = select_image_path()
reply_tweet(tweet, message, img)
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
71 Ways to Write a Social Media Update - Buffer
A deep dive into the specific ways to compose social media updates. Everything from capitalization, link placement, symbols, and more.
Read more >How to Stay Up-To-Date With the Latest Social Media Changes
Another way to use Twitter to stay up-to-date is by finding social media influencers and then adding them to a list.
Read more >26 Creative Ways to Publish Social Media Updates
Find 26 ways to publish updates on social media. ... Hashtagged events are popular and another good way to show your personality instead...
Read more >7 Ways To Update Your Social Media Business Profiles
1. Get Rid of Old Posts · 2. Implement Your Brand Colors · 3. Update Your Profile Picture w/ a Professional Headshot ·...
Read more >8 Types of Updates You Should Be Sharing With Your Social ...
They're the ultimate way to follow the concept that social media isn't a one-way medium meant for pushing content. It may seem frustrating...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
If you try posting a reply without an image you’ll notice you’re still not making a reply. You need to follow tweepy docs for adding reply target ID and twitter docs which say you must also include a handle for it to become a reply
Example
https://michaelcurrin.github.io/python-twitter-guide/#/code_snippets?id=create-a-reply
Yes the deprecated method does work, as you’ve said it posts images and since my own app uses it
If you read the Tweepy docs you’ll see a note that it is deprecated and what the recommended alternative is.
The preferred approach is to use api.upload_media and then attach the returned ID as part of the media_ids list parameter on the api.update_status method
Here are my noted about that
https://michaelcurrin.github.io/python-twitter-guide/#/code_snippets?id=tweet-a-message-with-media