GET user_timeline from Twitter

1 posts, 0 answers
  1. Thomas
    Thomas avatar
    4 posts
    Member since:
    Aug 2012

    Posted 17 Oct 2012 Link to this post

    Hi,

    I want to stream a users timeline from twitter into a listview. I have tried to do this using the pull to refresh - scroll to load example and querying the username instead of html5. However this doesn't return all the users tweets only tweets up-to a certain date (17/10/2012 - 09/10/2012 no later!). So I changed the datasource to the code below:

    var dataSource = new kendo.data.DataSource({
        serverPaging: true,
        pageSize: 10,
        transport: {
            read: {
                // the remote service url
     
                // JSONP is required for cross-domain AJAX
                dataType: "jsonp",
     
                // additional parameters sent to the remote service
                data: {
                    screen_name: "USER_ID"
                }
            }
        },
        schema: { // describe the result format
            data: "results" // the data which the data source will be bound to is in the "results" field
        }
    });

    This doesn't work and nothing loads! I can't work out what's different from this apart from using 'screen_name' instead of 'q'. The query works if you put it into your browser: "https://api.twitter.com/1/statuses/user_timeline.json?screen_name=USER_ID". 

    The documentation from Twitter can be found here: https://dev.twitter.com/docs/api/1/get/statuses/user_timeline

    What is wrong? Why isn't it working?

    Thanks,
    Thomas
Back to Top