x-twitter-scraper 0.1.0 → 0.2.1

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 (310) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/README.md +5 -5
  3. package/client.d.mts +2 -2
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +2 -2
  6. package/client.d.ts.map +1 -1
  7. package/client.js.map +1 -1
  8. package/client.mjs.map +1 -1
  9. package/package.json +1 -1
  10. package/resources/account.d.mts +19 -0
  11. package/resources/account.d.mts.map +1 -1
  12. package/resources/account.d.ts +19 -0
  13. package/resources/account.d.ts.map +1 -1
  14. package/resources/account.js +20 -1
  15. package/resources/account.js.map +1 -1
  16. package/resources/account.mjs +20 -1
  17. package/resources/account.mjs.map +1 -1
  18. package/resources/api-keys.d.mts +20 -0
  19. package/resources/api-keys.d.mts.map +1 -1
  20. package/resources/api-keys.d.ts +20 -0
  21. package/resources/api-keys.d.ts.map +1 -1
  22. package/resources/api-keys.js +20 -3
  23. package/resources/api-keys.js.map +1 -1
  24. package/resources/api-keys.mjs +20 -3
  25. package/resources/api-keys.mjs.map +1 -1
  26. package/resources/compose.d.mts +28 -3
  27. package/resources/compose.d.mts.map +1 -1
  28. package/resources/compose.d.ts +28 -3
  29. package/resources/compose.d.ts.map +1 -1
  30. package/resources/compose.js +9 -0
  31. package/resources/compose.js.map +1 -1
  32. package/resources/compose.mjs +9 -0
  33. package/resources/compose.mjs.map +1 -1
  34. package/resources/credits.d.mts +12 -0
  35. package/resources/credits.d.mts.map +1 -1
  36. package/resources/credits.d.ts +12 -0
  37. package/resources/credits.d.ts.map +1 -1
  38. package/resources/credits.js +12 -0
  39. package/resources/credits.js.map +1 -1
  40. package/resources/credits.mjs +12 -0
  41. package/resources/credits.mjs.map +1 -1
  42. package/resources/drafts.d.mts +33 -0
  43. package/resources/drafts.d.mts.map +1 -1
  44. package/resources/drafts.d.ts +33 -0
  45. package/resources/drafts.d.ts.map +1 -1
  46. package/resources/drafts.js +24 -0
  47. package/resources/drafts.js.map +1 -1
  48. package/resources/drafts.mjs +24 -0
  49. package/resources/drafts.mjs.map +1 -1
  50. package/resources/draws.d.mts +46 -1
  51. package/resources/draws.d.mts.map +1 -1
  52. package/resources/draws.d.ts +46 -1
  53. package/resources/draws.d.ts.map +1 -1
  54. package/resources/draws.js +27 -0
  55. package/resources/draws.js.map +1 -1
  56. package/resources/draws.mjs +27 -0
  57. package/resources/draws.mjs.map +1 -1
  58. package/resources/events.d.mts +25 -1
  59. package/resources/events.d.mts.map +1 -1
  60. package/resources/events.d.ts +25 -1
  61. package/resources/events.d.ts.map +1 -1
  62. package/resources/extractions.d.mts +74 -5
  63. package/resources/extractions.d.mts.map +1 -1
  64. package/resources/extractions.d.ts +74 -5
  65. package/resources/extractions.d.ts.map +1 -1
  66. package/resources/extractions.js +36 -0
  67. package/resources/extractions.js.map +1 -1
  68. package/resources/extractions.mjs +36 -0
  69. package/resources/extractions.mjs.map +1 -1
  70. package/resources/index.d.mts +1 -1
  71. package/resources/index.d.mts.map +1 -1
  72. package/resources/index.d.ts +1 -1
  73. package/resources/index.d.ts.map +1 -1
  74. package/resources/index.js.map +1 -1
  75. package/resources/index.mjs.map +1 -1
  76. package/resources/integrations.d.mts +77 -0
  77. package/resources/integrations.d.mts.map +1 -1
  78. package/resources/integrations.d.ts +77 -0
  79. package/resources/integrations.d.ts.map +1 -1
  80. package/resources/integrations.js +47 -0
  81. package/resources/integrations.js.map +1 -1
  82. package/resources/integrations.mjs +47 -0
  83. package/resources/integrations.mjs.map +1 -1
  84. package/resources/monitors.d.mts +46 -0
  85. package/resources/monitors.d.mts.map +1 -1
  86. package/resources/monitors.d.ts +46 -0
  87. package/resources/monitors.d.ts.map +1 -1
  88. package/resources/monitors.js +31 -0
  89. package/resources/monitors.js.map +1 -1
  90. package/resources/monitors.mjs +31 -0
  91. package/resources/monitors.mjs.map +1 -1
  92. package/resources/radar.d.mts +4 -1
  93. package/resources/radar.d.mts.map +1 -1
  94. package/resources/radar.d.ts +4 -1
  95. package/resources/radar.d.ts.map +1 -1
  96. package/resources/shared.d.mts +12 -0
  97. package/resources/shared.d.mts.map +1 -1
  98. package/resources/shared.d.ts +12 -0
  99. package/resources/shared.d.ts.map +1 -1
  100. package/resources/styles.d.mts +63 -4
  101. package/resources/styles.d.mts.map +1 -1
  102. package/resources/styles.d.ts +63 -4
  103. package/resources/styles.d.ts.map +1 -1
  104. package/resources/styles.js +55 -8
  105. package/resources/styles.js.map +1 -1
  106. package/resources/styles.mjs +55 -8
  107. package/resources/styles.mjs.map +1 -1
  108. package/resources/support/tickets.d.mts +34 -0
  109. package/resources/support/tickets.d.mts.map +1 -1
  110. package/resources/support/tickets.d.ts +34 -0
  111. package/resources/support/tickets.d.ts.map +1 -1
  112. package/resources/support/tickets.js +34 -0
  113. package/resources/support/tickets.js.map +1 -1
  114. package/resources/support/tickets.mjs +34 -0
  115. package/resources/support/tickets.mjs.map +1 -1
  116. package/resources/trends.d.mts +4 -1
  117. package/resources/trends.d.mts.map +1 -1
  118. package/resources/trends.d.ts +4 -1
  119. package/resources/trends.d.ts.map +1 -1
  120. package/resources/trends.js +1 -1
  121. package/resources/trends.mjs +1 -1
  122. package/resources/webhooks.d.mts +54 -0
  123. package/resources/webhooks.d.mts.map +1 -1
  124. package/resources/webhooks.d.ts +54 -0
  125. package/resources/webhooks.d.ts.map +1 -1
  126. package/resources/webhooks.js +36 -0
  127. package/resources/webhooks.js.map +1 -1
  128. package/resources/webhooks.mjs +36 -0
  129. package/resources/webhooks.mjs.map +1 -1
  130. package/resources/x/accounts.d.mts +59 -3
  131. package/resources/x/accounts.d.mts.map +1 -1
  132. package/resources/x/accounts.d.ts +59 -3
  133. package/resources/x/accounts.d.ts.map +1 -1
  134. package/resources/x/accounts.js +55 -5
  135. package/resources/x/accounts.js.map +1 -1
  136. package/resources/x/accounts.mjs +55 -5
  137. package/resources/x/accounts.mjs.map +1 -1
  138. package/resources/x/bookmarks.d.mts +11 -1
  139. package/resources/x/bookmarks.d.mts.map +1 -1
  140. package/resources/x/bookmarks.d.ts +11 -1
  141. package/resources/x/bookmarks.d.ts.map +1 -1
  142. package/resources/x/bookmarks.js +10 -0
  143. package/resources/x/bookmarks.js.map +1 -1
  144. package/resources/x/bookmarks.mjs +10 -0
  145. package/resources/x/bookmarks.mjs.map +1 -1
  146. package/resources/x/communities/communities.d.mts +118 -11
  147. package/resources/x/communities/communities.d.mts.map +1 -1
  148. package/resources/x/communities/communities.d.ts +118 -11
  149. package/resources/x/communities/communities.d.ts.map +1 -1
  150. package/resources/x/communities/communities.js +45 -16
  151. package/resources/x/communities/communities.js.map +1 -1
  152. package/resources/x/communities/communities.mjs +45 -16
  153. package/resources/x/communities/communities.mjs.map +1 -1
  154. package/resources/x/communities/index.d.mts +1 -1
  155. package/resources/x/communities/index.d.mts.map +1 -1
  156. package/resources/x/communities/index.d.ts +1 -1
  157. package/resources/x/communities/index.d.ts.map +1 -1
  158. package/resources/x/communities/index.js.map +1 -1
  159. package/resources/x/communities/index.mjs.map +1 -1
  160. package/resources/x/communities/join.d.mts +18 -2
  161. package/resources/x/communities/join.d.mts.map +1 -1
  162. package/resources/x/communities/join.d.ts +18 -2
  163. package/resources/x/communities/join.d.ts.map +1 -1
  164. package/resources/x/communities/join.js +16 -0
  165. package/resources/x/communities/join.js.map +1 -1
  166. package/resources/x/communities/join.mjs +16 -0
  167. package/resources/x/communities/join.mjs.map +1 -1
  168. package/resources/x/communities/tweets.d.mts +28 -5
  169. package/resources/x/communities/tweets.d.mts.map +1 -1
  170. package/resources/x/communities/tweets.d.ts +28 -5
  171. package/resources/x/communities/tweets.d.ts.map +1 -1
  172. package/resources/x/communities/tweets.js +20 -6
  173. package/resources/x/communities/tweets.js.map +1 -1
  174. package/resources/x/communities/tweets.mjs +20 -6
  175. package/resources/x/communities/tweets.mjs.map +1 -1
  176. package/resources/x/dm.d.mts +19 -2
  177. package/resources/x/dm.d.mts.map +1 -1
  178. package/resources/x/dm.d.ts +19 -2
  179. package/resources/x/dm.d.ts.map +1 -1
  180. package/resources/x/dm.js +17 -0
  181. package/resources/x/dm.js.map +1 -1
  182. package/resources/x/dm.mjs +17 -0
  183. package/resources/x/dm.mjs.map +1 -1
  184. package/resources/x/followers.d.mts +8 -0
  185. package/resources/x/followers.d.mts.map +1 -1
  186. package/resources/x/followers.d.ts +8 -0
  187. package/resources/x/followers.d.ts.map +1 -1
  188. package/resources/x/followers.js +8 -0
  189. package/resources/x/followers.js.map +1 -1
  190. package/resources/x/followers.mjs +8 -0
  191. package/resources/x/followers.mjs.map +1 -1
  192. package/resources/x/index.d.mts +2 -2
  193. package/resources/x/index.d.mts.map +1 -1
  194. package/resources/x/index.d.ts +2 -2
  195. package/resources/x/index.d.ts.map +1 -1
  196. package/resources/x/index.js.map +1 -1
  197. package/resources/x/index.mjs.map +1 -1
  198. package/resources/x/lists.d.mts +27 -6
  199. package/resources/x/lists.d.mts.map +1 -1
  200. package/resources/x/lists.d.ts +27 -6
  201. package/resources/x/lists.d.ts.map +1 -1
  202. package/resources/x/lists.js +23 -16
  203. package/resources/x/lists.js.map +1 -1
  204. package/resources/x/lists.mjs +23 -16
  205. package/resources/x/lists.mjs.map +1 -1
  206. package/resources/x/media.d.mts +17 -1
  207. package/resources/x/media.d.mts.map +1 -1
  208. package/resources/x/media.d.ts +17 -1
  209. package/resources/x/media.d.ts.map +1 -1
  210. package/resources/x/media.js +16 -0
  211. package/resources/x/media.js.map +1 -1
  212. package/resources/x/media.mjs +16 -0
  213. package/resources/x/media.mjs.map +1 -1
  214. package/resources/x/profile.d.mts +30 -3
  215. package/resources/x/profile.d.mts.map +1 -1
  216. package/resources/x/profile.d.ts +30 -3
  217. package/resources/x/profile.d.ts.map +1 -1
  218. package/resources/x/profile.js +27 -0
  219. package/resources/x/profile.js.map +1 -1
  220. package/resources/x/profile.mjs +27 -0
  221. package/resources/x/profile.mjs.map +1 -1
  222. package/resources/x/tweets/like.d.mts +18 -4
  223. package/resources/x/tweets/like.d.mts.map +1 -1
  224. package/resources/x/tweets/like.d.ts +18 -4
  225. package/resources/x/tweets/like.d.ts.map +1 -1
  226. package/resources/x/tweets/like.js +18 -4
  227. package/resources/x/tweets/like.js.map +1 -1
  228. package/resources/x/tweets/like.mjs +18 -4
  229. package/resources/x/tweets/like.mjs.map +1 -1
  230. package/resources/x/tweets/retweet.d.mts +18 -4
  231. package/resources/x/tweets/retweet.d.mts.map +1 -1
  232. package/resources/x/tweets/retweet.d.ts +18 -4
  233. package/resources/x/tweets/retweet.d.ts.map +1 -1
  234. package/resources/x/tweets/retweet.js +18 -4
  235. package/resources/x/tweets/retweet.js.map +1 -1
  236. package/resources/x/tweets/retweet.mjs +18 -4
  237. package/resources/x/tweets/retweet.mjs.map +1 -1
  238. package/resources/x/tweets/tweets.d.mts +146 -15
  239. package/resources/x/tweets/tweets.d.mts.map +1 -1
  240. package/resources/x/tweets/tweets.d.ts +146 -15
  241. package/resources/x/tweets/tweets.d.ts.map +1 -1
  242. package/resources/x/tweets/tweets.js +74 -10
  243. package/resources/x/tweets/tweets.js.map +1 -1
  244. package/resources/x/tweets/tweets.mjs +74 -10
  245. package/resources/x/tweets/tweets.mjs.map +1 -1
  246. package/resources/x/users/follow.d.mts +19 -4
  247. package/resources/x/users/follow.d.mts.map +1 -1
  248. package/resources/x/users/follow.d.ts +19 -4
  249. package/resources/x/users/follow.d.ts.map +1 -1
  250. package/resources/x/users/follow.js +19 -4
  251. package/resources/x/users/follow.js.map +1 -1
  252. package/resources/x/users/follow.mjs +19 -4
  253. package/resources/x/users/follow.mjs.map +1 -1
  254. package/resources/x/users/users.d.mts +94 -21
  255. package/resources/x/users/users.d.mts.map +1 -1
  256. package/resources/x/users/users.d.ts +94 -21
  257. package/resources/x/users/users.d.ts.map +1 -1
  258. package/resources/x/users/users.js +78 -33
  259. package/resources/x/users/users.js.map +1 -1
  260. package/resources/x/users/users.mjs +78 -33
  261. package/resources/x/users/users.mjs.map +1 -1
  262. package/resources/x/x.d.mts +42 -6
  263. package/resources/x/x.d.mts.map +1 -1
  264. package/resources/x/x.d.ts +42 -6
  265. package/resources/x/x.d.ts.map +1 -1
  266. package/resources/x/x.js +21 -5
  267. package/resources/x/x.js.map +1 -1
  268. package/resources/x/x.mjs +21 -5
  269. package/resources/x/x.mjs.map +1 -1
  270. package/src/client.ts +2 -0
  271. package/src/resources/account.ts +20 -1
  272. package/src/resources/api-keys.ts +23 -3
  273. package/src/resources/compose.ts +32 -1
  274. package/src/resources/credits.ts +12 -0
  275. package/src/resources/drafts.ts +33 -0
  276. package/src/resources/draws.ts +46 -1
  277. package/src/resources/events.ts +25 -1
  278. package/src/resources/extractions.ts +74 -5
  279. package/src/resources/index.ts +1 -0
  280. package/src/resources/integrations.ts +77 -0
  281. package/src/resources/monitors.ts +46 -0
  282. package/src/resources/radar.ts +4 -1
  283. package/src/resources/shared.ts +12 -0
  284. package/src/resources/styles.ts +67 -8
  285. package/src/resources/support/tickets.ts +34 -0
  286. package/src/resources/trends.ts +4 -1
  287. package/src/resources/webhooks.ts +54 -0
  288. package/src/resources/x/accounts.ts +72 -7
  289. package/src/resources/x/bookmarks.ts +11 -1
  290. package/src/resources/x/communities/communities.ts +142 -26
  291. package/src/resources/x/communities/index.ts +1 -1
  292. package/src/resources/x/communities/join.ts +18 -2
  293. package/src/resources/x/communities/tweets.ts +41 -11
  294. package/src/resources/x/dm.ts +19 -2
  295. package/src/resources/x/followers.ts +8 -0
  296. package/src/resources/x/index.ts +2 -0
  297. package/src/resources/x/lists.ts +30 -22
  298. package/src/resources/x/media.ts +17 -1
  299. package/src/resources/x/profile.ts +30 -3
  300. package/src/resources/x/tweets/like.ts +20 -6
  301. package/src/resources/x/tweets/retweet.ts +20 -14
  302. package/src/resources/x/tweets/tweets.ts +157 -27
  303. package/src/resources/x/users/follow.ts +21 -10
  304. package/src/resources/x/users/users.ts +103 -52
  305. package/src/resources/x/x.ts +50 -8
  306. package/src/version.ts +1 -1
  307. package/version.d.mts +1 -1
  308. package/version.d.ts +1 -1
  309. package/version.js +1 -1
  310. package/version.mjs +1 -1
@@ -1,7 +1,7 @@
1
1
  import { APIResource } from "../../core/resource.js";
2
2
  import * as Shared from "../shared.js";
3
3
  import * as AccountsAPI from "./accounts.js";
4
- import { AccountCreateParams, AccountCreateResponse, AccountDeleteResponse, AccountListResponse, AccountReauthParams, AccountReauthResponse, Accounts, XAccount, XAccountDetail } from "./accounts.js";
4
+ import { AccountBulkRetryResponse, AccountCreateParams, AccountCreateResponse, AccountDeleteResponse, AccountListResponse, AccountReauthParams, AccountReauthResponse, Accounts, XAccount, XAccountDetail } from "./accounts.js";
5
5
  import * as BookmarksAPI from "./bookmarks.js";
6
6
  import { BookmarkListParams, BookmarkRetrieveFoldersResponse, Bookmarks } from "./bookmarks.js";
7
7
  import * as DmAPI from "./dm.js";
@@ -38,23 +38,46 @@ export declare class X extends APIResource {
38
38
  lists: ListsAPI.Lists;
39
39
  /**
40
40
  * Retrieve the full content of an X Article (long-form post) by tweet ID.
41
+ *
42
+ * @example
43
+ * ```ts
44
+ * const response = await client.x.getArticle('tweetId');
45
+ * ```
41
46
  */
42
47
  getArticle(tweetID: string, options?: RequestOptions): APIPromise<XGetArticleResponse>;
43
48
  /**
44
49
  * Get home timeline
50
+ *
51
+ * @example
52
+ * ```ts
53
+ * const paginatedTweets = await client.x.getHomeTimeline();
54
+ * ```
45
55
  */
46
56
  getHomeTimeline(query?: XGetHomeTimelineParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
47
57
  /**
48
58
  * Get notifications
59
+ *
60
+ * @example
61
+ * ```ts
62
+ * const response = await client.x.getNotifications();
63
+ * ```
49
64
  */
50
65
  getNotifications(query?: XGetNotificationsParams | null | undefined, options?: RequestOptions): APIPromise<XGetNotificationsResponse>;
51
66
  /**
52
67
  * Get trending topics
68
+ *
69
+ * @example
70
+ * ```ts
71
+ * const response = await client.x.getTrends();
72
+ * ```
53
73
  */
54
- getTrends(options?: RequestOptions): APIPromise<void>;
74
+ getTrends(options?: RequestOptions): APIPromise<XGetTrendsResponse>;
55
75
  }
56
76
  export interface XGetArticleResponse {
57
77
  article: XGetArticleResponse.Article;
78
+ /**
79
+ * Author of a tweet with follower count and verification status.
80
+ */
58
81
  author?: TweetsAPI.TweetAuthor;
59
82
  }
60
83
  export declare namespace XGetArticleResponse {
@@ -99,9 +122,22 @@ export declare namespace XGetNotificationsResponse {
99
122
  type?: string;
100
123
  }
101
124
  }
125
+ export interface XGetTrendsResponse {
126
+ count: number;
127
+ trends: Array<XGetTrendsResponse.Trend>;
128
+ woeid: number;
129
+ }
130
+ export declare namespace XGetTrendsResponse {
131
+ interface Trend {
132
+ name: string;
133
+ description?: string;
134
+ query?: string;
135
+ rank?: number;
136
+ }
137
+ }
102
138
  export interface XGetHomeTimelineParams {
103
139
  /**
104
- * Pagination cursor from previous response
140
+ * Pagination cursor for timeline
105
141
  */
106
142
  cursor?: string;
107
143
  /**
@@ -111,7 +147,7 @@ export interface XGetHomeTimelineParams {
111
147
  }
112
148
  export interface XGetNotificationsParams {
113
149
  /**
114
- * Pagination cursor from previous response
150
+ * Pagination cursor for notifications
115
151
  */
116
152
  cursor?: string;
117
153
  /**
@@ -120,7 +156,7 @@ export interface XGetNotificationsParams {
120
156
  type?: 'All' | 'Verified' | 'Mentions';
121
157
  }
122
158
  export declare namespace X {
123
- export { type XGetArticleResponse as XGetArticleResponse, type XGetNotificationsResponse as XGetNotificationsResponse, type XGetHomeTimelineParams as XGetHomeTimelineParams, type XGetNotificationsParams as XGetNotificationsParams, };
159
+ export { type XGetArticleResponse as XGetArticleResponse, type XGetNotificationsResponse as XGetNotificationsResponse, type XGetTrendsResponse as XGetTrendsResponse, type XGetHomeTimelineParams as XGetHomeTimelineParams, type XGetNotificationsParams as XGetNotificationsParams, };
124
160
  export { Tweets as Tweets, type SearchTweet as SearchTweet, type TweetAuthor as TweetAuthor, type TweetDetail as TweetDetail, type TweetCreateResponse as TweetCreateResponse, type TweetRetrieveResponse as TweetRetrieveResponse, type TweetDeleteResponse as TweetDeleteResponse, type TweetCreateParams as TweetCreateParams, type TweetListParams as TweetListParams, type TweetDeleteParams as TweetDeleteParams, type TweetGetFavoritersParams as TweetGetFavoritersParams, type TweetGetQuotesParams as TweetGetQuotesParams, type TweetGetRepliesParams as TweetGetRepliesParams, type TweetGetRetweetersParams as TweetGetRetweetersParams, type TweetGetThreadParams as TweetGetThreadParams, type TweetSearchParams as TweetSearchParams, };
125
161
  export { Users as Users, type UserProfile as UserProfile, type UserRetrieveBatchParams as UserRetrieveBatchParams, type UserRetrieveFollowersParams as UserRetrieveFollowersParams, type UserRetrieveFollowersYouKnowParams as UserRetrieveFollowersYouKnowParams, type UserRetrieveFollowingParams as UserRetrieveFollowingParams, type UserRetrieveLikesParams as UserRetrieveLikesParams, type UserRetrieveMediaParams as UserRetrieveMediaParams, type UserRetrieveMentionsParams as UserRetrieveMentionsParams, type UserRetrieveSearchParams as UserRetrieveSearchParams, type UserRetrieveTweetsParams as UserRetrieveTweetsParams, type UserRetrieveVerifiedFollowersParams as UserRetrieveVerifiedFollowersParams, };
126
162
  export { Followers as Followers, type FollowerCheckResponse as FollowerCheckResponse, type FollowerCheckParams as FollowerCheckParams, };
@@ -128,7 +164,7 @@ export declare namespace X {
128
164
  export { Media as Media, type MediaDownloadResponse as MediaDownloadResponse, type MediaUploadResponse as MediaUploadResponse, type MediaDownloadParams as MediaDownloadParams, type MediaUploadParams as MediaUploadParams, };
129
165
  export { Profile as Profile, type ProfileUpdateResponse as ProfileUpdateResponse, type ProfileUpdateAvatarResponse as ProfileUpdateAvatarResponse, type ProfileUpdateBannerResponse as ProfileUpdateBannerResponse, type ProfileUpdateParams as ProfileUpdateParams, type ProfileUpdateAvatarParams as ProfileUpdateAvatarParams, type ProfileUpdateBannerParams as ProfileUpdateBannerParams, };
130
166
  export { Communities as Communities, type CommunityActionResult as CommunityActionResult, type CommunityCreateResponse as CommunityCreateResponse, type CommunityDeleteResponse as CommunityDeleteResponse, type CommunityRetrieveInfoResponse as CommunityRetrieveInfoResponse, type CommunityCreateParams as CommunityCreateParams, type CommunityDeleteParams as CommunityDeleteParams, type CommunityRetrieveMembersParams as CommunityRetrieveMembersParams, type CommunityRetrieveModeratorsParams as CommunityRetrieveModeratorsParams, type CommunityRetrieveSearchParams as CommunityRetrieveSearchParams, };
131
- export { Accounts as Accounts, type XAccount as XAccount, type XAccountDetail as XAccountDetail, type AccountCreateResponse as AccountCreateResponse, type AccountListResponse as AccountListResponse, type AccountDeleteResponse as AccountDeleteResponse, type AccountReauthResponse as AccountReauthResponse, type AccountCreateParams as AccountCreateParams, type AccountReauthParams as AccountReauthParams, };
167
+ export { Accounts as Accounts, type XAccount as XAccount, type XAccountDetail as XAccountDetail, type AccountCreateResponse as AccountCreateResponse, type AccountListResponse as AccountListResponse, type AccountDeleteResponse as AccountDeleteResponse, type AccountBulkRetryResponse as AccountBulkRetryResponse, type AccountReauthResponse as AccountReauthResponse, type AccountCreateParams as AccountCreateParams, type AccountReauthParams as AccountReauthParams, };
132
168
  export { Bookmarks as Bookmarks, type BookmarkRetrieveFoldersResponse as BookmarkRetrieveFoldersResponse, type BookmarkListParams as BookmarkListParams, };
133
169
  export { Lists as Lists, type ListRetrieveFollowersParams as ListRetrieveFollowersParams, type ListRetrieveMembersParams as ListRetrieveMembersParams, type ListRetrieveTweetsParams as ListRetrieveTweetsParams, };
134
170
  }
@@ -1 +1 @@
1
- {"version":3,"file":"x.d.ts","sourceRoot":"","sources":["../../src/resources/x/x.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,KAAK,WAAW;OAChB,EACL,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,QAAQ,EACR,QAAQ,EACR,cAAc,EACf;OACM,KAAK,YAAY;OACjB,EAAE,kBAAkB,EAAE,+BAA+B,EAAE,SAAS,EAAE;OAClE,KAAK,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,CAAC;IAEF,OAAO,EACL,SAAS,IAAI,SAAS,EACtB,KAAK,+BAA+B,IAAI,+BAA+B,EACvE,KAAK,kBAAkB,IAAI,kBAAkB,GAC9C,CAAC;IAEF,OAAO,EACL,KAAK,IAAI,KAAK,EACd,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
1
+ {"version":3,"file":"x.d.ts","sourceRoot":"","sources":["../../src/resources/x/x.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,KAAK,WAAW;OAChB,EACL,wBAAwB,EACxB,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,QAAQ,EACR,QAAQ,EACR,cAAc,EACf;OACM,KAAK,YAAY;OACjB,EAAE,kBAAkB,EAAE,+BAA+B,EAAE,SAAS,EAAE;OAClE,KAAK,KAAK;OACV,EAAE,EAAE,EAAE,uBAAuB,EAAE,yBAAyB,EAAE,YAAY,EAAE,cAAc,EAAE;OACxF,KAAK,YAAY;OACjB,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,SAAS,EAAE;OACzD,KAAK,QAAQ;OACb,EACL,2BAA2B,EAC3B,yBAAyB,EACzB,wBAAwB,EACxB,KAAK,EACN;OACM,KAAK,QAAQ;OACb,EACL,KAAK,EACL,mBAAmB,EACnB,qBAAqB,EACrB,iBAAiB,EACjB,mBAAmB,EACpB;OACM,KAAK,UAAU;OACf,EACL,OAAO,EACP,yBAAyB,EACzB,2BAA2B,EAC3B,yBAAyB,EACzB,2BAA2B,EAC3B,mBAAmB,EACnB,qBAAqB,EACtB;OACM,KAAK,cAAc;OACnB,EACL,WAAW,EACX,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,qBAAqB,EACrB,uBAAuB,EACvB,6BAA6B,EAC7B,8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OAAO,EACL,KAAK,IAAI,KAAK,EACd,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
package/resources/x/x.js CHANGED
@@ -24,7 +24,6 @@ const TweetsAPI = tslib_1.__importStar(require("./tweets/tweets.js"));
24
24
  const tweets_1 = require("./tweets/tweets.js");
25
25
  const UsersAPI = tslib_1.__importStar(require("./users/users.js"));
26
26
  const users_1 = require("./users/users.js");
27
- const headers_1 = require("../../internal/headers.js");
28
27
  const path_1 = require("../../internal/utils/path.js");
29
28
  /**
30
29
  * X data lookups (subscription required)
@@ -45,30 +44,47 @@ class X extends resource_1.APIResource {
45
44
  }
46
45
  /**
47
46
  * Retrieve the full content of an X Article (long-form post) by tweet ID.
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * const response = await client.x.getArticle('tweetId');
51
+ * ```
48
52
  */
49
53
  getArticle(tweetID, options) {
50
54
  return this._client.get((0, path_1.path) `/x/articles/${tweetID}`, options);
51
55
  }
52
56
  /**
53
57
  * Get home timeline
58
+ *
59
+ * @example
60
+ * ```ts
61
+ * const paginatedTweets = await client.x.getHomeTimeline();
62
+ * ```
54
63
  */
55
64
  getHomeTimeline(query = {}, options) {
56
65
  return this._client.get('/x/timeline', { query, ...options });
57
66
  }
58
67
  /**
59
68
  * Get notifications
69
+ *
70
+ * @example
71
+ * ```ts
72
+ * const response = await client.x.getNotifications();
73
+ * ```
60
74
  */
61
75
  getNotifications(query = {}, options) {
62
76
  return this._client.get('/x/notifications', { query, ...options });
63
77
  }
64
78
  /**
65
79
  * Get trending topics
80
+ *
81
+ * @example
82
+ * ```ts
83
+ * const response = await client.x.getTrends();
84
+ * ```
66
85
  */
67
86
  getTrends(options) {
68
- return this._client.get('/x/trends', {
69
- ...options,
70
- headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
71
- });
87
+ return this._client.get('/x/trends', options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S,GAAG,qBAAS,CAAC;AACxB,CAAC,CAAC,KAAK,GAAG,aAAK,CAAC"}
package/resources/x/x.mjs CHANGED
@@ -20,7 +20,6 @@ import * as TweetsAPI from "./tweets/tweets.mjs";
20
20
  import { Tweets, } from "./tweets/tweets.mjs";
21
21
  import * as UsersAPI from "./users/users.mjs";
22
22
  import { Users, } from "./users/users.mjs";
23
- import { buildHeaders } from "../../internal/headers.mjs";
24
23
  import { path } from "../../internal/utils/path.mjs";
25
24
  /**
26
25
  * X data lookups (subscription required)
@@ -41,30 +40,47 @@ export class X extends APIResource {
41
40
  }
42
41
  /**
43
42
  * Retrieve the full content of an X Article (long-form post) by tweet ID.
43
+ *
44
+ * @example
45
+ * ```ts
46
+ * const response = await client.x.getArticle('tweetId');
47
+ * ```
44
48
  */
45
49
  getArticle(tweetID, options) {
46
50
  return this._client.get(path `/x/articles/${tweetID}`, options);
47
51
  }
48
52
  /**
49
53
  * Get home timeline
54
+ *
55
+ * @example
56
+ * ```ts
57
+ * const paginatedTweets = await client.x.getHomeTimeline();
58
+ * ```
50
59
  */
51
60
  getHomeTimeline(query = {}, options) {
52
61
  return this._client.get('/x/timeline', { query, ...options });
53
62
  }
54
63
  /**
55
64
  * Get notifications
65
+ *
66
+ * @example
67
+ * ```ts
68
+ * const response = await client.x.getNotifications();
69
+ * ```
56
70
  */
57
71
  getNotifications(query = {}, options) {
58
72
  return this._client.get('/x/notifications', { query, ...options });
59
73
  }
60
74
  /**
61
75
  * Get trending topics
76
+ *
77
+ * @example
78
+ * ```ts
79
+ * const response = await client.x.getTrends();
80
+ * ```
62
81
  */
63
82
  getTrends(options) {
64
- return this._client.get('/x/trends', {
65
- ...options,
66
- headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
67
- });
83
+ return this._client.get('/x/trends', options);
68
84
  }
69
85
  }
70
86
  X.Tweets = Tweets;
@@ -1 +1 @@
1
- {"version":3,"file":"x.mjs","sourceRoot":"","sources":["../../src/resources/x/x.ts"],"names":[],"mappings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C,CAAC,WAAW,GAAG,WAAW,CAAC;AAC5B,CAAC,CAAC,QAAQ,GAAG,QAAQ,CAAC;AACtB,CAAC,CAAC,SAAS,GAAG,SAAS,CAAC;AACxB,CAAC,CAAC,KAAK,GAAG,KAAK,CAAC"}
package/src/client.ts CHANGED
@@ -134,6 +134,7 @@ import {
134
134
  XGetHomeTimelineParams,
135
135
  XGetNotificationsParams,
136
136
  XGetNotificationsResponse,
137
+ XGetTrendsResponse,
137
138
  } from './resources/x/x';
138
139
  import { type Fetch } from './internal/builtin-types';
139
140
  import { HeadersLike, NullableHeaders, buildHeaders } from './internal/headers';
@@ -1095,6 +1096,7 @@ export declare namespace XTwitterScraper {
1095
1096
  X as X,
1096
1097
  type XGetArticleResponse as XGetArticleResponse,
1097
1098
  type XGetNotificationsResponse as XGetNotificationsResponse,
1099
+ type XGetTrendsResponse as XGetTrendsResponse,
1098
1100
  type XGetHomeTimelineParams as XGetHomeTimelineParams,
1099
1101
  type XGetNotificationsParams as XGetNotificationsParams,
1100
1102
  };
@@ -10,6 +10,11 @@ import { RequestOptions } from '../internal/request-options';
10
10
  export class Account extends APIResource {
11
11
  /**
12
12
  * Get account info
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const account = await client.account.retrieve();
17
+ * ```
13
18
  */
14
19
  retrieve(options?: RequestOptions): APIPromise<AccountRetrieveResponse> {
15
20
  return this._client.get('/account', { ...options, __security: { apiKeyAuth: true } });
@@ -17,6 +22,13 @@ export class Account extends APIResource {
17
22
 
18
23
  /**
19
24
  * Set linked X username
25
+ *
26
+ * @example
27
+ * ```ts
28
+ * const response = await client.account.setXUsername({
29
+ * username: 'elonmusk',
30
+ * });
31
+ * ```
20
32
  */
21
33
  setXUsername(
22
34
  body: AccountSetXUsernameParams,
@@ -27,12 +39,19 @@ export class Account extends APIResource {
27
39
 
28
40
  /**
29
41
  * Update account locale
42
+ *
43
+ * @example
44
+ * ```ts
45
+ * const response = await client.account.updateLocale({
46
+ * locale: 'en',
47
+ * });
48
+ * ```
30
49
  */
31
50
  updateLocale(
32
51
  body: AccountUpdateLocaleParams,
33
52
  options?: RequestOptions,
34
53
  ): APIPromise<AccountUpdateLocaleResponse> {
35
- return this._client.patch('/account', { body, ...options, __security: {} });
54
+ return this._client.patch('/account', { body, ...options, __security: { apiKeyAuth: true } });
36
55
  }
37
56
  }
38
57
 
@@ -11,26 +11,46 @@ import { path } from '../internal/utils/path';
11
11
  export class APIKeys extends APIResource {
12
12
  /**
13
13
  * Create API key
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * const apiKey = await client.apiKeys.create({
18
+ * name: 'My API Key',
19
+ * });
20
+ * ```
14
21
  */
15
22
  create(body: APIKeyCreateParams, options?: RequestOptions): APIPromise<APIKeyCreateResponse> {
16
- return this._client.post('/api-keys', { body, ...options, __security: {} });
23
+ return this._client.post('/api-keys', { body, ...options, __security: { apiKeyAuth: true } });
17
24
  }
18
25
 
19
26
  /**
20
27
  * List API keys
28
+ *
29
+ * @example
30
+ * ```ts
31
+ * const apiKeys = await client.apiKeys.list();
32
+ * ```
21
33
  */
22
34
  list(options?: RequestOptions): APIPromise<APIKeyListResponse> {
23
- return this._client.get('/api-keys', { ...options, __security: {} });
35
+ return this._client.get('/api-keys', { ...options, __security: { apiKeyAuth: true } });
24
36
  }
25
37
 
26
38
  /**
27
39
  * Revoke API key
40
+ *
41
+ * @example
42
+ * ```ts
43
+ * const response = await client.apiKeys.revoke('id');
44
+ * ```
28
45
  */
29
46
  revoke(id: string, options?: RequestOptions): APIPromise<APIKeyRevokeResponse> {
30
- return this._client.delete(path`/api-keys/${id}`, { ...options, __security: {} });
47
+ return this._client.delete(path`/api-keys/${id}`, { ...options, __security: { apiKeyAuth: true } });
31
48
  }
32
49
  }
33
50
 
51
+ /**
52
+ * API key metadata returned when listing keys.
53
+ */
34
54
  export interface APIKey {
35
55
  id: string;
36
56
 
@@ -10,13 +10,44 @@ import { RequestOptions } from '../internal/request-options';
10
10
  export class Compose extends APIResource {
11
11
  /**
12
12
  * Compose, refine, or score a tweet
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const compose = await client.compose.create({
17
+ * step: 'compose',
18
+ * goal: 'engagement',
19
+ * topic: 'AI trends in 2025',
20
+ * });
21
+ * ```
13
22
  */
14
23
  create(body: ComposeCreateParams, options?: RequestOptions): APIPromise<ComposeCreateResponse> {
15
24
  return this._client.post('/compose', { body, ...options });
16
25
  }
17
26
  }
18
27
 
19
- export type ComposeCreateResponse = { [key: string]: unknown };
28
+ export interface ComposeCreateResponse {
29
+ /**
30
+ * AI feedback on the draft
31
+ */
32
+ feedback?: string;
33
+
34
+ /**
35
+ * Engagement score (0-100)
36
+ */
37
+ score?: number;
38
+
39
+ /**
40
+ * Improvement suggestions
41
+ */
42
+ suggestions?: Array<string>;
43
+
44
+ /**
45
+ * Generated or refined tweet text
46
+ */
47
+ text?: string;
48
+
49
+ [k: string]: unknown;
50
+ }
20
51
 
21
52
  export interface ComposeCreateParams {
22
53
  /**
@@ -10,6 +10,11 @@ import { RequestOptions } from '../internal/request-options';
10
10
  export class Credits extends APIResource {
11
11
  /**
12
12
  * Get credits balance
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const response = await client.credits.retrieveBalance();
17
+ * ```
13
18
  */
14
19
  retrieveBalance(options?: RequestOptions): APIPromise<CreditRetrieveBalanceResponse> {
15
20
  return this._client.get('/credits', options);
@@ -17,6 +22,13 @@ export class Credits extends APIResource {
17
22
 
18
23
  /**
19
24
  * Top up credits balance
25
+ *
26
+ * @example
27
+ * ```ts
28
+ * const response = await client.credits.topupBalance({
29
+ * amount: 10000,
30
+ * });
31
+ * ```
20
32
  */
21
33
  topupBalance(
22
34
  body: CreditTopupBalanceParams,
@@ -12,6 +12,15 @@ import { path } from '../internal/utils/path';
12
12
  export class Drafts extends APIResource {
13
13
  /**
14
14
  * Save a tweet draft
15
+ *
16
+ * @example
17
+ * ```ts
18
+ * const draftDetail = await client.drafts.create({
19
+ * text: 'AI is the future of productivity',
20
+ * goal: 'engagement',
21
+ * topic: 'AI trends',
22
+ * });
23
+ * ```
15
24
  */
16
25
  create(body: DraftCreateParams, options?: RequestOptions): APIPromise<DraftDetail> {
17
26
  return this._client.post('/drafts', { body, ...options });
@@ -19,6 +28,11 @@ export class Drafts extends APIResource {
19
28
 
20
29
  /**
21
30
  * Get draft by ID
31
+ *
32
+ * @example
33
+ * ```ts
34
+ * const draftDetail = await client.drafts.retrieve('id');
35
+ * ```
22
36
  */
23
37
  retrieve(id: string, options?: RequestOptions): APIPromise<DraftDetail> {
24
38
  return this._client.get(path`/drafts/${id}`, options);
@@ -26,6 +40,11 @@ export class Drafts extends APIResource {
26
40
 
27
41
  /**
28
42
  * List saved drafts
43
+ *
44
+ * @example
45
+ * ```ts
46
+ * const drafts = await client.drafts.list();
47
+ * ```
29
48
  */
30
49
  list(
31
50
  query: DraftListParams | null | undefined = {},
@@ -36,6 +55,11 @@ export class Drafts extends APIResource {
36
55
 
37
56
  /**
38
57
  * Delete a draft
58
+ *
59
+ * @example
60
+ * ```ts
61
+ * await client.drafts.delete('id');
62
+ * ```
39
63
  */
40
64
  delete(id: string, options?: RequestOptions): APIPromise<void> {
41
65
  return this._client.delete(path`/drafts/${id}`, {
@@ -45,6 +69,9 @@ export class Drafts extends APIResource {
45
69
  }
46
70
  }
47
71
 
72
+ /**
73
+ * Saved tweet draft with optional topic and goal.
74
+ */
48
75
  export interface Draft {
49
76
  id: string;
50
77
 
@@ -57,6 +84,9 @@ export interface Draft {
57
84
  topic?: string;
58
85
  }
59
86
 
87
+ /**
88
+ * Full tweet draft including update timestamp.
89
+ */
60
90
  export interface DraftDetail {
61
91
  id: string;
62
92
 
@@ -93,6 +123,9 @@ export interface DraftListParams {
93
123
  */
94
124
  afterCursor?: string;
95
125
 
126
+ /**
127
+ * Maximum number of items to return (1-100, default 50)
128
+ */
96
129
  limit?: number;
97
130
  }
98
131
 
@@ -12,6 +12,11 @@ import { path } from '../internal/utils/path';
12
12
  export class Draws extends APIResource {
13
13
  /**
14
14
  * Get draw details
15
+ *
16
+ * @example
17
+ * ```ts
18
+ * const draw = await client.draws.retrieve('id');
19
+ * ```
15
20
  */
16
21
  retrieve(id: string, options?: RequestOptions): APIPromise<DrawRetrieveResponse> {
17
22
  return this._client.get(path`/draws/${id}`, options);
@@ -19,6 +24,11 @@ export class Draws extends APIResource {
19
24
 
20
25
  /**
21
26
  * List draws
27
+ *
28
+ * @example
29
+ * ```ts
30
+ * const draws = await client.draws.list();
31
+ * ```
22
32
  */
23
33
  list(
24
34
  query: DrawListParams | null | undefined = {},
@@ -29,6 +39,14 @@ export class Draws extends APIResource {
29
39
 
30
40
  /**
31
41
  * Export draw data
42
+ *
43
+ * @example
44
+ * ```ts
45
+ * const response = await client.draws.export('id');
46
+ *
47
+ * const content = await response.blob();
48
+ * console.log(content);
49
+ * ```
32
50
  */
33
51
  export(
34
52
  id: string,
@@ -45,12 +63,24 @@ export class Draws extends APIResource {
45
63
 
46
64
  /**
47
65
  * Run giveaway draw
66
+ *
67
+ * @example
68
+ * ```ts
69
+ * const response = await client.draws.run({
70
+ * tweetUrl: 'https://x.com/elonmusk/status/1234567890',
71
+ * mustRetweet: true,
72
+ * winnerCount: 3,
73
+ * });
74
+ * ```
48
75
  */
49
76
  run(body: DrawRunParams, options?: RequestOptions): APIPromise<DrawRunResponse> {
50
77
  return this._client.post('/draws', { body, ...options });
51
78
  }
52
79
  }
53
80
 
81
+ /**
82
+ * Full giveaway draw with tweet metrics, entries, and timing.
83
+ */
54
84
  export interface DrawDetail {
55
85
  id: string;
56
86
 
@@ -81,6 +111,9 @@ export interface DrawDetail {
81
111
  drawnAt?: string;
82
112
  }
83
113
 
114
+ /**
115
+ * Giveaway draw summary with entry counts and status.
116
+ */
84
117
  export interface DrawListItem {
85
118
  id: string;
86
119
 
@@ -97,6 +130,9 @@ export interface DrawListItem {
97
130
  drawnAt?: string;
98
131
  }
99
132
 
133
+ /**
134
+ * Giveaway draw winner with position and backup flag.
135
+ */
100
136
  export interface Winner {
101
137
  authorUsername: string;
102
138
 
@@ -108,6 +144,9 @@ export interface Winner {
108
144
  }
109
145
 
110
146
  export interface DrawRetrieveResponse {
147
+ /**
148
+ * Full giveaway draw with tweet metrics, entries, and timing.
149
+ */
111
150
  draw: DrawDetail;
112
151
 
113
152
  winners: Array<Winner>;
@@ -135,14 +174,20 @@ export interface DrawRunResponse {
135
174
 
136
175
  export interface DrawListParams {
137
176
  /**
138
- * Cursor for pagination
177
+ * Cursor for keyset pagination
139
178
  */
140
179
  after?: string;
141
180
 
181
+ /**
182
+ * Maximum number of items to return (1-100, default 50)
183
+ */
142
184
  limit?: number;
143
185
  }
144
186
 
145
187
  export interface DrawExportParams {
188
+ /**
189
+ * Export output format
190
+ */
146
191
  format?: 'csv' | 'json' | 'md' | 'md-document' | 'pdf' | 'txt' | 'xlsx';
147
192
 
148
193
  /**