x-twitter-scraper 0.4.1 → 0.5.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 (140) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +1 -0
  3. package/package.json +1 -1
  4. package/resources/credits.d.mts +1 -1
  5. package/resources/credits.d.ts +1 -1
  6. package/resources/extractions.d.mts +4 -4
  7. package/resources/extractions.d.ts +4 -4
  8. package/resources/guest-wallets.d.mts +2 -2
  9. package/resources/guest-wallets.d.ts +2 -2
  10. package/resources/shared.d.mts +24 -8
  11. package/resources/shared.d.mts.map +1 -1
  12. package/resources/shared.d.ts +24 -8
  13. package/resources/shared.d.ts.map +1 -1
  14. package/resources/support/tickets.d.mts +67 -4
  15. package/resources/support/tickets.d.mts.map +1 -1
  16. package/resources/support/tickets.d.ts +67 -4
  17. package/resources/support/tickets.d.ts.map +1 -1
  18. package/resources/support/tickets.js +22 -4
  19. package/resources/support/tickets.js.map +1 -1
  20. package/resources/support/tickets.mjs +22 -4
  21. package/resources/support/tickets.mjs.map +1 -1
  22. package/resources/x/account-connection-challenges.d.mts +1 -1
  23. package/resources/x/account-connection-challenges.d.ts +1 -1
  24. package/resources/x/account-connection-challenges.js +1 -1
  25. package/resources/x/account-connection-challenges.mjs +1 -1
  26. package/resources/x/accounts.d.mts +9 -6
  27. package/resources/x/accounts.d.mts.map +1 -1
  28. package/resources/x/accounts.d.ts +9 -6
  29. package/resources/x/accounts.d.ts.map +1 -1
  30. package/resources/x/accounts.js +4 -2
  31. package/resources/x/accounts.js.map +1 -1
  32. package/resources/x/accounts.mjs +4 -2
  33. package/resources/x/accounts.mjs.map +1 -1
  34. package/resources/x/communities/communities.d.mts +360 -10
  35. package/resources/x/communities/communities.d.mts.map +1 -1
  36. package/resources/x/communities/communities.d.ts +360 -10
  37. package/resources/x/communities/communities.d.ts.map +1 -1
  38. package/resources/x/communities/communities.js +17 -4
  39. package/resources/x/communities/communities.js.map +1 -1
  40. package/resources/x/communities/communities.mjs +17 -4
  41. package/resources/x/communities/communities.mjs.map +1 -1
  42. package/resources/x/communities/join.d.mts +361 -7
  43. package/resources/x/communities/join.d.mts.map +1 -1
  44. package/resources/x/communities/join.d.ts +361 -7
  45. package/resources/x/communities/join.d.ts.map +1 -1
  46. package/resources/x/communities/join.js +20 -5
  47. package/resources/x/communities/join.js.map +1 -1
  48. package/resources/x/communities/join.mjs +20 -5
  49. package/resources/x/communities/join.mjs.map +1 -1
  50. package/resources/x/dm.d.mts +183 -5
  51. package/resources/x/dm.d.mts.map +1 -1
  52. package/resources/x/dm.d.ts +183 -5
  53. package/resources/x/dm.d.ts.map +1 -1
  54. package/resources/x/dm.js +9 -2
  55. package/resources/x/dm.js.map +1 -1
  56. package/resources/x/dm.mjs +9 -2
  57. package/resources/x/dm.mjs.map +1 -1
  58. package/resources/x/media.d.mts +178 -10
  59. package/resources/x/media.d.mts.map +1 -1
  60. package/resources/x/media.d.ts +178 -10
  61. package/resources/x/media.d.ts.map +1 -1
  62. package/resources/x/media.js +9 -5
  63. package/resources/x/media.js.map +1 -1
  64. package/resources/x/media.mjs +9 -5
  65. package/resources/x/media.mjs.map +1 -1
  66. package/resources/x/profile.d.mts +545 -14
  67. package/resources/x/profile.d.mts.map +1 -1
  68. package/resources/x/profile.d.ts +545 -14
  69. package/resources/x/profile.d.ts.map +1 -1
  70. package/resources/x/profile.js +25 -6
  71. package/resources/x/profile.js.map +1 -1
  72. package/resources/x/profile.mjs +25 -6
  73. package/resources/x/profile.mjs.map +1 -1
  74. package/resources/x/tweets/like.d.mts +358 -6
  75. package/resources/x/tweets/like.d.mts.map +1 -1
  76. package/resources/x/tweets/like.d.ts +358 -6
  77. package/resources/x/tweets/like.d.ts.map +1 -1
  78. package/resources/x/tweets/like.js +17 -4
  79. package/resources/x/tweets/like.js.map +1 -1
  80. package/resources/x/tweets/like.mjs +17 -4
  81. package/resources/x/tweets/like.mjs.map +1 -1
  82. package/resources/x/tweets/retweet.d.mts +358 -6
  83. package/resources/x/tweets/retweet.d.mts.map +1 -1
  84. package/resources/x/tweets/retweet.d.ts +358 -6
  85. package/resources/x/tweets/retweet.d.ts.map +1 -1
  86. package/resources/x/tweets/retweet.js +17 -4
  87. package/resources/x/tweets/retweet.js.map +1 -1
  88. package/resources/x/tweets/retweet.mjs +17 -4
  89. package/resources/x/tweets/retweet.mjs.map +1 -1
  90. package/resources/x/tweets/tweets.d.mts +376 -18
  91. package/resources/x/tweets/tweets.d.mts.map +1 -1
  92. package/resources/x/tweets/tweets.d.ts +376 -18
  93. package/resources/x/tweets/tweets.d.ts.map +1 -1
  94. package/resources/x/tweets/tweets.js +25 -6
  95. package/resources/x/tweets/tweets.js.map +1 -1
  96. package/resources/x/tweets/tweets.mjs +25 -6
  97. package/resources/x/tweets/tweets.mjs.map +1 -1
  98. package/resources/x/users/follow.d.mts +361 -7
  99. package/resources/x/users/follow.d.mts.map +1 -1
  100. package/resources/x/users/follow.d.ts +361 -7
  101. package/resources/x/users/follow.d.ts.map +1 -1
  102. package/resources/x/users/follow.js +20 -5
  103. package/resources/x/users/follow.js.map +1 -1
  104. package/resources/x/users/follow.mjs +20 -5
  105. package/resources/x/users/follow.mjs.map +1 -1
  106. package/resources/x/users/users.d.mts +181 -5
  107. package/resources/x/users/users.d.mts.map +1 -1
  108. package/resources/x/users/users.d.ts +181 -5
  109. package/resources/x/users/users.d.ts.map +1 -1
  110. package/resources/x/users/users.js +9 -2
  111. package/resources/x/users/users.js.map +1 -1
  112. package/resources/x/users/users.mjs +9 -2
  113. package/resources/x/users/users.mjs.map +1 -1
  114. package/resources/x/write-actions.d.mts +155 -12
  115. package/resources/x/write-actions.d.mts.map +1 -1
  116. package/resources/x/write-actions.d.ts +155 -12
  117. package/resources/x/write-actions.d.ts.map +1 -1
  118. package/src/resources/credits.ts +1 -1
  119. package/src/resources/extractions.ts +4 -4
  120. package/src/resources/guest-wallets.ts +2 -2
  121. package/src/resources/shared.ts +93 -9
  122. package/src/resources/support/tickets.ts +122 -6
  123. package/src/resources/x/account-connection-challenges.ts +1 -1
  124. package/src/resources/x/accounts.ts +9 -6
  125. package/src/resources/x/communities/communities.ts +515 -12
  126. package/src/resources/x/communities/join.ts +518 -9
  127. package/src/resources/x/dm.ts +261 -6
  128. package/src/resources/x/media.ts +258 -11
  129. package/src/resources/x/profile.ts +786 -17
  130. package/src/resources/x/tweets/like.ts +515 -8
  131. package/src/resources/x/tweets/retweet.ts +523 -8
  132. package/src/resources/x/tweets/tweets.ts +529 -23
  133. package/src/resources/x/users/follow.ts +518 -9
  134. package/src/resources/x/users/users.ts +260 -6
  135. package/src/resources/x/write-actions.ts +207 -14
  136. package/src/version.ts +1 -1
  137. package/version.d.mts +1 -1
  138. package/version.d.ts +1 -1
  139. package/version.js +1 -1
  140. package/version.mjs +1 -1
@@ -11,6 +11,7 @@ import {
11
11
  FollowDeleteAllResponse,
12
12
  } from './follow';
13
13
  import { APIPromise } from '../../../core/api-promise';
14
+ import { buildHeaders } from '../../../internal/headers';
14
15
  import { RequestOptions } from '../../../internal/request-options';
15
16
  import { path } from '../../../internal/utils/path';
16
17
 
@@ -36,15 +37,21 @@ export class Users extends APIResource {
36
37
  * ```ts
37
38
  * const response = await client.x.users.removeFollower('id', {
38
39
  * account: '@elonmusk',
40
+ * 'Idempotency-Key': 'Idempotency-Key',
39
41
  * });
40
42
  * ```
41
43
  */
42
44
  removeFollower(
43
45
  id: string,
44
- body: UserRemoveFollowerParams,
46
+ params: UserRemoveFollowerParams,
45
47
  options?: RequestOptions,
46
48
  ): APIPromise<UserRemoveFollowerResponse> {
47
- return this._client.post(path`/x/users/${id}/remove-follower`, { body, ...options });
49
+ const { 'Idempotency-Key': idempotencyKey, ...body } = params;
50
+ return this._client.post(path`/x/users/${id}/remove-follower`, {
51
+ body,
52
+ ...options,
53
+ headers: buildHeaders([{ 'Idempotency-Key': idempotencyKey }, options?.headers]),
54
+ });
48
55
  }
49
56
 
50
57
  /**
@@ -238,8 +245,247 @@ export class Users extends APIResource {
238
245
  }
239
246
  }
240
247
 
248
+ /**
249
+ * Durable write lifecycle record. Poll statusUrl until terminal is true. Reusing
250
+ * the original Idempotency-Key returns this same record. Submit a new write only
251
+ * when safeToRetry is true, using a new key.
252
+ */
241
253
  export interface UserRemoveFollowerResponse {
242
- success: true;
254
+ id: string;
255
+
256
+ /**
257
+ * Connected account selected for the write.
258
+ */
259
+ account: UserRemoveFollowerResponse.Account | null;
260
+
261
+ action:
262
+ | 'create_tweet'
263
+ | 'delete_tweet'
264
+ | 'like'
265
+ | 'unlike'
266
+ | 'retweet'
267
+ | 'unretweet'
268
+ | 'follow'
269
+ | 'unfollow'
270
+ | 'remove_follower'
271
+ | 'send_dm'
272
+ | 'upload_media'
273
+ | 'update_profile'
274
+ | 'update_avatar'
275
+ | 'update_banner'
276
+ | 'create_community'
277
+ | 'delete_community'
278
+ | 'join_community'
279
+ | 'leave_community';
280
+
281
+ /**
282
+ * plannedCredits is the approved maximum. chargedCredits comes from the settled
283
+ * credit ledger. Pending or failed writes are not charged.
284
+ */
285
+ billing: UserRemoveFollowerResponse.Billing;
286
+
287
+ charged: boolean;
288
+
289
+ chargedCredits: string;
290
+
291
+ /**
292
+ * Exact follow-up an API client or agent should perform.
293
+ */
294
+ nextAction: UserRemoveFollowerResponse.NextAction | null;
295
+
296
+ object: 'x_write_action';
297
+
298
+ pollAfterMs: number | null;
299
+
300
+ /**
301
+ * Stable fingerprint and sanitized payload for replay checks.
302
+ */
303
+ request: UserRemoveFollowerResponse.Request;
304
+
305
+ /**
306
+ * Confirmed result produced by the write, when available.
307
+ */
308
+ result: UserRemoveFollowerResponse.Result | null;
309
+
310
+ /**
311
+ * True only when a new attempt can reasonably succeed.
312
+ */
313
+ retryable: boolean;
314
+
315
+ /**
316
+ * True only when no write was dispatched and a new idempotency key may be used.
317
+ */
318
+ safeToRetry: boolean;
319
+
320
+ sendDispatched: boolean;
321
+
322
+ status: 'accepted' | 'dispatching' | 'pending_confirmation' | 'success' | 'failed' | 'expired';
323
+
324
+ statusUrl: string;
325
+
326
+ success: boolean;
327
+
328
+ /**
329
+ * Existing X resource targeted by the write, when applicable.
330
+ */
331
+ target: UserRemoveFollowerResponse.Target | null;
332
+
333
+ targetId: string | null;
334
+
335
+ terminal: boolean;
336
+
337
+ writeActionId: string;
338
+
339
+ /**
340
+ * Compatibility field for a confirmed community ID.
341
+ */
342
+ communityId?: string;
343
+
344
+ /**
345
+ * Confirmed community name when available.
346
+ */
347
+ communityName?: string;
348
+
349
+ completedAt?: string;
350
+
351
+ confirmationAttempts?: number;
352
+
353
+ confirmationCheckedAt?: string;
354
+
355
+ confirmedAt?: string;
356
+
357
+ createdAt?: string;
358
+
359
+ /**
360
+ * Structured recovery context for a failed write.
361
+ */
362
+ details?: { [key: string]: unknown };
363
+
364
+ error?: string;
365
+
366
+ /**
367
+ * Deadline for resolving a non-terminal write. This is not the Idempotency-Key
368
+ * retention deadline.
369
+ */
370
+ expiresAt?: string;
371
+
372
+ idempotent?: boolean;
373
+
374
+ /**
375
+ * Media count, kind, size, and billing details when used.
376
+ */
377
+ media?: { [key: string]: unknown };
378
+
379
+ /**
380
+ * Compatibility field for a confirmed media upload ID.
381
+ */
382
+ mediaId?: string;
383
+
384
+ /**
385
+ * Public media URL when the upload creates one.
386
+ */
387
+ mediaUrl?: string;
388
+
389
+ message?: string;
390
+
391
+ /**
392
+ * Compatibility field for a confirmed direct message ID.
393
+ */
394
+ messageId?: string;
395
+
396
+ requestHash?: string;
397
+
398
+ requestId?: string;
399
+
400
+ /**
401
+ * Compatibility result ID for other write actions.
402
+ */
403
+ resultId?: string;
404
+
405
+ /**
406
+ * Dispatch timestamp when the write reached execution.
407
+ */
408
+ sendDispatchedAt?: string;
409
+
410
+ /**
411
+ * Compatibility field for a confirmed tweet result ID.
412
+ */
413
+ tweetId?: string;
414
+
415
+ updatedAt?: string;
416
+ }
417
+
418
+ export namespace UserRemoveFollowerResponse {
419
+ /**
420
+ * Connected account selected for the write.
421
+ */
422
+ export interface Account {
423
+ id: string;
424
+
425
+ username: string;
426
+ }
427
+
428
+ /**
429
+ * plannedCredits is the approved maximum. chargedCredits comes from the settled
430
+ * credit ledger. Pending or failed writes are not charged.
431
+ */
432
+ export interface Billing {
433
+ charged: boolean;
434
+
435
+ chargedCredits: string;
436
+
437
+ plannedCredits: string;
438
+
439
+ status: 'not_charged' | 'pending' | 'charged' | 'charge_failed' | 'refunded';
440
+ }
441
+
442
+ /**
443
+ * Exact follow-up an API client or agent should perform.
444
+ */
445
+ export interface NextAction {
446
+ type: 'poll' | 'retry' | 'verify_result' | 'fix_request';
447
+
448
+ afterMs?: number;
449
+
450
+ requiresNewIdempotencyKey?: boolean;
451
+
452
+ url?: string;
453
+ }
454
+
455
+ /**
456
+ * Stable fingerprint and sanitized payload for replay checks.
457
+ */
458
+ export interface Request {
459
+ /**
460
+ * Stable hash of account, action, target, and payload.
461
+ */
462
+ hash: string | null;
463
+
464
+ /**
465
+ * Exact sanitized payload dispatched for this action.
466
+ */
467
+ payload: { [key: string]: unknown } | null;
468
+ }
469
+
470
+ /**
471
+ * Confirmed result produced by the write, when available.
472
+ */
473
+ export interface Result {
474
+ id?: string;
475
+
476
+ state?: string;
477
+
478
+ type?: 'tweet' | 'direct_message' | 'media' | 'community' | 'state_change';
479
+ }
480
+
481
+ /**
482
+ * Existing X resource targeted by the write, when applicable.
483
+ */
484
+ export interface Target {
485
+ id: string;
486
+
487
+ type: 'tweet' | 'user' | 'community';
488
+ }
243
489
  }
244
490
 
245
491
  /**
@@ -290,9 +536,17 @@ export interface UserRetrieveBatchResponse {
290
536
 
291
537
  export interface UserRemoveFollowerParams {
292
538
  /**
293
- * X account identifier (@username or account ID)
539
+ * Body param: X account identifier (@username or account ID)
294
540
  */
295
541
  account: string;
542
+
543
+ /**
544
+ * Header param: Generate one unique value for each intended write. Reuse it only
545
+ * when retrying the exact same account, action, target, and payload. A reused key
546
+ * returns the original action. Reusing it with different input returns 409. Replay
547
+ * protection remains active for at least 90 days.
548
+ */
549
+ 'Idempotency-Key': string;
296
550
  }
297
551
 
298
552
  export interface UserRetrieveBatchParams {
@@ -345,7 +599,7 @@ export interface UserRetrieveFollowersYouKnowParams {
345
599
 
346
600
  export interface UserRetrieveFollowingParams {
347
601
  /**
348
- * Legacy cursor alias. Prefer cursor.
602
+ * Deprecated following cursor alias. Prefer cursor.
349
603
  */
350
604
  after?: string;
351
605
 
@@ -847,7 +1101,7 @@ export interface UserRetrieveRepliesParams {
847
1101
  hashtags?: string;
848
1102
 
849
1103
  /**
850
- * Include parent tweet for replies
1104
+ * Include each reply's parent tweet.
851
1105
  */
852
1106
  includeParentTweet?: boolean;
853
1107
 
@@ -24,53 +24,246 @@ export class WriteActions extends APIResource {
24
24
  }
25
25
  }
26
26
 
27
+ /**
28
+ * Durable write lifecycle record. Poll statusUrl until terminal is true. Reusing
29
+ * the original Idempotency-Key returns this same record. Submit a new write only
30
+ * when safeToRetry is true, using a new key.
31
+ */
27
32
  export interface WriteActionRetrieveResponse {
28
- action: string;
33
+ id: string;
34
+
35
+ /**
36
+ * Connected account selected for the write.
37
+ */
38
+ account: WriteActionRetrieveResponse.Account | null;
39
+
40
+ action:
41
+ | 'create_tweet'
42
+ | 'delete_tweet'
43
+ | 'like'
44
+ | 'unlike'
45
+ | 'retweet'
46
+ | 'unretweet'
47
+ | 'follow'
48
+ | 'unfollow'
49
+ | 'remove_follower'
50
+ | 'send_dm'
51
+ | 'upload_media'
52
+ | 'update_profile'
53
+ | 'update_avatar'
54
+ | 'update_banner'
55
+ | 'create_community'
56
+ | 'delete_community'
57
+ | 'join_community'
58
+ | 'leave_community';
59
+
60
+ /**
61
+ * plannedCredits is the approved maximum. chargedCredits comes from the settled
62
+ * credit ledger. Pending or failed writes are not charged.
63
+ */
64
+ billing: WriteActionRetrieveResponse.Billing;
29
65
 
30
66
  charged: boolean;
31
67
 
32
68
  chargedCredits: string;
33
69
 
34
- createdAt: string;
70
+ /**
71
+ * Exact follow-up an API client or agent should perform.
72
+ */
73
+ nextAction: WriteActionRetrieveResponse.NextAction | null;
35
74
 
36
- media: WriteActionRetrieveResponse.Media;
75
+ object: 'x_write_action';
37
76
 
38
- retryable: false;
77
+ pollAfterMs: number | null;
78
+
79
+ /**
80
+ * Stable fingerprint and sanitized payload for replay checks.
81
+ */
82
+ request: WriteActionRetrieveResponse.Request;
83
+
84
+ /**
85
+ * Confirmed result produced by the write, when available.
86
+ */
87
+ result: WriteActionRetrieveResponse.Result | null;
88
+
89
+ /**
90
+ * True only when a new attempt can reasonably succeed.
91
+ */
92
+ retryable: boolean;
93
+
94
+ /**
95
+ * True only when no write was dispatched and a new idempotency key may be used.
96
+ */
97
+ safeToRetry: boolean;
39
98
 
40
99
  sendDispatched: boolean;
41
100
 
42
- status: 'success' | 'failed' | 'pending_confirmation';
101
+ status: 'accepted' | 'dispatching' | 'pending_confirmation' | 'success' | 'failed' | 'expired';
102
+
103
+ statusUrl: string;
104
+
105
+ success: boolean;
106
+
107
+ /**
108
+ * Existing X resource targeted by the write, when applicable.
109
+ */
110
+ target: WriteActionRetrieveResponse.Target | null;
111
+
112
+ targetId: string | null;
113
+
114
+ terminal: boolean;
43
115
 
44
116
  writeActionId: string;
45
117
 
118
+ /**
119
+ * Compatibility field for a confirmed community ID.
120
+ */
121
+ communityId?: string;
122
+
123
+ /**
124
+ * Confirmed community name when available.
125
+ */
126
+ communityName?: string;
127
+
128
+ completedAt?: string;
129
+
46
130
  confirmationAttempts?: number;
47
131
 
48
132
  confirmationCheckedAt?: string;
49
133
 
50
- confirmationSource?: string | null;
51
-
52
134
  confirmedAt?: string;
53
135
 
136
+ createdAt?: string;
137
+
138
+ /**
139
+ * Structured recovery context for a failed write.
140
+ */
141
+ details?: { [key: string]: unknown };
142
+
143
+ error?: string;
144
+
145
+ /**
146
+ * Deadline for resolving a non-terminal write. This is not the Idempotency-Key
147
+ * retention deadline.
148
+ */
149
+ expiresAt?: string;
150
+
151
+ idempotent?: boolean;
152
+
153
+ /**
154
+ * Media count, kind, size, and billing details when used.
155
+ */
156
+ media?: { [key: string]: unknown };
157
+
158
+ /**
159
+ * Compatibility field for a confirmed media upload ID.
160
+ */
161
+ mediaId?: string;
162
+
163
+ /**
164
+ * Public media URL when the upload creates one.
165
+ */
166
+ mediaUrl?: string;
167
+
54
168
  message?: string;
55
169
 
170
+ /**
171
+ * Compatibility field for a confirmed direct message ID.
172
+ */
56
173
  messageId?: string;
57
174
 
58
- sendDispatchedAt?: string;
175
+ requestHash?: string;
176
+
177
+ requestId?: string;
59
178
 
60
- targetId?: string | null;
179
+ /**
180
+ * Compatibility result ID for other write actions.
181
+ */
182
+ resultId?: string;
61
183
 
184
+ /**
185
+ * Dispatch timestamp when the write reached execution.
186
+ */
187
+ sendDispatchedAt?: string;
188
+
189
+ /**
190
+ * Compatibility field for a confirmed tweet result ID.
191
+ */
62
192
  tweetId?: string;
193
+
194
+ updatedAt?: string;
63
195
  }
64
196
 
65
197
  export namespace WriteActionRetrieveResponse {
66
- export interface Media {
67
- count: number;
198
+ /**
199
+ * Connected account selected for the write.
200
+ */
201
+ export interface Account {
202
+ id: string;
203
+
204
+ username: string;
205
+ }
68
206
 
69
- credits: string;
207
+ /**
208
+ * plannedCredits is the approved maximum. chargedCredits comes from the settled
209
+ * credit ledger. Pending or failed writes are not charged.
210
+ */
211
+ export interface Billing {
212
+ charged: boolean;
70
213
 
71
- kind: 'none' | 'image' | 'video';
214
+ chargedCredits: string;
215
+
216
+ plannedCredits: string;
217
+
218
+ status: 'not_charged' | 'pending' | 'charged' | 'charge_failed' | 'refunded';
219
+ }
220
+
221
+ /**
222
+ * Exact follow-up an API client or agent should perform.
223
+ */
224
+ export interface NextAction {
225
+ type: 'poll' | 'retry' | 'verify_result' | 'fix_request';
226
+
227
+ afterMs?: number;
228
+
229
+ requiresNewIdempotencyKey?: boolean;
230
+
231
+ url?: string;
232
+ }
233
+
234
+ /**
235
+ * Stable fingerprint and sanitized payload for replay checks.
236
+ */
237
+ export interface Request {
238
+ /**
239
+ * Stable hash of account, action, target, and payload.
240
+ */
241
+ hash: string | null;
242
+
243
+ /**
244
+ * Exact sanitized payload dispatched for this action.
245
+ */
246
+ payload: { [key: string]: unknown } | null;
247
+ }
248
+
249
+ /**
250
+ * Confirmed result produced by the write, when available.
251
+ */
252
+ export interface Result {
253
+ id?: string;
254
+
255
+ state?: string;
256
+
257
+ type?: 'tweet' | 'direct_message' | 'media' | 'community' | 'state_change';
258
+ }
259
+
260
+ /**
261
+ * Existing X resource targeted by the write, when applicable.
262
+ */
263
+ export interface Target {
264
+ id: string;
72
265
 
73
- totalBytes: string;
266
+ type: 'tweet' | 'user' | 'community';
74
267
  }
75
268
  }
76
269
 
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.4.1'; // x-release-please-version
1
+ export const VERSION = '0.5.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.4.1";
1
+ export declare const VERSION = "0.5.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.4.1";
1
+ export declare const VERSION = "0.5.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.4.1'; // x-release-please-version
4
+ exports.VERSION = '0.5.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.4.1'; // x-release-please-version
1
+ export const VERSION = '0.5.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map