6. API ORGANIZATION
Streaming APIsREST APIs
POST statuses / filter
GET statuses / sample
GET statuses / firehose
User streams
Site streams
Public streams
GET site
GET user
Public API
GET statuses/user_timeline
GET statuses/show/:id
POST statuses/update
GET search/tweets
GET followers/list
GET trends/place
Media API
POST media/upload
POST media/upload (INIT)
POST media/upload (APPEND)
POST media/upload (FINALIZE)
POST media/metadata/create
GET media/upload (STATUS)
7. API RATE LIMITS
Streaming APIsREST APIs
Reasons for limiting:
• Backoff strategy not
implemented
• Frequent breaks and
reconnecting
• Too many connections
Limit notices
{
"limit":{
"track":1234
}
}
15 minute windows
Most limits are either:
• 15 calls / 15 minutes
• 180 calls / 15 minutes
9. Ads APIs
API VERSIONING
• Frequent updates means aggressive versioning
• MAJOR and MINOR numbers used (e.g. 2.3)
• Backward incompatible increases MAJOR
• Backward compatible increases MINOR
• Only need to specify MAJOR number in call
Example:
https://ads-api.twitter.com/1/accounts/abc1/tailored_audiences