x-twitter-scraper 0.16.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (198) hide show
  1. package/CHANGELOG.md +44 -5
  2. package/README.md +1 -0
  3. package/client.d.mts +8 -2
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +8 -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/internal/detect-platform.d.mts +3 -1
  10. package/internal/detect-platform.d.mts.map +1 -1
  11. package/internal/detect-platform.d.ts +3 -1
  12. package/internal/detect-platform.d.ts.map +1 -1
  13. package/internal/detect-platform.js +1 -1
  14. package/internal/detect-platform.js.map +1 -1
  15. package/internal/detect-platform.mjs +1 -1
  16. package/internal/detect-platform.mjs.map +1 -1
  17. package/package.json +1 -1
  18. package/resources/events.d.mts +50 -11
  19. package/resources/events.d.mts.map +1 -1
  20. package/resources/events.d.ts +50 -11
  21. package/resources/events.d.ts.map +1 -1
  22. package/resources/events.js.map +1 -1
  23. package/resources/events.mjs.map +1 -1
  24. package/resources/index.d.mts +1 -1
  25. package/resources/index.d.mts.map +1 -1
  26. package/resources/index.d.ts +1 -1
  27. package/resources/index.d.ts.map +1 -1
  28. package/resources/index.js.map +1 -1
  29. package/resources/index.mjs.map +1 -1
  30. package/resources/monitors/index.d.mts +2 -1
  31. package/resources/monitors/index.d.mts.map +1 -1
  32. package/resources/monitors/index.d.ts +2 -1
  33. package/resources/monitors/index.d.ts.map +1 -1
  34. package/resources/monitors/index.js +3 -1
  35. package/resources/monitors/index.js.map +1 -1
  36. package/resources/monitors/index.mjs +1 -0
  37. package/resources/monitors/index.mjs.map +1 -1
  38. package/resources/monitors/keywords.d.mts +10 -96
  39. package/resources/monitors/keywords.d.mts.map +1 -1
  40. package/resources/monitors/keywords.d.ts +10 -96
  41. package/resources/monitors/keywords.d.ts.map +1 -1
  42. package/resources/monitors/monitors.d.mts +6 -2
  43. package/resources/monitors/monitors.d.mts.map +1 -1
  44. package/resources/monitors/monitors.d.ts +6 -2
  45. package/resources/monitors/monitors.d.ts.map +1 -1
  46. package/resources/monitors/monitors.js +4 -0
  47. package/resources/monitors/monitors.js.map +1 -1
  48. package/resources/monitors/monitors.mjs +4 -0
  49. package/resources/monitors/monitors.mjs.map +1 -1
  50. package/resources/monitors/posts.d.mts +344 -0
  51. package/resources/monitors/posts.d.mts.map +1 -0
  52. package/resources/monitors/posts.d.ts +344 -0
  53. package/resources/monitors/posts.d.ts.map +1 -0
  54. package/resources/monitors/posts.js +94 -0
  55. package/resources/monitors/posts.js.map +1 -0
  56. package/resources/monitors/posts.mjs +90 -0
  57. package/resources/monitors/posts.mjs.map +1 -0
  58. package/resources/shared.d.mts +577 -2
  59. package/resources/shared.d.mts.map +1 -1
  60. package/resources/shared.d.ts +577 -2
  61. package/resources/shared.d.ts.map +1 -1
  62. package/resources/support/index.d.mts +1 -1
  63. package/resources/support/index.d.mts.map +1 -1
  64. package/resources/support/index.d.ts +1 -1
  65. package/resources/support/index.d.ts.map +1 -1
  66. package/resources/support/index.js.map +1 -1
  67. package/resources/support/index.mjs.map +1 -1
  68. package/resources/support/support.d.mts +2 -2
  69. package/resources/support/support.d.mts.map +1 -1
  70. package/resources/support/support.d.ts +2 -2
  71. package/resources/support/support.d.ts.map +1 -1
  72. package/resources/support/support.js.map +1 -1
  73. package/resources/support/support.mjs.map +1 -1
  74. package/resources/support/tickets.d.mts +12 -20
  75. package/resources/support/tickets.d.mts.map +1 -1
  76. package/resources/support/tickets.d.ts +12 -20
  77. package/resources/support/tickets.d.ts.map +1 -1
  78. package/resources/webhooks.d.mts +5 -4
  79. package/resources/webhooks.d.mts.map +1 -1
  80. package/resources/webhooks.d.ts +5 -4
  81. package/resources/webhooks.d.ts.map +1 -1
  82. package/resources/webhooks.js.map +1 -1
  83. package/resources/webhooks.mjs.map +1 -1
  84. package/resources/x/accounts.d.mts +14 -4
  85. package/resources/x/accounts.d.mts.map +1 -1
  86. package/resources/x/accounts.d.ts +14 -4
  87. package/resources/x/accounts.d.ts.map +1 -1
  88. package/resources/x/accounts.js +6 -4
  89. package/resources/x/accounts.js.map +1 -1
  90. package/resources/x/accounts.mjs +6 -4
  91. package/resources/x/accounts.mjs.map +1 -1
  92. package/resources/x/broadcasts.d.mts +3 -131
  93. package/resources/x/broadcasts.d.mts.map +1 -1
  94. package/resources/x/broadcasts.d.ts +3 -131
  95. package/resources/x/broadcasts.d.ts.map +1 -1
  96. package/resources/x/communities/communities.d.mts +92 -1
  97. package/resources/x/communities/communities.d.mts.map +1 -1
  98. package/resources/x/communities/communities.d.ts +92 -1
  99. package/resources/x/communities/communities.d.ts.map +1 -1
  100. package/resources/x/communities/communities.js +14 -0
  101. package/resources/x/communities/communities.js.map +1 -1
  102. package/resources/x/communities/communities.mjs +14 -0
  103. package/resources/x/communities/communities.mjs.map +1 -1
  104. package/resources/x/communities/index.d.mts +1 -1
  105. package/resources/x/communities/index.d.mts.map +1 -1
  106. package/resources/x/communities/index.d.ts +1 -1
  107. package/resources/x/communities/index.d.ts.map +1 -1
  108. package/resources/x/communities/index.js.map +1 -1
  109. package/resources/x/communities/index.mjs.map +1 -1
  110. package/resources/x/community-notes.d.mts +122 -510
  111. package/resources/x/community-notes.d.mts.map +1 -1
  112. package/resources/x/community-notes.d.ts +122 -510
  113. package/resources/x/community-notes.d.ts.map +1 -1
  114. package/resources/x/community-notes.js.map +1 -1
  115. package/resources/x/community-notes.mjs.map +1 -1
  116. package/resources/x/index.d.mts +7 -6
  117. package/resources/x/index.d.mts.map +1 -1
  118. package/resources/x/index.d.ts +7 -6
  119. package/resources/x/index.d.ts.map +1 -1
  120. package/resources/x/index.js +3 -1
  121. package/resources/x/index.js.map +1 -1
  122. package/resources/x/index.mjs +1 -0
  123. package/resources/x/index.mjs.map +1 -1
  124. package/resources/x/jobs.d.mts +144 -291
  125. package/resources/x/jobs.d.mts.map +1 -1
  126. package/resources/x/jobs.d.ts +144 -291
  127. package/resources/x/jobs.d.ts.map +1 -1
  128. package/resources/x/jobs.js.map +1 -1
  129. package/resources/x/jobs.mjs.map +1 -1
  130. package/resources/x/lists.d.mts +21 -419
  131. package/resources/x/lists.d.mts.map +1 -1
  132. package/resources/x/lists.d.ts +21 -419
  133. package/resources/x/lists.d.ts.map +1 -1
  134. package/resources/x/spaces.d.mts +213 -693
  135. package/resources/x/spaces.d.mts.map +1 -1
  136. package/resources/x/spaces.d.ts +213 -693
  137. package/resources/x/spaces.d.ts.map +1 -1
  138. package/resources/x/spaces.js.map +1 -1
  139. package/resources/x/spaces.mjs.map +1 -1
  140. package/resources/x/sports.d.mts +1512 -0
  141. package/resources/x/sports.d.mts.map +1 -0
  142. package/resources/x/sports.d.ts +1512 -0
  143. package/resources/x/sports.d.ts.map +1 -0
  144. package/resources/x/sports.js +91 -0
  145. package/resources/x/sports.js.map +1 -0
  146. package/resources/x/sports.mjs +87 -0
  147. package/resources/x/sports.mjs.map +1 -0
  148. package/resources/x/tweets/tweets.d.mts +11 -13
  149. package/resources/x/tweets/tweets.d.mts.map +1 -1
  150. package/resources/x/tweets/tweets.d.ts +11 -13
  151. package/resources/x/tweets/tweets.d.ts.map +1 -1
  152. package/resources/x/users/users.d.mts +29 -585
  153. package/resources/x/users/users.d.mts.map +1 -1
  154. package/resources/x/users/users.d.ts +29 -585
  155. package/resources/x/users/users.d.ts.map +1 -1
  156. package/resources/x/users/users.js.map +1 -1
  157. package/resources/x/users/users.mjs.map +1 -1
  158. package/resources/x/x.d.mts +55 -118
  159. package/resources/x/x.d.mts.map +1 -1
  160. package/resources/x/x.d.ts +55 -118
  161. package/resources/x/x.d.ts.map +1 -1
  162. package/resources/x/x.js +4 -0
  163. package/resources/x/x.js.map +1 -1
  164. package/resources/x/x.mjs +4 -0
  165. package/resources/x/x.mjs.map +1 -1
  166. package/skills/x-twitter-scraper/references/api-endpoints-x-api.md +1 -0
  167. package/src/client.ts +8 -0
  168. package/src/internal/detect-platform.ts +2 -2
  169. package/src/resources/events.ts +72 -10
  170. package/src/resources/index.ts +1 -0
  171. package/src/resources/monitors/index.ts +21 -0
  172. package/src/resources/monitors/keywords.ts +10 -118
  173. package/src/resources/monitors/monitors.ts +46 -0
  174. package/src/resources/monitors/posts.ts +463 -0
  175. package/src/resources/shared.ts +773 -200
  176. package/src/resources/support/index.ts +1 -0
  177. package/src/resources/support/support.ts +2 -0
  178. package/src/resources/support/tickets.ts +14 -21
  179. package/src/resources/webhooks.ts +5 -4
  180. package/src/resources/x/accounts.ts +19 -4
  181. package/src/resources/x/broadcasts.ts +3 -159
  182. package/src/resources/x/communities/communities.ts +113 -0
  183. package/src/resources/x/communities/index.ts +3 -0
  184. package/src/resources/x/community-notes.ts +137 -582
  185. package/src/resources/x/index.ts +70 -0
  186. package/src/resources/x/jobs.ts +160 -334
  187. package/src/resources/x/lists.ts +21 -493
  188. package/src/resources/x/spaces.ts +227 -817
  189. package/src/resources/x/sports.ts +1877 -0
  190. package/src/resources/x/tweets/tweets.ts +15 -15
  191. package/src/resources/x/users/users.ts +29 -693
  192. package/src/resources/x/x.ts +191 -128
  193. package/src/version.ts +1 -1
  194. package/version.d.mts +1 -1
  195. package/version.d.ts +1 -1
  196. package/version.js +1 -1
  197. package/version.mjs +1 -1
  198. package/src/lib/.keep +0 -2
@@ -0,0 +1,463 @@
1
+ // SPDX-FileCopyrightText: 2026 Xquik contributors
2
+ //
3
+ // SPDX-License-Identifier: Apache-2.0
4
+
5
+ import { APIResource } from '../../core/resource';
6
+ import { APIPromise } from '../../core/api-promise';
7
+ import { RequestOptions } from '../../internal/request-options';
8
+ import { path } from '../../internal/utils/path';
9
+
10
+ /**
11
+ * Post monitoring with replies, quotes, edits, deletion & 6 metrics
12
+ */
13
+ export class Posts extends APIResource {
14
+ /**
15
+ * Creates a monitor for 1 X post. It tracks replies, quotes, edits, deletion
16
+ * & 6 metrics, for 30 credits an hour with events & webhook deliveries
17
+ * included. That hourly price is a monitor's only charge. Creation needs the
18
+ * credits of the first hour & reads the post once.
19
+ *
20
+ * @example
21
+ * ```ts
22
+ * const postMonitor = await client.monitors.posts.create({
23
+ * post: 'https://x.com/xquik/status/2104984505677430978',
24
+ * });
25
+ * ```
26
+ */
27
+ create(body: PostCreateParams, options?: RequestOptions): APIPromise<PostMonitor> {
28
+ return this._client.post('/monitors/posts', { body, ...options });
29
+ }
30
+
31
+ /**
32
+ * Returns 1 post monitor with its post & the 6 metrics, each with its current
33
+ * value & gain since tracking began.
34
+ *
35
+ * @example
36
+ * ```ts
37
+ * const postMonitor = await client.monitors.posts.retrieve('id');
38
+ * ```
39
+ */
40
+ retrieve(id: string, options?: RequestOptions): APIPromise<PostMonitor> {
41
+ return this._client.get(path`/monitors/posts/${id}`, options);
42
+ }
43
+
44
+ /**
45
+ * Updates a post monitor's label, event types or active state. Turning a
46
+ * paused monitor on reads the post first, & answers 409 while X hides it.
47
+ *
48
+ * @example
49
+ * ```ts
50
+ * const postMonitor = await client.monitors.posts.update('id', {
51
+ * isActive: false,
52
+ * });
53
+ * ```
54
+ */
55
+ update(id: string, body: PostUpdateParams, options?: RequestOptions): APIPromise<PostMonitor> {
56
+ return this._client.patch(path`/monitors/posts/${id}`, { body, ...options });
57
+ }
58
+
59
+ /**
60
+ * Returns post monitors with each post's 6 metrics, their current values &
61
+ * gains since tracking began.
62
+ *
63
+ * @example
64
+ * ```ts
65
+ * const posts = await client.monitors.posts.list();
66
+ * ```
67
+ */
68
+ list(
69
+ query: PostListParams | null | undefined = {},
70
+ options?: RequestOptions,
71
+ ): APIPromise<PostListResponse> {
72
+ return this._client.get('/monitors/posts', { query, ...options });
73
+ }
74
+
75
+ /**
76
+ * Stops 1 post monitor, then removes its stored events & metric history in
77
+ * bounded batches. Poll statusUrl until the monitor returns 404.
78
+ *
79
+ * @example
80
+ * ```ts
81
+ * const post = await client.monitors.posts.delete('id');
82
+ * ```
83
+ */
84
+ delete(id: string, options?: RequestOptions): APIPromise<PostDeleteResponse> {
85
+ return this._client.delete(path`/monitors/posts/${id}`, options);
86
+ }
87
+
88
+ /**
89
+ * Returns 1 bucket per hour with each metric's value at the hour's end & its
90
+ * gain over that hour. The last bucket is the current hour. Hours before
91
+ * tracking began carry the starting values with a gain of 0.
92
+ *
93
+ * @example
94
+ * ```ts
95
+ * const postMonitorMetrics = await client.monitors.posts.retrieveMetrics('id');
96
+ * ```
97
+ */
98
+ retrieveMetrics(
99
+ id: string,
100
+ query: PostRetrieveMetricsParams | null | undefined = {},
101
+ options?: RequestOptions,
102
+ ): APIPromise<PostMonitorMetrics> {
103
+ return this._client.get(path`/monitors/posts/${id}/metrics`, { query, ...options });
104
+ }
105
+ }
106
+
107
+ /**
108
+ * A post event type.
109
+ */
110
+ export type PostEventType =
111
+ | 'post.reply.new'
112
+ | 'post.quote.new'
113
+ | 'post.likes.changed'
114
+ | 'post.retweets.changed'
115
+ | 'post.replies.changed'
116
+ | 'post.quotes.changed'
117
+ | 'post.bookmarks.changed'
118
+ | 'post.views.changed'
119
+ | 'post.edited'
120
+ | 'post.deleted';
121
+
122
+ /**
123
+ * A metric's current value & its gain since tracking began. Both are null when
124
+ * X shows no count, as for views on old posts.
125
+ */
126
+ export interface PostMetricReading {
127
+ current: number | null;
128
+
129
+ gain: number | null;
130
+ }
131
+
132
+ /**
133
+ * The 6 metrics of a post.
134
+ */
135
+ export interface PostMetrics {
136
+ /**
137
+ * A metric's current value & its gain since tracking began. Both are null
138
+ * when X shows no count, as for views on old posts.
139
+ */
140
+ views: PostMetricReading;
141
+
142
+ /**
143
+ * A metric's current value & its gain since tracking began. Both are null
144
+ * when X shows no count, as for views on old posts.
145
+ */
146
+ likes: PostMetricReading;
147
+
148
+ /**
149
+ * A metric's current value & its gain since tracking began. Both are null
150
+ * when X shows no count, as for views on old posts.
151
+ */
152
+ retweets: PostMetricReading;
153
+
154
+ /**
155
+ * A metric's current value & its gain since tracking began. Both are null
156
+ * when X shows no count, as for views on old posts.
157
+ */
158
+ replies: PostMetricReading;
159
+
160
+ /**
161
+ * A metric's current value & its gain since tracking began. Both are null
162
+ * when X shows no count, as for views on old posts.
163
+ */
164
+ quotes: PostMetricReading;
165
+
166
+ /**
167
+ * A metric's current value & its gain since tracking began. Both are null
168
+ * when X shows no count, as for views on old posts.
169
+ */
170
+ bookmarks: PostMetricReading;
171
+ }
172
+
173
+ /**
174
+ * Post monitor that tracks 1 X post's replies, quotes, edits & metrics.
175
+ */
176
+ export interface PostMonitor {
177
+ id: string;
178
+
179
+ /**
180
+ * ID of the post you gave.
181
+ */
182
+ postId: string;
183
+
184
+ postUrl: string;
185
+
186
+ /**
187
+ * Permanent X user ID of the post's author.
188
+ */
189
+ authorId: string;
190
+
191
+ authorUsername: string;
192
+
193
+ authorName: string;
194
+
195
+ /**
196
+ * Text of the newest version Xquik read.
197
+ */
198
+ text: string;
199
+
200
+ postedAt: string;
201
+
202
+ /**
203
+ * Post event types to send. Without it, a monitor sends new replies, new
204
+ * quotes, like & retweet changes, edits & deletion.
205
+ */
206
+ eventTypes: Array<PostEventType>;
207
+
208
+ isActive: boolean;
209
+
210
+ createdAt: string;
211
+
212
+ /**
213
+ * Next hourly credit charge time for this post monitor.
214
+ */
215
+ nextBillingAt: string;
216
+
217
+ /**
218
+ * The 6 metrics of a post.
219
+ */
220
+ metrics: PostMetrics;
221
+
222
+ /**
223
+ * Customer-set label of the post monitor, when set.
224
+ */
225
+ name?: string;
226
+
227
+ /**
228
+ * Why Xquik paused this post monitor. insufficient_credits means the balance
229
+ * could not pay an hour, so add credits & resume. The other 3 mean X stopped
230
+ * showing the post. Absent when the monitor is active or you paused it
231
+ * yourself.
232
+ */
233
+ pausedReason?: 'insufficient_credits' | 'x_post_deleted' | 'x_post_protected' | 'x_post_unavailable';
234
+
235
+ /**
236
+ * When Xquik paused this post monitor.
237
+ */
238
+ pausedAt?: string;
239
+ }
240
+
241
+ /**
242
+ * A metric's value at the hour's end & its gain over that hour. Both are null
243
+ * when X shows no count.
244
+ */
245
+ export interface PostMetricPoint {
246
+ value: number | null;
247
+
248
+ gain: number | null;
249
+ }
250
+
251
+ export interface PostMonitorMetricsBucketMetrics {
252
+ /**
253
+ * A metric's value at the hour's end & its gain over that hour. Both are null
254
+ * when X shows no count.
255
+ */
256
+ views: PostMetricPoint;
257
+
258
+ /**
259
+ * A metric's value at the hour's end & its gain over that hour. Both are null
260
+ * when X shows no count.
261
+ */
262
+ likes: PostMetricPoint;
263
+
264
+ /**
265
+ * A metric's value at the hour's end & its gain over that hour. Both are null
266
+ * when X shows no count.
267
+ */
268
+ retweets: PostMetricPoint;
269
+
270
+ /**
271
+ * A metric's value at the hour's end & its gain over that hour. Both are null
272
+ * when X shows no count.
273
+ */
274
+ replies: PostMetricPoint;
275
+
276
+ /**
277
+ * A metric's value at the hour's end & its gain over that hour. Both are null
278
+ * when X shows no count.
279
+ */
280
+ quotes: PostMetricPoint;
281
+
282
+ /**
283
+ * A metric's value at the hour's end & its gain over that hour. Both are null
284
+ * when X shows no count.
285
+ */
286
+ bookmarks: PostMetricPoint;
287
+ }
288
+
289
+ export interface PostMonitorMetricsBucket {
290
+ /**
291
+ * Start of the hour.
292
+ */
293
+ at: string;
294
+
295
+ metrics: PostMonitorMetricsBucketMetrics;
296
+ }
297
+
298
+ /**
299
+ * Hourly metric buckets of 1 post monitor, oldest first.
300
+ */
301
+ export interface PostMonitorMetrics {
302
+ hours: number;
303
+
304
+ buckets: Array<PostMonitorMetricsBucket>;
305
+ }
306
+
307
+ /**
308
+ * A post metric's change since its last event, on post.likes.changed,
309
+ * post.retweets.changed, post.replies.changed, post.quotes.changed,
310
+ * post.bookmarks.changed & post.views.changed.
311
+ */
312
+ export interface MonitorPostMetricChange {
313
+ /**
314
+ * Current count minus previous count.
315
+ */
316
+ change: number;
317
+
318
+ /**
319
+ * The count X shows now.
320
+ */
321
+ current: number;
322
+
323
+ /**
324
+ * The metric that changed.
325
+ */
326
+ metric: 'bookmarks' | 'likes' | 'quotes' | 'replies' | 'retweets' | 'views';
327
+
328
+ /**
329
+ * The count the last event of this metric reported.
330
+ */
331
+ previous: number;
332
+ }
333
+
334
+ /**
335
+ * The post's text before & after an edit, on post.edited.
336
+ */
337
+ export interface MonitorPostEdit {
338
+ /**
339
+ * The text before the edit.
340
+ */
341
+ previousText: string;
342
+
343
+ /**
344
+ * The text of the newest version.
345
+ */
346
+ text: string;
347
+
348
+ /**
349
+ * X's ID of the newest version of the post.
350
+ */
351
+ versionId: string;
352
+ }
353
+
354
+ /**
355
+ * The last text the monitor saw, on post.deleted.
356
+ */
357
+ export interface MonitorPostDeleted {
358
+ /**
359
+ * The post's text before its author deleted it.
360
+ */
361
+ text: string;
362
+ }
363
+
364
+ export interface PostListResponse {
365
+ hasMore: boolean;
366
+
367
+ monitors: Array<PostMonitor>;
368
+
369
+ /**
370
+ * Post monitors on this page.
371
+ */
372
+ total: number;
373
+
374
+ nextCursor?: string;
375
+ }
376
+
377
+ export interface PostDeleteResponse {
378
+ deletionStatus: 'deleting';
379
+
380
+ /**
381
+ * Poll this monitor URL until it returns 404.
382
+ */
383
+ statusUrl: string;
384
+
385
+ success: true;
386
+ }
387
+
388
+ export interface PostCreateParams {
389
+ /**
390
+ * Post link or ID. x.com, twitter.com, mobile & /i/web/status/ links work
391
+ * with any query string.
392
+ */
393
+ post: string;
394
+
395
+ /**
396
+ * Post event types to send. Without it, a monitor sends new replies, new
397
+ * quotes, like & retweet changes, edits & deletion.
398
+ */
399
+ eventTypes?: Array<PostEventType>;
400
+
401
+ /**
402
+ * Your own label for the post monitor. Its events carry it as monitorName.
403
+ */
404
+ name?: string | null;
405
+ }
406
+
407
+ export interface PostUpdateParams {
408
+ /**
409
+ * Post event types to send. Without it, a monitor sends new replies, new
410
+ * quotes, like & retweet changes, edits & deletion.
411
+ */
412
+ eventTypes?: Array<PostEventType>;
413
+
414
+ isActive?: boolean;
415
+
416
+ /**
417
+ * New label for the post monitor. Send null to remove it.
418
+ */
419
+ name?: string | null;
420
+ }
421
+
422
+ export interface PostListParams {
423
+ /**
424
+ * Previous nextCursor. The after alias also works. Offset pagination is not
425
+ * supported.
426
+ */
427
+ cursor?: string;
428
+
429
+ /**
430
+ * Maximum items per page, from 1 to 200. Default 200. Pass nextCursor as
431
+ * cursor for the next page.
432
+ */
433
+ limit?: number;
434
+ }
435
+
436
+ export interface PostRetrieveMetricsParams {
437
+ /**
438
+ * Hours to return, from 1 to 720.
439
+ */
440
+ hours?: number;
441
+ }
442
+
443
+ export declare namespace Posts {
444
+ export {
445
+ type PostEventType as PostEventType,
446
+ type PostMetricReading as PostMetricReading,
447
+ type PostMetrics as PostMetrics,
448
+ type PostMonitor as PostMonitor,
449
+ type PostMetricPoint as PostMetricPoint,
450
+ type PostMonitorMetricsBucketMetrics as PostMonitorMetricsBucketMetrics,
451
+ type PostMonitorMetricsBucket as PostMonitorMetricsBucket,
452
+ type PostMonitorMetrics as PostMonitorMetrics,
453
+ type MonitorPostMetricChange as MonitorPostMetricChange,
454
+ type MonitorPostEdit as MonitorPostEdit,
455
+ type MonitorPostDeleted as MonitorPostDeleted,
456
+ type PostListResponse as PostListResponse,
457
+ type PostDeleteResponse as PostDeleteResponse,
458
+ type PostCreateParams as PostCreateParams,
459
+ type PostUpdateParams as PostUpdateParams,
460
+ type PostListParams as PostListParams,
461
+ type PostRetrieveMetricsParams as PostRetrieveMetricsParams,
462
+ };
463
+ }