Documentation
¶
Index ¶
- type AccountSettings
- type AccountSleepTime
- type Client
- func (c *Client) AddListMember(params *Values) (*List, error)
- func (c *Client) AddListMembers(params *Values) (*List, error)
- func (c *Client) CreateList(params *Values) (*List, error)
- func (c *Client) DeleteList(params *Values) (*List, error)
- func (c *Client) DeleteListMember(params *Values) (*List, error)
- func (c *Client) DeleteListMembers(params *Values) (*List, error)
- func (c *Client) GET(path string, params *Values, data interface{}) error
- func (c *Client) GetAccessToken(verifier string) error
- func (c *Client) GetAccountSettings(params *Values) (*AccountSettings, error)
- func (c *Client) GetFollowerIDs(params *Values) (*UserIDs, error)
- func (c *Client) GetFriendsIDs(params *Values) (*UserIDs, error)
- func (c *Client) GetList(params *Values) (*List, error)
- func (c *Client) GetListMembers(params *Values) (*ListMembers, error)
- func (c *Client) GetLists(params *Values) ([]List, error)
- func (c *Client) GetUser(params *Values) (*User, error)
- func (c *Client) GetUserProfileBanner(params *Values) (*Images, error)
- func (c *Client) GetUsers(params *Values) ([]User, error)
- func (c *Client) NewStreaming(method, urlStr string, params *Values) (*Streaming, error)
- func (c *Client) NewUserStream(params *Values) (*Streaming, error)
- func (c *Client) POST(path string, params *Values, data interface{}) error
- func (c *Client) ReportSpamUser(params *Values) (*User, error)
- func (c *Client) RequestTokenURL(callback string) (string, error)
- func (c *Client) SearchUsers(params *Values) ([]User, error)
- func (c *Client) UpdateAccountSettings(params *Values) (*AccountSettings, error)
- func (c *Client) VerifyCredentials(params *Values) (*User, error)
- type Contributor
- type Coordinates
- type Cursor
- type DirectMessage
- type Entities
- type Entity
- type Error
- type Errors
- type HashtagEntity
- type ID
- type Image
- type Images
- type List
- type ListMembers
- type MediaEntity
- type MediaEntitySize
- type MediaEntitySizes
- type Place
- type PlaceBoundingBox
- type Streaming
- type StreamingControlEvent
- type StreamingDeleteDirectMessageEvent
- type StreamingDeleteLocationEvent
- type StreamingDeleteTweetEvent
- type StreamingDeletedObject
- type StreamingDirectMessageEvent
- type StreamingDisconnectEvent
- type StreamingEnvelopeEvent
- type StreamingFriendsEvent
- type StreamingGeneralEvent
- type StreamingLimitEvent
- type StreamingListEvent
- type StreamingStatusWithheldEvent
- type StreamingTweetEvent
- type StreamingUserWithheldEvent
- type StreamingWarningEvent
- type StreamingWithheldObject
- type SymbolEntity
- type Time
- type TimeZone
- type TrendLocation
- type TrendPlaceType
- type Tweet
- type URLEntity
- type User
- type UserIDs
- type UserMentionEntity
- type Values
- type VideoInfo
- type VideoInfoVariant
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountSettings ¶
type AccountSettings struct {
AllowContributorRequest string `json:"allow_contributor_request"`
AllowDMsFrom string `json:"allow_dms_from"`
AllowDMGroupsFrom string `json:"allow_dm_groups_from"`
AlwaysUseHttps bool `json:"always_use_https"`
DiscoverableByEmail bool `json:"discoverable_by_email"`
DiscoverableByMobilePhone bool `json:"discoverable_by_mobile_phone"`
DisplaySensitiveMedia bool `json:"display_sensitive_media"`
GeoEnabled bool `json:"geo_enabled"`
Language string `json:"language"`
Protected bool `json:"protected"`
ScreenName string `json:"screen_name"`
ShowAllInlineMedia bool `json:"show_all_inline_media"`
SleepTime AccountSleepTime `json:"sleep_time"`
TimeZone TimeZone `json:"time_zone"`
TranslatorType string `json:"translator_type"`
TrendLocation []TrendLocation `json:"trend_location"`
UseCookiePersonalization bool `json:"use_cookie_personalization"`
}
type AccountSleepTime ¶
type Client ¶
type Client struct {
OAuthClient oauth.Client
AccessToken *oauth.Credentials
RequestToken *oauth.Credentials
URLFormat string
UserStreamURL string
}
func NewClient ¶
func NewClient(consumer, token *oauth.Credentials) *Client
func (*Client) DeleteListMembers ¶
func (*Client) GetAccessToken ¶
func (*Client) GetAccountSettings ¶
func (c *Client) GetAccountSettings(params *Values) (*AccountSettings, error)
func (*Client) GetListMembers ¶
func (c *Client) GetListMembers(params *Values) (*ListMembers, error)
func (*Client) GetUserProfileBanner ¶
func (*Client) NewStreaming ¶
func (*Client) UpdateAccountSettings ¶
func (c *Client) UpdateAccountSettings(params *Values) (*AccountSettings, error)
type Contributor ¶
type Coordinates ¶
type DirectMessage ¶
type DirectMessage struct {
ID
CreatedAt Time `json:"created_at"`
Entities Entities `json:"entities"`
Recipient User `json:"recipient"`
RecipientID int64 `json:"recipient_id"`
RecipientScreenName string `json:"recipient_screen_name"`
Sender User `json:"sender"`
SenderID int64 `json:"sender_id"`
SenderScreenName string `json:"sender_screen_name"`
Text string `json:"text"`
}
type Entities ¶
type Entities struct {
Media []MediaEntity `json:"media"`
URLs []URLEntity `json:"urls"`
UserMentions []UserMentionEntity `json:"user_mentions"`
Symbols []SymbolEntity `json:"symbols"`
}
type Errors ¶
type HashtagEntity ¶
type HashtagEntity SymbolEntity
type List ¶
type List struct {
ID
Slug string `json:"slug"`
Name string `json:"name"`
CreatedAt Time `json:"created_at"`
URI string `json:"uri"`
SubscriberCount int `json:"subscriber_count"`
MemberCount int `json:"member_count"`
Mode string `json:"mode"`
FullName string `json:"full_name"`
Description string `json:"description"`
User User `json:"user"`
Following bool `json:"following"`
}
type ListMembers ¶
type MediaEntity ¶
type MediaEntitySize ¶
type MediaEntitySizes ¶
type MediaEntitySizes struct {
Thumb MediaEntitySize `json:"thumb"`
Large MediaEntitySize `json:"large"`
Medium MediaEntitySize `json:"medium"`
Small MediaEntitySize `json:"small"`
}
type Place ¶
type Place struct {
Attributes map[string]string `json:"attributes"`
BoundingBox PlaceBoundingBox `json:"bounding_box"`
ContainedWithin []Place `json:"contained_within"`
Country string `json:"country"`
CountryCode string `json:"country_code"`
FullName string `json:"full_name"`
Geometry PlaceBoundingBox `json:"geometry"`
ID string `json:"id"`
Name string `json:"name"`
PlaceType string `json:"place_type"`
URL string `json:"url"`
}
type PlaceBoundingBox ¶
type Streaming ¶
type StreamingControlEvent ¶
type StreamingControlEvent struct {
Control struct {
ControlURI string `json:"control_uri"`
} `json:"control"`
}
type StreamingDeleteDirectMessageEvent ¶
type StreamingDeleteDirectMessageEvent struct {
Delete struct {
DirectMessage StreamingDeletedObject `json:"direct_message"`
} `json:"delete"`
}
type StreamingDeleteTweetEvent ¶
type StreamingDeleteTweetEvent struct {
Delete struct {
Status StreamingDeletedObject `json:"status"`
TimestampMS int64 `json:"timestamp_ms"`
} `json:"delete"`
}
type StreamingDeletedObject ¶
type StreamingDirectMessageEvent ¶
type StreamingDirectMessageEvent struct {
DirectMessage DirectMessage `json:"direct_message"`
}
type StreamingEnvelopeEvent ¶
type StreamingFriendsEvent ¶
type StreamingFriendsEvent struct {
Friends []int64 `json:"friends"`
}
type StreamingGeneralEvent ¶
type StreamingLimitEvent ¶
type StreamingLimitEvent struct {
Limit struct {
Track int `json:"track"`
} `json:"limit"`
}
type StreamingListEvent ¶
type StreamingListEvent struct {
StreamingGeneralEvent
TargetObject List `json:"target_object"`
}
type StreamingStatusWithheldEvent ¶
type StreamingStatusWithheldEvent struct {
StatusWithheld StreamingWithheldObject `json:"status_withheld"`
}
type StreamingTweetEvent ¶
type StreamingTweetEvent struct {
StreamingGeneralEvent
TargetObject Tweet `json:"target_object"`
}
type StreamingUserWithheldEvent ¶
type StreamingUserWithheldEvent struct {
UserWithheld StreamingWithheldObject `json:"user_withheld"`
}
type StreamingWarningEvent ¶
type StreamingWithheldObject ¶
type SymbolEntity ¶
type TrendLocation ¶
type TrendPlaceType ¶
type Tweet ¶
type Tweet struct {
ID
Contributors []Contributor `json:"contributors"`
Coordinates *Coordinates `json:"coordinates"`
CreatedAt Time `json:"created_at"`
CurrentUserRetweet ID `json:"current_user_retweet"`
Entities Entities `json:"entities"`
ExtendedEntities *Entities `json:"extended_entities"`
FavoriteCount *int `json:"favorite_count"`
Favorited *bool `json:"favorited"`
FilterLevel string `json:"filter_level"`
Geo *interface{} `json:"geo"`
InReplyToScreenName *string `json:"in_reply_to_screen_name"`
InReplyToStatusID *int64 `json:"in_reply_to_status_id"`
InReplyToStatusIDStr *string `json:"in_reply_to_status_id_str"`
InReplyToUserID *int64 `json:"in_reply_to_user_id"`
InReplyToUserIDStr *string `json:"in_reply_to_user_id_str"`
Lang *string `json:"lang"`
Place *Place `json:"place"`
PossiblySensitive *bool `json:"possibly_sensitive"`
QuotedStatusID *int64 `json:"quoted_status_id"`
QuotedStatusIDStr *string `json:"quoted_status_id_str"`
QuotedStatus *Tweet `json:"quoted_status"`
Scopes map[string]interface{} `json:"scopes"`
RetweetCount *int `json:"retweet_count"`
Retweeted bool `json:"retweeted"`
RetweetedStatus *Tweet `json:"retweeted_status"`
Source string `json:"source"`
Text string `json:"text"`
Truncated bool `json:"truncated"`
User User `json:"user"`
WithheldCopyright bool `json:"withheld_copyright"`
WithheldInCountries []string `json:"withheld_in_countries"`
WithheldScope string `json:"withheld_scope"`
}
type User ¶
type User struct {
ID
ContributorsEnabled bool `json:"contributors_enabled"`
CreatedAt Time `json:"created_at"`
DefaultProfile bool `json:"default_profile"`
DefaultProfileImage bool `json:"default_profile_image"`
Description *string `json:"description"`
Entities Entities `json:"entities"`
FavouritesCount int `json:"favourites_count"`
FollowRequestSent *bool `json:"follow_request_sent"`
Following *bool `json:"following"`
FollowersCount int `json:"followers_count"`
FriendsCount int `json:"friends_count"`
GeoEnabled bool `json:"geo_enabled"`
IsTranslator bool `json:"is_translator"`
Lang string `json:"lang"`
ListedCount int `json:"listed_count"`
Location *string `json:"location"`
Name string `json:"name"`
Notifications bool `json:"notifications"`
ProfileBackgroundColor string `json:"profile_background_color"`
ProfileBackgroundImageURL string `json:"profile_background_image_url"`
ProfileBackgroundImageURLHttps string `json:"profile_background_image_url_https"`
ProfileBackgroundTile bool `json:"profile_background_tile"`
ProfileBannerURL string `json:"profile_banner_url"`
ProfileImageURL string `json:"profile_image_url"`
ProfileImageURLHttps string `json:"profile_image_url_https"`
ProfileLinkColor string `json:"profile_link_color"`
ProfileSidebarBorderColor string `json:"profile_sidebar_border_color"`
ProfileSidebarFillColor string `json:"profile_sidebar_fill_color"`
ProfileTextColor string `json:"profile_text_color"`
ProfileUseBackgroundImage bool `json:"profile_use_background_image"`
Protected bool `json:"protected"`
ScreenName string `json:"screen_name"`
ShowAllInlineMedia bool `json:"show_all_inline_media"`
Status *Tweet `json:"status"`
StatusesCount int `json:"statuses_count"`
TimeZone *string `json:"time_zone"`
URL *string `json:"url"`
UTCOffset *int `json:"utc_offset"`
Verified bool `json:"verified"`
WithheldInCountries string `json:"withheld_in_countries"`
WithheldScope string `json:"withheld_scope"`
}
type UserMentionEntity ¶
type Values ¶
func (*Values) AddNextCursor ¶
func (*Values) AddPreviousCursor ¶
func (*Values) ToURLValues ¶
type VideoInfo ¶
type VideoInfo struct {
AspectRatio [2]int `json:"aspect_ratio"`
DurationMillis int `json:"duration_millis"`
Variants []VideoInfoVariant `json:"variants"`
}
type VideoInfoVariant ¶
Click to show internal directories.
Click to hide internal directories.