rettiwt-api 5.0.0-alpha.1 → 5.0.0-alpha.3

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 (406) hide show
  1. package/dist/Rettiwt.d.ts +10 -3
  2. package/dist/Rettiwt.js +19 -7
  3. package/dist/Rettiwt.js.map +1 -1
  4. package/dist/collections/Extractors.d.ts +35 -2
  5. package/dist/collections/Extractors.js +3 -0
  6. package/dist/collections/Extractors.js.map +1 -1
  7. package/dist/collections/Groups.js +3 -0
  8. package/dist/collections/Groups.js.map +1 -1
  9. package/dist/collections/Requests.js +41 -41
  10. package/dist/collections/Requests.js.map +1 -1
  11. package/dist/commands/Tweet.js +33 -7
  12. package/dist/commands/Tweet.js.map +1 -1
  13. package/dist/commands/User.js +12 -2
  14. package/dist/commands/User.js.map +1 -1
  15. package/dist/enums/Authentication.d.ts +2 -10
  16. package/dist/enums/Authentication.js +3 -12
  17. package/dist/enums/Authentication.js.map +1 -1
  18. package/dist/enums/Data.d.ts +3 -15
  19. package/dist/enums/Data.js +4 -17
  20. package/dist/enums/Data.js.map +1 -1
  21. package/dist/enums/Media.d.ts +10 -0
  22. package/dist/enums/Media.js +15 -0
  23. package/dist/enums/Media.js.map +1 -0
  24. package/dist/enums/Notification.d.ts +12 -0
  25. package/dist/enums/Notification.js +17 -0
  26. package/dist/enums/Notification.js.map +1 -0
  27. package/dist/enums/Resource.d.ts +3 -0
  28. package/dist/enums/Resource.js +3 -0
  29. package/dist/enums/Resource.js.map +1 -1
  30. package/dist/enums/raw/Analytics.d.ts +28 -0
  31. package/dist/enums/raw/Analytics.js +34 -0
  32. package/dist/enums/raw/Analytics.js.map +1 -0
  33. package/dist/enums/raw/Media.d.ts +10 -0
  34. package/dist/enums/raw/Media.js +15 -0
  35. package/dist/enums/raw/Media.js.map +1 -0
  36. package/dist/enums/raw/Notification.d.ts +11 -0
  37. package/dist/enums/raw/Notification.js +16 -0
  38. package/dist/enums/raw/Notification.js.map +1 -0
  39. package/dist/enums/raw/Tweet.d.ts +9 -0
  40. package/dist/enums/raw/Tweet.js +14 -0
  41. package/dist/enums/raw/Tweet.js.map +1 -0
  42. package/dist/helper/TidUtils.d.ts +2 -0
  43. package/dist/helper/TidUtils.js +162 -0
  44. package/dist/helper/TidUtils.js.map +1 -0
  45. package/dist/index.d.ts +75 -4
  46. package/dist/index.js +26 -5
  47. package/dist/index.js.map +1 -1
  48. package/dist/models/RettiwtConfig.d.ts +28 -0
  49. package/dist/models/RettiwtConfig.js +55 -0
  50. package/dist/models/RettiwtConfig.js.map +1 -0
  51. package/dist/models/args/FetchArgs.d.ts +46 -3
  52. package/dist/models/args/FetchArgs.js +107 -5
  53. package/dist/models/args/FetchArgs.js.map +1 -1
  54. package/dist/models/args/PostArgs.d.ts +44 -16
  55. package/dist/models/args/PostArgs.js +61 -22
  56. package/dist/models/args/PostArgs.js.map +1 -1
  57. package/dist/models/auth/AuthCookie.d.ts +2 -0
  58. package/dist/models/auth/AuthCookie.js +2 -0
  59. package/dist/models/auth/AuthCookie.js.map +1 -1
  60. package/dist/models/auth/AuthCredential.d.ts +2 -0
  61. package/dist/models/auth/AuthCredential.js +2 -0
  62. package/dist/models/auth/AuthCredential.js.map +1 -1
  63. package/dist/models/data/CursoredData.d.ts +4 -13
  64. package/dist/models/data/CursoredData.js +16 -23
  65. package/dist/models/data/CursoredData.js.map +1 -1
  66. package/dist/models/data/List.d.ts +5 -1
  67. package/dist/models/data/List.js +14 -0
  68. package/dist/models/data/List.js.map +1 -1
  69. package/dist/models/data/Notification.d.ts +7 -5
  70. package/dist/models/data/Notification.js +19 -8
  71. package/dist/models/data/Notification.js.map +1 -1
  72. package/dist/models/data/Tweet.d.ts +29 -9
  73. package/dist/models/data/Tweet.js +103 -25
  74. package/dist/models/data/Tweet.js.map +1 -1
  75. package/dist/models/data/User.d.ts +17 -8
  76. package/dist/models/data/User.js +63 -13
  77. package/dist/models/data/User.js.map +1 -1
  78. package/dist/models/errors/RettiwtError.d.ts +3 -2
  79. package/dist/models/errors/RettiwtError.js +3 -2
  80. package/dist/models/errors/RettiwtError.js.map +1 -1
  81. package/dist/models/params/Variables.d.ts +41 -0
  82. package/dist/models/params/Variables.js +61 -0
  83. package/dist/models/params/Variables.js.map +1 -0
  84. package/dist/requests/List.d.ts +24 -0
  85. package/dist/requests/List.js +122 -0
  86. package/dist/requests/List.js.map +1 -0
  87. package/dist/requests/Media.d.ts +21 -0
  88. package/dist/requests/Media.js +70 -0
  89. package/dist/requests/Media.js.map +1 -0
  90. package/dist/requests/Tweet.d.ts +75 -0
  91. package/dist/requests/Tweet.js +500 -0
  92. package/dist/requests/Tweet.js.map +1 -0
  93. package/dist/requests/User.d.ts +111 -0
  94. package/dist/requests/User.js +762 -0
  95. package/dist/requests/User.js.map +1 -0
  96. package/dist/services/internal/AuthService.d.ts +3 -5
  97. package/dist/services/internal/AuthService.js +5 -8
  98. package/dist/services/internal/AuthService.js.map +1 -1
  99. package/dist/services/internal/TidService.d.ts +44 -0
  100. package/dist/services/internal/TidService.js +162 -0
  101. package/dist/services/internal/TidService.js.map +1 -0
  102. package/dist/services/public/FetcherService.d.ts +20 -19
  103. package/dist/services/public/FetcherService.js +67 -49
  104. package/dist/services/public/FetcherService.js.map +1 -1
  105. package/dist/services/public/ListService.d.ts +2 -2
  106. package/dist/services/public/ListService.js.map +1 -1
  107. package/dist/services/public/TweetService.d.ts +35 -7
  108. package/dist/services/public/TweetService.js +54 -8
  109. package/dist/services/public/TweetService.js.map +1 -1
  110. package/dist/services/public/UserService.d.ts +4 -4
  111. package/dist/services/public/UserService.js +25 -13
  112. package/dist/services/public/UserService.js.map +1 -1
  113. package/dist/types/RettiwtConfig.d.ts +9 -10
  114. package/dist/types/args/FetchArgs.d.ts +71 -7
  115. package/dist/types/args/PostArgs.d.ts +62 -18
  116. package/dist/types/auth/AuthCookie.d.ts +2 -0
  117. package/dist/types/auth/AuthCredential.d.ts +2 -0
  118. package/dist/types/auth/TidDynamicArgs.d.ts +10 -0
  119. package/dist/types/auth/{AccountCredential.js → TidDynamicArgs.js} +1 -1
  120. package/dist/types/auth/TidDynamicArgs.js.map +1 -0
  121. package/dist/types/auth/TidHeader.d.ts +8 -0
  122. package/dist/types/{ReturnTypes.js → auth/TidHeader.js} +1 -1
  123. package/dist/types/auth/TidHeader.js.map +1 -0
  124. package/dist/types/auth/TidParams.d.ts +27 -0
  125. package/dist/types/auth/TidParams.js +3 -0
  126. package/dist/types/auth/TidParams.js.map +1 -0
  127. package/dist/types/auth/TidProvider.d.ts +18 -0
  128. package/dist/types/auth/TidProvider.js +3 -0
  129. package/dist/types/auth/TidProvider.js.map +1 -0
  130. package/dist/types/data/CursoredData.d.ts +1 -10
  131. package/dist/types/data/Notification.d.ts +2 -2
  132. package/dist/types/data/Tweet.d.ts +2 -2
  133. package/dist/types/params/Variables.d.ts +27 -0
  134. package/dist/types/params/Variables.js +3 -0
  135. package/dist/types/params/Variables.js.map +1 -0
  136. package/dist/types/raw/base/Analytic.d.ts +21 -0
  137. package/dist/types/raw/base/Analytic.js +4 -0
  138. package/dist/types/raw/base/Analytic.js.map +1 -0
  139. package/dist/types/raw/base/Cursor.d.ts +11 -0
  140. package/dist/types/raw/base/Cursor.js +4 -0
  141. package/dist/types/raw/base/Cursor.js.map +1 -0
  142. package/dist/types/raw/base/LimitedVisibilityTweet.d.ts +32 -0
  143. package/dist/types/raw/base/LimitedVisibilityTweet.js +4 -0
  144. package/dist/types/raw/base/LimitedVisibilityTweet.js.map +1 -0
  145. package/dist/types/raw/base/List.d.ts +43 -0
  146. package/dist/types/raw/base/List.js +4 -0
  147. package/dist/types/raw/base/List.js.map +1 -0
  148. package/dist/types/raw/base/Media.d.ts +43 -0
  149. package/dist/types/raw/base/Media.js +4 -0
  150. package/dist/types/raw/base/Media.js.map +1 -0
  151. package/dist/types/raw/base/Notification.d.ts +53 -0
  152. package/dist/types/raw/base/Notification.js +4 -0
  153. package/dist/types/raw/base/Notification.js.map +1 -0
  154. package/dist/types/raw/base/Space.d.ts +32 -0
  155. package/dist/types/raw/base/Space.js +4 -0
  156. package/dist/types/raw/base/Space.js.map +1 -0
  157. package/dist/types/raw/base/Tweet.d.ts +119 -0
  158. package/dist/types/raw/base/Tweet.js +4 -0
  159. package/dist/types/raw/base/Tweet.js.map +1 -0
  160. package/dist/types/raw/base/User.d.ts +140 -0
  161. package/dist/types/raw/base/User.js +4 -0
  162. package/dist/types/raw/base/User.js.map +1 -0
  163. package/dist/types/raw/composite/DataResult.d.ts +8 -0
  164. package/dist/types/raw/composite/DataResult.js +3 -0
  165. package/dist/types/raw/composite/DataResult.js.map +1 -0
  166. package/dist/types/raw/composite/TimelineTweet.d.ts +11 -0
  167. package/dist/types/raw/composite/TimelineTweet.js +4 -0
  168. package/dist/types/raw/composite/TimelineTweet.js.map +1 -0
  169. package/dist/types/raw/composite/TimelineUser.d.ts +10 -0
  170. package/dist/types/raw/composite/TimelineUser.js +4 -0
  171. package/dist/types/raw/composite/TimelineUser.js.map +1 -0
  172. package/dist/types/raw/generic/Error.d.ts +30 -0
  173. package/dist/types/raw/generic/Error.js +3 -0
  174. package/dist/types/raw/generic/Error.js.map +1 -0
  175. package/dist/types/raw/generic/Response.d.ts +12 -0
  176. package/dist/types/raw/generic/Response.js +3 -0
  177. package/dist/types/raw/generic/Response.js.map +1 -0
  178. package/dist/types/raw/list/Details.d.ts +122 -0
  179. package/dist/types/raw/list/Details.js +4 -0
  180. package/dist/types/raw/list/Details.js.map +1 -0
  181. package/dist/types/raw/list/Members.d.ts +134 -0
  182. package/dist/types/raw/list/Members.js +4 -0
  183. package/dist/types/raw/list/Members.js.map +1 -0
  184. package/dist/types/raw/list/Tweets.d.ts +1968 -0
  185. package/dist/types/raw/list/Tweets.js +4 -0
  186. package/dist/types/raw/list/Tweets.js.map +1 -0
  187. package/dist/types/raw/media/FinalizeUpload.d.ts +18 -0
  188. package/dist/types/raw/media/FinalizeUpload.js +4 -0
  189. package/dist/types/raw/media/FinalizeUpload.js.map +1 -0
  190. package/dist/types/raw/media/InitalizeUpload.d.ts +10 -0
  191. package/dist/types/raw/media/InitalizeUpload.js +4 -0
  192. package/dist/types/raw/media/InitalizeUpload.js.map +1 -0
  193. package/dist/types/raw/media/LiveVideoStream.d.ts +19 -0
  194. package/dist/types/raw/media/LiveVideoStream.js +4 -0
  195. package/dist/types/raw/media/LiveVideoStream.js.map +1 -0
  196. package/dist/types/raw/space/Details.d.ts +315 -0
  197. package/dist/types/raw/space/Details.js +4 -0
  198. package/dist/types/raw/space/Details.js.map +1 -0
  199. package/dist/types/raw/tweet/Details.d.ts +183 -0
  200. package/dist/types/raw/tweet/Details.js +4 -0
  201. package/dist/types/raw/tweet/Details.js.map +1 -0
  202. package/dist/types/raw/tweet/Like.d.ts +12 -0
  203. package/dist/types/raw/tweet/Like.js +4 -0
  204. package/dist/types/raw/tweet/Like.js.map +1 -0
  205. package/dist/types/raw/tweet/Likers.d.ts +170 -0
  206. package/dist/types/raw/tweet/Likers.js +4 -0
  207. package/dist/types/raw/tweet/Likers.js.map +1 -0
  208. package/dist/types/raw/tweet/Post.d.ts +133 -0
  209. package/dist/types/raw/tweet/Post.js +4 -0
  210. package/dist/types/raw/tweet/Post.js.map +1 -0
  211. package/dist/types/raw/tweet/Replies.d.ts +465 -0
  212. package/dist/types/raw/tweet/Replies.js +4 -0
  213. package/dist/types/raw/tweet/Replies.js.map +1 -0
  214. package/dist/types/raw/tweet/Retweet.d.ts +25 -0
  215. package/dist/types/raw/tweet/Retweet.js +4 -0
  216. package/dist/types/raw/tweet/Retweet.js.map +1 -0
  217. package/dist/types/raw/tweet/Retweeters.d.ts +177 -0
  218. package/dist/types/raw/tweet/Retweeters.js +4 -0
  219. package/dist/types/raw/tweet/Retweeters.js.map +1 -0
  220. package/dist/types/raw/tweet/Schedule.d.ts +15 -0
  221. package/dist/types/raw/tweet/Schedule.js +4 -0
  222. package/dist/types/raw/tweet/Schedule.js.map +1 -0
  223. package/dist/types/raw/tweet/Search.d.ts +518 -0
  224. package/dist/types/raw/tweet/Search.js +4 -0
  225. package/dist/types/raw/tweet/Search.js.map +1 -0
  226. package/dist/types/raw/tweet/Unlike.d.ts +12 -0
  227. package/dist/types/raw/tweet/Unlike.js +4 -0
  228. package/dist/types/raw/tweet/Unlike.js.map +1 -0
  229. package/dist/types/raw/tweet/Unpost.d.ts +17 -0
  230. package/dist/types/raw/tweet/Unpost.js +4 -0
  231. package/dist/types/raw/tweet/Unpost.js.map +1 -0
  232. package/dist/types/raw/tweet/Unretweet.d.ts +25 -0
  233. package/dist/types/raw/tweet/Unretweet.js +4 -0
  234. package/dist/types/raw/tweet/Unretweet.js.map +1 -0
  235. package/dist/types/raw/tweet/Unschedule.d.ts +12 -0
  236. package/dist/types/raw/tweet/Unschedule.js +4 -0
  237. package/dist/types/raw/tweet/Unschedule.js.map +1 -0
  238. package/dist/types/raw/user/Affiliates.d.ts +154 -0
  239. package/dist/types/raw/user/Affiliates.js +4 -0
  240. package/dist/types/raw/user/Affiliates.js.map +1 -0
  241. package/dist/types/raw/user/Analytics.d.ts +32 -0
  242. package/dist/types/raw/user/Analytics.js +4 -0
  243. package/dist/types/raw/user/Analytics.js.map +1 -0
  244. package/dist/types/raw/user/Bookmarks.d.ts +550 -0
  245. package/dist/types/raw/user/Bookmarks.js +4 -0
  246. package/dist/types/raw/user/Bookmarks.js.map +1 -0
  247. package/dist/types/raw/user/Details.d.ts +157 -0
  248. package/dist/types/raw/user/Details.js +4 -0
  249. package/dist/types/raw/user/Details.js.map +1 -0
  250. package/dist/types/raw/user/Follow.d.ts +248 -0
  251. package/dist/types/raw/user/Follow.js +4 -0
  252. package/dist/types/raw/user/Follow.js.map +1 -0
  253. package/dist/types/raw/user/Followed.d.ts +1666 -0
  254. package/dist/types/raw/user/Followed.js +4 -0
  255. package/dist/types/raw/user/Followed.js.map +1 -0
  256. package/dist/types/raw/user/Followers.d.ts +182 -0
  257. package/dist/types/raw/user/Followers.js +4 -0
  258. package/dist/types/raw/user/Followers.js.map +1 -0
  259. package/dist/types/raw/user/Following.d.ts +182 -0
  260. package/dist/types/raw/user/Following.js +4 -0
  261. package/dist/types/raw/user/Following.js.map +1 -0
  262. package/dist/types/raw/user/Highlights.d.ts +1106 -0
  263. package/dist/types/raw/user/Highlights.js +4 -0
  264. package/dist/types/raw/user/Highlights.js.map +1 -0
  265. package/dist/types/raw/user/Likes.d.ts +1065 -0
  266. package/dist/types/raw/user/Likes.js +4 -0
  267. package/dist/types/raw/user/Likes.js.map +1 -0
  268. package/dist/types/raw/user/Media.d.ts +1492 -0
  269. package/dist/types/raw/user/Media.js +4 -0
  270. package/dist/types/raw/user/Media.js.map +1 -0
  271. package/dist/types/raw/user/Notifications.d.ts +142 -0
  272. package/dist/types/raw/user/Notifications.js +4 -0
  273. package/dist/types/raw/user/Notifications.js.map +1 -0
  274. package/dist/types/raw/user/Recommended.d.ts +1991 -0
  275. package/dist/types/raw/user/Recommended.js +4 -0
  276. package/dist/types/raw/user/Recommended.js.map +1 -0
  277. package/dist/types/raw/user/Scheduled.d.ts +31 -0
  278. package/dist/types/raw/user/Scheduled.js +4 -0
  279. package/dist/types/raw/user/Scheduled.js.map +1 -0
  280. package/dist/types/raw/user/Subscriptions.d.ts +151 -0
  281. package/dist/types/raw/user/Subscriptions.js +4 -0
  282. package/dist/types/raw/user/Subscriptions.js.map +1 -0
  283. package/dist/types/raw/user/Tweets.d.ts +1065 -0
  284. package/dist/types/raw/user/Tweets.js +4 -0
  285. package/dist/types/raw/user/Tweets.js.map +1 -0
  286. package/dist/types/raw/user/TweetsAndReplies.d.ts +1065 -0
  287. package/dist/types/raw/user/TweetsAndReplies.js +4 -0
  288. package/dist/types/raw/user/TweetsAndReplies.js.map +1 -0
  289. package/dist/types/raw/user/Unfollow.d.ts +248 -0
  290. package/dist/types/raw/user/Unfollow.js +4 -0
  291. package/dist/types/raw/user/Unfollow.js.map +1 -0
  292. package/package.json +3 -3
  293. package/src/Rettiwt.ts +22 -7
  294. package/src/collections/Extractors.ts +38 -34
  295. package/src/collections/Groups.ts +3 -0
  296. package/src/collections/Requests.ts +43 -42
  297. package/src/commands/Tweet.ts +35 -7
  298. package/src/commands/User.ts +13 -2
  299. package/src/enums/Authentication.ts +2 -11
  300. package/src/enums/Data.ts +3 -16
  301. package/src/enums/Media.ts +10 -0
  302. package/src/enums/Notification.ts +12 -0
  303. package/src/enums/Resource.ts +3 -0
  304. package/src/enums/raw/Analytics.ts +29 -0
  305. package/src/enums/raw/Media.ts +10 -0
  306. package/src/enums/raw/Notification.ts +11 -0
  307. package/src/enums/raw/Tweet.ts +9 -0
  308. package/src/helper/TidUtils.ts +189 -0
  309. package/src/index.ts +78 -43
  310. package/src/models/RettiwtConfig.ts +64 -0
  311. package/src/models/args/FetchArgs.ts +121 -5
  312. package/src/models/args/PostArgs.ts +61 -21
  313. package/src/models/auth/AuthCookie.ts +2 -0
  314. package/src/models/auth/AuthCredential.ts +2 -0
  315. package/src/models/data/CursoredData.ts +16 -24
  316. package/src/models/data/List.ts +16 -2
  317. package/src/models/data/Notification.ts +21 -12
  318. package/src/models/data/Tweet.ts +120 -39
  319. package/src/models/data/User.ts +71 -15
  320. package/src/models/errors/RettiwtError.ts +3 -2
  321. package/src/models/params/Variables.ts +62 -0
  322. package/src/requests/List.ts +121 -0
  323. package/src/requests/Media.ts +67 -0
  324. package/src/requests/Tweet.ts +516 -0
  325. package/src/requests/User.ts +783 -0
  326. package/src/services/internal/AuthService.ts +6 -11
  327. package/src/services/internal/TidService.ts +147 -0
  328. package/src/services/public/FetcherService.ts +78 -58
  329. package/src/services/public/ListService.ts +4 -4
  330. package/src/services/public/TweetService.ts +87 -40
  331. package/src/services/public/UserService.ts +47 -35
  332. package/src/types/RettiwtConfig.ts +11 -12
  333. package/src/types/args/FetchArgs.ts +92 -8
  334. package/src/types/args/PostArgs.ts +72 -22
  335. package/src/types/auth/AuthCookie.ts +2 -0
  336. package/src/types/auth/AuthCredential.ts +2 -0
  337. package/src/types/auth/TidDynamicArgs.ts +10 -0
  338. package/src/types/auth/TidHeader.ts +12 -0
  339. package/src/types/auth/TidParams.ts +36 -0
  340. package/src/types/auth/TidProvider.ts +19 -0
  341. package/src/types/data/CursoredData.ts +1 -11
  342. package/src/types/data/Notification.ts +2 -2
  343. package/src/types/data/Tweet.ts +2 -2
  344. package/src/types/params/Variables.ts +41 -0
  345. package/src/types/raw/base/Analytic.ts +26 -0
  346. package/src/types/raw/base/Cursor.ts +13 -0
  347. package/src/types/raw/base/LimitedVisibilityTweet.ts +40 -0
  348. package/src/types/raw/base/List.ts +50 -0
  349. package/src/types/raw/base/Media.ts +53 -0
  350. package/src/types/raw/base/Notification.ts +67 -0
  351. package/src/types/raw/base/Space.ts +35 -0
  352. package/src/types/raw/base/Tweet.ts +139 -0
  353. package/src/types/raw/base/User.ts +164 -0
  354. package/src/types/raw/composite/DataResult.ts +8 -0
  355. package/src/types/raw/composite/TimelineTweet.ts +14 -0
  356. package/src/types/raw/composite/TimelineUser.ts +13 -0
  357. package/src/types/raw/generic/Error.ts +35 -0
  358. package/src/types/raw/generic/Response.ts +13 -0
  359. package/src/types/raw/list/Details.ts +137 -0
  360. package/src/types/raw/list/Members.ts +154 -0
  361. package/src/types/raw/list/Tweets.ts +2296 -0
  362. package/src/types/raw/media/FinalizeUpload.ts +20 -0
  363. package/src/types/raw/media/InitalizeUpload.ts +12 -0
  364. package/src/types/raw/media/LiveVideoStream.ts +21 -0
  365. package/src/types/raw/space/Details.ts +359 -0
  366. package/src/types/raw/tweet/Details.ts +210 -0
  367. package/src/types/raw/tweet/Like.ts +14 -0
  368. package/src/types/raw/tweet/Likers.ts +200 -0
  369. package/src/types/raw/tweet/Post.ts +150 -0
  370. package/src/types/raw/tweet/Replies.ts +539 -0
  371. package/src/types/raw/tweet/Retweet.ts +31 -0
  372. package/src/types/raw/tweet/Retweeters.ts +208 -0
  373. package/src/types/raw/tweet/Schedule.ts +18 -0
  374. package/src/types/raw/tweet/Search.ts +597 -0
  375. package/src/types/raw/tweet/Unlike.ts +14 -0
  376. package/src/types/raw/tweet/Unpost.ts +20 -0
  377. package/src/types/raw/tweet/Unretweet.ts +31 -0
  378. package/src/types/raw/tweet/Unschedule.ts +14 -0
  379. package/src/types/raw/user/Affiliates.ts +179 -0
  380. package/src/types/raw/user/Analytics.ts +39 -0
  381. package/src/types/raw/user/Bookmarks.ts +637 -0
  382. package/src/types/raw/user/Details.ts +185 -0
  383. package/src/types/raw/user/Follow.ts +280 -0
  384. package/src/types/raw/user/Followed.ts +1942 -0
  385. package/src/types/raw/user/Followers.ts +215 -0
  386. package/src/types/raw/user/Following.ts +215 -0
  387. package/src/types/raw/user/Highlights.ts +1287 -0
  388. package/src/types/raw/user/Likes.ts +1254 -0
  389. package/src/types/raw/user/Media.ts +1738 -0
  390. package/src/types/raw/user/Notifications.ts +175 -0
  391. package/src/types/raw/user/Recommended.ts +2319 -0
  392. package/src/types/raw/user/Scheduled.ts +37 -0
  393. package/src/types/raw/user/Subscriptions.ts +176 -0
  394. package/src/types/raw/user/Tweets.ts +1254 -0
  395. package/src/types/raw/user/TweetsAndReplies.ts +1254 -0
  396. package/src/types/raw/user/Unfollow.ts +280 -0
  397. package/dist/models/auth/AccountCredential.d.ts +0 -13
  398. package/dist/models/auth/AccountCredential.js +0 -21
  399. package/dist/models/auth/AccountCredential.js.map +0 -1
  400. package/dist/types/ReturnTypes.d.ts +0 -21
  401. package/dist/types/ReturnTypes.js.map +0 -1
  402. package/dist/types/auth/AccountCredential.d.ts +0 -11
  403. package/dist/types/auth/AccountCredential.js.map +0 -1
  404. package/src/models/auth/AccountCredential.ts +0 -19
  405. package/src/types/ReturnTypes.ts +0 -24
  406. package/src/types/auth/AccountCredential.ts +0 -13
@@ -0,0 +1,500 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TweetRequests = void 0;
4
+ const Tweet_1 = require("../enums/raw/Tweet");
5
+ const FetchArgs_1 = require("../models/args/FetchArgs");
6
+ const PostArgs_1 = require("../models/args/PostArgs");
7
+ const Variables_1 = require("../models/params/Variables");
8
+ /**
9
+ * Collection of requests related to tweets.
10
+ *
11
+ * @public
12
+ */
13
+ class TweetRequests {
14
+ /**
15
+ * @param ids - The IDs of the tweets whose details are to be fetched.
16
+ */
17
+ static bulkDetails(ids) {
18
+ return {
19
+ method: 'get',
20
+ url: 'https://x.com/i/api/graphql/kPnxYjNX2HCKu8aY96er5w/TweetResultsByRestIds',
21
+ params: {
22
+ /* eslint-disable @typescript-eslint/naming-convention */
23
+ variables: JSON.stringify({
24
+ tweetIds: ids,
25
+ referrer: 'home',
26
+ with_rux_injections: false,
27
+ includePromotedContent: false,
28
+ withCommunity: false,
29
+ withQuickPromoteEligibilityTweetFields: false,
30
+ withBirdwatchNotes: false,
31
+ withVoice: false,
32
+ withV2Timeline: false,
33
+ }),
34
+ features: JSON.stringify({
35
+ rweb_lists_timeline_redesign_enabled: true,
36
+ responsive_web_graphql_exclude_directive_enabled: true,
37
+ verified_phone_label_enabled: true,
38
+ creator_subscriptions_tweet_preview_api_enabled: true,
39
+ responsive_web_graphql_timeline_navigation_enabled: true,
40
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
41
+ tweetypie_unmention_optimization_enabled: true,
42
+ responsive_web_edit_tweet_api_enabled: true,
43
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
44
+ view_counts_everywhere_api_enabled: true,
45
+ longform_notetweets_consumption_enabled: true,
46
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
47
+ tweet_awards_web_tipping_enabled: false,
48
+ freedom_of_speech_not_reach_fetch_enabled: true,
49
+ standardized_nudges_misinfo: true,
50
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
51
+ longform_notetweets_rich_text_read_enabled: true,
52
+ longform_notetweets_inline_media_enabled: true,
53
+ responsive_web_media_download_video_enabled: false,
54
+ responsive_web_enhance_cards_enabled: false,
55
+ responsive_web_grok_show_grok_translated_post: false,
56
+ responsive_web_grok_analyze_post_followups_enabled: false,
57
+ responsive_web_jetfuel_frame: false,
58
+ responsive_web_grok_image_annotation_enabled: false,
59
+ communities_web_enable_tweet_community_results_fetch: false,
60
+ c9s_tweet_anatomy_moderator_badge_enabled: false,
61
+ premium_content_api_read_enabled: false,
62
+ responsive_web_grok_analysis_button_from_backend: false,
63
+ profile_label_improvements_pcf_label_in_post_enabled: false,
64
+ rweb_tipjar_consumption_enabled: false,
65
+ creator_subscriptions_quote_tweet_preview_enabled: false,
66
+ responsive_web_grok_analyze_button_fetch_trends_enabled: false,
67
+ articles_preview_enabled: false,
68
+ responsive_web_grok_share_attachment_enabled: false,
69
+ }),
70
+ /* eslint-enable @typescript-eslint/naming-convention */
71
+ },
72
+ paramsSerializer: { encode: encodeURIComponent },
73
+ };
74
+ }
75
+ /**
76
+ * @param id - The id of the tweet whose details are to be fetched.
77
+ */
78
+ static details(id) {
79
+ return {
80
+ method: 'get',
81
+ url: 'https://x.com/i/api/graphql/0hWvDhmW8YQ-S_ib3azIrw/TweetResultByRestId',
82
+ params: {
83
+ /* eslint-disable @typescript-eslint/naming-convention */
84
+ variables: JSON.stringify({
85
+ tweetId: id,
86
+ referrer: 'home',
87
+ with_rux_injections: false,
88
+ includePromotedContent: false,
89
+ withCommunity: false,
90
+ withQuickPromoteEligibilityTweetFields: false,
91
+ withBirdwatchNotes: false,
92
+ withVoice: false,
93
+ withV2Timeline: false,
94
+ }),
95
+ features: JSON.stringify({
96
+ rweb_lists_timeline_redesign_enabled: true,
97
+ responsive_web_graphql_exclude_directive_enabled: true,
98
+ verified_phone_label_enabled: true,
99
+ creator_subscriptions_tweet_preview_api_enabled: true,
100
+ responsive_web_graphql_timeline_navigation_enabled: true,
101
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
102
+ tweetypie_unmention_optimization_enabled: true,
103
+ responsive_web_edit_tweet_api_enabled: true,
104
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
105
+ view_counts_everywhere_api_enabled: true,
106
+ longform_notetweets_consumption_enabled: true,
107
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
108
+ tweet_awards_web_tipping_enabled: false,
109
+ freedom_of_speech_not_reach_fetch_enabled: true,
110
+ standardized_nudges_misinfo: true,
111
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
112
+ longform_notetweets_rich_text_read_enabled: true,
113
+ longform_notetweets_inline_media_enabled: true,
114
+ responsive_web_media_download_video_enabled: false,
115
+ responsive_web_enhance_cards_enabled: false,
116
+ }),
117
+ /* eslint-enable @typescript-eslint/naming-convention */
118
+ },
119
+ paramsSerializer: { encode: encodeURIComponent },
120
+ };
121
+ }
122
+ /**
123
+ * @param id - The id of the tweet to be liked.
124
+ */
125
+ static like(id) {
126
+ return {
127
+ method: 'post',
128
+ url: 'https://x.com/i/api/graphql/lI07N6Otwv1PhnEgXILM7A/FavoriteTweet',
129
+ data: {
130
+ /* eslint-disable @typescript-eslint/naming-convention */
131
+ variables: {
132
+ tweet_id: id,
133
+ },
134
+ /* eslint-enable @typescript-eslint/naming-convention */
135
+ },
136
+ };
137
+ }
138
+ /**
139
+ * @param id - The id of the tweet whose likers are to be fetched.
140
+ * @param count - The number of likers to fetch. Only works as a lower limit when used with a cursor.
141
+ * @param cursor - The cursor to the batch of likers to fetch.
142
+ */
143
+ static likers(id, count, cursor) {
144
+ return {
145
+ method: 'get',
146
+ url: 'https://x.com/i/api/graphql/9XKD3EWWC2BKpIFyDj4KKQ/Favoriters',
147
+ params: {
148
+ /* eslint-disable @typescript-eslint/naming-convention */
149
+ variables: JSON.stringify({
150
+ tweetId: id,
151
+ count: count,
152
+ cursor: cursor,
153
+ includePromotedContent: false,
154
+ }),
155
+ features: JSON.stringify({
156
+ rweb_lists_timeline_redesign_enabled: true,
157
+ responsive_web_graphql_exclude_directive_enabled: true,
158
+ verified_phone_label_enabled: true,
159
+ creator_subscriptions_tweet_preview_api_enabled: true,
160
+ responsive_web_graphql_timeline_navigation_enabled: true,
161
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
162
+ tweetypie_unmention_optimization_enabled: true,
163
+ responsive_web_edit_tweet_api_enabled: true,
164
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
165
+ view_counts_everywhere_api_enabled: true,
166
+ longform_notetweets_consumption_enabled: true,
167
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
168
+ tweet_awards_web_tipping_enabled: false,
169
+ freedom_of_speech_not_reach_fetch_enabled: true,
170
+ standardized_nudges_misinfo: true,
171
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
172
+ longform_notetweets_rich_text_read_enabled: true,
173
+ longform_notetweets_inline_media_enabled: true,
174
+ responsive_web_media_download_video_enabled: false,
175
+ responsive_web_enhance_cards_enabled: false,
176
+ }),
177
+ /* eslint-enable @typescript-eslint/naming-convention */
178
+ },
179
+ paramsSerializer: { encode: encodeURIComponent },
180
+ };
181
+ }
182
+ /**
183
+ * @param args - The configuration object for the tweet to be posted.
184
+ */
185
+ static post(args) {
186
+ // Parsing the args
187
+ const parsedArgs = new PostArgs_1.NewTweet(args);
188
+ return {
189
+ method: 'post',
190
+ url: 'https://x.com/i/api/graphql/bDE2rBtZb3uyrczSZ_pI9g/CreateTweet',
191
+ data: {
192
+ /* eslint-disable @typescript-eslint/naming-convention */
193
+ variables: {
194
+ tweet_text: parsedArgs.text,
195
+ dark_request: false,
196
+ attachment_url: parsedArgs.quote ? `https://x.com/i/status/${parsedArgs.quote}` : undefined,
197
+ media: parsedArgs.media ? new Variables_1.MediaVariable(parsedArgs.media) : undefined,
198
+ reply: parsedArgs.replyTo ? new Variables_1.ReplyVariable(parsedArgs.replyTo) : undefined,
199
+ semantic_annotation_ids: [],
200
+ },
201
+ features: {
202
+ tweetypie_unmention_optimization_enabled: true,
203
+ responsive_web_edit_tweet_api_enabled: true,
204
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
205
+ view_counts_everywhere_api_enabled: true,
206
+ longform_notetweets_consumption_enabled: true,
207
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
208
+ tweet_awards_web_tipping_enabled: false,
209
+ longform_notetweets_rich_text_read_enabled: true,
210
+ longform_notetweets_inline_media_enabled: true,
211
+ responsive_web_graphql_exclude_directive_enabled: true,
212
+ verified_phone_label_enabled: true,
213
+ freedom_of_speech_not_reach_fetch_enabled: true,
214
+ standardized_nudges_misinfo: true,
215
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
216
+ responsive_web_media_download_video_enabled: false,
217
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
218
+ responsive_web_graphql_timeline_navigation_enabled: true,
219
+ responsive_web_enhance_cards_enabled: false,
220
+ rweb_video_timestamps_enabled: true,
221
+ c9s_tweet_anatomy_moderator_badge_enabled: true,
222
+ },
223
+ /* eslint-enable @typescript-eslint/naming-convention */
224
+ },
225
+ };
226
+ }
227
+ /**
228
+ * @param id - The id of the tweet whose replies are to be fetched.
229
+ * @param cursor - The cursor to the batch of replies to fetch.
230
+ */
231
+ static replies(id, cursor) {
232
+ return {
233
+ method: 'get',
234
+ url: 'https://x.com/i/api/graphql/B9_KmbkLhXt6jRwGjJrweg/TweetDetail',
235
+ params: {
236
+ /* eslint-disable @typescript-eslint/naming-convention */
237
+ variables: JSON.stringify({
238
+ focalTweetId: id,
239
+ cursor: cursor,
240
+ referrer: 'tweet',
241
+ controller_data: cursor,
242
+ with_rux_injections: false,
243
+ includePromotedContent: false,
244
+ withCommunity: true,
245
+ withQuickPromoteEligibilityTweetFields: true,
246
+ withBirdwatchNotes: true,
247
+ withVoice: true,
248
+ withV2Timeline: true,
249
+ }),
250
+ features: JSON.stringify({
251
+ responsive_web_graphql_exclude_directive_enabled: true,
252
+ verified_phone_label_enabled: true,
253
+ creator_subscriptions_tweet_preview_api_enabled: true,
254
+ responsive_web_graphql_timeline_navigation_enabled: true,
255
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
256
+ c9s_tweet_anatomy_moderator_badge_enabled: true,
257
+ tweetypie_unmention_optimization_enabled: true,
258
+ responsive_web_edit_tweet_api_enabled: true,
259
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
260
+ view_counts_everywhere_api_enabled: true,
261
+ longform_notetweets_consumption_enabled: true,
262
+ responsive_web_twitter_article_tweet_consumption_enabled: true,
263
+ tweet_awards_web_tipping_enabled: false,
264
+ freedom_of_speech_not_reach_fetch_enabled: true,
265
+ standardized_nudges_misinfo: true,
266
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
267
+ rweb_video_timestamps_enabled: true,
268
+ longform_notetweets_rich_text_read_enabled: true,
269
+ longform_notetweets_inline_media_enabled: true,
270
+ responsive_web_media_download_video_enabled: false,
271
+ responsive_web_enhance_cards_enabled: false,
272
+ }),
273
+ /* eslint-enable @typescript-eslint/naming-convention */
274
+ },
275
+ paramsSerializer: { encode: encodeURIComponent },
276
+ };
277
+ }
278
+ /**
279
+ * @param id - The id of the tweet which is to be retweeted.
280
+ */
281
+ static retweet(id) {
282
+ return {
283
+ method: 'post',
284
+ url: 'https://x.com/i/api/graphql/ojPdsZsimiJrUGLR1sjUtA/CreateRetweet',
285
+ data: {
286
+ variables: {
287
+ /* eslint-disable @typescript-eslint/naming-convention */
288
+ tweet_id: id,
289
+ dark_request: false,
290
+ /* eslint-enable @typescript-eslint/naming-convention */
291
+ },
292
+ },
293
+ };
294
+ }
295
+ /**
296
+ * @param id - The id of the tweet whose retweeters are to be fetched.
297
+ * @param count - The number of retweeters to fetch. Only works as a lower limit when used with a cursor.
298
+ * @param cursor - The cursor to the batch of retweeters to fetch.
299
+ */
300
+ static retweeters(id, count, cursor) {
301
+ return {
302
+ method: 'get',
303
+ url: 'https://x.com/i/api/graphql/v5h-KLmyl-wqZ8i-a_q73w/Retweeters',
304
+ params: {
305
+ /* eslint-disable @typescript-eslint/naming-convention */
306
+ variables: JSON.stringify({
307
+ tweetId: id,
308
+ count: count,
309
+ cursor: cursor,
310
+ includePromotedContent: false,
311
+ }),
312
+ features: JSON.stringify({
313
+ rweb_lists_timeline_redesign_enabled: true,
314
+ responsive_web_graphql_exclude_directive_enabled: true,
315
+ verified_phone_label_enabled: true,
316
+ creator_subscriptions_tweet_preview_api_enabled: true,
317
+ responsive_web_graphql_timeline_navigation_enabled: true,
318
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
319
+ tweetypie_unmention_optimization_enabled: true,
320
+ responsive_web_edit_tweet_api_enabled: true,
321
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
322
+ view_counts_everywhere_api_enabled: true,
323
+ longform_notetweets_consumption_enabled: true,
324
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
325
+ tweet_awards_web_tipping_enabled: false,
326
+ freedom_of_speech_not_reach_fetch_enabled: true,
327
+ standardized_nudges_misinfo: true,
328
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
329
+ longform_notetweets_rich_text_read_enabled: true,
330
+ longform_notetweets_inline_media_enabled: true,
331
+ responsive_web_media_download_video_enabled: false,
332
+ responsive_web_enhance_cards_enabled: false,
333
+ }),
334
+ /* eslint-enable @typescript-eslint/naming-convention */
335
+ },
336
+ paramsSerializer: { encode: encodeURIComponent },
337
+ };
338
+ }
339
+ /**
340
+ * @param args - The configuration object for the tweet to be posted.
341
+ *
342
+ * @remarks - Only `text` and `media.id` parameters are supported.
343
+ */
344
+ static schedule(args) {
345
+ // Parsing the args
346
+ const parsedArgs = new PostArgs_1.NewTweet(args);
347
+ return {
348
+ method: 'post',
349
+ maxBodyLength: Infinity,
350
+ url: 'https://x.com/i/api/graphql/LCVzRQGxOaGnOnYH01NQXg/CreateScheduledTweet',
351
+ data: {
352
+ /* eslint-disable @typescript-eslint/naming-convention */
353
+ variables: {
354
+ post_tweet_request: {
355
+ auto_populate_reply_metadata: false,
356
+ status: parsedArgs.text,
357
+ exclude_reply_user_ids: [],
358
+ media_ids: parsedArgs.media?.map((item) => item.id) ?? [],
359
+ },
360
+ execute_at: Math.floor((parsedArgs.scheduleFor ?? new Date()).getTime() / 1000),
361
+ },
362
+ /* eslint-enable @typescript-eslint/naming-convention */
363
+ },
364
+ };
365
+ }
366
+ /**
367
+ * @param filter - The filter to use for searching tweets.
368
+ * @param count - The number of tweets to fetch. Only works as a lower limit when used with a cursor.
369
+ * @param cursor - The cursor to the batch of tweets to fetch.
370
+ */
371
+ static search(filter, count, cursor) {
372
+ // Parsing the filter
373
+ const parsedFilter = new FetchArgs_1.TweetFilter(filter);
374
+ return {
375
+ method: 'get',
376
+ url: 'https://x.com/i/api/graphql/nK1dw4oV3k4w5TdtcAdSww/SearchTimeline',
377
+ params: {
378
+ /* eslint-disable @typescript-eslint/naming-convention */
379
+ variables: JSON.stringify({
380
+ rawQuery: new FetchArgs_1.TweetFilter(parsedFilter).toString(),
381
+ count: count,
382
+ cursor: cursor,
383
+ querySource: 'typed_query',
384
+ product: parsedFilter.top ? Tweet_1.ERawTweetSearchResultType.TOP : Tweet_1.ERawTweetSearchResultType.LATEST,
385
+ withAuxiliaryUserLabels: false,
386
+ withArticleRichContentState: false,
387
+ withArticlePlainText: false,
388
+ withGrokAnalyze: false,
389
+ withDisallowedReplyControls: false,
390
+ }),
391
+ features: JSON.stringify({
392
+ rweb_lists_timeline_redesign_enabled: true,
393
+ responsive_web_graphql_exclude_directive_enabled: true,
394
+ verified_phone_label_enabled: true,
395
+ creator_subscriptions_tweet_preview_api_enabled: true,
396
+ responsive_web_graphql_timeline_navigation_enabled: true,
397
+ responsive_web_graphql_skip_user_profile_image_extensions_enabled: false,
398
+ tweetypie_unmention_optimization_enabled: true,
399
+ responsive_web_edit_tweet_api_enabled: true,
400
+ graphql_is_translatable_rweb_tweet_is_translatable_enabled: true,
401
+ view_counts_everywhere_api_enabled: true,
402
+ longform_notetweets_consumption_enabled: true,
403
+ responsive_web_twitter_article_tweet_consumption_enabled: false,
404
+ tweet_awards_web_tipping_enabled: false,
405
+ freedom_of_speech_not_reach_fetch_enabled: true,
406
+ standardized_nudges_misinfo: true,
407
+ tweet_with_visibility_results_prefer_gql_limited_actions_policy_enabled: true,
408
+ longform_notetweets_rich_text_read_enabled: true,
409
+ longform_notetweets_inline_media_enabled: true,
410
+ responsive_web_media_download_video_enabled: false,
411
+ responsive_web_enhance_cards_enabled: false,
412
+ c9s_tweet_anatomy_moderator_badge_enabled: false,
413
+ responsive_web_grok_show_grok_translated_post: false,
414
+ premium_content_api_read_enabled: false,
415
+ rweb_video_screen_enabled: false,
416
+ responsive_web_grok_analyze_post_followups_enabled: false,
417
+ creator_subscriptions_quote_tweet_preview_enabled: false,
418
+ communities_web_enable_tweet_community_results_fetch: false,
419
+ rweb_tipjar_consumption_enabled: false,
420
+ responsive_web_grok_analyze_button_fetch_trends_enabled: false,
421
+ profile_label_improvements_pcf_label_in_post_enabled: false,
422
+ responsive_web_grok_image_annotation_enabled: false,
423
+ responsive_web_jetfuel_frame: false,
424
+ articles_preview_enabled: false,
425
+ responsive_web_grok_share_attachment_enabled: false,
426
+ responsive_web_grok_analysis_button_from_backend: false,
427
+ }),
428
+ /* eslint-enable @typescript-eslint/naming-convention */
429
+ },
430
+ paramsSerializer: { encode: encodeURIComponent },
431
+ };
432
+ }
433
+ /**
434
+ * @param id - The id of the tweet to be unliked.
435
+ */
436
+ static unlike(id) {
437
+ return {
438
+ method: 'post',
439
+ url: 'https://x.com/i/api/graphql/ZYKSe-w7KEslx3JhSIk5LA/UnfavoriteTweet',
440
+ data: {
441
+ /* eslint-disable @typescript-eslint/naming-convention */
442
+ variables: {
443
+ tweet_id: id,
444
+ },
445
+ /* eslint-enable @typescript-eslint/naming-convention */
446
+ },
447
+ };
448
+ }
449
+ /**
450
+ * @param id - The id of the tweet to be unposted.
451
+ */
452
+ static unpost(id) {
453
+ return {
454
+ method: 'post',
455
+ url: 'https://x.com/i/api/graphql/VaenaVgh5q5ih7kvyVjgtg/DeleteTweet',
456
+ data: {
457
+ /* eslint-disable @typescript-eslint/naming-convention */
458
+ variables: {
459
+ tweet_id: id,
460
+ },
461
+ /* eslint-enable @typescript-eslint/naming-convention */
462
+ },
463
+ };
464
+ }
465
+ /**
466
+ * @param id - The id of the source tweet (which was retweeted), to be unretweeted.
467
+ */
468
+ static unretweet(id) {
469
+ return {
470
+ method: 'post',
471
+ url: 'https://x.com/i/api/graphql/iQtK4dl5hBmXewYZuEOKVw/DeleteRetweet',
472
+ data: {
473
+ /* eslint-disable @typescript-eslint/naming-convention */
474
+ variables: {
475
+ source_tweet_id: id,
476
+ },
477
+ /* eslint-enable @typescript-eslint/naming-convention */
478
+ },
479
+ };
480
+ }
481
+ /**
482
+ * @param id - The id of the scheduled tweet to be unscheduled.
483
+ */
484
+ static unschedule(id) {
485
+ return {
486
+ method: 'post',
487
+ url: 'https://x.com/i/api/graphql/CTOVqej0JBXAZSwkp1US0g/DeleteScheduledTweet',
488
+ data: {
489
+ /* eslint-disable @typescript-eslint/naming-convention */
490
+ variables: {
491
+ scheduled_tweet_id: id,
492
+ },
493
+ queryId: 'CTOVqej0JBXAZSwkp1US0g',
494
+ /* eslint-enable @typescript-eslint/naming-convention */
495
+ },
496
+ };
497
+ }
498
+ }
499
+ exports.TweetRequests = TweetRequests;
500
+ //# sourceMappingURL=Tweet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Tweet.js","sourceRoot":"","sources":["../../src/requests/Tweet.ts"],"names":[],"mappings":";;;AAEA,8CAA+D;AAC/D,wDAAuD;AACvD,sDAAmD;AACnD,0DAA0E;AAI1E;;;;GAIG;AACH,MAAa,aAAa;IACzB;;OAEG;IACI,MAAM,CAAC,WAAW,CAAC,GAAa;QACtC,OAAO;YACN,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,0EAA0E;YAC/E,MAAM,EAAE;gBACP,yDAAyD;gBACzD,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC;oBACzB,QAAQ,EAAE,GAAG;oBACb,QAAQ,EAAE,MAAM;oBAChB,mBAAmB,EAAE,KAAK;oBAC1B,sBAAsB,EAAE,KAAK;oBA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
1
+ import { AxiosRequestConfig } from 'axios';
2
+ import { ERawAnalyticsGranularity, ERawAnalyticsMetric } from '../enums/raw/Analytics';
3
+ /**
4
+ * Collection of requests related to users.
5
+ *
6
+ * @public
7
+ */
8
+ export declare class UserRequests {
9
+ /**
10
+ * @param id - The id of the user whose affiliates are to be fetched.
11
+ * @param count - The number of affiliates to fetch. Only works as a lower limit when used with a cursor.
12
+ * @param cursor - The cursor to the batch of affiliates to fetch.
13
+ */
14
+ static affiliates(id: string, count?: number, cursor?: string): AxiosRequestConfig;
15
+ /**
16
+ * @param fromTime - The start time of the analytic data to be fetched.
17
+ * @param toTime - The end time of the analytic data to be fetched.
18
+ * @param granularity - The granularity of the analytic data to be fetched.
19
+ * @param requestedMetrics - The metrics to be fetched.
20
+ */
21
+ static analytics(fromTime: Date, toTime: Date, granularity: ERawAnalyticsGranularity, requestedMetrics: ERawAnalyticsMetric[]): AxiosRequestConfig;
22
+ /**
23
+ * @param count - The number of bookmarks to fetch.
24
+ * @param cursor - The cursor to the batch of bookmarks to fetch.
25
+ */
26
+ static bookmarks(count?: number, cursor?: string): AxiosRequestConfig;
27
+ /**
28
+ * @param ids - The IDs of the users whose details are to be fetched.
29
+ */
30
+ static bulkDetailsByIds(ids: string[]): AxiosRequestConfig;
31
+ /**
32
+ * @param id - The id of the user whose details are to be fetched.
33
+ */
34
+ static detailsById(id: string): AxiosRequestConfig;
35
+ /**
36
+ * @param userName - The username of the user whose details are to be fetched.
37
+ */
38
+ static detailsByUsername(userName: string): AxiosRequestConfig;
39
+ /**
40
+ * @param id - The id of the user to follow.
41
+ */
42
+ static follow(id: string): AxiosRequestConfig;
43
+ /**
44
+ * @param count - The number of timeline items to fetch. Only works as a lower limit when used with a cursor.
45
+ * @param cursor - The cursor to the batch of followed timeline items to fetch.
46
+ */
47
+ static followed(count?: number, cursor?: string): AxiosRequestConfig;
48
+ /**
49
+ * @param id - The id of the user whose followers are to be fetched.
50
+ * @param count - The number of followers to fetch. Only works as a lower limit when used with a cursor.
51
+ * @param cursor - The cursor to the batch of followers to fetch.
52
+ */
53
+ static followers(id: string, count?: number, cursor?: string): AxiosRequestConfig;
54
+ /**
55
+ * @param id - The id of the user whose followings are to be fetched.
56
+ * @param count - The number of followings to fetch. Only works as a lower limit when used with a cursor.
57
+ * @param cursor - The cursor to the batch of followings to fetch.
58
+ */
59
+ static following(id: string, count?: number, cursor?: string): AxiosRequestConfig;
60
+ /**
61
+ * @param id - The id of the user whose highlights are to be fetched.
62
+ * @param count - The number of highlights to fetch. Only works as a lower limit when used with a cursor.
63
+ * @param cursor - The cursor to the batch of highlights to fetch.
64
+ */
65
+ static highlights(id: string, count?: number, cursor?: string): AxiosRequestConfig;
66
+ /**
67
+ * @param id - The id of the user whose likes are to be fetched.
68
+ * @param count - The number of likes to fetch. Only works as a lower limit when used with a cursor.
69
+ * @param cursor - The cursor to the batch of likes to fetch.
70
+ */
71
+ static likes(id: string, count?: number, cursor?: string): AxiosRequestConfig;
72
+ /**
73
+ * @param id - The id of the user whose media is to be fetched.
74
+ * @param count - The number of media to fetch. Only works as a lower limit when used with a cursor.
75
+ * @param cursor - The cursor to the batch of media to fetch.
76
+ */
77
+ static media(id: string, count?: number, cursor?: string): AxiosRequestConfig;
78
+ /**
79
+ * @param count - The number of notifications to fetch.
80
+ * @param cursor - The cursor to the batch of notifications to fetch.
81
+ */
82
+ static notifications(count?: number, cursor?: string): AxiosRequestConfig;
83
+ /**
84
+ * @param count - The number of timeline items to fetch. Only works as a lower limit when used with a cursor.
85
+ * @param cursor - The cursor to the batch of recommended timeline items to fetch.
86
+ */
87
+ static recommended(count?: number, cursor?: string): AxiosRequestConfig;
88
+ static scheduled(): AxiosRequestConfig;
89
+ /**
90
+ * @param id - The id of the user whose subscriptions are to be fetched.
91
+ * @param count - The number of subscriptions to fetch. Only works as a lower limit when used with a cursor.
92
+ * @param cursor - The cursor to the batch of subscriptions to fetch.
93
+ */
94
+ static subscriptions(id: string, count?: number, cursor?: string): AxiosRequestConfig;
95
+ /**
96
+ * @param id - The id of the user whose timeline tweets are to be fetched.
97
+ * @param count - The number of timeline tweets to fetch. Only works as a lower limit when used with a cursor.
98
+ * @param cursor - The cursor to the batch of timeline tweets to fetch.
99
+ */
100
+ static tweets(id: string, count?: number, cursor?: string): AxiosRequestConfig;
101
+ /**
102
+ * @param id - The id of the user whose timeline tweets and replies are to be fetched.
103
+ * @param count - The number of timeline tweets and replies to fetch. Only works as a lower limit when used with a cursor.
104
+ * @param cursor - The cursor to the batch of timeline tweets and replies to fetch.
105
+ */
106
+ static tweetsAndReplies(id: string, count?: number, cursor?: string): AxiosRequestConfig;
107
+ /**
108
+ * @param id - The id of the user to be unfollowed.
109
+ */
110
+ static unfollow(id: string): AxiosRequestConfig;
111
+ }