import tweepy CONSUMER_KEY = 'My key' CONSUMER_SECRET = 'My secret' ACCESS_KEY = 'my key' ACCESS_SECRET = 'my secret' auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET) auth.set_access_token(ACCESS_KEY, ACCESS_SECRET) api = tweepy.API(auth) try: api.verify_credentials() print("Authentication OK") except: print("Error during authentication") api.update_status("Hello")
Obviously at the top I don't actually have my secret, my key, etc. up there, but I have the actual keys and it connects just fine. The problem is I keep getting an error whenever I try to send the tweet hello. Can anyone help?
https://stackoverflow.com/questions/66501106/status-is-a-duplicate-error-i-m-trying-to-make-my-bot-post-a-tweet-but-it-s-no March 06, 2021 at 08:09AM
没有评论:
发表评论