twitter-conduit-0.2.2.2: Twitter API package with conduit interface and Streaming API support.

Safe HaskellNone
LanguageHaskell2010

Web.Twitter.Conduit.Status

Contents

Synopsis

Timelines

mentionsTimeline :: APIRequest StatusesMentionsTimeline [Status] Source #

Returns query data asks the most recent mentions for the authenticating user.

You can perform a query using call:

res <- call mentionsTimeline
>>> mentionsTimeline
APIRequestGet "https://api.twitter.com/1.1/statuses/mentions_timeline.json" []

userTimeline :: UserParam -> APIRequest StatusesUserTimeline [Status] Source #

Returns query data asks a collection of the most recent Tweets posted by the user indicated by the screen_name or user_id parameters.

You can perform a search query using call:

res <- call $ userTimeline (ScreenNameParam "thimura")
>>> userTimeline (ScreenNameParam "thimura")
APIRequestGet "https://api.twitter.com/1.1/statuses/user_timeline.json" [("screen_name","thimura")]
>>> userTimeline (ScreenNameParam "thimura") & includeRts ?~ True & count ?~ 200
APIRequestGet "https://api.twitter.com/1.1/statuses/user_timeline.json" [("count","200"),("include_rts","true"),("screen_name","thimura")]

homeTimeline :: APIRequest StatusesHomeTimeline [Status] Source #

Returns query data asks a collection of the most recentTweets and retweets posted by the authenticating user and the users they follow.

You can perform a search query using call:

res <- call homeTimeline
>>> homeTimeline
APIRequestGet "https://api.twitter.com/1.1/statuses/home_timeline.json" []
>>> homeTimeline & count ?~ 200
APIRequestGet "https://api.twitter.com/1.1/statuses/home_timeline.json" [("count","200")]

retweetsOfMe :: APIRequest StatusesRetweetsOfMe [Status] Source #

Returns query data asks the most recent tweets authored by the authenticating user that have been retweeted by others.

You can perform a search query using call:

res <- call retweetsOfMe
>>> retweetsOfMe
APIRequestGet "https://api.twitter.com/1.1/statuses/retweets_of_me.json" []
>>> retweetsOfMe & count ?~ 100
APIRequestGet "https://api.twitter.com/1.1/statuses/retweets_of_me.json" [("count","100")]

Tweets

retweetsId :: StatusId -> APIRequest StatusesRetweetsId [RetweetedStatus] Source #

Returns query data that asks for the most recent retweets of the specified tweet

You can perform a search query using call:

res <- call twInfo mgr $ retweetsId 1234567890
>>> retweetsId 1234567890
APIRequestGet "https://api.twitter.com/1.1/statuses/retweets/1234567890.json" []
>>> retweetsId 1234567890 & count ?~ 100
APIRequestGet "https://api.twitter.com/1.1/statuses/retweets/1234567890.json" [("count","100")]

showId :: StatusId -> APIRequest StatusesShowId Status Source #

Returns query data asks a single Tweet, specified by the id parameter.

You can perform a search query using call:

res <- call twInfo mgr $ showId 1234567890
>>> showId 1234567890
APIRequestGet "https://api.twitter.com/1.1/statuses/show/1234567890.json" []
>>> showId 1234567890 & includeMyRetweet ?~ True
APIRequestGet "https://api.twitter.com/1.1/statuses/show/1234567890.json" [("include_my_retweet","true")]

destroyId :: StatusId -> APIRequest StatusesDestroyId Status Source #

Returns post data which destroys the status specified by the require ID parameter.

You can perform a search query using call:

res <- call twInfo mgr $ destroyId 1234567890
>>> destroyId 1234567890
APIRequestPost "https://api.twitter.com/1.1/statuses/destroy/1234567890.json" []

update :: Text -> APIRequest StatusesUpdate Status Source #

Returns post data which updates the authenticating user's current status. To upload an image to accompany the tweet, use updateWithMedia.

You can perform a search query using call:

res <- call twInfo mgr $ update "Hello World"
>>> update "Hello World"
APIRequestPost "https://api.twitter.com/1.1/statuses/update.json" [("status","Hello World")]
>>> update "Hello World" & inReplyToStatusId ?~ 1234567890
APIRequestPost "https://api.twitter.com/1.1/statuses/update.json" [("in_reply_to_status_id","1234567890"),("status","Hello World")]

retweetId :: StatusId -> APIRequest StatusesRetweetId RetweetedStatus Source #

Returns post data which retweets a tweet, specified by ID.

You can perform a search query using call:

res <- call twInfo mgr $ retweetId 1234567890
>>> retweetId 1234567890
APIRequestPost "https://api.twitter.com/1.1/statuses/retweet/1234567890.json" []

updateWithMedia :: Text -> MediaData -> APIRequest StatusesUpdateWithMedia Status Source #

Returns post data which updates the authenticating user's current status and attaches media for upload.

You can perform a search query using call:

res <- call twInfo mgr $ updateWithMedia "Hello World" (MediaFromFile "homethimura/test.jpeg")
>>> updateWithMedia "Hello World" (MediaFromFile "/home/fuga/test.jpeg")
APIRequestPostMultipart "https://api.twitter.com/1.1/statuses/update_with_media.json" [("status","Hello World")]

lookup :: [StatusId] -> APIRequest StatusesLookup [Status] Source #

Returns fully-hydrated tweet objects for up to 100 tweets per request, as specified by comma-separated values passed to the id parameter.

You can perform a request using call:

res <- call twInfo mgr $ lookup [20, 432656548536401920]
>>> lookup [10]
APIRequestGet "https://api.twitter.com/1.1/statuses/lookup.json" [("id","10")]
>>> lookup [10, 432656548536401920]
APIRequestGet "https://api.twitter.com/1.1/statuses/lookup.json" [("id","10,432656548536401920")]
>>> lookup [10, 432656548536401920] & includeEntities ?~ True
APIRequestGet "https://api.twitter.com/1.1/statuses/lookup.json" [("include_entities","true"),("id","10,432656548536401920")]