I am using Twitter API version 1 and replacing them to v1.1.
Then I cannot find users/profile_image/:screen_name API on version 1.1.
https://api.twitter.com/1/users/profile_image/shonanshachu
Does anyone know which API can be the best practice for replacing users/profile_image?
What I want is list of profile images or simple url with parameter of Twitter ID or screen name.
listed_count : The number of public lists the account has been added to. created_at : The time at which the account was created.
Go to your profile and tap Edit Profile. Tap on your profile photo. Upload or select the photo you want.
Check the dimensions. Recommended dimensions for profile images are 400x400 pixels. Recommended dimensions for header images are 1500x500 pixels.
Profile banners allow users to further customize the expressiveness of their profiles. Use POST account/update_profile_banner to upload a profile banner on behalf of a user. Profile banners come in a variety of display-enhanced sizes.
Maybe this will be useful for you. Those calls return all the info you need, including the image link. If you need only one user's image for a given user_id or user_screen, then you can read more from here: https://dev.twitter.com/docs/user-profile-images-and-banners
https://api.twitter.com/1.1/followers/list.json (you can replace followers with friends)
I haven't found a great solution to this yet. The closest thing I have found is the twitter API 1.1 docs for users/show, but that is an authenticated call (requiring a user context) which is rate-limited (180 requests per 15 minutes). They mention this about getting the profile image url on the page about uploading a new photo:
You can either update your local cache the next time you request the user's information, or, at least 5 seconds after uploading the image, ask for the updated URL using GET users/show.
I imagine once the 1.0 API is shut off in March 2013, this question will get a lot of votes. :)
There are some hints that twitter is adding methods to their API to aid in retrieving images. We'll have to wait and see.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With