Versions in this module Expand all Collapse all v1 v1.0.0 Sep 2, 2017 Changes in this version + const BaseUrl + const BaseUrlSiteStream + const BaseUrlStream + const BaseUrlUserStream + const BaseUrlV1 + const DEFAULT_CAPACITY + const DEFAULT_DELAY + const TwitterErrorAccountSuspended + const TwitterErrorApi1Deprecation + const TwitterErrorBadAuthenticationData + const TwitterErrorCouldNotAuthenticate + const TwitterErrorCouldNotAuthenticateYou + const TwitterErrorDoesNotExist + const TwitterErrorDoesNotExist2 + const TwitterErrorInternalError + const TwitterErrorInvalidToken + const TwitterErrorOverCapacity + const TwitterErrorRateLimitExceeded + const TwitterErrorStatusIsADuplicate + const TwitterErrorUserMustVerifyLogin + const UploadBaseUrl + func AuthorizationURL(callback string) (string, *oauth.Credentials, error) + func GetCredentials(tempCred *oauth.Credentials, verifier string) (*oauth.Credentials, url.Values, error) + func NewHTTP420ErrBackoff() backoff.Interface + func NewHTTPErrBackoff() backoff.Interface + func NewTCPIPErrBackoff() backoff.Interface + func SetConsumerKey(consumer_key string) + func SetConsumerSecret(consumer_secret string) + type AddUserToListResponse struct + Users []User + type ApiError struct + Body string + Decoded TwitterErrorResponse + Header http.Header + StatusCode int + URL *url.URL + func NewApiError(resp *http.Response) *ApiError + func (aerr *ApiError) RateLimitCheck() (isRateLimitError bool, nextWindow time.Time) + func (aerr ApiError) Error() string + type ChunkedMedia struct + ExpiresAfterSecs int + MediaID int64 + MediaIDString string + type Configuration struct + CharactersReservedPerMedia int + MaxMediaPerUpload int + NonUsernamePaths []string + PhotoSizeLimit int + PhotoSizes struct{ ... } + ShortUrlLength int + ShortUrlLengthHttps int + type Contributor struct + Id int64 + IdStr string + ScreenName string + type Coordinates struct + Coordinates [2]float64 + Type string + type Cursor struct + Ids []int64 + Next_cursor int64 + Next_cursor_str string + Previous_cursor int64 + Previous_cursor_str string + type DirectMessage struct + CreatedAt string + Entities Entities + Id int64 + IdStr string + Recipient User + RecipientId int64 + RecipientScreenName string + Sender User + SenderId int64 + SenderScreenName string + Text string + type DisconnectMessage struct + Code int64 + Reason string + StreamName string + type Entities struct + Hashtags []struct{ ... } + Media []EntityMedia + Url UrlEntity + Urls []struct{ ... } + User_mentions []struct{ ... } + type EntityMedia struct + Display_url string + Expanded_url string + Id int64 + Id_str string + Indices []int + Media_url string + Media_url_https string + Sizes MediaSizes + Source_status_id int64 + Source_status_id_str string + Type string + Url string + VideoInfo VideoInfo + type Event struct + CreatedAt string + Event string + Source *User + Target *User + type EventList struct + TargetObject *List + type EventTweet struct + TargetObject *Tweet + type ExtendedTweet struct + DisplayTextRange []int + Entities Entities + ExtendedEntities Entities + FullText string + type FollowersIdsPage struct + Error error + Ids []int64 + type FollowersPage struct + Error error + Followers []User + type FriendsIdsCursor struct + Ids []int64 + Next_cursor int64 + Next_cursor_str string + Previous_cursor int64 + Previous_cursor_str string + type FriendsIdsPage struct + Error error + Ids []int64 + type FriendsList []int64 + type FriendsPage struct + Error error + Friends []User + type Friendship struct + Connections []string + Id int64 + Id_str string + Name string + Screen_name string + type GeoSearchResult struct + Query struct{ ... } + Result struct{ ... } + type Image struct + H int + ImageType string + W int + type LimitNotice struct + Track int64 + type List struct + CreatedAt string + Description string + Following bool + FullName string + Id int64 + MemberCount int64 + Mode string + Name string + Slug string + SubscriberCount int64 + URL string + User User + type ListResponse struct + Lists []List + NextCursor int + PreviousCursor int + type Location struct + Name string + Woeid int + type LocationDeletionNotice struct + UpToStatusId int64 + UpToStatusIdStr string + UserId int64 + UserIdStr string + type Logger interface + Critical func(args ...interface{}) + Criticalf func(format string, args ...interface{}) + Debug func(args ...interface{}) + Debugf func(format string, args ...interface{}) + Error func(args ...interface{}) + Errorf func(format string, args ...interface{}) + Fatal func(args ...interface{}) + Fatalf func(format string, args ...interface{}) + Info func(args ...interface{}) + Infof func(format string, args ...interface{}) + Notice func(args ...interface{}) + Noticef func(format string, args ...interface{}) + Panic func(args ...interface{}) + Panicf func(format string, args ...interface{}) + Warning func(args ...interface{}) + Warningf func(format string, args ...interface{}) + var BasicLogger Logger + type Media struct + Image Image + MediaID int64 + MediaIDString string + Size int + type MediaSize struct + H int + Resize string + W int + type MediaSizes struct + Large MediaSize + Medium MediaSize + Small MediaSize + Thumb MediaSize + type OEmbed struct + Author_name string + Author_url string + Cache_age string + Height int + Html string + Provider_name string + Provider_url string + Type string + Url string + Version string + Width int + type Place struct + Attributes map[string]string + BoundingBox struct{ ... } + ContainedWithin []struct{ ... } + Country string + CountryCode string + FullName string + Geometry struct{ ... } + ID string + Name string + PlaceType string + Polylines []string + URL string + type Relationship struct + Source Source + Target Target + type RelationshipResponse struct + Relationship Relationship + type SearchMetadata struct + CompletedIn float32 + Count int + MaxId int64 + MaxIdString string + NextResults string + Query string + RefreshUrl string + SinceId int64 + SinceIdString string + type SearchResponse struct + Metadata SearchMetadata + Statuses []Tweet + func (sr *SearchResponse) GetNext(a *TwitterApi) (SearchResponse, error) + type Source struct + All_replies bool + Blocking bool + Can_dm bool + Followed_by bool + Following bool + Id int64 + Id_str string + Marked_spam bool + Muting bool + Notifications_enabled bool + Screen_name string + Want_retweets bool + type StallWarning struct + Code string + Message string + PercentFull int64 + type StatusDeletionNotice struct + Id int64 + IdStr string + UserId int64 + UserIdStr string + type StatusWithheldNotice struct + Id int64 + UserId int64 + WithheldInCountries []string + type Stream struct + C chan interface{} + func (s *Stream) Stop() + type Target struct + Followed_by bool + Following bool + Id int64 + Id_str string + Screen_name string + type TooManyFollow struct + Warning ... + type Trend struct + Name string + PromotedContent string + Query string + Url string + type TrendLocation struct + Country string + CountryCode string + Name string + ParentId int + PlaceType struct{ ... } + Url string + Woeid int32 + type TrendResponse struct + AsOf string + CreatedAt string + Locations []Location + Trends []Trend + type Tweet struct + Contributors []int64 + Coordinates *Coordinates + CreatedAt string + DisplayTextRange []int + Entities Entities + ExtendedEntities Entities + ExtendedTweet ExtendedTweet + FavoriteCount int + Favorited bool + FilterLevel string + FullText string + HasExtendedProfile bool + Id int64 + IdStr string + InReplyToScreenName string + InReplyToStatusID int64 + InReplyToStatusIdStr string + InReplyToUserID int64 + InReplyToUserIdStr string + IsTranslationEnabled bool + Lang string + Place Place + PossiblySensitive bool + PossiblySensitiveAppealable bool + QuotedStatus *Tweet + QuotedStatusID int64 + QuotedStatusIdStr string + RetweetCount int + Retweeted bool + RetweetedStatus *Tweet + Scopes map[string]interface{} + Source string + Text string + User User + WithheldCopyright bool + WithheldInCountries []string + WithheldScope string + func (t *Tweet) UnmarshalJSON(data []byte) error + func (t Tweet) CreatedAtTime() (time.Time, error) + func (t Tweet) HasCoordinates() bool + func (t Tweet) Latitude() (float64, error) + func (t Tweet) Longitude() (float64, error) + func (t Tweet) X() (float64, error) + func (t Tweet) Y() (float64, error) + type TwitterApi struct + Credentials *oauth.Credentials + HttpClient *http.Client + Log Logger + func NewTwitterApi(access_token string, access_token_secret string) *TwitterApi + func (a TwitterApi) AddUserToList(screenName string, listID int64, v url.Values) (users []User, err error) + func (a TwitterApi) Block(v url.Values) (user User, err error) + func (a TwitterApi) BlockUser(screenName string, v url.Values) (user User, err error) + func (a TwitterApi) BlockUserId(id int64, v url.Values) (user User, err error) + func (a TwitterApi) CreateList(name, description string, v url.Values) (list List, err error) + func (a TwitterApi) DeleteActivityWebhooks(v url.Values, webhookID string) (u interface{}, err error) + func (a TwitterApi) DeleteDirectMessage(id int64, includeEntities bool) (message DirectMessage, err error) + func (a TwitterApi) DeleteTweet(id int64, trimUser bool) (tweet Tweet, err error) + func (a TwitterApi) DeleteWHSubscription(v url.Values, webhookID string) (u interface{}, err error) + func (a TwitterApi) Favorite(id int64) (rt Tweet, err error) + func (a TwitterApi) FollowUser(screenName string) (user User, err error) + func (a TwitterApi) FollowUserId(userId int64, v url.Values) (user User, err error) + func (a TwitterApi) GeoSearch(v url.Values) (c GeoSearchResult, err error) + func (a TwitterApi) GetActivityWebhooks(v url.Values) (u []WebHookResp, err error) + func (a TwitterApi) GetBlocksIds(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetBlocksList(v url.Values) (c UserCursor, err error) + func (a TwitterApi) GetConfiguration(v url.Values) (conf Configuration, err error) + func (a TwitterApi) GetDirectMessages(v url.Values) (messages []DirectMessage, err error) + func (a TwitterApi) GetDirectMessagesSent(v url.Values) (messages []DirectMessage, err error) + func (a TwitterApi) GetDirectMessagesShow(v url.Values) (messages []DirectMessage, err error) + func (a TwitterApi) GetFavorites(v url.Values) (favorites []Tweet, err error) + func (a TwitterApi) GetFollowersIds(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFollowersIdsAll(v url.Values) (result chan FollowersIdsPage) + func (a TwitterApi) GetFollowersList(v url.Values) (c UserCursor, err error) + func (a TwitterApi) GetFollowersListAll(v url.Values) (result chan FollowersPage) + func (a TwitterApi) GetFollowersUser(id int64, v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFriendsIds(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFriendsIdsAll(v url.Values) (result chan FriendsIdsPage) + func (a TwitterApi) GetFriendsList(v url.Values) (c UserCursor, err error) + func (a TwitterApi) GetFriendsListAll(v url.Values) (result chan FriendsPage) + func (a TwitterApi) GetFriendsUser(id int64, v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFriendshipsIncoming(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFriendshipsLookup(v url.Values) (friendships []Friendship, err error) + func (a TwitterApi) GetFriendshipsNoRetweets() (ids []int64, err error) + func (a TwitterApi) GetFriendshipsOutgoing(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetFriendshipsShow(v url.Values) (relationshipResponse RelationshipResponse, err error) + func (a TwitterApi) GetHomeTimeline(v url.Values) (timeline []Tweet, err error) + func (a TwitterApi) GetListTweets(listID int64, includeRTs bool, v url.Values) (tweets []Tweet, err error) + func (a TwitterApi) GetListsOwnedBy(userID int64, v url.Values) (lists []List, err error) + func (a TwitterApi) GetMentionsTimeline(v url.Values) (timeline []Tweet, err error) + func (a TwitterApi) GetMutedUsersIds(v url.Values) (c Cursor, err error) + func (a TwitterApi) GetMutedUsersList(v url.Values) (c UserCursor, err error) + func (a TwitterApi) GetOEmbed(v url.Values) (o OEmbed, err error) + func (a TwitterApi) GetOEmbedId(id int64, v url.Values) (o OEmbed, err error) + func (a TwitterApi) GetRetweets(id int64, v url.Values) (tweets []Tweet, err error) + func (a TwitterApi) GetRetweetsOfMe(v url.Values) (tweets []Tweet, err error) + func (a TwitterApi) GetSearch(queryString string, v url.Values) (sr SearchResponse, err error) + func (a TwitterApi) GetSelf(v url.Values) (u User, err error) + func (a TwitterApi) GetTrendsAvailableLocations(v url.Values) (locations []TrendLocation, err error) + func (a TwitterApi) GetTrendsByPlace(id int64, v url.Values) (trendResp TrendResponse, err error) + func (a TwitterApi) GetTrendsClosestLocations(lat float64, long float64, v url.Values) (locations []TrendLocation, err error) + func (a TwitterApi) GetTweet(id int64, v url.Values) (tweet Tweet, err error) + func (a TwitterApi) GetTweetsLookupByIds(ids []int64, v url.Values) (tweet []Tweet, err error) + func (a TwitterApi) GetUserSearch(searchTerm string, v url.Values) (u []User, err error) + func (a TwitterApi) GetUserTimeline(v url.Values) (timeline []Tweet, err error) + func (a TwitterApi) GetUsersLookup(usernames string, v url.Values) (u []User, err error) + func (a TwitterApi) GetUsersLookupByIds(ids []int64, v url.Values) (u []User, err error) + func (a TwitterApi) GetUsersShow(username string, v url.Values) (u User, err error) + func (a TwitterApi) GetUsersShowById(id int64, v url.Values) (u User, err error) + func (a TwitterApi) GetWHSubscription(v url.Values, webhookID string) (u interface{}, err error) + func (a TwitterApi) Mute(v url.Values) (user User, err error) + func (a TwitterApi) MuteUser(screenName string, v url.Values) (user User, err error) + func (a TwitterApi) MuteUserId(id int64, v url.Values) (user User, err error) + func (a TwitterApi) PostDMToScreenName(text, screenName string) (message DirectMessage, err error) + func (a TwitterApi) PostDMToUserId(text string, userId int64) (message DirectMessage, err error) + func (a TwitterApi) PostTweet(status string, v url.Values) (tweet Tweet, err error) + func (a TwitterApi) PublicStreamFilter(v url.Values) (stream *Stream) + func (a TwitterApi) PublicStreamFirehose(v url.Values) (stream *Stream) + func (a TwitterApi) PublicStreamSample(v url.Values) (stream *Stream) + func (a TwitterApi) PutActivityWebhooks(v url.Values, webhookID string) (u interface{}, err error) + func (a TwitterApi) Retweet(id int64, trimUser bool) (rt Tweet, err error) + func (a TwitterApi) SetActivityWebhooks(v url.Values) (u []WebHookResp, err error) + func (a TwitterApi) SetWHSubscription(v url.Values, webhookID string) (u interface{}, err error) + func (a TwitterApi) SiteStream(v url.Values) (stream *Stream) + func (a TwitterApi) UnRetweet(id int64, trimUser bool) (rt Tweet, err error) + func (a TwitterApi) Unblock(v url.Values) (user User, err error) + func (a TwitterApi) UnblockUser(screenName string, v url.Values) (user User, err error) + func (a TwitterApi) UnblockUserId(id int64, v url.Values) (user User, err error) + func (a TwitterApi) Unfavorite(id int64) (rt Tweet, err error) + func (a TwitterApi) UnfollowUser(screenname string) (u User, err error) + func (a TwitterApi) UnfollowUserId(userId int64) (u User, err error) + func (a TwitterApi) Unmute(v url.Values) (user User, err error) + func (a TwitterApi) UnmuteUser(screenName string, v url.Values) (user User, err error) + func (a TwitterApi) UnmuteUserId(id int64, v url.Values) (user User, err error) + func (a TwitterApi) UploadMedia(base64String string) (media Media, err error) + func (a TwitterApi) UploadVideoAppend(mediaIdString string, segmentIndex int, base64String string) error + func (a TwitterApi) UploadVideoFinalize(mediaIdString string) (videoMedia VideoMedia, err error) + func (a TwitterApi) UploadVideoInit(totalBytes int, mimeType string) (chunkedMedia ChunkedMedia, err error) + func (a TwitterApi) UserStream(v url.Values) (stream *Stream) + func (a TwitterApi) VerifyCredentials() (ok bool, err error) + func (c *TwitterApi) Close() + func (c *TwitterApi) DisableThrottling() + func (c *TwitterApi) EnableThrottling(rate time.Duration, bufferSize int64) + func (c *TwitterApi) GetDelay() time.Duration + func (c *TwitterApi) ReturnRateLimitError(b bool) + func (c *TwitterApi) SetBaseUrl(baseUrl string) + func (c *TwitterApi) SetDelay(t time.Duration) + func (c *TwitterApi) SetLogger(l Logger) + type TwitterError struct + Code int + Message string + func (te TwitterError) Error() string + type TwitterErrorResponse struct + Errors []TwitterError + func (tr TwitterErrorResponse) Error() string + func (tr TwitterErrorResponse) First() error + type UrlEntity struct + Urls []struct{ ... } + type User struct + ContributorsEnabled bool + CreatedAt string + DefaultProfile bool + DefaultProfileImage bool + Description string + Entities Entities + FavouritesCount int + FollowRequestSent bool + FollowersCount int + Following bool + FriendsCount int + GeoEnabled bool + HasExtendedProfile bool + Id int64 + IdStr string + IsTranslationEnabled bool + IsTranslator bool + Lang string + ListedCount int64 + Location string + Name string + Notifications bool + ProfileBackgroundColor string + ProfileBackgroundImageURL string + ProfileBackgroundImageUrlHttps string + ProfileBackgroundTile bool + ProfileBannerURL string + ProfileImageURL string + ProfileImageUrlHttps string + ProfileLinkColor string + ProfileSidebarBorderColor string + ProfileSidebarFillColor string + ProfileTextColor string + ProfileUseBackgroundImage bool + Protected bool + ScreenName string + ShowAllInlineMedia bool + Status *Tweet + StatusesCount int64 + TimeZone string + URL string + UtcOffset int + Verified bool + WithheldInCountries []string + WithheldScope string + type UserCursor struct + Next_cursor int64 + Next_cursor_str string + Previous_cursor int64 + Previous_cursor_str string + Users []User + type UserWithheldNotice struct + Id int64 + WithheldInCountries []string + type Variant struct + Bitrate int + ContentType string + Url string + type Video struct + VideoType string + type VideoInfo struct + AspectRatio []int + DurationMillis int64 + Variants []Variant + type VideoMedia struct + ExpiresAfterSecs int + MediaID int64 + MediaIDString string + Size int + Video Video + type WebHookResp struct + CreatedAt string + ID string + URL string + Valid bool Incompatible versions in this module v2.0.0+incompatible Feb 26, 2018