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,4 +1,5 @@
1
1
  import { APIResource } from "../../../core/resource.mjs";
2
+ import * as Shared from "../../shared.mjs";
2
3
  import { APIPromise } from "../../../core/api-promise.mjs";
3
4
  import { RequestOptions } from "../../../internal/request-options.mjs";
4
5
  /**
@@ -7,24 +8,46 @@ import { RequestOptions } from "../../../internal/request-options.mjs";
7
8
  export declare class Tweets extends APIResource {
8
9
  /**
9
10
  * Search tweets across all communities
11
+ *
12
+ * @example
13
+ * ```ts
14
+ * const paginatedTweets =
15
+ * await client.x.communities.tweets.list({ q: 'q' });
16
+ * ```
10
17
  */
11
- list(query: TweetListParams, options?: RequestOptions): APIPromise<void>;
18
+ list(query: TweetListParams, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
19
+ /**
20
+ * Get community tweets
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const paginatedTweets =
25
+ * await client.x.communities.tweets.listByCommunity('id');
26
+ * ```
27
+ */
28
+ listByCommunity(id: string, query?: TweetListByCommunityParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
12
29
  }
13
30
  export interface TweetListParams {
14
31
  /**
15
- * Search query
32
+ * Search query for cross-community tweets
16
33
  */
17
34
  q: string;
18
35
  /**
19
- * Pagination cursor
36
+ * Pagination cursor for cross-community results
20
37
  */
21
38
  cursor?: string;
22
39
  /**
23
- * Sort order (Latest or Top)
40
+ * Sort order for cross-community results (Latest or Top)
24
41
  */
25
42
  queryType?: string;
26
43
  }
44
+ export interface TweetListByCommunityParams {
45
+ /**
46
+ * Pagination cursor for community tweets
47
+ */
48
+ cursor?: string;
49
+ }
27
50
  export declare namespace Tweets {
28
- export { type TweetListParams as TweetListParams };
51
+ export { type TweetListParams as TweetListParams, type TweetListByCommunityParams as TweetListByCommunityParams, };
29
52
  }
30
53
  //# sourceMappingURL=tweets.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tweets.d.mts","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OAEd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CAAC,KAAK,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAOzE;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,CAAC,EAAE,MAAM,CAAC;IAEV;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CACpD"}
1
+ {"version":3,"file":"tweets.d.mts","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;;;;;;OAQG;IACH,IAAI,CAAC,KAAK,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,MAAM,CAAC,eAAe,CAAC;IAI1F;;;;;;;;OAQG;IACH,eAAe,CACb,EAAE,EAAE,MAAM,EACV,KAAK,GAAE,0BAA0B,GAAG,IAAI,GAAG,SAAc,EACzD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,MAAM,CAAC,eAAe,CAAC;CAGtC;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,CAAC,EAAE,MAAM,CAAC;IAEV;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;CACH"}
@@ -1,4 +1,5 @@
1
1
  import { APIResource } from "../../../core/resource.js";
2
+ import * as Shared from "../../shared.js";
2
3
  import { APIPromise } from "../../../core/api-promise.js";
3
4
  import { RequestOptions } from "../../../internal/request-options.js";
4
5
  /**
@@ -7,24 +8,46 @@ import { RequestOptions } from "../../../internal/request-options.js";
7
8
  export declare class Tweets extends APIResource {
8
9
  /**
9
10
  * Search tweets across all communities
11
+ *
12
+ * @example
13
+ * ```ts
14
+ * const paginatedTweets =
15
+ * await client.x.communities.tweets.list({ q: 'q' });
16
+ * ```
10
17
  */
11
- list(query: TweetListParams, options?: RequestOptions): APIPromise<void>;
18
+ list(query: TweetListParams, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
19
+ /**
20
+ * Get community tweets
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const paginatedTweets =
25
+ * await client.x.communities.tweets.listByCommunity('id');
26
+ * ```
27
+ */
28
+ listByCommunity(id: string, query?: TweetListByCommunityParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
12
29
  }
13
30
  export interface TweetListParams {
14
31
  /**
15
- * Search query
32
+ * Search query for cross-community tweets
16
33
  */
17
34
  q: string;
18
35
  /**
19
- * Pagination cursor
36
+ * Pagination cursor for cross-community results
20
37
  */
21
38
  cursor?: string;
22
39
  /**
23
- * Sort order (Latest or Top)
40
+ * Sort order for cross-community results (Latest or Top)
24
41
  */
25
42
  queryType?: string;
26
43
  }
44
+ export interface TweetListByCommunityParams {
45
+ /**
46
+ * Pagination cursor for community tweets
47
+ */
48
+ cursor?: string;
49
+ }
27
50
  export declare namespace Tweets {
28
- export { type TweetListParams as TweetListParams };
51
+ export { type TweetListParams as TweetListParams, type TweetListByCommunityParams as TweetListByCommunityParams, };
29
52
  }
30
53
  //# sourceMappingURL=tweets.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tweets.d.ts","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OAEd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CAAC,KAAK,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAOzE;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,CAAC,EAAE,MAAM,CAAC;IAEV;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CACpD"}
1
+ {"version":3,"file":"tweets.d.ts","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,MAAM;OACX,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;;;;;;;OAQG;IACH,IAAI,CAAC,KAAK,EAAE,eAAe,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,MAAM,CAAC,eAAe,CAAC;IAI1F;;;;;;;;OAQG;IACH,eAAe,CACb,EAAE,EAAE,MAAM,EACV,KAAK,GAAE,0BAA0B,GAAG,IAAI,GAAG,SAAc,EACzD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,MAAM,CAAC,eAAe,CAAC;CAGtC;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,CAAC,EAAE,MAAM,CAAC;IAEV;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;CACH"}
@@ -3,20 +3,34 @@
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
4
  exports.Tweets = void 0;
5
5
  const resource_1 = require("../../../core/resource.js");
6
- const headers_1 = require("../../../internal/headers.js");
6
+ const path_1 = require("../../../internal/utils/path.js");
7
7
  /**
8
8
  * X data lookups (subscription required)
9
9
  */
10
10
  class Tweets extends resource_1.APIResource {
11
11
  /**
12
12
  * Search tweets across all communities
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const paginatedTweets =
17
+ * await client.x.communities.tweets.list({ q: 'q' });
18
+ * ```
13
19
  */
14
20
  list(query, options) {
15
- return this._client.get('/x/communities/tweets', {
16
- query,
17
- ...options,
18
- headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
19
- });
21
+ return this._client.get('/x/communities/tweets', { query, ...options });
22
+ }
23
+ /**
24
+ * Get community tweets
25
+ *
26
+ * @example
27
+ * ```ts
28
+ * const paginatedTweets =
29
+ * await client.x.communities.tweets.listByCommunity('id');
30
+ * ```
31
+ */
32
+ listByCommunity(id, query = {}, options) {
33
+ return this._client.get((0, path_1.path) `/x/communities/${id}/tweets`, { query, ...options });
20
34
  }
21
35
  }
22
36
  exports.Tweets = Tweets;
@@ -1 +1 @@
1
- {"version":3,"file":"tweets.js","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAErD,0DAAyD;AAGzD;;GAEG;AACH,MAAa,MAAO,SAAQ,sBAAW;IACrC;;OAEG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE;YAC/C,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF;AAXD,wBAWC"}
1
+ {"version":3,"file":"tweets.js","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAIrD,0DAAoD;AAEpD;;GAEG;AACH,MAAa,MAAO,SAAQ,sBAAW;IACrC;;;;;;;;OAQG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC1E,CAAC;IAED;;;;;;;;OAQG;IACH,eAAe,CACb,EAAU,EACV,QAAuD,EAAE,EACzD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,kBAAkB,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF;AA9BD,wBA8BC"}
@@ -1,19 +1,33 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
  import { APIResource } from "../../../core/resource.mjs";
3
- import { buildHeaders } from "../../../internal/headers.mjs";
3
+ import { path } from "../../../internal/utils/path.mjs";
4
4
  /**
5
5
  * X data lookups (subscription required)
6
6
  */
7
7
  export class Tweets extends APIResource {
8
8
  /**
9
9
  * Search tweets across all communities
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * const paginatedTweets =
14
+ * await client.x.communities.tweets.list({ q: 'q' });
15
+ * ```
10
16
  */
11
17
  list(query, options) {
12
- return this._client.get('/x/communities/tweets', {
13
- query,
14
- ...options,
15
- headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
16
- });
18
+ return this._client.get('/x/communities/tweets', { query, ...options });
19
+ }
20
+ /**
21
+ * Get community tweets
22
+ *
23
+ * @example
24
+ * ```ts
25
+ * const paginatedTweets =
26
+ * await client.x.communities.tweets.listByCommunity('id');
27
+ * ```
28
+ */
29
+ listByCommunity(id, query = {}, options) {
30
+ return this._client.get(path `/x/communities/${id}/tweets`, { query, ...options });
17
31
  }
18
32
  }
19
33
  //# sourceMappingURL=tweets.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"tweets.mjs","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAEf,EAAE,YAAY,EAAE;AAGvB;;GAEG;AACH,MAAM,OAAO,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE;YAC/C,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF"}
1
+ {"version":3,"file":"tweets.mjs","sourceRoot":"","sources":["../../../src/resources/x/communities/tweets.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,IAAI,EAAE;AAEf;;GAEG;AACH,MAAM,OAAO,MAAO,SAAQ,WAAW;IACrC;;;;;;;;OAQG;IACH,IAAI,CAAC,KAAsB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,uBAAuB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC1E,CAAC;IAED;;;;;;;;OAQG;IACH,eAAe,CACb,EAAU,EACV,QAAuD,EAAE,EACzD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,kBAAkB,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACpF,CAAC;CACF"}
@@ -4,10 +4,27 @@ import { RequestOptions } from "../../internal/request-options.mjs";
4
4
  export declare class Dm extends APIResource {
5
5
  /**
6
6
  * Get DM conversation history
7
+ *
8
+ * @example
9
+ * ```ts
10
+ * const response = await client.x.dm.retrieveHistory(
11
+ * 'userId',
12
+ * );
13
+ * ```
7
14
  */
8
15
  retrieveHistory(userID: string, query?: DmRetrieveHistoryParams | null | undefined, options?: RequestOptions): APIPromise<DmRetrieveHistoryResponse>;
9
16
  /**
10
17
  * Send direct message
18
+ *
19
+ * @example
20
+ * ```ts
21
+ * const response = await client.x.dm.send('userId', {
22
+ * account: '@elonmusk',
23
+ * text: 'Example text content',
24
+ * media_ids: ['1234567890123456789'],
25
+ * reply_to_message_id: '1234567890123456789',
26
+ * });
27
+ * ```
11
28
  */
12
29
  send(userID: string, body: DmSendParams, options?: RequestOptions): APIPromise<DmSendResponse>;
13
30
  }
@@ -31,7 +48,7 @@ export interface DmSendResponse {
31
48
  }
32
49
  export interface DmRetrieveHistoryParams {
33
50
  /**
34
- * Pagination cursor from previous response
51
+ * Pagination cursor for DM history
35
52
  */
36
53
  cursor?: string;
37
54
  /**
@@ -41,7 +58,7 @@ export interface DmRetrieveHistoryParams {
41
58
  }
42
59
  export interface DmSendParams {
43
60
  /**
44
- * X account (@username or account ID)
61
+ * X account (@username or ID) sending the DM
45
62
  */
46
63
  account: string;
47
64
  text: string;
@@ -1 +1 @@
1
- {"version":3,"file":"dm.d.mts","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,EAAG,SAAQ,WAAW;IACjC;;OAEG;IACH,eAAe,CACb,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,uBAAuB,GAAG,IAAI,GAAG,SAAc,EACtD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,yBAAyB,CAAC;IAIxC;;OAEG;IACH,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;CAG/F;AAED,MAAM,WAAW,yBAAyB;IACxC,aAAa,EAAE,OAAO,CAAC;IAEvB,QAAQ,EAAE,KAAK,CAAC,yBAAyB,CAAC,OAAO,CAAC,CAAC;IAEnD,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,yBAAiB,yBAAyB,CAAC;IACzC,UAAiB,OAAO;QACtB,EAAE,EAAE,MAAM,CAAC;QAEX,SAAS,CAAC,EAAE,MAAM,CAAC;QAEnB,UAAU,CAAC,EAAE,MAAM,CAAC;QAEpB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAElB,IAAI,CAAC,EAAE,MAAM,CAAC;KACf;CACF;AAED,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,MAAM,CAAC;IAElB,OAAO,EAAE,IAAI,CAAC;CACf;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB,IAAI,EAAE,MAAM,CAAC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AAE,MAAM,CAAC;IAElB,OAAO,EAAE,IAAI,CAAC;CACf;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB,IAAI,EAAE,MAAM,CAAC;IAEb,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAE1B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,WAAW,EAAE,CAAC;IAC1B,OAAO,EACL,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,YAAY,IAAI,YAAY,GAClC,CAAC;CACH"}
@@ -4,10 +4,27 @@ import { RequestOptions } from "../../internal/request-options.js";
4
4
  export declare class Dm extends APIResource {
5
5
  /**
6
6
  * Get DM conversation history
7
+ *
8
+ * @example
9
+ * ```ts
10
+ * const response = await client.x.dm.retrieveHistory(
11
+ * 'userId',
12
+ * );
13
+ * ```
7
14
  */
8
15
  retrieveHistory(userID: string, query?: DmRetrieveHistoryParams | null | undefined, options?: RequestOptions): APIPromise<DmRetrieveHistoryResponse>;
9
16
  /**
10
17
  * Send direct message
18
+ *
19
+ * @example
20
+ * ```ts
21
+ * const response = await client.x.dm.send('userId', {
22
+ * account: '@elonmusk',
23
+ * text: 'Example text content',
24
+ * media_ids: ['1234567890123456789'],
25
+ * reply_to_message_id: '1234567890123456789',
26
+ * });
27
+ * ```
11
28
  */
12
29
  send(userID: string, body: DmSendParams, options?: RequestOptions): APIPromise<DmSendResponse>;
13
30
  }
@@ -31,7 +48,7 @@ export interface DmSendResponse {
31
48
  }
32
49
  export interface DmRetrieveHistoryParams {
33
50
  /**
34
- * Pagination cursor from previous response
51
+ * Pagination cursor for DM history
35
52
  */
36
53
  cursor?: string;
37
54
  /**
@@ -41,7 +58,7 @@ export interface DmRetrieveHistoryParams {
41
58
  }
42
59
  export interface DmSendParams {
43
60
  /**
44
- * X account (@username or account ID)
61
+ * X account (@username or ID) sending the DM
45
62
  */
46
63
  account: string;
47
64
  text: string;
@@ -1 +1 @@
1
- {"version":3,"file":"dm.d.ts","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAGzB,qBAAa,EAAG,SAAQ,WAAW;IACjC;;OAEG;IACH,eAAe,CACb,MAAM,EAAE,MAAM,EACd,KAAK,GAAE,uBAAuB,GAAG,IAAI,GAAG,SAAc,EACtD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,yBAAyB,CAAC;IAIxC;;OAEG;IACH,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,YAAY,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;CAG/F;AAED,MAAM,WAAW,yBAAyB;IACxC,aAAa,EAAE,OAAO,CAAC;IAEvB,QAAQ,EAAE,KAAK,CAAC,yBAAyB,CAAC,OAAO,CAAC,CAAC;IAEnD,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,yBAAiB,yBAAyB,CAAC;IACzC,UAAiB,OAAO;QACtB,EAAE,EAAE,MAAM,CAAC;QAEX,SAAS,CAAC,EAAE,MAAM,CAAC;QAEnB,UAAU,CAAC,EAAE,MAAM,CAAC;QAEpB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAElB,IAAI,CAAC,EAAE,MAAM,CAAC;KACf;CACF;AAED,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,MAAM,CAAC;IAElB,OAAO,EAAE,IAAI,CAAC;CACf;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,MAAM,CAA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,MAAM,CAAC;QAEnB,UAAU,CAAC,EAAE,MAAM,CAAC;QAEpB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAElB,IAAI,CAAC,EAAE,MAAM,CAAC;KACf;CACF;AAED,MAAM,WAAW,cAAc;IAC7B,SAAS,EAAE,MAAM,CAAC;IAElB,OAAO,EAAE,IAAI,CAAC;CACf;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB,IAAI,EAAE,MAAM,CAAC;IAEb,SAAS,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAE1B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED,MAAM,CAAC,OAAO,WAAW,EAAE,CAAC;IAC1B,OAAO,EACL,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,YAAY,IAAI,YAAY,GAClC,CAAC;CACH"}
package/resources/x/dm.js CHANGED
@@ -7,12 +7,29 @@ const path_1 = require("../../internal/utils/path.js");
7
7
  class Dm extends resource_1.APIResource {
8
8
  /**
9
9
  * Get DM conversation history
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * const response = await client.x.dm.retrieveHistory(
14
+ * 'userId',
15
+ * );
16
+ * ```
10
17
  */
11
18
  retrieveHistory(userID, query = {}, options) {
12
19
  return this._client.get((0, path_1.path) `/x/dm/${userID}/history`, { query, ...options });
13
20
  }
14
21
  /**
15
22
  * Send direct message
23
+ *
24
+ * @example
25
+ * ```ts
26
+ * const response = await client.x.dm.send('userId', {
27
+ * account: '@elonmusk',
28
+ * text: 'Example text content',
29
+ * media_ids: ['1234567890123456789'],
30
+ * reply_to_message_id: '1234567890123456789',
31
+ * });
32
+ * ```
16
33
  */
17
34
  send(userID, body, options) {
18
35
  return this._client.post((0, path_1.path) `/x/dm/${userID}`, { body, ...options });
@@ -1 +1 @@
1
- {"version":3,"file":"dm.js","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAGlD,uDAAiD;AAEjD,MAAa,EAAG,SAAQ,sBAAW;IACjC;;OAEG;IACH,eAAe,CACb,MAAc,EACd,QAAoD,EAAE,EACtD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,SAAS,MAAM,UAAU,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;IAED;;OAEG;IACH,IAAI,CAAC,MAAc,EAAE,IAAkB,EAAE,OAAwB;QAC/D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,SAAS,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF;AAlBD,gBAkBC"}
1
+ {"version":3,"file":"dm.js","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAGlD,uDAAiD;AAEjD,MAAa,EAAG,SAAQ,sBAAW;IACjC;;;;;;;;;OASG;IACH,eAAe,CACb,MAAc,EACd,QAAoD,EAAE,EACtD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,SAAS,MAAM,UAAU,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,IAAI,CAAC,MAAc,EAAE,IAAkB,EAAE,OAAwB;QAC/D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,SAAS,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF;AAnCD,gBAmCC"}
@@ -4,12 +4,29 @@ import { path } from "../../internal/utils/path.mjs";
4
4
  export class Dm extends APIResource {
5
5
  /**
6
6
  * Get DM conversation history
7
+ *
8
+ * @example
9
+ * ```ts
10
+ * const response = await client.x.dm.retrieveHistory(
11
+ * 'userId',
12
+ * );
13
+ * ```
7
14
  */
8
15
  retrieveHistory(userID, query = {}, options) {
9
16
  return this._client.get(path `/x/dm/${userID}/history`, { query, ...options });
10
17
  }
11
18
  /**
12
19
  * Send direct message
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * const response = await client.x.dm.send('userId', {
24
+ * account: '@elonmusk',
25
+ * text: 'Example text content',
26
+ * media_ids: ['1234567890123456789'],
27
+ * reply_to_message_id: '1234567890123456789',
28
+ * });
29
+ * ```
13
30
  */
14
31
  send(userID, body, options) {
15
32
  return this._client.post(path `/x/dm/${userID}`, { body, ...options });
@@ -1 +1 @@
1
- {"version":3,"file":"dm.mjs","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,EAAG,SAAQ,WAAW;IACjC;;OAEG;IACH,eAAe,CACb,MAAc,EACd,QAAoD,EAAE,EACtD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,SAAS,MAAM,UAAU,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;IAED;;OAEG;IACH,IAAI,CAAC,MAAc,EAAE,IAAkB,EAAE,OAAwB;QAC/D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,SAAS,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF"}
1
+ {"version":3,"file":"dm.mjs","sourceRoot":"","sources":["../../src/resources/x/dm.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,EAAG,SAAQ,WAAW;IACjC;;;;;;;;;OASG;IACH,eAAe,CACb,MAAc,EACd,QAAoD,EAAE,EACtD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,SAAS,MAAM,UAAU,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAChF,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,IAAI,CAAC,MAAc,EAAE,IAAkB,EAAE,OAAwB;QAC/D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,SAAS,MAAM,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxE,CAAC;CACF"}
@@ -7,6 +7,14 @@ import { RequestOptions } from "../../internal/request-options.mjs";
7
7
  export declare class Followers extends APIResource {
8
8
  /**
9
9
  * Check follow relationship
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * const response = await client.x.followers.check({
14
+ * source: 'source',
15
+ * target: 'target',
16
+ * });
17
+ * ```
10
18
  */
11
19
  check(query: FollowerCheckParams, options?: RequestOptions): APIPromise<FollowerCheckResponse>;
12
20
  }
@@ -1 +1 @@
1
- {"version":3,"file":"followers.d.mts","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,SAAU,SAAQ,WAAW;IACxC;;OAEG;IACH,KAAK,CAAC,KAAK,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,qBAAqB;IACpC,YAAY,EAAE,OAAO,CAAC;IAEtB,WAAW,EAAE,OAAO,CAAC;IAErB,cAAc,EAAE,MAAM,CAAC;IAEvB,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
1
+ {"version":3,"file":"followers.d.mts","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAAK,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,qBAAqB;IACpC,YAAY,EAAE,OAAO,CAAC;IAEtB,WAAW,EAAE,OAAO,CAAC;IAErB,cAAc,EAAE,MAAM,CAAC;IAEvB,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -7,6 +7,14 @@ import { RequestOptions } from "../../internal/request-options.js";
7
7
  export declare class Followers extends APIResource {
8
8
  /**
9
9
  * Check follow relationship
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * const response = await client.x.followers.check({
14
+ * source: 'source',
15
+ * target: 'target',
16
+ * });
17
+ * ```
10
18
  */
11
19
  check(query: FollowerCheckParams, options?: RequestOptions): APIPromise<FollowerCheckResponse>;
12
20
  }
@@ -1 +1 @@
1
- {"version":3,"file":"followers.d.ts","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,SAAU,SAAQ,WAAW;IACxC;;OAEG;IACH,KAAK,CAAC,KAAK,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,qBAAqB;IACpC,YAAY,EAAE,OAAO,CAAC;IAEtB,WAAW,EAAE,OAAO,CAAC;IAErB,cAAc,EAAE,MAAM,CAAC;IAEvB,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
1
+ {"version":3,"file":"followers.d.ts","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;GAEG;AACH,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAAK,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG/F;AAED,MAAM,WAAW,qBAAqB;IACpC,YAAY,EAAE,OAAO,CAAC;IAEtB,WAAW,EAAE,OAAO,CAAC;IAErB,cAAc,EAAE,MAAM,CAAC;IAEvB,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
@@ -9,6 +9,14 @@ const resource_1 = require("../../core/resource.js");
9
9
  class Followers extends resource_1.APIResource {
10
10
  /**
11
11
  * Check follow relationship
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * const response = await client.x.followers.check({
16
+ * source: 'source',
17
+ * target: 'target',
18
+ * });
19
+ * ```
12
20
  */
13
21
  check(query, options) {
14
22
  return this._client.get('/x/followers/check', { query, ...options });
@@ -1 +1 @@
1
- {"version":3,"file":"followers.js","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAIlD;;GAEG;AACH,MAAa,SAAU,SAAQ,sBAAW;IACxC;;OAEG;IACH,KAAK,CAAC,KAA0B,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvE,CAAC;CACF;AAPD,8BAOC"}
1
+ {"version":3,"file":"followers.js","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAIlD;;GAEG;AACH,MAAa,SAAU,SAAQ,sBAAW;IACxC;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAA0B,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvE,CAAC;CACF;AAfD,8BAeC"}
@@ -6,6 +6,14 @@ import { APIResource } from "../../core/resource.mjs";
6
6
  export class Followers extends APIResource {
7
7
  /**
8
8
  * Check follow relationship
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * const response = await client.x.followers.check({
13
+ * source: 'source',
14
+ * target: 'target',
15
+ * });
16
+ * ```
9
17
  */
10
18
  check(query, options) {
11
19
  return this._client.get('/x/followers/check', { query, ...options });
@@ -1 +1 @@
1
- {"version":3,"file":"followers.mjs","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB;;GAEG;AACH,MAAM,OAAO,SAAU,SAAQ,WAAW;IACxC;;OAEG;IACH,KAAK,CAAC,KAA0B,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvE,CAAC;CACF"}
1
+ {"version":3,"file":"followers.mjs","sourceRoot":"","sources":["../../src/resources/x/followers.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB;;GAEG;AACH,MAAM,OAAO,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;OAUG;IACH,KAAK,CAAC,KAA0B,EAAE,OAAwB;QACxD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACvE,CAAC;CACF"}
@@ -1,4 +1,4 @@
1
- export { Accounts, type XAccount, type XAccountDetail, type AccountCreateResponse, type AccountListResponse, type AccountDeleteResponse, type AccountReauthResponse, type AccountCreateParams, type AccountReauthParams, } from "./accounts.mjs";
1
+ export { Accounts, type XAccount, type XAccountDetail, type AccountCreateResponse, type AccountListResponse, type AccountDeleteResponse, type AccountBulkRetryResponse, type AccountReauthResponse, type AccountCreateParams, type AccountReauthParams, } from "./accounts.mjs";
2
2
  export { Bookmarks, type BookmarkRetrieveFoldersResponse, type BookmarkListParams } from "./bookmarks.mjs";
3
3
  export { Communities, type CommunityActionResult, type CommunityCreateResponse, type CommunityDeleteResponse, type CommunityRetrieveInfoResponse, type CommunityCreateParams, type CommunityDeleteParams, type CommunityRetrieveMembersParams, type CommunityRetrieveModeratorsParams, type CommunityRetrieveSearchParams, } from "./communities/index.mjs";
4
4
  export { Dm, type DmRetrieveHistoryResponse, type DmSendResponse, type DmRetrieveHistoryParams, type DmSendParams, } from "./dm.mjs";
@@ -8,5 +8,5 @@ export { Media, type MediaDownloadResponse, type MediaUploadResponse, type Media
8
8
  export { Profile, type ProfileUpdateResponse, type ProfileUpdateAvatarResponse, type ProfileUpdateBannerResponse, type ProfileUpdateParams, type ProfileUpdateAvatarParams, type ProfileUpdateBannerParams, } from "./profile.mjs";
9
9
  export { Tweets, type SearchTweet, type TweetAuthor, type TweetDetail, type TweetCreateResponse, type TweetRetrieveResponse, type TweetDeleteResponse, type TweetCreateParams, type TweetListParams, type TweetDeleteParams, type TweetGetFavoritersParams, type TweetGetQuotesParams, type TweetGetRepliesParams, type TweetGetRetweetersParams, type TweetGetThreadParams, type TweetSearchParams, } from "./tweets/index.mjs";
10
10
  export { Users, type UserProfile, type UserRetrieveBatchParams, type UserRetrieveFollowersParams, type UserRetrieveFollowersYouKnowParams, type UserRetrieveFollowingParams, type UserRetrieveLikesParams, type UserRetrieveMediaParams, type UserRetrieveMentionsParams, type UserRetrieveSearchParams, type UserRetrieveTweetsParams, type UserRetrieveVerifiedFollowersParams, } from "./users/index.mjs";
11
- export { X, type XGetArticleResponse, type XGetNotificationsResponse, type XGetHomeTimelineParams, type XGetNotificationsParams, } from "./x.mjs";
11
+ export { X, type XGetArticleResponse, type XGetNotificationsResponse, type XGetTrendsResponse, type XGetHomeTimelineParams, type XGetNotificationsParams, } from "./x.mjs";
12
12
  //# sourceMappingURL=index.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,cAAc,EACnB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB;OACM,EAAE,SAAS,EAAE,KAAK,+BAA+B,EAAE,KAAK,kBAAkB,EAAE;OAC5E,EACL,WAAW,EACX,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,6BAA6B,EAClC,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,8BAA8B,EACnC,KAAK,iCAAiC,EACtC,KAAK,6BAA6B,GACnC;OACM,EACL,EAAE,EACF,KAAK,yBAAyB,EAC9B,KAAK,cAAc,EACnB,KAAK,uBAAuB,EAC5B,KAAK,YAAY,GAClB;OACM,EAAE,SAAS,EAAE,KAAK,qBAAqB,EAAE,KAAK,mBAAmB,EAAE;OACnE,EACL,KAAK,EACL,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB;OACM,EACL,OAAO,EACP,KAAK,qBAAqB,EAC1B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,GAC/B;OACM,EACL,MAAM,EACN,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,WAAW,EACh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BAAuB,EAC5B,KAAK,YAAY,GAClB;OACM,EAAE,SAAS,EAAE,KAAK,qBAAqB,EAAE,KAAK,mBAAmB,EAAE;OACnE,EACL,KAAK,EACL,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB;OACM,EACL,OAAO,EACP,KAAK,qBAAqB,EAC1B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,GAC/B;OACM,EACL,MAAM,EACN,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,GACvB;OACM,EACL,KAAK,EACL,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,kCAAkC,EACvC,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,EAC7B,KAAK,mCAAmC,GACzC;OACM,EACL,CAAC,EACD,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,GAC7B"}
@@ -1,4 +1,4 @@
1
- export { Accounts, type XAccount, type XAccountDetail, type AccountCreateResponse, type AccountListResponse, type AccountDeleteResponse, type AccountReauthResponse, type AccountCreateParams, type AccountReauthParams, } from "./accounts.js";
1
+ export { Accounts, type XAccount, type XAccountDetail, type AccountCreateResponse, type AccountListResponse, type AccountDeleteResponse, type AccountBulkRetryResponse, type AccountReauthResponse, type AccountCreateParams, type AccountReauthParams, } from "./accounts.js";
2
2
  export { Bookmarks, type BookmarkRetrieveFoldersResponse, type BookmarkListParams } from "./bookmarks.js";
3
3
  export { Communities, type CommunityActionResult, type CommunityCreateResponse, type CommunityDeleteResponse, type CommunityRetrieveInfoResponse, type CommunityCreateParams, type CommunityDeleteParams, type CommunityRetrieveMembersParams, type CommunityRetrieveModeratorsParams, type CommunityRetrieveSearchParams, } from "./communities/index.js";
4
4
  export { Dm, type DmRetrieveHistoryResponse, type DmSendResponse, type DmRetrieveHistoryParams, type DmSendParams, } from "./dm.js";
@@ -8,5 +8,5 @@ export { Media, type MediaDownloadResponse, type MediaUploadResponse, type Media
8
8
  export { Profile, type ProfileUpdateResponse, type ProfileUpdateAvatarResponse, type ProfileUpdateBannerResponse, type ProfileUpdateParams, type ProfileUpdateAvatarParams, type ProfileUpdateBannerParams, } from "./profile.js";
9
9
  export { Tweets, type SearchTweet, type TweetAuthor, type TweetDetail, type TweetCreateResponse, type TweetRetrieveResponse, type TweetDeleteResponse, type TweetCreateParams, type TweetListParams, type TweetDeleteParams, type TweetGetFavoritersParams, type TweetGetQuotesParams, type TweetGetRepliesParams, type TweetGetRetweetersParams, type TweetGetThreadParams, type TweetSearchParams, } from "./tweets/index.js";
10
10
  export { Users, type UserProfile, type UserRetrieveBatchParams, type UserRetrieveFollowersParams, type UserRetrieveFollowersYouKnowParams, type UserRetrieveFollowingParams, type UserRetrieveLikesParams, type UserRetrieveMediaParams, type UserRetrieveMentionsParams, type UserRetrieveSearchParams, type UserRetrieveTweetsParams, type UserRetrieveVerifiedFollowersParams, } from "./users/index.js";
11
- export { X, type XGetArticleResponse, type XGetNotificationsResponse, type XGetHomeTimelineParams, type XGetNotificationsParams, } from "./x.js";
11
+ export { X, type XGetArticleResponse, type XGetNotificationsResponse, type XGetTrendsResponse, type XGetHomeTimelineParams, type XGetNotificationsParams, } from "./x.js";
12
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":"OAEO,EACL,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,cAAc,EACnB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,GACzB;OACM,EAAE,SAAS,EAAE,KAAK,+BAA+B,EAAE,KAAK,kBAAkB,EAAE;OAC5E,EACL,WAAW,EACX,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,6BAA6B,EAClC,KAAK,qBAAqB,EAC1B,KAAK,qBAAqB,EAC1B,KAAK,8BAA8B,EACnC,KAAK,iCAAiC,EACtC,KAAK,6BAA6B,GACnC;OACM,EACL,EAAE,EACF,KAAK,yBAAyB,EAC9B,KAAK,cAAc,EACnB,KAAK,uBAAuB,EAC5B,KAAK,YAAY,GAClB;OACM,EAAE,SAAS,EAAE,KAAK,qBAAqB,EAAE,KAAK,mBAAmB,EAAE;OACnE,EACL,KAAK,EACL,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB;OACM,EACL,OAAO,EACP,KAAK,qBAAqB,EAC1B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,GAC/B;OACM,EACL,MAAM,EACN,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,WAAW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AK,uBAAuB,EAC5B,KAAK,YAAY,GAClB;OACM,EAAE,SAAS,EAAE,KAAK,qBAAqB,EAAE,KAAK,mBAAmB,EAAE;OACnE,EACL,KAAK,EACL,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB;OACM,EACL,OAAO,EACP,KAAK,qBAAqB,EAC1B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,GAC/B;OACM,EACL,MAAM,EACN,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,eAAe,EACpB,KAAK,iBAAiB,EACtB,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,EAC1B,KAAK,wBAAwB,EAC7B,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,GACvB;OACM,EACL,KAAK,EACL,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,kCAAkC,EACvC,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC5B,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,EAC7B,KAAK,mCAAmC,GACzC;OACM,EACL,CAAC,EACD,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,EAC9B,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,GAC7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0CAUoB;AATlB,oGAAA,QAAQ,OAAA;AAUV,4CAAuG;AAA9F,sGAAA,SAAS,OAAA;AAClB,gDAW6B;AAV3B,oGAAA,WAAW,OAAA;AAWb,8BAMc;AALZ,wFAAA,EAAE,OAAA;AAMJ,4CAA8F;AAArF,sGAAA,SAAS,OAAA;AAClB,oCAKiB;AAJf,8FAAA,KAAK,OAAA;AAKP,oCAMiB;AALf,8FAAA,KAAK,OAAA;AAMP,wCAQmB;AAPjB,kGAAA,OAAO,OAAA;AAQT,2CAiBwB;AAhBtB,+FAAA,MAAM,OAAA;AAiBR,0CAauB;AAZrB,8FAAA,KAAK,OAAA;AAaP,4BAMa;AALX,sFAAA,CAAC,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,0CAWoB;AAVlB,oGAAA,QAAQ,OAAA;AAWV,4CAAuG;AAA9F,sGAAA,SAAS,OAAA;AAClB,gDAW6B;AAV3B,oGAAA,WAAW,OAAA;AAWb,8BAMc;AALZ,wFAAA,EAAE,OAAA;AAMJ,4CAA8F;AAArF,sGAAA,SAAS,OAAA;AAClB,oCAKiB;AAJf,8FAAA,KAAK,OAAA;AAKP,oCAMiB;AALf,8FAAA,KAAK,OAAA;AAMP,wCAQmB;AAPjB,kGAAA,OAAO,OAAA;AAQT,2CAiBwB;AAhBtB,+FAAA,MAAM,OAAA;AAiBR,0CAauB;AAZrB,8FAAA,KAAK,OAAA;AAaP,4BAOa;AANX,sFAAA,CAAC,OAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,QAAQ,GAST;OACM,EAAE,SAAS,EAAiE;OAC5E,EACL,WAAW,GAUZ;OACM,EACL,EAAE,GAKH;OACM,EAAE,SAAS,EAAwD;OACnE,EACL,KAAK,GAIN;OACM,EACL,KAAK,GAKN;OACM,EACL,OAAO,GAOR;OACM,EACL,MAAM,GAgBP;OACM,EACL,KAAK,GAYN;OACM,EACL,CAAC,GAKF"}
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../src/resources/x/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,QAAQ,GAUT;OACM,EAAE,SAAS,EAAiE;OAC5E,EACL,WAAW,GAUZ;OACM,EACL,EAAE,GAKH;OACM,EAAE,SAAS,EAAwD;OACnE,EACL,KAAK,GAIN;OACM,EACL,KAAK,GAKN;OACM,EACL,OAAO,GAOR;OACM,EACL,MAAM,GAgBP;OACM,EACL,KAAK,GAYN;OACM,EACL,CAAC,GAMF"}
@@ -1,4 +1,5 @@
1
1
  import { APIResource } from "../../core/resource.mjs";
2
+ import * as Shared from "../shared.mjs";
2
3
  import { APIPromise } from "../../core/api-promise.mjs";
3
4
  import { RequestOptions } from "../../internal/request-options.mjs";
4
5
  /**
@@ -7,32 +8,52 @@ import { RequestOptions } from "../../internal/request-options.mjs";
7
8
  export declare class Lists extends APIResource {
8
9
  /**
9
10
  * Get list followers
11
+ *
12
+ * @example
13
+ * ```ts
14
+ * const paginatedUsers =
15
+ * await client.x.lists.retrieveFollowers('id');
16
+ * ```
10
17
  */
11
- retrieveFollowers(id: string, query?: ListRetrieveFollowersParams | null | undefined, options?: RequestOptions): APIPromise<void>;
18
+ retrieveFollowers(id: string, query?: ListRetrieveFollowersParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedUsers>;
12
19
  /**
13
20
  * Get list members
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const paginatedUsers = await client.x.lists.retrieveMembers(
25
+ * 'id',
26
+ * );
27
+ * ```
14
28
  */
15
- retrieveMembers(id: string, query?: ListRetrieveMembersParams | null | undefined, options?: RequestOptions): APIPromise<void>;
29
+ retrieveMembers(id: string, query?: ListRetrieveMembersParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedUsers>;
16
30
  /**
17
31
  * Get list tweets
32
+ *
33
+ * @example
34
+ * ```ts
35
+ * const paginatedTweets = await client.x.lists.retrieveTweets(
36
+ * 'id',
37
+ * );
38
+ * ```
18
39
  */
19
- retrieveTweets(id: string, query?: ListRetrieveTweetsParams | null | undefined, options?: RequestOptions): APIPromise<void>;
40
+ retrieveTweets(id: string, query?: ListRetrieveTweetsParams | null | undefined, options?: RequestOptions): APIPromise<Shared.PaginatedTweets>;
20
41
  }
21
42
  export interface ListRetrieveFollowersParams {
22
43
  /**
23
- * Pagination cursor
44
+ * Pagination cursor for list followers
24
45
  */
25
46
  cursor?: string;
26
47
  }
27
48
  export interface ListRetrieveMembersParams {
28
49
  /**
29
- * Pagination cursor
50
+ * Pagination cursor for list members
30
51
  */
31
52
  cursor?: string;
32
53
  }
33
54
  export interface ListRetrieveTweetsParams {
34
55
  /**
35
- * Pagination cursor
56
+ * Pagination cursor for list tweets
36
57
  */
37
58
  cursor?: string;
38
59
  /**