How to find the exact time of tweets


The Twitter API returns UTC time of the tweet [1] while we see the tweet in our timeline in our local time (in my case, UTC+1). The original time of the tweet published by the author should be UTC time - utc_offset/3600 = 00:14:52 - 7hours = 17:14:52 on Thursday April [2, 3].

{"created_at":"Fri Apr 15 00:14:52 +0000 2016","id":720767307794911232,"id_str":"720767307794911232","text":"A big welcome to Twitter, @KathyChen2016! She joins us as our MD for China!","entities":{"hashtags":[],"symbols":[],"user_mentions":[{"screen_name":"kathychen2016","name":"Kathy_Chen","id":715507198365839361,"id_str":"715507198365839361","indices":[26,40]}],"urls":[]},"truncated":false,"source":"\u003ca href=\"http:\/\/twitter.com\/download\/iphone\" rel=\"nofollow\"\u003eTwitter for iPhone\u003c\/a\u003e","in_reply_to_status_id":null,"in_reply_to_status_id_str":null,"in_reply_to_user_id":null,"in_reply_to_user_id_str":null,"in_reply_to_screen_name":null,"user":{"id":12,"id_str":"12","name":"Jack","screen_name":"jack","location":"California, USA","description":"#withMalala!","url":null,"entities":{"description":{"urls":[]}},"protected":false,"followers_count":3524565,"friends_count":1933,"listed_count":26141,"created_at":"Tue Mar 21 20:50:14 +0000 2006","favourites_count":12446,"utc_offset":-25200,"time_zone":"Pacific Time (US & Canada)","geo_enabled":true,"verified":true,"statuses_count":19482,"lang":"en","contributors_enabled":false,"is_translator":false,"is_translation_enabled":false,"profile_background_color":"EBEBEB","profile_background_image_url":"http:\/\/abs.twimg.com\/images\/themes\/theme7\/bg.gif","profile_background_image_url_https":"https:\/\/abs.twimg.com\/images\/themes\/theme7\/bg.gif","profile_background_tile":false,"profile_image_url":"http:\/\/pbs.twimg.com\/profile_images\/668328458519384064\/FSAIjKRl_normal.jpg","profile_image_url_https":"https:\/\/pbs.twimg.com\/profile_images\/668328458519384064\/FSAIjKRl_normal.jpg","profile_link_color":"990000","profile_sidebar_border_color":"DFDFDF","profile_sidebar_fill_color":"F3F3F3","profile_text_color":"333333","profile_use_background_image":true,"has_extended_profile":true,"default_profile":false,"default_profile_image":false,"following":false,"follow_request_sent":false,"notifications":false},"geo":null,"coordinates":null,"place":null,"contributors":null,"is_quote_status":false,"retweet_count":150,"favorite_count":397,"favorited":false,"retweeted":false,"lang":"en"}

Current rate limit for looking up tweet object based on tweet id [4]:



[2]. http://www.adweek.com/socialtimes/tweet-timestamps/456093

[3]. http://stackoverflow.com/questions/6217056/twitter-timezone-created-at-utc-time-values-to-calculate-what-time-zone-the

[4]. https://dev.twitter.com/rest/reference/get/statuses/show/%3Aid

No comments:

Post a Comment