Skip to content

Instantly share code, notes, and snippets.

@Andygmb
Created August 3, 2019 04:39
Show Gist options
  • Save Andygmb/8e9efed60c17d05065e5b2d04b79fa93 to your computer and use it in GitHub Desktop.
Save Andygmb/8e9efed60c17d05065e5b2d04b79fa93 to your computer and use it in GitHub Desktop.
Update your twitter header and profile image with the twitter API to avoid twitter's default compression
import twitter
from PIL import Image
api = twitter.Api(consumer_key="REPLACE_ME",
consumer_secret="REPLACE_ME",
access_token_key="REPLACE_ME",
access_token_secret="REPLACE_ME")
api.UpdateBanner(image='twitter_header_image.png')
api.UpdateImage(image='twitter_profile_image.png')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment