Cannot access /statuses/user_timeline anymore

shortmagic
@shortmagic Mig

Hello,

I use this sort of API call on a couple of websites:
/statuses/user_timeline.json?count=10&exclude_replies=true&screen_name=THE_SCREEN_NAME

But it stopped working very recently.
Now I get this error for any screen_name I use:
{"errors":[{"message":"Sorry, that page does not exist","code":34}]}

Did something change in the procedure? Or is there any other problem?

Thank you for your help,
Mig

1 year 26 weeks ago

Replies

joeysmit28
@joeysmit28 Joey Smit

Same problem here. Stopped working on all sites I maintain.

edit: It stopped working around yesterday afternoon (+1GMT).

1 year 26 weeks ago
PhantasiAeterna
@PhantasiAeterna Phantasia Aeterna

I have same problem, hope it's just some kind of maintenance...

1 year 26 weeks ago
mcairo
@mcairo Marcelo Cairo

I have the same problem here.

1 year 26 weeks ago
yurls
@yurls YURLS.net

same problem here http://www.yurls.net/nl/

1 year 26 weeks ago
hgreif
@hgreif Hillel Greif

Thank you so much. Looked everywhere for a quick fix. Wow...can they make it more difficult to find an answer. Seriously appreciate your posting this.

1 year 14 weeks ago
soulstudio_info
@soulstudio_info Mihovil Mikulec

Same here... We sure could use some official answer on this one. Is this just temporary (maintenance, as someone mentioned) or do we need to use Oauth from now on ??

1 year 26 weeks ago
soulstudio_info
@soulstudio_info Mihovil Mikulec

Just found this -> https://dev.twitter.com/discussions/11564 We are forced to use OAuth for all methods in API v1.1, including user timeline, according to @episod

This just sucks. :(

1 year 26 weeks ago
lsascha
@lsascha Sascha Löffler

If all of you are still using the old API url, it seems they disabled the old url. the current deprecated API can be accessed with https://api.twitter.com/1/

so the new URL looks like https://api.twitter.com/1/statuses/user_timeline/jbrooksuk.json

But i would recommend to switch to API v1.1 as soon as possible as Twitter will remove the v1 API in the near future.

Hope this helps.

1 year 26 weeks ago
SBTDev
@SBTDev SBTDev

Also having this issue. I have 3 published PHP apps that all relied on this now-broken feature. I find it extremely silly to need OAuth and the hassle that goes with it to read PUBLIC information.

As is likely the case with most others, I had zero notice on the change...

1 year 26 weeks ago
episod
@episod Taylor Singletary

API v1 is still active until March 2013. You don't need to use OAuth with API v1.

"API v0" URLs, which have been announced as deprecated for a number of years now, were retired from service yesterday. If you were using the API with an outdated, unversioned URL or one without the api subdomain, your requests will now return a 404.

See Following up on API housekeeping for more information.

1 year 26 weeks ago
shortmagic
@shortmagic Mig

Thanks @episod.

For those who want a quick answer, you have to use this kind of URL now:
http://api.twitter.com/1/statuses/user_timeline.json?count=10&exclude_replies=true&screen_name=THE_SCREEN_NAME

So you must specify the "api" subdomain and the API version at the beginning of the path.

Bye,
mig

1 year 26 weeks ago
rwilk
@rwilk Robert Wilkins

This is the code that used to work for me, have no idea how to resolve...

  1. <script type="text/javascript">
  2. $(document).ready(function() {
  3.       $('#tweets').jtwt({image_size : 20, count : 10, username: 'username', convert_links : 1, loader_text : 'loading new tweets...'});   
  4. });                      
  5. </script>
  6.  
  7. <script type="text/javascript">
  8. $(document).ready(function() {  
  9.         $("#tweets").draggable();
  10. });                      
  11. </script>
1 year 26 weeks ago
soulstudio_info
@soulstudio_info Mihovil Mikulec

You are also using the URL that looks like http://twitter.com/statuses/user_timeline/your_username.json.... Replace it with https://api.twitter.com/1/statuses/user_timeline/your_username.json.... That should do the trick. :)

1 year 26 weeks ago
shortmagic
@shortmagic Mig

@rwilk Your snippet of javascript shows that you use a jQuery plugin which calls twitter for you.
It does it by adding the jtwt function.

You could go and grab the new version of that plugin (it is most likely updated yet).
If it is not the case, you can contact the author.

Worst case scenario, I suggest that you look at the code of the plugin, it shouldn't be very hard to spot the place where you can update this.

I am saying "worst case scenario" because it is always better to contribute by contacting the author and maybe submit a patch him. But sometimes you're in a hurry and some open source developers are quite busy and don't reply straight away.

mig

1 year 26 weeks ago
k_maier
@k_maier Kristopher Maier

I am also having a problem with the blogger.js example..

  1. <!--<script src="http://twitter.com/javascripts/blogger.js" type="text/javascript"></script>-->
  2. \<!--<script src="http://twitter.com/statuses/user_timeline/VisitOzaukee.json?callback=twitterCallback2&count=1" type="text/javascript"></script>-->
  3.  
  4.     <script src="https://api.twitter.com/1/javascripts/blogger.js" type="text/javascript"></script>
  5.    <script src="https://api.twitter.com/1/statuses/user_timeline/VisitOzaukee.json" type="text/javascript"></script>

is this no longer a valid way to display a tweet on a page?

1 year 26 weeks ago
episod
@episod Taylor Singletary

The blogger.js URL you don't want to change -- it's not strictly an API. Try this combo:

  1.     <script src="https://twitter.com/javascripts/blogger.js" type="text/javascript"></script>
  2.    <script src="https://api.twitter.com/1/statuses/user_timeline/VisitOzaukee.json" type="text/javascript"></script>
1 year 26 weeks ago
AxWax
@AxWax AxWax

I'm afraid the above code does not work - and trying to access the Twitter Badge Widget (which the blogger.js method was based off) doesn't either: https://twitter.com/settings/widgets
(try clicking 'create new')
Shouldn't Twitter at least make sure their own code is updated before switching off deprecated methods?

1 year 25 weeks ago
AxWax
@AxWax AxWax

For anyone else tearing their hair out about this - the essential info the above post was missing is the URL parameter callback=twitterCallback2

1 year 25 weeks ago
mcbabycrusher
@mcbabycrusher Curtiss Taylor

Thank You! Worked Perfectly!

1 year 24 weeks ago
brainwipe
@brainwipe Rob Lang

This worked for me on blogger, thank you!

1 year 23 weeks ago
k_maier
@k_maier Kristopher Maier

thanks, I had tried that with no luck.

Found a different solution here:
http://www.queness.com/post/8567/create-a-dead-simple-twitter-feed-with-jquery

1 year 26 weeks ago
Joses_Coffee
@Joses_Coffee Joses Gourmet Coffee

It is really easy to solve this problem, take a look to my page www.josesgourmetcoffee.com

you have to change your address to the new one.

https://api.twitter.com/1/statuses/user_timeline/YOUR-USER-NAME.xml
or
https://api.twitter.com/1/statuses/user_timeline/YOU-USER-NAME.json

Hope this work for you.

1 year 25 weeks ago
esibercom
@esibercom E-Siber.com

I tried "https://api.twitter.com/1/statuses/user_timeline/username.json" instead of "http://twitter.com/statuses/user_timeline/esibercom.json". And it worked very well in:

  1. <ul id="twitter_update_list" style="margin-top: -15px;"><li></li></ul></div>
  2. <script type="text/javascript" src="http://twitter.com/javascripts/blogger.js"></script>
  3. <script type="text/javascript" src="https://api.twitter.com/1/statuses/user_timeline/esibercom.json?callback=twitterCallback2&amp;count=5"></script>
1 year 22 weeks ago
hubenet
@hubenet Theo Hubenet

I used the jQuery getJSON method to read my user_timeline: https://api.twitter.com/1/statuses/user_timeline.json?callback=?&exclude_replies=true&include_entities=true&include_rts=true&screen_name=hubenet&count=8
The trick that made it work for me is wrapping the json string like this:

  1. <?php
  2. $sJSON = file_get_contents('https://api.twitter.com/1/statuses/user_timeline.json?callback=?&exclude_replies=true&include_entities=true&include_rts=true&screen_name=hubenet&count=8');
  3. echo '{"results":'.$sJSON.'}';
  4. ?>

And using the http://jquery.malsup.com cycle2 plugin to display:

  1. var request = '/test.php'; // the json retrieved php
  2.  
  3.        $.getJSON(request, function(json) {
  4.             var tweets = $('#tweets');
  5.            $.each(json.results, function(i) {
  6.              var tweet = this, text = tweet.text;
  7.                if(tweet.retweeted_status) {
  8.                    profile_image = tweet.retweeted_status.user.profile_image_url;
  9.              }
  10.               else {
  11.                  profile_image = tweet.user.profile_image_url;
  12.               }
  13.               text = text.replace(/(http:\/\/\S+)/g, '<a href="$1" target="_blank">$1</a>');
  14.                text = text.replace(/\@(\w+)/g, '<a href="http://twitter.com/$1">@$1</a>');
  15.                 tweets.append( '<p><img align="left" hspace="15" src="' + profile_image + '">' + text + '</p>' );
  16.             });
  17.             tweets.cycle();
1 year 21 weeks ago
hdptrd
@hdptrd atreda wicaksi

thanks.. it's works!!

1 year 12 weeks ago
omendragangwar
@omendragangwar Omendra Gangwar

I am trying this link https://twitter.com/statuses/user_timeline/om.json?callback=twitterCallback2&count=10

Error is given below:-

twittercallback2({"errors":[{"message":"Sorry, that page does not exist","code":34}]});

1 year 12 weeks ago
episod
@episod Taylor Singletary

Unversioned URLs are retired. You want to move to API v1.1 and OAuth 1.0A: Current status: API v1.1

1 year 12 weeks ago
MrGood238
@MrGood238 Mr Good

Hi, i'm use URL "http://twitter.com/statuses/user_timeline/username.json" but its not working.

1 year 10 weeks ago
episod
@episod Taylor Singletary

See other posts by me in this thread for information on why this is.

1 year 10 weeks ago
Metronomezine
@Metronomezine metrono.me

So now that March 5 has passed, how would I embed a twitter status update on my page? Before it was

  1. <script type="text/javascript" src="http://twitter.com/javascripts/blogger.js"></script>
  2. <script type="text/javascript" src="http://twitter.com/statuses/user_timeline/metronomezine.json?callback=twitterCallback2&amp;count=5"></script>

How would I change this to make it work?

1 year 6 weeks ago
episod
@episod Taylor Singletary

See Embedded Timelines for information on the widgets that replace those older ones.

1 year 6 weeks ago
mattmaber
@mattmaber Matt Maber

And if one just wants a simple tweet, no bells and whistles one has to jump through the OAuth hoop?

ANy chance of simple instructions to replace those simple 2 lines? Ive even got my own OAuth JSON using http://www.webdevdoor.com/php/authenticating-twitter-feed-timeline-oauth/ but it wont drop and replace the old v1 url in the second line.

SHame you cant keep this simple guys.

41 weeks 1 day ago
mattmaber
@mattmaber Matt Maber

I got it workng thanks to the webdevdoor, but seriously guys, you need to think about who may be using this and not try to force us into using your hokey chromed UI crap. K I S S.

41 weeks 8 hours ago
livepokeri
@livepokeri Livepokeri

This is good tutorial about v1.1 timeline
http://vancebell.com/blog/twitter-widget-or-feed-not-working-update-to-use-twitter-api-1-1/

40 weeks 4 days ago
Neocsatornaja

This script not working enymore:

  1. (function(a){a.fn.dpSocialFeedr=function(b){var c;c=a.extend({},a.fn.dpSocialFeedr.defaults,b);general_vars=a.extend({},a.fn.dpSocialFeedr.general_vars,b);var d=c.twitter,e=c.facebook_page,f=c.delicious,g=c.flickr,h=c.tumblr,i=c.youtube,j=c.dribbble,k=c.digg,l=c.pinterest,m=c.total,n=c.displayStyle,o=c.showIcons,p=c.fadeSpeed,q=c.feedPause,r=c.fadeAutohover,s=c.fadeAutoheight,t=c.addColorbox;a.fn.dpSocialFeedr.general_vars.social[0]={name:d,url:"http://twitter.com/statuses/user_timeline/"+d+".rss",favicon:"http://www.twitter.com/favicon.ico"};

Can help anybody how can fix it?

32 weeks 1 day ago
episod
@episod Taylor Singletary

It's not really code that can be fixed. You have to take a completely alternative approach, such as using our Embedded Timelines or working with the API from a server.

32 weeks 1 day ago