SlideShare a Scribd company logo
1 of 39
Download to read offline
#twitterflight
October 22, 2014 #twitterflight
Connecting to the Pulse
of the Planet
Romain Huet
Developer Advocate
@romainhuet
271M+
500M+
Active Users
Tweets per Day
2006 2014
Twitter is global,

open and real-time
Twitter is the shortest distance
between @you and your #interests
Twitter is there at

world events
Twitter is the pulse

of the planet
How can you use Twitter Data

to power your apps?
Data Platform
Twitter APIs deal both with the

right now and what happened
Streaming APIs allow you to ingest
what’s happening right now
Streaming APIs let you ingest
what’s happening right now
POST https://stream.twitter.com/1.1/statuses/filter.json
Returns Tweets matching your criteria.
Data follow: 3946301

track: #twitterflight

locations: 2.1733,41.3633,2.1933,41.4033
language: fr
Streaming APIs let you ingest
what’s happening right now
GET https://stream.twitter.com/1.1/statuses/sample.json
Returns ~1% of all firehose data, statistically relevant.
GET https://stream.twitter.com/1.1/statuses/firehose.json
Returns all firehose data, requires business deal.
Streaming APIs let you ingest
what’s happening right now
{"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264085194330112,"id_str":"407264085194330112","text":"u201c@DM_Minions: The minion mobile! http://t.co/Tq8AQoXcVyu201d shall I get
it, @CourtneyLouu ud83dude0fud83dude18","source":"u003ca href="http://twitter.com/download/iphone" rel="nofollow"u003eTwitter for iPhoneu003c/a
u003e","truncated":false,"in_reply_to_status_id":407263303405023232,"in_reply_to_status_id_str":"407263303405023232","in_reply_to_user_id":
948825632,"in_reply_to_user_id_str":"948825632","in_reply_to_screen_name":"DM_Minions","user":{"id":
404024178,"id_str":"404024178","name":"emilyjade","screen_name":"_emilyjade","location":"","url":null,"description":"'what is essential, is invisible to the
eye'","protected":false,"followers_count":156,"friends_count":287,"listed_count":0,"created_at":"Thu Nov 03 10:18:49 +0000 2011","favourites_count":
379,"utc_offset":null,"time_zone":null,"geo_enabled":true,"verified":false,"statuses_count":
8506,"lang":"en","contributors_enabled":false,"is_translator":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/378800000811908687/bc82e20db7c7812a1f61f72998f948e9_normal.jpeg","profile_image_url_https":"https://pbs.twimg.com/profile_images/378800000811908687/
bc82e20db7c7812a1f61f72998f948e9_normal.jpeg","profile_banner_url":"https://pbs.twimg.com/profile_banners/404024178/
1385914936","profile_link_color":"990000","profile_sidebar_border_color":"DFDFDF","profile_sidebar_fill_color":"F3F3F3","profile_text_color":"333333","profile_use_background_image":true,"def
ault_profile":false,"default_profile_image":false,"following":null,"follow_request_sent":null,"notifications":null},"geo":{"type":"Point","coordinates":
[51.35264663,-1.15710757]},"coordinates":{"type":"Point","coordinates":[-1.15710757,51.35264663]},"place":{"id":"d009bfdb11c20f3e","url":"https://api.twitter.com/1.1/geo/id/
d009bfdb11c20f3e.json","place_type":"city","name":"Basingstoke and Deane","full_name":"Basingstoke and Deane, Hampshire","country_code":"GB","country":"United Kingdom","contained_within":
[],"bounding_box":{"type":"Polygon","coordinates":[[[-1.4601689999999998,51.133537999999994],[-1.4601689999999998,51.383949],[-0.9748119999999999,51.383949],
[-0.9748119999999999,51.133537999999994]]]},"attributes":{}},"contributors":null,"retweet_count":0,"favorite_count":0,"entities":{"hashtags":[],"symbols":[],"urls":[],"user_mentions":
[{"screen_name":"DM_Minions","name":"DespicableMe Minions","id":948825632,"id_str":"948825632","indices":[1,12]},{"screen_name":"CourtneyLouu","name":"coourts","id":
43456930,"id_str":"43456930","indices":[73,86]}],"media":[{"id":407263303325335552,"id_str":"407263303325335552","indices":[33,55],"media_url":"http://pbs.twimg.com/media/
Babj0QzCQAAMrX4.jpg","media_url_https":"https://pbs.twimg.com/media/Babj0QzCQAAMrX4.jpg","url":"http://t.co/Tq8AQoXcVy","display_url":"pic.twitter.com/
Tq8AQoXcVy","expanded_url":"http://twitter.com/DM_Minions/status/407263303405023232/photo/1","type":"photo","sizes":{"small":{"w":339,"h":236,"resize":"fit"},"large":{"w":958,"h":
666,"resize":"fit"},"thumb":{"w":150,"h":150,"resize":"crop"},"medium":{"w":599,"h":417,"resize":"fit"}},"source_status_id":
407263303405023232,"source_status_id_str":"407263303405023232"}]},"favorited":false,"retweeted":false,"possibly_sensitive":false,"filter_level":"medium","lang":"en"}
{"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264086347747328,"id_str":"407264086347747328","text":"@DannyArratoon already eaten it but you can bring me another
one?","source":"u003ca href="http://twitter.com/download/iphone" rel="nofollow"u003eTwitter for iPhoneu003c/au003e","truncated":false,"in_reply_to_status_id":
407263944844533761,"in_reply_to_status_id_str":"407263944844533761","in_reply_to_user_id":210579473,"in_reply_to_user_id_str":"210579473","in_reply_to_screen_name":"DannyArratoon","user":
{"id":495068253,"id_str":"495068253","name":"eleanor","screen_name":"ell_eysselinck","location":"london","url":null,"description":null,"protected":false,"followers_count":
430,"friends_count":345,"listed_count":0,"created_at":"Fri Feb 17 15:23:34 +0000 2012","favourites_count":3934,"utc_offset":
0,"time_zone":"London","geo_enabled":true,"verified":false,"statuses_count":
7800,"lang":"en","contributors_enabled":false,"is_translator":false,"profile_background_color":"000000","profile_background_image_url":"http://a0.twimg.com/profile_background_images/
635582704/nud5dpj44ngj5bgv5k55.jpeg","profile_background_image_url_https":"https://si0.twimg.com/profile_background_images/635582704/
nud5dpj44ngj5bgv5k55.jpeg","profile_background_tile":true,"profile_image_url":"http://pbs.twimg.com/profile_images/378800000812022272/
b0218f45cb51525440be4f5782aaba6b_normal.jpeg","profile_image_url_https":"https://pbs.twimg.com/profile_images/378800000812022272/
b0218f45cb51525440be4f5782aaba6b_normal.jpeg","profile_banner_url":"https://pbs.twimg.com/profile_banners/495068253/
1378837388","profile_link_color":"EB091C","profile_sidebar_border_color":"C0DEED","profile_sidebar_fill_color":"DDEEF6","profile_text_color":"333333","profile_use_background_image":true,"def
ault_profile":false,"default_profile_image":false,"following":null,"follow_request_sent":null,"notifications":null},"geo":{"type":"Point","coordinates":
[51.37097685,-0.21992044]},"coordinates":{"type":"Point","coordinates":[-0.21992044,51.37097685]},"place":{"id":"8840213b5fc1032a","url":"https://api.twitter.com/1.1/geo/id/
8840213b5fc1032a.json","place_type":"city","name":"Sutton","full_name":"Sutton, London","country_code":"GB","country":"United Kingdom","contained_within":[],"bounding_box":
{"type":"Polygon","coordinates":[[[-0.24586899999999998,51.321324999999995],[-0.24586899999999998,51.393378999999996],[-0.117306,51.393378999999996],
[-0.117306,51.321324999999995]]]},"attributes":{}},"contributors":null,"retweet_count":0,"favorite_count":0,"entities":{"hashtags":[],"symbols":[],"urls":[],"user_mentions":
[{"screen_name":"DannyArratoon","name":"Danny","id":210579473,"id_str":"210579473","indices":[0,14]}]},"favorited":false,"retweeted":false,"filter_level":"medium","lang":"en"}
{"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264087085953025,"id_str":"407264087085953025","text":"@brontemaria22 #firstin","source":"u003ca href="http://twitter.com/download
/iphone" rel="nofollow"u003eTwitter for iPhoneu003c/au003e","truncated":false,"in_reply_to_status_id":
407262865251643392,"in_reply_to_status_id_str":"407262865251643392","in_reply_to_user_id":771468884,"in_reply_to_user_id_str":"771468884","in_reply_to_screen_name":"brontemaria22","user":
{"id":442104599,"id_str":"442104599","name":"zolf","screen_name":"FleurMarie32","location":"","url":null,"description":null,"protected":false,"followers_count":360,"friends_count":
238,"listed_count":0,"created_at":"Tue Dec 20 19:13:40 +0000 2011","favourites_count":563,"utc_offset":null,"time_zone":null,"geo_enabled":true,"verified":false,"statuses_count":
Anatomy of a Tweet
{
"created_at": "Wed Oct 02 15:53:43 +0000 2013",
"id": 385432417126739968,
"id_str": "385432417126739968",
"text": "Learn more about the powerful #Linux container engine @docker in this video intro with @solomonstre -
http://t.co/QJLdA1762Y @TwitterOSS",
"source": "web",
"truncated": false,
"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": 1665823832,
"id_str": "1665823832",
"name": "Twitter University",
"screen_name": "university",
"location": "",
"description": "Building a culture of learning for @TwitterEng and the world at large",
"url": "http://t.co/c8IHJLE1Y8",
"entities": {
"url": {
"urls": [{
"url": "http://t.co/c8IHJLE1Y8",
"expanded_url": "http://youtube.com/twitteruniversity",
"display_url": "youtube.com/twitteruniversu2026",
"favorite_count": 25,
"entities": {
"hashtags": [{
"text": "Linux",
"indices": [30, 36]
}],
"symbols": [],
"urls": [{
"url": "http://t.co/QJLdA1762Y",
"expanded_url": "http://youtu.be/Q5POuMHxW-0",
"display_url": "youtu.be/Q5POuMHxW-0",
"indices": [102, 124]
}],
"user_mentions": [{
"screen_name": "docker",
"name": "Docker",
"id": 1138959692,
"id_str": "1138959692",
"indices": [54, 61]
}, {
"screen_name": "solomonstre",
"name": "Solomon Hykes",
"id": 9551792,
"id_str": "9551792",
"indices": [87, 99]
}, {
"screen_name": "TwitterOSS",
"name": "Twitter Open Source",
"id": 376825877,
"id_str": "376825877",
"indices": [125, 136]
}]
},
"favorited": false,
"retweeted": true,
"possibly_sensitive": false,
"lang": "en"
}
143,199

Tweets per second
5,700
TPS on average
REST APIs let you perform actions
and access what happened
REST APIs let you perform actions
and access what happened
Tweets & Media GET statuses/lookup
POST statuses/update
POST media/upload
Timelines GET statuses/home_timeline
GET statuses/user_timeline
GET statuses/mentions_timeline
Search GET tweets/search
Following GET friends/list
And many more: Users, Favorites, Direct Messages, Followers, Lists, Trends, Geo, Spam Reporting…
Demo
#twitterflight
+
+
Mobile Platform
Fabric Sample App
Cannonball
Open source for iOS & Android:



github.com/twitterdev
NodeCopter.com
Demo
#twitterflight
Sign In with Twitter
and Digits
@IBAction func signInWithTwitter(sender: UIButton) {
Twitter.sharedInstance().logInWithCompletion { (session:
TWTRSession!, error: NSError!) -> Void in
if session != nil {
// Save any useful data from the Twitter session,
// then move to the next view controller.
}
}
}
@IBAction func signInWithPhone(sender: UIButton) {
Digits.sharedInstance().authenticateWithCompletion { (session:
DGTSession!, error: NSError!) -> Void in
if session != nil {
// Save any useful data from the Digits session,
// then move to the next view controller.
}
}
}
Adding a Tweet View
to the View Controller
override func viewDidLoad() {
super.viewDidLoad()
// Request the Twitter API.
Twitter.sharedInstance().APIClient.loadTweetWithID(tweetId,
completion: { (tweet: TWTRTweet!, error: NSError!) -> Void in
// Build the Tweet view.
self.tweetView = TWTRTweetView(tweet: tweet, style: .Regular)
// Add the Tweet view to the main view.
self.view.addSubview(self.tweetView)
})
}
Sharing a Tweet with
the Tweet Composer
@IBAction func postTweet(sender: AnyObject) {
// Use the TwitterKit to create a Tweet composer.
let composer = TWTRComposer()
// Prepare the Tweet text with drone commands.
composer.setText(droneCommands)
// Present the composer to the user.
composer.showWithCompletion({ (result: TWTRComposerResult!) -> Void
in
if result == .Cancelled {
println("Tweet composition cancelled")
} else {
println("Tweeting commands to the drone!")
}
})
}
Displaying Tweets in a
Table View
override func tableView(tableView: UITableView, cellForRowAtIndexPath
indexPath: NSIndexPath) -> UITableViewCell {
// Retrieve the Tweet cell.
let cell =
tableView.dequeueReusableCellWithIdentifier(tweetTableCellReuseIdentifie
r, forIndexPath: indexPath) as TWTRTweetTableViewCell
// Assign the delegate to control events on Tweets.
cell.tweetView.delegate = self
// Retrieve the Tweet model object from the array of loaded Tweets.
let tweet = tweets[indexPath.row]
// Configure the cell with the Tweet.
cell.configureWithTweet(tweet)
// Return the Tweet cell.
return cell
}
Thank You

More Related Content

Similar to #TwitterFlight: Connecting to the Pulse of the Planet

Connecting to the Pulse of the Planet with the Twitter Platform
Connecting to the Pulse of the Planet with the Twitter PlatformConnecting to the Pulse of the Planet with the Twitter Platform
Connecting to the Pulse of the Planet with the Twitter PlatformAndy Piper
 
Unleashing Twitter Data for Fun and Insight
Unleashing Twitter Data for Fun and InsightUnleashing Twitter Data for Fun and Insight
Unleashing Twitter Data for Fun and InsightMatthew Russell
 
Unleashing twitter data for fun and insight
Unleashing twitter data for fun and insightUnleashing twitter data for fun and insight
Unleashing twitter data for fun and insightDigital Reasoning
 
Montreal Elasticsearch Meetup
Montreal Elasticsearch MeetupMontreal Elasticsearch Meetup
Montreal Elasticsearch MeetupLoïc Bertron
 
Module 02.Spreadable media
Module 02.Spreadable mediaModule 02.Spreadable media
Module 02.Spreadable mediaJulian Matthews
 
Working With Facebook, Twitter, et al. - Social Media Camp
Working With Facebook, Twitter, et al. - Social Media CampWorking With Facebook, Twitter, et al. - Social Media Camp
Working With Facebook, Twitter, et al. - Social Media CampMike Anderson
 
Seattle bot + Twitter data prezo
Seattle bot + Twitter data prezoSeattle bot + Twitter data prezo
Seattle bot + Twitter data prezoHarrison Neff
 
What to expect when you are visualizing
What to expect when you are visualizingWhat to expect when you are visualizing
What to expect when you are visualizingKrist Wongsuphasawat
 
Adventure in Data: A tour of visualization projects at Twitter
Adventure in Data: A tour of visualization projects at TwitterAdventure in Data: A tour of visualization projects at Twitter
Adventure in Data: A tour of visualization projects at TwitterKrist Wongsuphasawat
 
Twitter APIs: Connecting to the Pulse of the Planet
Twitter APIs: Connecting to the Pulse of the PlanetTwitter APIs: Connecting to the Pulse of the Planet
Twitter APIs: Connecting to the Pulse of the PlanetRomain Huet
 
Social Media and the Customer-centric Data Strategy #data17
Social Media and the Customer-centric Data Strategy #data17Social Media and the Customer-centric Data Strategy #data17
Social Media and the Customer-centric Data Strategy #data17Alexander Loth
 
MongoDB In Production At Sailthru
MongoDB In Production At SailthruMongoDB In Production At Sailthru
MongoDB In Production At Sailthruibwhite
 
Big Data Analytics course: Named Entities and Deep Learning for NLP
Big Data Analytics course: Named Entities and Deep Learning for NLPBig Data Analytics course: Named Entities and Deep Learning for NLP
Big Data Analytics course: Named Entities and Deep Learning for NLPChristian Morbidoni
 
Goodle Developer Days Munich 2008 - Open Social Update
Goodle Developer Days Munich 2008 - Open Social UpdateGoodle Developer Days Munich 2008 - Open Social Update
Goodle Developer Days Munich 2008 - Open Social UpdatePatrick Chanezon
 
Apache Solr for TYPO3 what's new 2018
Apache Solr for TYPO3 what's new 2018Apache Solr for TYPO3 what's new 2018
Apache Solr for TYPO3 what's new 2018timohund
 
HackPR at UPR in Mayaguez - September 2015
HackPR at UPR in Mayaguez - September 2015HackPR at UPR in Mayaguez - September 2015
HackPR at UPR in Mayaguez - September 2015Jonathan Bulava
 
Twitterface: A viral marketing concept
Twitterface: A viral marketing conceptTwitterface: A viral marketing concept
Twitterface: A viral marketing conceptAra Pehlivanian
 
Connecting to the pulse of the planet with Twitter APIs
Connecting to the pulse of the planet with Twitter APIsConnecting to the pulse of the planet with Twitter APIs
Connecting to the pulse of the planet with Twitter APIsAndy Piper
 

Similar to #TwitterFlight: Connecting to the Pulse of the Planet (20)

Connecting to the Pulse of the Planet with the Twitter Platform
Connecting to the Pulse of the Planet with the Twitter PlatformConnecting to the Pulse of the Planet with the Twitter Platform
Connecting to the Pulse of the Planet with the Twitter Platform
 
Unleashing Twitter Data for Fun and Insight
Unleashing Twitter Data for Fun and InsightUnleashing Twitter Data for Fun and Insight
Unleashing Twitter Data for Fun and Insight
 
Unleashing twitter data for fun and insight
Unleashing twitter data for fun and insightUnleashing twitter data for fun and insight
Unleashing twitter data for fun and insight
 
Montreal Elasticsearch Meetup
Montreal Elasticsearch MeetupMontreal Elasticsearch Meetup
Montreal Elasticsearch Meetup
 
Module 02.Spreadable media
Module 02.Spreadable mediaModule 02.Spreadable media
Module 02.Spreadable media
 
Working With Facebook, Twitter, et al. - Social Media Camp
Working With Facebook, Twitter, et al. - Social Media CampWorking With Facebook, Twitter, et al. - Social Media Camp
Working With Facebook, Twitter, et al. - Social Media Camp
 
Seattle bot + Twitter data prezo
Seattle bot + Twitter data prezoSeattle bot + Twitter data prezo
Seattle bot + Twitter data prezo
 
What to expect when you are visualizing
What to expect when you are visualizingWhat to expect when you are visualizing
What to expect when you are visualizing
 
Adventure in Data: A tour of visualization projects at Twitter
Adventure in Data: A tour of visualization projects at TwitterAdventure in Data: A tour of visualization projects at Twitter
Adventure in Data: A tour of visualization projects at Twitter
 
Twitter APIs: Connecting to the Pulse of the Planet
Twitter APIs: Connecting to the Pulse of the PlanetTwitter APIs: Connecting to the Pulse of the Planet
Twitter APIs: Connecting to the Pulse of the Planet
 
Mining Georeferenced Data
Mining Georeferenced DataMining Georeferenced Data
Mining Georeferenced Data
 
Social Media and the Customer-centric Data Strategy #data17
Social Media and the Customer-centric Data Strategy #data17Social Media and the Customer-centric Data Strategy #data17
Social Media and the Customer-centric Data Strategy #data17
 
Beyond User Research
Beyond User ResearchBeyond User Research
Beyond User Research
 
MongoDB In Production At Sailthru
MongoDB In Production At SailthruMongoDB In Production At Sailthru
MongoDB In Production At Sailthru
 
Big Data Analytics course: Named Entities and Deep Learning for NLP
Big Data Analytics course: Named Entities and Deep Learning for NLPBig Data Analytics course: Named Entities and Deep Learning for NLP
Big Data Analytics course: Named Entities and Deep Learning for NLP
 
Goodle Developer Days Munich 2008 - Open Social Update
Goodle Developer Days Munich 2008 - Open Social UpdateGoodle Developer Days Munich 2008 - Open Social Update
Goodle Developer Days Munich 2008 - Open Social Update
 
Apache Solr for TYPO3 what's new 2018
Apache Solr for TYPO3 what's new 2018Apache Solr for TYPO3 what's new 2018
Apache Solr for TYPO3 what's new 2018
 
HackPR at UPR in Mayaguez - September 2015
HackPR at UPR in Mayaguez - September 2015HackPR at UPR in Mayaguez - September 2015
HackPR at UPR in Mayaguez - September 2015
 
Twitterface: A viral marketing concept
Twitterface: A viral marketing conceptTwitterface: A viral marketing concept
Twitterface: A viral marketing concept
 
Connecting to the pulse of the planet with Twitter APIs
Connecting to the pulse of the planet with Twitter APIsConnecting to the pulse of the planet with Twitter APIs
Connecting to the pulse of the planet with Twitter APIs
 

Recently uploaded

Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Bhuvaneswari Subramani
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusZilliz
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontologyjohnbeverley2021
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Zilliz
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 

Recently uploaded (20)

Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 

#TwitterFlight: Connecting to the Pulse of the Planet

  • 2. October 22, 2014 #twitterflight Connecting to the Pulse of the Planet
  • 6. Twitter is the shortest distance between @you and your #interests
  • 7. Twitter is there at
 world events
  • 8. Twitter is the pulse
 of the planet
  • 9. How can you use Twitter Data
 to power your apps?
  • 10.
  • 11.
  • 12.
  • 14.
  • 15. Twitter APIs deal both with the
 right now and what happened
  • 16. Streaming APIs allow you to ingest what’s happening right now
  • 17. Streaming APIs let you ingest what’s happening right now POST https://stream.twitter.com/1.1/statuses/filter.json Returns Tweets matching your criteria. Data follow: 3946301
 track: #twitterflight
 locations: 2.1733,41.3633,2.1933,41.4033 language: fr
  • 18. Streaming APIs let you ingest what’s happening right now GET https://stream.twitter.com/1.1/statuses/sample.json Returns ~1% of all firehose data, statistically relevant. GET https://stream.twitter.com/1.1/statuses/firehose.json Returns all firehose data, requires business deal.
  • 19. Streaming APIs let you ingest what’s happening right now {"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264085194330112,"id_str":"407264085194330112","text":"u201c@DM_Minions: The minion mobile! http://t.co/Tq8AQoXcVyu201d shall I get it, @CourtneyLouu ud83dude0fud83dude18","source":"u003ca href="http://twitter.com/download/iphone" rel="nofollow"u003eTwitter for iPhoneu003c/a u003e","truncated":false,"in_reply_to_status_id":407263303405023232,"in_reply_to_status_id_str":"407263303405023232","in_reply_to_user_id": 948825632,"in_reply_to_user_id_str":"948825632","in_reply_to_screen_name":"DM_Minions","user":{"id": 404024178,"id_str":"404024178","name":"emilyjade","screen_name":"_emilyjade","location":"","url":null,"description":"'what is essential, is invisible to the eye'","protected":false,"followers_count":156,"friends_count":287,"listed_count":0,"created_at":"Thu Nov 03 10:18:49 +0000 2011","favourites_count": 379,"utc_offset":null,"time_zone":null,"geo_enabled":true,"verified":false,"statuses_count": 8506,"lang":"en","contributors_enabled":false,"is_translator":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/378800000811908687/bc82e20db7c7812a1f61f72998f948e9_normal.jpeg","profile_image_url_https":"https://pbs.twimg.com/profile_images/378800000811908687/ bc82e20db7c7812a1f61f72998f948e9_normal.jpeg","profile_banner_url":"https://pbs.twimg.com/profile_banners/404024178/ 1385914936","profile_link_color":"990000","profile_sidebar_border_color":"DFDFDF","profile_sidebar_fill_color":"F3F3F3","profile_text_color":"333333","profile_use_background_image":true,"def ault_profile":false,"default_profile_image":false,"following":null,"follow_request_sent":null,"notifications":null},"geo":{"type":"Point","coordinates": [51.35264663,-1.15710757]},"coordinates":{"type":"Point","coordinates":[-1.15710757,51.35264663]},"place":{"id":"d009bfdb11c20f3e","url":"https://api.twitter.com/1.1/geo/id/ d009bfdb11c20f3e.json","place_type":"city","name":"Basingstoke and Deane","full_name":"Basingstoke and Deane, Hampshire","country_code":"GB","country":"United Kingdom","contained_within": [],"bounding_box":{"type":"Polygon","coordinates":[[[-1.4601689999999998,51.133537999999994],[-1.4601689999999998,51.383949],[-0.9748119999999999,51.383949], [-0.9748119999999999,51.133537999999994]]]},"attributes":{}},"contributors":null,"retweet_count":0,"favorite_count":0,"entities":{"hashtags":[],"symbols":[],"urls":[],"user_mentions": [{"screen_name":"DM_Minions","name":"DespicableMe Minions","id":948825632,"id_str":"948825632","indices":[1,12]},{"screen_name":"CourtneyLouu","name":"coourts","id": 43456930,"id_str":"43456930","indices":[73,86]}],"media":[{"id":407263303325335552,"id_str":"407263303325335552","indices":[33,55],"media_url":"http://pbs.twimg.com/media/ Babj0QzCQAAMrX4.jpg","media_url_https":"https://pbs.twimg.com/media/Babj0QzCQAAMrX4.jpg","url":"http://t.co/Tq8AQoXcVy","display_url":"pic.twitter.com/ Tq8AQoXcVy","expanded_url":"http://twitter.com/DM_Minions/status/407263303405023232/photo/1","type":"photo","sizes":{"small":{"w":339,"h":236,"resize":"fit"},"large":{"w":958,"h": 666,"resize":"fit"},"thumb":{"w":150,"h":150,"resize":"crop"},"medium":{"w":599,"h":417,"resize":"fit"}},"source_status_id": 407263303405023232,"source_status_id_str":"407263303405023232"}]},"favorited":false,"retweeted":false,"possibly_sensitive":false,"filter_level":"medium","lang":"en"} {"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264086347747328,"id_str":"407264086347747328","text":"@DannyArratoon already eaten it but you can bring me another one?","source":"u003ca href="http://twitter.com/download/iphone" rel="nofollow"u003eTwitter for iPhoneu003c/au003e","truncated":false,"in_reply_to_status_id": 407263944844533761,"in_reply_to_status_id_str":"407263944844533761","in_reply_to_user_id":210579473,"in_reply_to_user_id_str":"210579473","in_reply_to_screen_name":"DannyArratoon","user": {"id":495068253,"id_str":"495068253","name":"eleanor","screen_name":"ell_eysselinck","location":"london","url":null,"description":null,"protected":false,"followers_count": 430,"friends_count":345,"listed_count":0,"created_at":"Fri Feb 17 15:23:34 +0000 2012","favourites_count":3934,"utc_offset": 0,"time_zone":"London","geo_enabled":true,"verified":false,"statuses_count": 7800,"lang":"en","contributors_enabled":false,"is_translator":false,"profile_background_color":"000000","profile_background_image_url":"http://a0.twimg.com/profile_background_images/ 635582704/nud5dpj44ngj5bgv5k55.jpeg","profile_background_image_url_https":"https://si0.twimg.com/profile_background_images/635582704/ nud5dpj44ngj5bgv5k55.jpeg","profile_background_tile":true,"profile_image_url":"http://pbs.twimg.com/profile_images/378800000812022272/ b0218f45cb51525440be4f5782aaba6b_normal.jpeg","profile_image_url_https":"https://pbs.twimg.com/profile_images/378800000812022272/ b0218f45cb51525440be4f5782aaba6b_normal.jpeg","profile_banner_url":"https://pbs.twimg.com/profile_banners/495068253/ 1378837388","profile_link_color":"EB091C","profile_sidebar_border_color":"C0DEED","profile_sidebar_fill_color":"DDEEF6","profile_text_color":"333333","profile_use_background_image":true,"def ault_profile":false,"default_profile_image":false,"following":null,"follow_request_sent":null,"notifications":null},"geo":{"type":"Point","coordinates": [51.37097685,-0.21992044]},"coordinates":{"type":"Point","coordinates":[-0.21992044,51.37097685]},"place":{"id":"8840213b5fc1032a","url":"https://api.twitter.com/1.1/geo/id/ 8840213b5fc1032a.json","place_type":"city","name":"Sutton","full_name":"Sutton, London","country_code":"GB","country":"United Kingdom","contained_within":[],"bounding_box": {"type":"Polygon","coordinates":[[[-0.24586899999999998,51.321324999999995],[-0.24586899999999998,51.393378999999996],[-0.117306,51.393378999999996], [-0.117306,51.321324999999995]]]},"attributes":{}},"contributors":null,"retweet_count":0,"favorite_count":0,"entities":{"hashtags":[],"symbols":[],"urls":[],"user_mentions": [{"screen_name":"DannyArratoon","name":"Danny","id":210579473,"id_str":"210579473","indices":[0,14]}]},"favorited":false,"retweeted":false,"filter_level":"medium","lang":"en"} {"created_at":"Sun Dec 01 21:44:59 +0000 2013","id":407264087085953025,"id_str":"407264087085953025","text":"@brontemaria22 #firstin","source":"u003ca href="http://twitter.com/download /iphone" rel="nofollow"u003eTwitter for iPhoneu003c/au003e","truncated":false,"in_reply_to_status_id": 407262865251643392,"in_reply_to_status_id_str":"407262865251643392","in_reply_to_user_id":771468884,"in_reply_to_user_id_str":"771468884","in_reply_to_screen_name":"brontemaria22","user": {"id":442104599,"id_str":"442104599","name":"zolf","screen_name":"FleurMarie32","location":"","url":null,"description":null,"protected":false,"followers_count":360,"friends_count": 238,"listed_count":0,"created_at":"Tue Dec 20 19:13:40 +0000 2011","favourites_count":563,"utc_offset":null,"time_zone":null,"geo_enabled":true,"verified":false,"statuses_count":
  • 20. Anatomy of a Tweet { "created_at": "Wed Oct 02 15:53:43 +0000 2013", "id": 385432417126739968, "id_str": "385432417126739968", "text": "Learn more about the powerful #Linux container engine @docker in this video intro with @solomonstre - http://t.co/QJLdA1762Y @TwitterOSS", "source": "web", "truncated": false, "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": 1665823832, "id_str": "1665823832", "name": "Twitter University", "screen_name": "university", "location": "", "description": "Building a culture of learning for @TwitterEng and the world at large", "url": "http://t.co/c8IHJLE1Y8", "entities": { "url": { "urls": [{ "url": "http://t.co/c8IHJLE1Y8", "expanded_url": "http://youtube.com/twitteruniversity", "display_url": "youtube.com/twitteruniversu2026",
  • 21. "favorite_count": 25, "entities": { "hashtags": [{ "text": "Linux", "indices": [30, 36] }], "symbols": [], "urls": [{ "url": "http://t.co/QJLdA1762Y", "expanded_url": "http://youtu.be/Q5POuMHxW-0", "display_url": "youtu.be/Q5POuMHxW-0", "indices": [102, 124] }], "user_mentions": [{ "screen_name": "docker", "name": "Docker", "id": 1138959692, "id_str": "1138959692", "indices": [54, 61] }, { "screen_name": "solomonstre", "name": "Solomon Hykes", "id": 9551792, "id_str": "9551792", "indices": [87, 99] }, { "screen_name": "TwitterOSS", "name": "Twitter Open Source", "id": 376825877, "id_str": "376825877", "indices": [125, 136] }] }, "favorited": false, "retweeted": true, "possibly_sensitive": false, "lang": "en" }
  • 23. REST APIs let you perform actions and access what happened
  • 24. REST APIs let you perform actions and access what happened Tweets & Media GET statuses/lookup POST statuses/update POST media/upload Timelines GET statuses/home_timeline GET statuses/user_timeline GET statuses/mentions_timeline Search GET tweets/search Following GET friends/list And many more: Users, Favorites, Direct Messages, Followers, Lists, Trends, Geo, Spam Reporting…
  • 26. +
  • 27. +
  • 29.
  • 30.
  • 31. Fabric Sample App Cannonball Open source for iOS & Android:
 
 github.com/twitterdev
  • 33.
  • 35. Sign In with Twitter and Digits @IBAction func signInWithTwitter(sender: UIButton) { Twitter.sharedInstance().logInWithCompletion { (session: TWTRSession!, error: NSError!) -> Void in if session != nil { // Save any useful data from the Twitter session, // then move to the next view controller. } } } @IBAction func signInWithPhone(sender: UIButton) { Digits.sharedInstance().authenticateWithCompletion { (session: DGTSession!, error: NSError!) -> Void in if session != nil { // Save any useful data from the Digits session, // then move to the next view controller. } } }
  • 36. Adding a Tweet View to the View Controller override func viewDidLoad() { super.viewDidLoad() // Request the Twitter API. Twitter.sharedInstance().APIClient.loadTweetWithID(tweetId, completion: { (tweet: TWTRTweet!, error: NSError!) -> Void in // Build the Tweet view. self.tweetView = TWTRTweetView(tweet: tweet, style: .Regular) // Add the Tweet view to the main view. self.view.addSubview(self.tweetView) }) }
  • 37. Sharing a Tweet with the Tweet Composer @IBAction func postTweet(sender: AnyObject) { // Use the TwitterKit to create a Tweet composer. let composer = TWTRComposer() // Prepare the Tweet text with drone commands. composer.setText(droneCommands) // Present the composer to the user. composer.showWithCompletion({ (result: TWTRComposerResult!) -> Void in if result == .Cancelled { println("Tweet composition cancelled") } else { println("Tweeting commands to the drone!") } }) }
  • 38. Displaying Tweets in a Table View override func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell { // Retrieve the Tweet cell. let cell = tableView.dequeueReusableCellWithIdentifier(tweetTableCellReuseIdentifie r, forIndexPath: indexPath) as TWTRTweetTableViewCell // Assign the delegate to control events on Tweets. cell.tweetView.delegate = self // Retrieve the Tweet model object from the array of loaded Tweets. let tweet = tweets[indexPath.row] // Configure the cell with the Tweet. cell.configureWithTweet(tweet) // Return the Tweet cell. return cell }