@glagan/rettiwt-api 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. package/.eslintrc.js +166 -0
  2. package/.gitattributes +3 -0
  3. package/.github/FUNDING.yml +4 -0
  4. package/.github/ISSUE_TEMPLATE/bug-report.yml +57 -0
  5. package/.github/ISSUE_TEMPLATE/feature-request.yml +20 -0
  6. package/.github/ISSUE_TEMPLATE/question.yml +15 -0
  7. package/.github/PULL_REQUEST_TEMPLATE.md +32 -0
  8. package/.github/workflows/ci.yml +32 -0
  9. package/.github/workflows/publish.yml +23 -0
  10. package/.nvmrc +1 -0
  11. package/.prettierignore +3 -0
  12. package/.prettierrc +13 -0
  13. package/LICENSE +21 -0
  14. package/README.md +566 -0
  15. package/dist/cli.js +43 -0
  16. package/eslint.config.mjs +17 -0
  17. package/package.json +50 -0
  18. package/src/Rettiwt.ts +97 -0
  19. package/src/cli.ts +48 -0
  20. package/src/collections/Extractors.ts +155 -0
  21. package/src/collections/Groups.ts +81 -0
  22. package/src/collections/Requests.ts +89 -0
  23. package/src/collections/Tweet.ts +17 -0
  24. package/src/commands/DirectMessage.ts +62 -0
  25. package/src/commands/List.ts +90 -0
  26. package/src/commands/Tweet.ts +437 -0
  27. package/src/commands/User.ts +367 -0
  28. package/src/enums/Api.ts +10 -0
  29. package/src/enums/Authentication.ts +10 -0
  30. package/src/enums/Data.ts +13 -0
  31. package/src/enums/Logging.ts +14 -0
  32. package/src/enums/Media.ts +10 -0
  33. package/src/enums/Notification.ts +12 -0
  34. package/src/enums/Resource.ts +69 -0
  35. package/src/enums/Tweet.ts +8 -0
  36. package/src/enums/raw/Analytics.ts +32 -0
  37. package/src/enums/raw/Media.ts +10 -0
  38. package/src/enums/raw/Notification.ts +11 -0
  39. package/src/enums/raw/Tweet.ts +20 -0
  40. package/src/helper/CliUtils.ts +17 -0
  41. package/src/helper/JsonUtils.ts +70 -0
  42. package/src/index.ts +128 -0
  43. package/src/models/RettiwtConfig.ts +101 -0
  44. package/src/models/args/FetchArgs.ts +169 -0
  45. package/src/models/args/PostArgs.ts +93 -0
  46. package/src/models/args/ProfileArgs.ts +68 -0
  47. package/src/models/auth/AuthCookie.ts +58 -0
  48. package/src/models/auth/AuthCredential.ts +83 -0
  49. package/src/models/data/Analytics.ts +97 -0
  50. package/src/models/data/BookmarkFolder.ts +73 -0
  51. package/src/models/data/Conversation.ts +344 -0
  52. package/src/models/data/CursoredData.ts +64 -0
  53. package/src/models/data/DirectMessage.ts +335 -0
  54. package/src/models/data/Inbox.ts +124 -0
  55. package/src/models/data/List.ts +113 -0
  56. package/src/models/data/Notification.ts +84 -0
  57. package/src/models/data/Tweet.ts +388 -0
  58. package/src/models/data/User.ts +187 -0
  59. package/src/models/errors/TwitterError.ts +65 -0
  60. package/src/models/params/Variables.ts +62 -0
  61. package/src/requests/DirectMessage.ts +229 -0
  62. package/src/requests/List.ts +203 -0
  63. package/src/requests/Media.ts +67 -0
  64. package/src/requests/Tweet.ts +607 -0
  65. package/src/requests/User.ts +1191 -0
  66. package/src/services/internal/AuthService.ts +115 -0
  67. package/src/services/internal/ErrorService.ts +41 -0
  68. package/src/services/internal/LogService.ts +34 -0
  69. package/src/services/public/DirectMessageService.ts +159 -0
  70. package/src/services/public/FetcherService.ts +366 -0
  71. package/src/services/public/ListService.ts +241 -0
  72. package/src/services/public/TweetService.ts +886 -0
  73. package/src/services/public/UserService.ts +1154 -0
  74. package/src/types/ErrorHandler.ts +13 -0
  75. package/src/types/Fetch.ts +3 -0
  76. package/src/types/RettiwtConfig.ts +48 -0
  77. package/src/types/args/FetchArgs.ts +233 -0
  78. package/src/types/args/PostArgs.ts +142 -0
  79. package/src/types/args/ProfileArgs.ts +33 -0
  80. package/src/types/auth/AuthCookie.ts +22 -0
  81. package/src/types/auth/AuthCredential.ts +28 -0
  82. package/src/types/auth/TransactionHeader.ts +8 -0
  83. package/src/types/data/Analytics.ts +58 -0
  84. package/src/types/data/BookmarkFolder.ts +12 -0
  85. package/src/types/data/Conversation.ts +44 -0
  86. package/src/types/data/CursoredData.ts +24 -0
  87. package/src/types/data/DirectMessage.ts +33 -0
  88. package/src/types/data/Inbox.ts +23 -0
  89. package/src/types/data/List.ts +33 -0
  90. package/src/types/data/Notification.ts +26 -0
  91. package/src/types/data/Tweet.ts +99 -0
  92. package/src/types/data/User.ts +54 -0
  93. package/src/types/errors/TwitterError.ts +37 -0
  94. package/src/types/params/Variables.ts +41 -0
  95. package/src/types/raw/base/Analytic.ts +32 -0
  96. package/src/types/raw/base/BookmarkFolder.ts +12 -0
  97. package/src/types/raw/base/Cursor.ts +13 -0
  98. package/src/types/raw/base/Error.ts +38 -0
  99. package/src/types/raw/base/LimitedVisibilityTweet.ts +40 -0
  100. package/src/types/raw/base/List.ts +50 -0
  101. package/src/types/raw/base/Media.ts +53 -0
  102. package/src/types/raw/base/Message.ts +22 -0
  103. package/src/types/raw/base/Notification.ts +66 -0
  104. package/src/types/raw/base/Space.ts +35 -0
  105. package/src/types/raw/base/Tweet.ts +139 -0
  106. package/src/types/raw/base/User.ts +182 -0
  107. package/src/types/raw/composite/DataResult.ts +8 -0
  108. package/src/types/raw/composite/TimelineList.ts +10 -0
  109. package/src/types/raw/composite/TimelineTweet.ts +14 -0
  110. package/src/types/raw/composite/TimelineUser.ts +13 -0
  111. package/src/types/raw/dm/Conversation.ts +59 -0
  112. package/src/types/raw/dm/InboxInitial.ts +155 -0
  113. package/src/types/raw/dm/InboxTimeline.ts +301 -0
  114. package/src/types/raw/dm/UserUpdates.ts +46 -0
  115. package/src/types/raw/generic/Response.ts +10 -0
  116. package/src/types/raw/list/AddMember.ts +175 -0
  117. package/src/types/raw/list/Details.ts +176 -0
  118. package/src/types/raw/list/Members.ts +154 -0
  119. package/src/types/raw/list/RemoveMember.ts +174 -0
  120. package/src/types/raw/list/Tweets.ts +2296 -0
  121. package/src/types/raw/media/FinalizeUpload.ts +20 -0
  122. package/src/types/raw/media/InitalizeUpload.ts +12 -0
  123. package/src/types/raw/media/LiveVideoStream.ts +21 -0
  124. package/src/types/raw/space/Details.ts +359 -0
  125. package/src/types/raw/tweet/Bookmark.ts +14 -0
  126. package/src/types/raw/tweet/Details.ts +210 -0
  127. package/src/types/raw/tweet/DetailsBulk.ts +338 -0
  128. package/src/types/raw/tweet/Like.ts +14 -0
  129. package/src/types/raw/tweet/Likers.ts +200 -0
  130. package/src/types/raw/tweet/Post.ts +150 -0
  131. package/src/types/raw/tweet/Replies.ts +539 -0
  132. package/src/types/raw/tweet/Retweet.ts +31 -0
  133. package/src/types/raw/tweet/Retweeters.ts +208 -0
  134. package/src/types/raw/tweet/Schedule.ts +18 -0
  135. package/src/types/raw/tweet/Search.ts +597 -0
  136. package/src/types/raw/tweet/Unbookmark.ts +14 -0
  137. package/src/types/raw/tweet/Unlike.ts +14 -0
  138. package/src/types/raw/tweet/Unpost.ts +20 -0
  139. package/src/types/raw/tweet/Unretweet.ts +31 -0
  140. package/src/types/raw/tweet/Unschedule.ts +14 -0
  141. package/src/types/raw/user/Affiliates.ts +179 -0
  142. package/src/types/raw/user/Analytics.ts +23 -0
  143. package/src/types/raw/user/BookmarkFolderTweets.ts +53 -0
  144. package/src/types/raw/user/BookmarkFolders.ts +41 -0
  145. package/src/types/raw/user/Bookmarks.ts +637 -0
  146. package/src/types/raw/user/Details.ts +185 -0
  147. package/src/types/raw/user/DetailsBulk.ts +104 -0
  148. package/src/types/raw/user/Follow.ts +280 -0
  149. package/src/types/raw/user/Followed.ts +1942 -0
  150. package/src/types/raw/user/Followers.ts +215 -0
  151. package/src/types/raw/user/Following.ts +215 -0
  152. package/src/types/raw/user/Highlights.ts +1287 -0
  153. package/src/types/raw/user/Likes.ts +1254 -0
  154. package/src/types/raw/user/Lists.ts +378 -0
  155. package/src/types/raw/user/Media.ts +1738 -0
  156. package/src/types/raw/user/Notifications.ts +499 -0
  157. package/src/types/raw/user/ProfileUpdate.ts +80 -0
  158. package/src/types/raw/user/Recommended.ts +2319 -0
  159. package/src/types/raw/user/Scheduled.ts +37 -0
  160. package/src/types/raw/user/Search.ts +230 -0
  161. package/src/types/raw/user/Subscriptions.ts +176 -0
  162. package/src/types/raw/user/Tweets.ts +1254 -0
  163. package/src/types/raw/user/TweetsAndReplies.ts +1254 -0
  164. package/src/types/raw/user/Unfollow.ts +280 -0
  165. package/tsconfig.json +97 -0
@@ -0,0 +1,301 @@
1
+ /* eslint-disable */
2
+
3
+ import { Users, Conversations } from './InboxInitial';
4
+
5
+ /**
6
+ * The raw data received when fetching the inbox timeline.
7
+ *
8
+ * @public
9
+ */
10
+ export interface IInboxTimelineResponse {
11
+ inbox_timeline: InboxTimeline;
12
+ }
13
+
14
+ interface InboxTimeline {
15
+ status: 'HAS_MORE' | 'AT_END';
16
+ min_entry_id: string;
17
+ entries: TimelineEntry[];
18
+ users: Users;
19
+ conversations: Conversations;
20
+ }
21
+
22
+ type TimelineEntry =
23
+ | { trust_conversation: TrustConversation }
24
+ | { message: TimelineMessage }
25
+ | { participants_leave: ParticipantsLeave };
26
+
27
+ interface TrustConversation {
28
+ id: string;
29
+ time: string;
30
+ affects_sort: boolean;
31
+ request_id: string;
32
+ conversation_id: string;
33
+ reason: string; // e.g., "accept"
34
+ }
35
+
36
+ export interface TimelineMessage {
37
+ id: string;
38
+ time: string;
39
+ affects_sort: boolean;
40
+ request_id: string;
41
+ conversation_id: string;
42
+ message_data: TimelineMessageData;
43
+ }
44
+
45
+ interface TimelineMessageData {
46
+ id: string;
47
+ time: string;
48
+ recipient_id?: string;
49
+ sender_id: string;
50
+ conversation_id?: string;
51
+ text: string;
52
+ edit_count: number;
53
+ entities?: MessageEntities;
54
+ reply_data?: ReplyData;
55
+ attachment?: MessageAttachment;
56
+ }
57
+
58
+ interface MessageEntities {
59
+ hashtags: any[];
60
+ symbols: any[];
61
+ user_mentions: UserMention[];
62
+ urls: UrlEntity[];
63
+ }
64
+
65
+ interface UserMention {
66
+ screen_name: string;
67
+ name: string;
68
+ id: number;
69
+ id_str: string;
70
+ indices: [number, number];
71
+ }
72
+
73
+ interface UrlEntity {
74
+ url: string;
75
+ expanded_url: string;
76
+ display_url: string;
77
+ indices: [number, number];
78
+ }
79
+
80
+ interface ReplyData {
81
+ id: string;
82
+ time: string;
83
+ recipient_id: string;
84
+ sender_id: string;
85
+ text: string;
86
+ edit_count: number;
87
+ entities?: MessageEntities;
88
+ }
89
+
90
+ interface MessageAttachment {
91
+ card?: CardAttachment;
92
+ tweet?: TweetAttachment;
93
+ }
94
+
95
+ interface CardAttachment {
96
+ name: string;
97
+ url: string;
98
+ card_type_url: string;
99
+ binding_values: CardBindingValues;
100
+ }
101
+
102
+ interface CardBindingValues {
103
+ vanity_url?: StringValue;
104
+ domain?: StringValue;
105
+ title?: StringValue;
106
+ description?: StringValue;
107
+ thumbnail_image_small?: ImageValue;
108
+ thumbnail_image?: ImageValue;
109
+ thumbnail_image_large?: ImageValue;
110
+ thumbnail_image_x_large?: ImageValue;
111
+ thumbnail_image_color?: ImageColorValue;
112
+ thumbnail_image_original?: ImageValue;
113
+ summary_photo_image_small?: ImageValue;
114
+ summary_photo_image?: ImageValue;
115
+ summary_photo_image_large?: ImageValue;
116
+ summary_photo_image_x_large?: ImageValue;
117
+ summary_photo_image_color?: ImageColorValue;
118
+ summary_photo_image_original?: ImageValue;
119
+ photo_image_full_size_small?: ImageValue;
120
+ photo_image_full_size?: ImageValue;
121
+ photo_image_full_size_large?: ImageValue;
122
+ photo_image_full_size_x_large?: ImageValue;
123
+ photo_image_full_size_color?: ImageColorValue;
124
+ photo_image_full_size_original?: ImageValue;
125
+ card_url?: StringValue;
126
+ }
127
+
128
+ interface StringValue {
129
+ type: 'STRING';
130
+ string_value: string;
131
+ scribe_key?: string;
132
+ }
133
+
134
+ interface ImageValue {
135
+ type: 'IMAGE';
136
+ image_value: {
137
+ url: string;
138
+ width: number;
139
+ height: number;
140
+ alt: string | null;
141
+ };
142
+ }
143
+
144
+ interface ImageColorValue {
145
+ type: 'IMAGE_COLOR';
146
+ image_color_value: {
147
+ palette: ColorPalette[];
148
+ };
149
+ }
150
+
151
+ interface ColorPalette {
152
+ percentage: number;
153
+ rgb: {
154
+ red: number;
155
+ green: number;
156
+ blue: number;
157
+ };
158
+ }
159
+
160
+ interface TweetAttachment {
161
+ id: string;
162
+ url: string;
163
+ display_url: string;
164
+ expanded_url: string;
165
+ indices: [number, number];
166
+ status: TwitterStatus;
167
+ }
168
+
169
+ interface TwitterStatus {
170
+ created_at: string;
171
+ id: number;
172
+ id_str: string;
173
+ full_text: string;
174
+ truncated: boolean;
175
+ display_text_range: [number, number];
176
+ entities: MessageEntities;
177
+ source: string;
178
+ in_reply_to_status_id: number | null;
179
+ in_reply_to_status_id_str: string | null;
180
+ in_reply_to_user_id: number | null;
181
+ in_reply_to_user_id_str: string | null;
182
+ in_reply_to_screen_name: string | null;
183
+ user: TwitterUser;
184
+ geo: any;
185
+ coordinates: any;
186
+ place: any;
187
+ contributors: any;
188
+ is_quote_status: boolean;
189
+ retweet_count: number;
190
+ favorite_count: number;
191
+ reply_count: number;
192
+ quote_count: number;
193
+ favorited: boolean;
194
+ retweeted: boolean;
195
+ lang: string;
196
+ supplemental_language: string | null;
197
+ ext: TwitterExtensions;
198
+ }
199
+
200
+ interface TwitterUser {
201
+ id: number;
202
+ id_str: string;
203
+ name: string;
204
+ screen_name: string;
205
+ location: string;
206
+ description: string;
207
+ url: string;
208
+ entities: UserEntityInfo;
209
+ protected: boolean;
210
+ followers_count: number;
211
+ fast_followers_count: number;
212
+ normal_followers_count: number;
213
+ friends_count: number;
214
+ listed_count: number;
215
+ created_at: string;
216
+ favourites_count: number;
217
+ utc_offset: any;
218
+ time_zone: any;
219
+ geo_enabled: boolean;
220
+ verified: boolean;
221
+ statuses_count: number;
222
+ media_count: number;
223
+ lang: any;
224
+ contributors_enabled: boolean;
225
+ is_translator: boolean;
226
+ is_translation_enabled: boolean;
227
+ profile_background_color: string;
228
+ profile_background_image_url: string | null;
229
+ profile_background_image_url_https: string | null;
230
+ profile_background_tile: boolean;
231
+ profile_image_url: string;
232
+ profile_image_url_https: string;
233
+ profile_banner_url: string;
234
+ profile_link_color: string;
235
+ profile_sidebar_border_color: string;
236
+ profile_sidebar_fill_color: string;
237
+ profile_text_color: string;
238
+ profile_use_background_image: boolean;
239
+ default_profile: boolean;
240
+ default_profile_image: boolean;
241
+ pinned_tweet_ids: number[];
242
+ pinned_tweet_ids_str: string[];
243
+ has_custom_timelines: boolean;
244
+ can_dm: any;
245
+ can_media_tag: boolean;
246
+ following: boolean;
247
+ follow_request_sent: boolean;
248
+ notifications: boolean;
249
+ muting: any;
250
+ blocking: boolean;
251
+ blocked_by: boolean;
252
+ want_retweets: boolean;
253
+ advertiser_account_type: string;
254
+ advertiser_account_service_levels: any[];
255
+ business_profile_state: string;
256
+ translator_type: string;
257
+ withheld_in_countries: any[];
258
+ followed_by: boolean;
259
+ ext: TwitterExtensions;
260
+ require_some_consent: boolean;
261
+ }
262
+
263
+ interface UserEntityInfo {
264
+ url: {
265
+ urls: UrlEntity[];
266
+ };
267
+ description: {
268
+ urls: UrlEntity[];
269
+ };
270
+ }
271
+
272
+ interface TwitterExtensions {
273
+ businessAffiliationsLabel?: {
274
+ r: { ok: any };
275
+ ttl: number;
276
+ };
277
+ superFollowMetadata?: {
278
+ r: { ok: any };
279
+ ttl: number;
280
+ };
281
+ parodyCommentaryFanLabel?: {
282
+ r: { ok: string };
283
+ ttl: number;
284
+ };
285
+ highlightedLabel?: {
286
+ r: { ok: any };
287
+ ttl: number;
288
+ };
289
+ }
290
+
291
+ interface ParticipantsLeave {
292
+ id: string;
293
+ time: string;
294
+ affects_sort: boolean;
295
+ conversation_id: string;
296
+ participants: ParticipantInfo[];
297
+ }
298
+
299
+ interface ParticipantInfo {
300
+ user_id: string;
301
+ }
@@ -0,0 +1,46 @@
1
+ /* eslint-disable */
2
+
3
+ import { Users, Conversations, InboxInitialState } from './InboxInitial';
4
+
5
+ /**
6
+ * The raw data received when fetching user updates from the DM system.
7
+ * The response structure varies based on query parameters.
8
+ *
9
+ * @public
10
+ */
11
+ export interface IUserUpdatesResponse {
12
+ user_events?: UserEvents;
13
+ inbox_initial_state?: InboxInitialState;
14
+ }
15
+
16
+ /**
17
+ * User events can have different structures based on the request type:
18
+ * - With active_conversation_id + cursor: Full data with users and conversations
19
+ * - Without active_conversation_id and cursor: Same as inbox initial (see IInboxInitialResponse)
20
+ * - With cursor only: Minimal data with just event IDs and cursor
21
+ */
22
+ type UserEvents = UserEventsWithData | UserEventsMinimal;
23
+
24
+ /**
25
+ * Full user events data returned when requesting with active_conversation_id and cursor.
26
+ * Used for conversation-specific updates with user and conversation context.
27
+ */
28
+ interface UserEventsWithData {
29
+ cursor: string;
30
+ last_seen_event_id: string;
31
+ trusted_last_seen_event_id: string;
32
+ untrusted_last_seen_event_id: string;
33
+ users: Users;
34
+ conversations: Conversations;
35
+ }
36
+
37
+ /**
38
+ * Minimal user events data returned when requesting with cursor only (no active_conversation_id).
39
+ * Used for lightweight polling of event state without full data.
40
+ */
41
+ interface UserEventsMinimal {
42
+ cursor: string;
43
+ last_seen_event_id: string;
44
+ trusted_last_seen_event_id: string;
45
+ untrusted_last_seen_event_id: string;
46
+ }
@@ -0,0 +1,10 @@
1
+ /**
2
+ * The generic raw data received.
3
+ *
4
+ * @typeParam DataType - The type of data contained in the response, incase of successful request.
5
+ *
6
+ * @public
7
+ */
8
+ export interface IResponse<DataType> {
9
+ data: DataType;
10
+ }
@@ -0,0 +1,175 @@
1
+ /* eslint-disable */
2
+
3
+ /**
4
+ * The raw data received after adding a member to a tweet list.
5
+ *
6
+ * @public
7
+ */
8
+ export interface IListMemberAddResponse {
9
+ data: Data;
10
+ }
11
+
12
+ export interface Data {
13
+ list: List;
14
+ }
15
+
16
+ export interface List {
17
+ created_at: number;
18
+ default_banner_media: DefaultBannerMedia;
19
+ default_banner_media_results: DefaultBannerMediaResults;
20
+ description: string;
21
+ facepile_urls: any[];
22
+ following: boolean;
23
+ id: string;
24
+ id_str: string;
25
+ is_member: boolean;
26
+ member_count: number;
27
+ members_context: string;
28
+ mode: string;
29
+ muting: boolean;
30
+ name: string;
31
+ pinning: boolean;
32
+ subscriber_count: number;
33
+ user_results: UserResults;
34
+ }
35
+
36
+ export interface DefaultBannerMedia {
37
+ media_info: MediaInfo;
38
+ }
39
+
40
+ export interface MediaInfo {
41
+ original_img_url: string;
42
+ original_img_width: number;
43
+ original_img_height: number;
44
+ salient_rect: SalientRect;
45
+ }
46
+
47
+ export interface SalientRect {
48
+ left: number;
49
+ top: number;
50
+ width: number;
51
+ height: number;
52
+ }
53
+
54
+ export interface DefaultBannerMediaResults {
55
+ result: Result;
56
+ }
57
+
58
+ export interface Result {
59
+ id: string;
60
+ media_key: string;
61
+ media_id: string;
62
+ media_info: MediaInfo2;
63
+ __typename: string;
64
+ }
65
+
66
+ export interface MediaInfo2 {
67
+ __typename: string;
68
+ original_img_height: number;
69
+ original_img_width: number;
70
+ original_img_url: string;
71
+ salient_rect: SalientRect2;
72
+ }
73
+
74
+ export interface SalientRect2 {
75
+ height: number;
76
+ left: number;
77
+ top: number;
78
+ width: number;
79
+ }
80
+
81
+ export interface UserResults {
82
+ result: Result2;
83
+ }
84
+
85
+ export interface Result2 {
86
+ __typename: string;
87
+ id: string;
88
+ rest_id: string;
89
+ affiliates_highlighted_label: AffiliatesHighlightedLabel;
90
+ avatar: Avatar;
91
+ core: Core;
92
+ dm_permissions: DmPermissions;
93
+ has_graduated_access: boolean;
94
+ is_blue_verified: boolean;
95
+ legacy: Legacy;
96
+ location: Location;
97
+ media_permissions: MediaPermissions;
98
+ parody_commentary_fan_label: string;
99
+ profile_image_shape: string;
100
+ privacy: Privacy;
101
+ relationship_perspectives: RelationshipPerspectives;
102
+ tipjar_settings: TipjarSettings;
103
+ verification: Verification;
104
+ verified_phone_status: boolean;
105
+ }
106
+
107
+ export interface AffiliatesHighlightedLabel {}
108
+
109
+ export interface Avatar {
110
+ image_url: string;
111
+ }
112
+
113
+ export interface Core {
114
+ created_at: string;
115
+ name: string;
116
+ screen_name: string;
117
+ }
118
+
119
+ export interface DmPermissions {
120
+ can_dm: boolean;
121
+ }
122
+
123
+ export interface Legacy {
124
+ default_profile: boolean;
125
+ default_profile_image: boolean;
126
+ description: string;
127
+ entities: Entities;
128
+ fast_followers_count: number;
129
+ favourites_count: number;
130
+ followers_count: number;
131
+ friends_count: number;
132
+ has_custom_timelines: boolean;
133
+ is_translator: boolean;
134
+ listed_count: number;
135
+ media_count: number;
136
+ needs_phone_verification: boolean;
137
+ normal_followers_count: number;
138
+ pinned_tweet_ids_str: any[];
139
+ possibly_sensitive: boolean;
140
+ profile_interstitial_type: string;
141
+ statuses_count: number;
142
+ translator_type: string;
143
+ want_retweets: boolean;
144
+ withheld_in_countries: any[];
145
+ }
146
+
147
+ export interface Entities {
148
+ description: Description;
149
+ }
150
+
151
+ export interface Description {
152
+ urls: any[];
153
+ }
154
+
155
+ export interface Location {
156
+ location: string;
157
+ }
158
+
159
+ export interface MediaPermissions {
160
+ can_media_tag: boolean;
161
+ }
162
+
163
+ export interface Privacy {
164
+ protected: boolean;
165
+ }
166
+
167
+ export interface RelationshipPerspectives {
168
+ following: boolean;
169
+ }
170
+
171
+ export interface TipjarSettings {}
172
+
173
+ export interface Verification {
174
+ verified: boolean;
175
+ }
@@ -0,0 +1,176 @@
1
+ /* eslint-disable */
2
+
3
+ /**
4
+ * The raw data received when fetching the details of a tweet list.
5
+ *
6
+ * @public
7
+ */
8
+ export interface IListDetailsResponse {
9
+ data: Data;
10
+ }
11
+
12
+ interface Data {
13
+ list: List;
14
+ }
15
+
16
+ interface List {
17
+ created_at: number;
18
+ default_banner_media: DefaultBannerMedia;
19
+ default_banner_media_results: DefaultBannerMediaResults;
20
+ description: string;
21
+ facepile_urls: string[];
22
+ followers_context: string;
23
+ following: boolean;
24
+ id: string;
25
+ id_str: string;
26
+ is_member: boolean;
27
+ member_count: number;
28
+ members_context: string;
29
+ mode: string;
30
+ muting: boolean;
31
+ name: string;
32
+ pinning: boolean;
33
+ subscriber_count: number;
34
+ user_results: UserResults;
35
+ }
36
+
37
+ interface DefaultBannerMedia {
38
+ media_info: MediaInfo;
39
+ }
40
+
41
+ interface MediaInfo {
42
+ original_img_url: string;
43
+ original_img_width: number;
44
+ original_img_height: number;
45
+ salient_rect: SalientRect;
46
+ }
47
+
48
+ interface SalientRect {
49
+ left: number;
50
+ top: number;
51
+ width: number;
52
+ height: number;
53
+ }
54
+
55
+ interface DefaultBannerMediaResults {
56
+ result: Result;
57
+ }
58
+
59
+ interface Result {
60
+ id: string;
61
+ media_key: string;
62
+ media_id: string;
63
+ media_info: MediaInfo2;
64
+ __typename: string;
65
+ }
66
+
67
+ interface MediaInfo2 {
68
+ __typename: string;
69
+ original_img_height: number;
70
+ original_img_width: number;
71
+ original_img_url: string;
72
+ salient_rect: SalientRect2;
73
+ }
74
+
75
+ interface SalientRect2 {
76
+ height: number;
77
+ left: number;
78
+ top: number;
79
+ width: number;
80
+ }
81
+
82
+ interface UserResults {
83
+ result: Result2;
84
+ }
85
+
86
+ interface Result2 {
87
+ __typename: string;
88
+ id: string;
89
+ rest_id: string;
90
+ affiliates_highlighted_label: AffiliatesHighlightedLabel;
91
+ avatar: Avatar;
92
+ core: Core;
93
+ dm_permissions: DmPermissions;
94
+ has_graduated_access: boolean;
95
+ is_blue_verified: boolean;
96
+ legacy: Legacy;
97
+ location: Location;
98
+ media_permissions: MediaPermissions;
99
+ parody_commentary_fan_label: string;
100
+ profile_image_shape: string;
101
+ privacy: Privacy;
102
+ relationship_perspectives: RelationshipPerspectives;
103
+ tipjar_settings: TipjarSettings;
104
+ verification: Verification;
105
+ verified_phone_status: boolean;
106
+ }
107
+
108
+ interface AffiliatesHighlightedLabel {}
109
+
110
+ interface Avatar {
111
+ image_url: string;
112
+ }
113
+
114
+ interface Core {
115
+ created_at: string;
116
+ name: string;
117
+ screen_name: string;
118
+ }
119
+
120
+ interface DmPermissions {
121
+ can_dm: boolean;
122
+ }
123
+
124
+ interface Legacy {
125
+ default_profile: boolean;
126
+ default_profile_image: boolean;
127
+ description: string;
128
+ entities: Entities;
129
+ fast_followers_count: number;
130
+ favourites_count: number;
131
+ followers_count: number;
132
+ friends_count: number;
133
+ has_custom_timelines: boolean;
134
+ is_translator: boolean;
135
+ listed_count: number;
136
+ media_count: number;
137
+ normal_followers_count: number;
138
+ pinned_tweet_ids_str: string[];
139
+ possibly_sensitive: boolean;
140
+ profile_banner_url: string;
141
+ profile_interstitial_type: string;
142
+ statuses_count: number;
143
+ translator_type: string;
144
+ want_retweets: boolean;
145
+ withheld_in_countries: any[];
146
+ }
147
+
148
+ interface Entities {
149
+ description: Description;
150
+ }
151
+
152
+ interface Description {
153
+ urls: any[];
154
+ }
155
+
156
+ interface Location {
157
+ location: string;
158
+ }
159
+
160
+ interface MediaPermissions {
161
+ can_media_tag: boolean;
162
+ }
163
+
164
+ interface Privacy {
165
+ protected: boolean;
166
+ }
167
+
168
+ interface RelationshipPerspectives {
169
+ following: boolean;
170
+ }
171
+
172
+ interface TipjarSettings {}
173
+
174
+ interface Verification {
175
+ verified: boolean;
176
+ }