Versions in this module Expand all Collapse all v1 v1.0.0 Aug 18, 2024 Changes in this version + const DefaultClientTimeout + type AuthToken struct + CSRFToken string + Token string + type FollowAction int + const Follow + const Unfollow + type GIF struct + ID string + Preview string + URL string + type Media struct + ExpiresAt time.Time + ID int + Parts int + Size int + Type string + type Mention struct + ID string + Name string + Username string + type NewTweet struct + Medias []*Media + Text string + type OpenAccount struct + OAuthToken string + OAuthTokenSecret string + type Photo struct + ID string + URL string + type Place struct + BoundingBox struct{ ... } + Country string + CountryCode string + FullName string + ID string + Name string + PlaceType string + type ProcessingInfo struct + CheckAfter int + Progress int + State string + type Profile struct + Avatar string + Banner string + Biography string + Birthday string + FollowedBy bool + FollowersCount int + Following bool + FollowingCount int + FriendsCount int + IsPrivate bool + IsVerified bool + Joined *time.Time + LikesCount int + ListedCount int + Location string + Name string + PinnedTweetIDs []string + Sensitive bool + TweetsCount int + URL string + UserID string + Username string + Website string + type ProfileResult struct + Error error + type ScheduledTweet struct + ExecuteAt time.Time + GIFs []GIF + ID string + Photos []Photo + State string + Text string + Videos []Video + type Scraper struct + func New() *Scraper + func (s *Scraper) ClearCookies() + func (s *Scraper) ClearGuestToken() error + func (s *Scraper) CreateRetweet(tweetId string) (string, error) + func (s *Scraper) CreateScheduledTweet(schedule TweetSchedule) (string, error) + func (s *Scraper) CreateTweet(tweet NewTweet) (*Tweet, error) + func (s *Scraper) DeleteRetweet(tweetId string) error + func (s *Scraper) DeleteScheduledTweet(id string) error + func (s *Scraper) DeleteTweet(tweetId string) error + func (s *Scraper) FetchBookmarks(maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchFollowers(user string, maxUsersNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) FetchFollowersByUserID(userID string, maxUsersNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) FetchFollowing(user string, maxUsersNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) FetchFollowingByUserID(userID string, maxUsersNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) FetchForYouTweets(maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchHomeTweets(maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchMediaTweets(user string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchMediaTweetsByUserID(userID string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchScheduledTweets() ([]*ScheduledTweet, error) + func (s *Scraper) FetchSearchProfiles(query string, maxProfilesNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) FetchSearchTweets(query string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchTweets(user string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchTweetsByUserID(userID string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FetchTweetsByUserIDLegacy(userID string, maxTweetsNbr int, cursor string) ([]*Tweet, string, error) + func (s *Scraper) FollowUser(user string, followAction FollowAction) error + func (s *Scraper) GetBookmarks(ctx context.Context, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) GetCookies() []*http.Cookie + func (s *Scraper) GetForYouTweets(ctx context.Context, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) GetGuestToken() error + func (s *Scraper) GetHomeTweets(ctx context.Context, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) GetMediaTweets(ctx context.Context, user string, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) GetProfile(username string) (Profile, error) + func (s *Scraper) GetProfileByID(userID string) (Profile, error) + func (s *Scraper) GetSpace(id string) (*Space, error) + func (s *Scraper) GetTrends() ([]string, error) + func (s *Scraper) GetTweet(id string) (*Tweet, error) + func (s *Scraper) GetTweetReplies(id string, cursor string) ([]*Tweet, []*ThreadCursor, error) + func (s *Scraper) GetTweetRetweeters(tweetId string, maxUsersNbr int, cursor string) ([]*Profile, string, error) + func (s *Scraper) GetTweets(ctx context.Context, user string, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) GetUserIDByScreenName(screenName string) (string, error) + func (s *Scraper) IsGuestToken() bool + func (s *Scraper) IsLoggedIn() bool + func (s *Scraper) LikeTweet(tweetId string) error + func (s *Scraper) Login(credentials ...string) error + func (s *Scraper) LoginOpenAccount() (OpenAccount, error) + func (s *Scraper) Logout() error + func (s *Scraper) RequestAPI(req *http.Request, target interface{}) error + func (s *Scraper) SearchProfiles(ctx context.Context, query string, maxProfilesNbr int) <-chan *ProfileResult + func (s *Scraper) SearchTweets(ctx context.Context, query string, maxTweetsNbr int) <-chan *TweetResult + func (s *Scraper) SetAuthToken(token AuthToken) + func (s *Scraper) SetCookies(cookies []*http.Cookie) + func (s *Scraper) SetProxy(proxyAddr string) error + func (s *Scraper) SetSearchMode(mode SearchMode) *Scraper + func (s *Scraper) UnlikeTweet(tweetId string) error + func (s *Scraper) UploadMedia(filePath string) (*Media, error) + func (s *Scraper) WithClientTimeout(timeout time.Duration) *Scraper + func (s *Scraper) WithDelay(seconds int64) *Scraper + func (s *Scraper) WithOpenAccount(openAccount OpenAccount) + func (s *Scraper) WithReplies(b bool) *Scraper + type SearchMode int + const SearchLatest + const SearchPhotos + const SearchTop + const SearchUsers + const SearchVideos + type Space struct + ContentType string + CreatedAt time.Time + ID string + Participants SpaceParticipants + ScheduledStart time.Time + StartedAt time.Time + State string + Title string + Topics []Topic + UpdatedAt time.Time + type SpaceParticipants struct + Admins []*SpaceUser + CurrentCount int + Listeners []*SpaceUser + Speakers []*SpaceUser + TotalCount int + type SpaceUser struct + Avatar string + ConnectedAt time.Time + IsVerified bool + Name string + UserID string + Username string + type ThreadCursor struct + Cursor string + CursorType string + FocalTweetID string + ThreadID string + type Topic struct + ID string + Title string + type Tweet struct + ConversationID string + GIFs []GIF + HTML string + Hashtags []string + ID string + InReplyToStatus *Tweet + InReplyToStatusID string + IsPin bool + IsQuoted bool + IsReply bool + IsRetweet bool + IsSelfThread bool + Likes int + Mentions []Mention + Name string + PermanentURL string + Photos []Photo + Place *Place + QuotedStatus *Tweet + QuotedStatusID string + Replies int + RetweetedStatus *Tweet + RetweetedStatusID string + Retweets int + SensitiveContent bool + Text string + Thread []*Tweet + TimeParsed time.Time + Timestamp int64 + URLs []string + UserID string + Username string + Videos []Video + Views int + type TweetResult struct + Error error + type TweetSchedule struct + Date time.Time + Medias []*Media + Text string + type Video struct + HLSURL string + ID string + Preview string + URL string