forked from g8rswimmer/go-twitter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
expansions.go
43 lines (40 loc) · 2.23 KB
/
expansions.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package twitter
// Expansion can expand objects referenced in the payload
type Expansion string
const (
// ExpansionAttachmentsPollIDs returns a poll object containing metadata for the poll included in the Tweet
ExpansionAttachmentsPollIDs Expansion = "attachments.poll_ids"
// ExpansionAttachmentsMediaKeys returns a media object representing the images, videos, GIFs included in the Tweet
ExpansionAttachmentsMediaKeys Expansion = "attachments.media_keys"
// ExpansionAuthorID returns a user object representing the Tweet’s author
ExpansionAuthorID Expansion = "author_id"
// ExpansionEntitiesMentionsUserName returns a user object for the user mentioned in the Tweet
ExpansionEntitiesMentionsUserName Expansion = "entities.mentions.username"
// ExpansionGeoPlaceID returns a place object containing metadata for the location tagged in the Tweet
ExpansionGeoPlaceID Expansion = "geo.place_id"
// ExpansionInReplyToUserID returns a user object representing the Tweet author this requested Tweet is a reply of
ExpansionInReplyToUserID Expansion = "in_reply_to_user_id"
// ExpansionReferencedTweetsID returns a Tweet object that this Tweet is referencing (either as a Retweet, Quoted Tweet, or reply)
ExpansionReferencedTweetsID Expansion = "referenced_tweets.id"
// ExpansionReferencedTweetsIDAuthorID returns a user object for the author of the referenced Tweet
ExpansionReferencedTweetsIDAuthorID Expansion = "referenced_tweets.id.author_id"
// ExpansionPinnedTweetID returns a Tweet object representing the Tweet pinned to the top of the user’s profile
ExpansionPinnedTweetID Expansion = "pinned_tweet_id"
// ExpansionOwnerID returns an owner in the includes
ExpansionOwnerID Expansion = "owner_id"
// ExpansionCreatorID returns the creator id
ExpansionCreatorID Expansion = "creator_id"
// ExpansionSpeakerIDS returns the speaker ids
ExpansionSpeakerIDS Expansion = "speaker_ids"
// ExpansionInvitedUserIDs returns the invited user ids
ExpansionInvitedUserIDs Expansion = "invited_user_ids"
// ExpansionHostIDs returns the host ids
ExpansionHostIDs Expansion = "host_ids"
)
func expansionStringArray(arr []Expansion) []string {
strs := make([]string, len(arr))
for i, expansion := range arr {
strs[i] = string(expansion)
}
return strs
}