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.
- package/CHANGELOG.md +44 -5
- package/README.md +1 -0
- package/client.d.mts +8 -2
- package/client.d.mts.map +1 -1
- package/client.d.ts +8 -2
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/internal/detect-platform.d.mts +3 -1
- package/internal/detect-platform.d.mts.map +1 -1
- package/internal/detect-platform.d.ts +3 -1
- package/internal/detect-platform.d.ts.map +1 -1
- package/internal/detect-platform.js +1 -1
- package/internal/detect-platform.js.map +1 -1
- package/internal/detect-platform.mjs +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/events.d.mts +50 -11
- package/resources/events.d.mts.map +1 -1
- package/resources/events.d.ts +50 -11
- package/resources/events.d.ts.map +1 -1
- package/resources/events.js.map +1 -1
- package/resources/events.mjs.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/monitors/index.d.mts +2 -1
- package/resources/monitors/index.d.mts.map +1 -1
- package/resources/monitors/index.d.ts +2 -1
- package/resources/monitors/index.d.ts.map +1 -1
- package/resources/monitors/index.js +3 -1
- package/resources/monitors/index.js.map +1 -1
- package/resources/monitors/index.mjs +1 -0
- package/resources/monitors/index.mjs.map +1 -1
- package/resources/monitors/keywords.d.mts +10 -96
- package/resources/monitors/keywords.d.mts.map +1 -1
- package/resources/monitors/keywords.d.ts +10 -96
- package/resources/monitors/keywords.d.ts.map +1 -1
- package/resources/monitors/monitors.d.mts +6 -2
- package/resources/monitors/monitors.d.mts.map +1 -1
- package/resources/monitors/monitors.d.ts +6 -2
- package/resources/monitors/monitors.d.ts.map +1 -1
- package/resources/monitors/monitors.js +4 -0
- package/resources/monitors/monitors.js.map +1 -1
- package/resources/monitors/monitors.mjs +4 -0
- package/resources/monitors/monitors.mjs.map +1 -1
- package/resources/monitors/posts.d.mts +344 -0
- package/resources/monitors/posts.d.mts.map +1 -0
- package/resources/monitors/posts.d.ts +344 -0
- package/resources/monitors/posts.d.ts.map +1 -0
- package/resources/monitors/posts.js +94 -0
- package/resources/monitors/posts.js.map +1 -0
- package/resources/monitors/posts.mjs +90 -0
- package/resources/monitors/posts.mjs.map +1 -0
- package/resources/shared.d.mts +577 -2
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +577 -2
- package/resources/shared.d.ts.map +1 -1
- package/resources/support/index.d.mts +1 -1
- package/resources/support/index.d.mts.map +1 -1
- package/resources/support/index.d.ts +1 -1
- package/resources/support/index.d.ts.map +1 -1
- package/resources/support/index.js.map +1 -1
- package/resources/support/index.mjs.map +1 -1
- package/resources/support/support.d.mts +2 -2
- package/resources/support/support.d.mts.map +1 -1
- package/resources/support/support.d.ts +2 -2
- package/resources/support/support.d.ts.map +1 -1
- package/resources/support/support.js.map +1 -1
- package/resources/support/support.mjs.map +1 -1
- package/resources/support/tickets.d.mts +12 -20
- package/resources/support/tickets.d.mts.map +1 -1
- package/resources/support/tickets.d.ts +12 -20
- package/resources/support/tickets.d.ts.map +1 -1
- package/resources/webhooks.d.mts +5 -4
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +5 -4
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs.map +1 -1
- package/resources/x/accounts.d.mts +14 -4
- package/resources/x/accounts.d.mts.map +1 -1
- package/resources/x/accounts.d.ts +14 -4
- package/resources/x/accounts.d.ts.map +1 -1
- package/resources/x/accounts.js +6 -4
- package/resources/x/accounts.js.map +1 -1
- package/resources/x/accounts.mjs +6 -4
- package/resources/x/accounts.mjs.map +1 -1
- package/resources/x/broadcasts.d.mts +3 -131
- package/resources/x/broadcasts.d.mts.map +1 -1
- package/resources/x/broadcasts.d.ts +3 -131
- package/resources/x/broadcasts.d.ts.map +1 -1
- package/resources/x/communities/communities.d.mts +92 -1
- package/resources/x/communities/communities.d.mts.map +1 -1
- package/resources/x/communities/communities.d.ts +92 -1
- package/resources/x/communities/communities.d.ts.map +1 -1
- package/resources/x/communities/communities.js +14 -0
- package/resources/x/communities/communities.js.map +1 -1
- package/resources/x/communities/communities.mjs +14 -0
- package/resources/x/communities/communities.mjs.map +1 -1
- package/resources/x/communities/index.d.mts +1 -1
- package/resources/x/communities/index.d.mts.map +1 -1
- package/resources/x/communities/index.d.ts +1 -1
- package/resources/x/communities/index.d.ts.map +1 -1
- package/resources/x/communities/index.js.map +1 -1
- package/resources/x/communities/index.mjs.map +1 -1
- package/resources/x/community-notes.d.mts +122 -510
- package/resources/x/community-notes.d.mts.map +1 -1
- package/resources/x/community-notes.d.ts +122 -510
- package/resources/x/community-notes.d.ts.map +1 -1
- package/resources/x/community-notes.js.map +1 -1
- package/resources/x/community-notes.mjs.map +1 -1
- package/resources/x/index.d.mts +7 -6
- package/resources/x/index.d.mts.map +1 -1
- package/resources/x/index.d.ts +7 -6
- package/resources/x/index.d.ts.map +1 -1
- package/resources/x/index.js +3 -1
- package/resources/x/index.js.map +1 -1
- package/resources/x/index.mjs +1 -0
- package/resources/x/index.mjs.map +1 -1
- package/resources/x/jobs.d.mts +144 -291
- package/resources/x/jobs.d.mts.map +1 -1
- package/resources/x/jobs.d.ts +144 -291
- package/resources/x/jobs.d.ts.map +1 -1
- package/resources/x/jobs.js.map +1 -1
- package/resources/x/jobs.mjs.map +1 -1
- package/resources/x/lists.d.mts +21 -419
- package/resources/x/lists.d.mts.map +1 -1
- package/resources/x/lists.d.ts +21 -419
- package/resources/x/lists.d.ts.map +1 -1
- package/resources/x/spaces.d.mts +213 -693
- package/resources/x/spaces.d.mts.map +1 -1
- package/resources/x/spaces.d.ts +213 -693
- package/resources/x/spaces.d.ts.map +1 -1
- package/resources/x/spaces.js.map +1 -1
- package/resources/x/spaces.mjs.map +1 -1
- package/resources/x/sports.d.mts +1512 -0
- package/resources/x/sports.d.mts.map +1 -0
- package/resources/x/sports.d.ts +1512 -0
- package/resources/x/sports.d.ts.map +1 -0
- package/resources/x/sports.js +91 -0
- package/resources/x/sports.js.map +1 -0
- package/resources/x/sports.mjs +87 -0
- package/resources/x/sports.mjs.map +1 -0
- package/resources/x/tweets/tweets.d.mts +11 -13
- package/resources/x/tweets/tweets.d.mts.map +1 -1
- package/resources/x/tweets/tweets.d.ts +11 -13
- package/resources/x/tweets/tweets.d.ts.map +1 -1
- package/resources/x/users/users.d.mts +29 -585
- package/resources/x/users/users.d.mts.map +1 -1
- package/resources/x/users/users.d.ts +29 -585
- package/resources/x/users/users.d.ts.map +1 -1
- package/resources/x/users/users.js.map +1 -1
- package/resources/x/users/users.mjs.map +1 -1
- package/resources/x/x.d.mts +55 -118
- package/resources/x/x.d.mts.map +1 -1
- package/resources/x/x.d.ts +55 -118
- package/resources/x/x.d.ts.map +1 -1
- package/resources/x/x.js +4 -0
- package/resources/x/x.js.map +1 -1
- package/resources/x/x.mjs +4 -0
- package/resources/x/x.mjs.map +1 -1
- package/skills/x-twitter-scraper/references/api-endpoints-x-api.md +1 -0
- package/src/client.ts +8 -0
- package/src/internal/detect-platform.ts +2 -2
- package/src/resources/events.ts +72 -10
- package/src/resources/index.ts +1 -0
- package/src/resources/monitors/index.ts +21 -0
- package/src/resources/monitors/keywords.ts +10 -118
- package/src/resources/monitors/monitors.ts +46 -0
- package/src/resources/monitors/posts.ts +463 -0
- package/src/resources/shared.ts +773 -200
- package/src/resources/support/index.ts +1 -0
- package/src/resources/support/support.ts +2 -0
- package/src/resources/support/tickets.ts +14 -21
- package/src/resources/webhooks.ts +5 -4
- package/src/resources/x/accounts.ts +19 -4
- package/src/resources/x/broadcasts.ts +3 -159
- package/src/resources/x/communities/communities.ts +113 -0
- package/src/resources/x/communities/index.ts +3 -0
- package/src/resources/x/community-notes.ts +137 -582
- package/src/resources/x/index.ts +70 -0
- package/src/resources/x/jobs.ts +160 -334
- package/src/resources/x/lists.ts +21 -493
- package/src/resources/x/spaces.ts +227 -817
- package/src/resources/x/sports.ts +1877 -0
- package/src/resources/x/tweets/tweets.ts +15 -15
- package/src/resources/x/users/users.ts +29 -693
- package/src/resources/x/x.ts +191 -128
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/src/lib/.keep +0 -2
package/src/resources/shared.ts
CHANGED
|
@@ -4,6 +4,168 @@
|
|
|
4
4
|
|
|
5
5
|
import * as Shared from './shared';
|
|
6
6
|
|
|
7
|
+
/**
|
|
8
|
+
* X broadcast, a live video
|
|
9
|
+
*/
|
|
10
|
+
export interface Broadcast {
|
|
11
|
+
/**
|
|
12
|
+
* Broadcast ID
|
|
13
|
+
*/
|
|
14
|
+
id: string;
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Camera rotation in degrees
|
|
18
|
+
*/
|
|
19
|
+
cameraRotation?: number;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* X's code for who may chat
|
|
23
|
+
*/
|
|
24
|
+
chatOption?: number;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Public X profile.
|
|
28
|
+
*/
|
|
29
|
+
creator?: UserProfile;
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* When the broadcast ended
|
|
33
|
+
*/
|
|
34
|
+
endedAt?: string;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Video height in pixels
|
|
38
|
+
*/
|
|
39
|
+
height?: number;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Whether X offers a recording of the broadcast
|
|
43
|
+
*/
|
|
44
|
+
isAvailableForReplay?: boolean;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Whether the video stream runs in high-latency mode
|
|
48
|
+
*/
|
|
49
|
+
isHighLatency?: boolean;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Whether X marks the chat private
|
|
53
|
+
*/
|
|
54
|
+
isPrivateChat?: boolean;
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Whether the broadcaster edited the title of the replay
|
|
58
|
+
*/
|
|
59
|
+
isTitleEdited?: boolean;
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* When the video stream last reached X
|
|
63
|
+
*/
|
|
64
|
+
lastPingAt?: string;
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* X's media key for the video
|
|
68
|
+
*/
|
|
69
|
+
mediaKey?: string;
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Broadcaster, as X's live video service names the account
|
|
73
|
+
*/
|
|
74
|
+
periscopeUser?: Broadcast.PeriscopeUser;
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Image X shows before the broadcast starts
|
|
78
|
+
*/
|
|
79
|
+
preLiveSlateUrl?: string;
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* When the broadcast was set to start
|
|
83
|
+
*/
|
|
84
|
+
scheduledStart?: string;
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* What produced the video stream, as X names it
|
|
88
|
+
*/
|
|
89
|
+
source?: string;
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* When the broadcast went live
|
|
93
|
+
*/
|
|
94
|
+
startedAt?: string;
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Such as NotStarted, Running or Ended, as X names it
|
|
98
|
+
*/
|
|
99
|
+
state?: string;
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* Broadcast title
|
|
103
|
+
*/
|
|
104
|
+
title?: string;
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* Accounts that watched, live or after
|
|
108
|
+
*/
|
|
109
|
+
totalWatched?: number;
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Accounts watching, as X counts them
|
|
113
|
+
*/
|
|
114
|
+
totalWatching?: number;
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* Search tweet with author. Zero metrics may mean X omitted counts.
|
|
118
|
+
*/
|
|
119
|
+
tweet?: SearchTweet;
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* ID of the post that announces the broadcast
|
|
123
|
+
*/
|
|
124
|
+
tweetId?: string;
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* X's revision number of the broadcast
|
|
128
|
+
*/
|
|
129
|
+
version?: number;
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* Video width in pixels
|
|
133
|
+
*/
|
|
134
|
+
width?: number;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export namespace Broadcast {
|
|
138
|
+
/**
|
|
139
|
+
* Broadcaster, as X's live video service names the account
|
|
140
|
+
*/
|
|
141
|
+
export interface PeriscopeUser {
|
|
142
|
+
/**
|
|
143
|
+
* Live video account ID
|
|
144
|
+
*/
|
|
145
|
+
id?: string;
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* Live video display name
|
|
149
|
+
*/
|
|
150
|
+
displayName?: string;
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* Live video avatar URL
|
|
154
|
+
*/
|
|
155
|
+
profilePicture?: string;
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* The broadcaster's avatar at full size
|
|
159
|
+
*/
|
|
160
|
+
profilePictureOriginal?: string;
|
|
161
|
+
|
|
162
|
+
/**
|
|
163
|
+
* Live video username
|
|
164
|
+
*/
|
|
165
|
+
username?: string;
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
|
|
7
169
|
/**
|
|
8
170
|
* Public X Community, as every Community read returns it.
|
|
9
171
|
*/
|
|
@@ -355,24 +517,325 @@ export interface EmbeddedTweet {
|
|
|
355
517
|
|
|
356
518
|
retweetCount: number;
|
|
357
519
|
|
|
358
|
-
text: string;
|
|
520
|
+
text: string;
|
|
521
|
+
|
|
522
|
+
viewCount: number;
|
|
523
|
+
|
|
524
|
+
/**
|
|
525
|
+
* Describes an X Article preview and its lifecycle metadata.
|
|
526
|
+
*/
|
|
527
|
+
article?: SearchTweet.Article;
|
|
528
|
+
|
|
529
|
+
/**
|
|
530
|
+
* Public X profile.
|
|
531
|
+
*/
|
|
532
|
+
author?: UserProfile;
|
|
533
|
+
|
|
534
|
+
/**
|
|
535
|
+
* Why the tweet has no author. X serves a suspended or deleted account as an
|
|
536
|
+
* unavailable user with a reason such as Suspended or NotFound. Omitted when the
|
|
537
|
+
* author is available.
|
|
538
|
+
*/
|
|
539
|
+
authorUnavailable?: SearchTweet.AuthorUnavailable;
|
|
540
|
+
|
|
541
|
+
/**
|
|
542
|
+
* Describes a public card and its referenced profiles.
|
|
543
|
+
*/
|
|
544
|
+
card?: SearchTweet.Card;
|
|
545
|
+
|
|
546
|
+
/**
|
|
547
|
+
* Price charts the author attached under the post, 1 per cashtag. Absent when the
|
|
548
|
+
* post has none. X may send a cashtag without a chart window.
|
|
549
|
+
*/
|
|
550
|
+
cashtagAttachments?: Array<SearchTweet.CashtagAttachment>;
|
|
551
|
+
|
|
552
|
+
/**
|
|
553
|
+
* Community ID.
|
|
554
|
+
*/
|
|
555
|
+
communityId?: string;
|
|
556
|
+
|
|
557
|
+
/**
|
|
558
|
+
* Community name. Present when X sends it with the post.
|
|
559
|
+
*/
|
|
560
|
+
communityName?: string;
|
|
561
|
+
|
|
562
|
+
/**
|
|
563
|
+
* Community Note presentation metadata returned by X.
|
|
564
|
+
*/
|
|
565
|
+
communityNote?: SearchTweet.CommunityNote;
|
|
566
|
+
|
|
567
|
+
/**
|
|
568
|
+
* Content disclosure metadata shown by X when a tweet is labeled as paid
|
|
569
|
+
* partnership content or AI-generated media.
|
|
570
|
+
*/
|
|
571
|
+
contentDisclosure?: ContentDisclosure;
|
|
572
|
+
|
|
573
|
+
/**
|
|
574
|
+
* Reply policy & conversation owner.
|
|
575
|
+
*/
|
|
576
|
+
conversationControl?: SearchTweet.ConversationControl;
|
|
577
|
+
|
|
578
|
+
conversationId?: string;
|
|
579
|
+
|
|
580
|
+
/**
|
|
581
|
+
* Author-published point, with longitude before latitude.
|
|
582
|
+
*/
|
|
583
|
+
coordinates?: SearchTweet.Coordinates;
|
|
584
|
+
|
|
585
|
+
createdAt?: string;
|
|
586
|
+
|
|
587
|
+
displayTextRange?: Array<number>;
|
|
588
|
+
|
|
589
|
+
/**
|
|
590
|
+
* Lists edit-chain identifiers and the remaining edit window.
|
|
591
|
+
*/
|
|
592
|
+
edit?: SearchTweet.Edit;
|
|
593
|
+
|
|
594
|
+
/**
|
|
595
|
+
* Lists hashtags, symbols, links, and mentions from tweet text.
|
|
596
|
+
*/
|
|
597
|
+
entities?: SearchTweet.Entities;
|
|
598
|
+
|
|
599
|
+
/**
|
|
600
|
+
* Marks a subscriber-only post with the creator whose subscription unlocks it.
|
|
601
|
+
* Non-subscribers get the preview text & the subscribe link. Omitted on public
|
|
602
|
+
* posts.
|
|
603
|
+
*/
|
|
604
|
+
exclusiveContent?: SearchTweet.ExclusiveContent;
|
|
605
|
+
|
|
606
|
+
/**
|
|
607
|
+
* Author-published point, with latitude before longitude.
|
|
608
|
+
*/
|
|
609
|
+
geo?: SearchTweet.Geo;
|
|
610
|
+
|
|
611
|
+
/**
|
|
612
|
+
* Public metadata whose fields are defined by X.
|
|
613
|
+
*/
|
|
614
|
+
grokShareAttachment?: { [key: string]: unknown };
|
|
615
|
+
|
|
616
|
+
/**
|
|
617
|
+
* Grok's translation of the post, as X shows it.
|
|
618
|
+
*/
|
|
619
|
+
grokTranslatedPost?: { [key: string]: unknown };
|
|
620
|
+
|
|
621
|
+
/**
|
|
622
|
+
* Whether X holds Community Notes on the post, shown or not.
|
|
623
|
+
*/
|
|
624
|
+
hasCommunityNotes?: boolean;
|
|
625
|
+
|
|
626
|
+
inReplyToId?: string;
|
|
627
|
+
|
|
628
|
+
inReplyToUserId?: string;
|
|
629
|
+
|
|
630
|
+
inReplyToUsername?: string;
|
|
631
|
+
|
|
632
|
+
/**
|
|
633
|
+
* The notice x.com covers the post with until the reader views it, such as X's
|
|
634
|
+
* public interest notice on a post that broke its rules but stays up.
|
|
635
|
+
*/
|
|
636
|
+
interstitial?: SearchTweet.Interstitial;
|
|
637
|
+
|
|
638
|
+
isLimitedReply?: boolean;
|
|
639
|
+
|
|
640
|
+
isNoteTweet?: boolean;
|
|
641
|
+
|
|
642
|
+
isPinned?: boolean;
|
|
643
|
+
|
|
644
|
+
isQuoteStatus?: boolean;
|
|
645
|
+
|
|
646
|
+
isReply?: boolean;
|
|
647
|
+
|
|
648
|
+
isRetweet?: boolean;
|
|
649
|
+
|
|
650
|
+
isTranslatable?: boolean;
|
|
651
|
+
|
|
652
|
+
/**
|
|
653
|
+
* Public metadata whose fields are defined by X.
|
|
654
|
+
*/
|
|
655
|
+
jetfuelAttachment?: { [key: string]: unknown };
|
|
656
|
+
|
|
657
|
+
lang?: string;
|
|
658
|
+
|
|
659
|
+
/**
|
|
660
|
+
* Public restrictions & prompts.
|
|
661
|
+
*/
|
|
662
|
+
limitedActions?: Array<SearchTweet.LimitedAction>;
|
|
663
|
+
|
|
664
|
+
/**
|
|
665
|
+
* Media, omitted when unavailable.
|
|
666
|
+
*/
|
|
667
|
+
media?: Array<TweetMedia>;
|
|
668
|
+
|
|
669
|
+
/**
|
|
670
|
+
* Complete Note Tweet content and rich-text metadata.
|
|
671
|
+
*/
|
|
672
|
+
noteTweet?: SearchTweet.NoteTweet;
|
|
673
|
+
|
|
674
|
+
/**
|
|
675
|
+
* The post this one replies to, with the same fields.
|
|
676
|
+
*/
|
|
677
|
+
parentTweet?: EmbeddedTweet;
|
|
678
|
+
|
|
679
|
+
/**
|
|
680
|
+
* Describes public place metadata on a geotagged tweet.
|
|
681
|
+
*/
|
|
682
|
+
place?: SearchTweet.Place;
|
|
683
|
+
|
|
684
|
+
possiblySensitive?: boolean;
|
|
685
|
+
|
|
686
|
+
/**
|
|
687
|
+
* Public metadata whose fields are defined by X.
|
|
688
|
+
*/
|
|
689
|
+
postCta?: { [key: string]: unknown };
|
|
690
|
+
|
|
691
|
+
/**
|
|
692
|
+
* Engagement counts retained from a prior tweet edit.
|
|
693
|
+
*/
|
|
694
|
+
previousCounts?: SearchTweet.PreviousCounts;
|
|
695
|
+
|
|
696
|
+
/**
|
|
697
|
+
* The post this one quotes, with the same fields.
|
|
698
|
+
*/
|
|
699
|
+
quoted_tweet?: EmbeddedTweet;
|
|
700
|
+
|
|
701
|
+
quotedTweetId?: string;
|
|
702
|
+
|
|
703
|
+
/**
|
|
704
|
+
* The quoted post's link, kept when X withholds that post.
|
|
705
|
+
*/
|
|
706
|
+
quotedTweetPermalink?: SearchTweet.QuotedTweetPermalink;
|
|
707
|
+
|
|
708
|
+
/**
|
|
709
|
+
* Why X shows no quoted post. Omitted when X names no reason, as its legacy
|
|
710
|
+
* answers never do.
|
|
711
|
+
*/
|
|
712
|
+
quotedTweetUnavailable?: SearchTweet.QuotedTweetUnavailable;
|
|
713
|
+
|
|
714
|
+
/**
|
|
715
|
+
* Public post & user this reaction references.
|
|
716
|
+
*/
|
|
717
|
+
reactionContext?: SearchTweet.ReactionContext;
|
|
718
|
+
|
|
719
|
+
/**
|
|
720
|
+
* The post this one reposts, with the same fields.
|
|
721
|
+
*/
|
|
722
|
+
retweeted_tweet?: EmbeddedTweet;
|
|
723
|
+
|
|
724
|
+
/**
|
|
725
|
+
* Repost event time in UTC. Null when unavailable. Omitted for other posts.
|
|
726
|
+
*/
|
|
727
|
+
retweetedAt?: string | null;
|
|
728
|
+
|
|
729
|
+
/**
|
|
730
|
+
* Public metadata whose fields are defined by X.
|
|
731
|
+
*/
|
|
732
|
+
scopes?: { [key: string]: unknown };
|
|
733
|
+
|
|
734
|
+
/**
|
|
735
|
+
* The label X shows under a post whose reach it limits. It links to the page that
|
|
736
|
+
* explains it.
|
|
737
|
+
*/
|
|
738
|
+
softIntervention?: SoftIntervention;
|
|
739
|
+
|
|
740
|
+
/**
|
|
741
|
+
* The app the post was sent from, as X labels it. X sends it for some posts only.
|
|
742
|
+
*/
|
|
743
|
+
source?: string;
|
|
744
|
+
|
|
745
|
+
/**
|
|
746
|
+
* Game metadata attached to this post.
|
|
747
|
+
*/
|
|
748
|
+
sportsContext?: SearchTweet.SportsContext;
|
|
749
|
+
|
|
750
|
+
/**
|
|
751
|
+
* The Subscriber badge X shows on a reply. The reply's author subscribes to the
|
|
752
|
+
* creator who started the conversation. Omitted on a post without the badge.
|
|
753
|
+
*/
|
|
754
|
+
subscriberBadge?: SearchTweet.SubscriberBadge;
|
|
755
|
+
|
|
756
|
+
/**
|
|
757
|
+
* Where `text` matches the search, on each row a search read. Offsets count code
|
|
758
|
+
* points of `text`, as `displayTextRange` does. Empty when X marks nothing in the
|
|
759
|
+
* post. X marks matches only in a post's first 280 characters.
|
|
760
|
+
*/
|
|
761
|
+
textHighlights?: Array<SearchTweet.TextHighlight>;
|
|
762
|
+
|
|
763
|
+
/**
|
|
764
|
+
* Public visibility notice attached to an available tweet.
|
|
765
|
+
*/
|
|
766
|
+
tombstone?: SearchTweet.Tombstone;
|
|
767
|
+
|
|
768
|
+
type?: string;
|
|
769
|
+
|
|
770
|
+
/**
|
|
771
|
+
* The author's ID when X withholds the author's profile.
|
|
772
|
+
*/
|
|
773
|
+
unavailableAuthorId?: string;
|
|
774
|
+
|
|
775
|
+
/**
|
|
776
|
+
* X did not send these counts, so each 0 means unknown.
|
|
777
|
+
*/
|
|
778
|
+
unknownCounts?: Array<
|
|
779
|
+
'retweetCount' | 'replyCount' | 'likeCount' | 'quoteCount' | 'viewCount' | 'bookmarkCount'
|
|
780
|
+
>;
|
|
781
|
+
|
|
782
|
+
/**
|
|
783
|
+
* User IDs that left this conversation.
|
|
784
|
+
*/
|
|
785
|
+
unmentionedUserIds?: Array<string>;
|
|
786
|
+
|
|
787
|
+
url?: string;
|
|
788
|
+
|
|
789
|
+
viewState?: string;
|
|
790
|
+
|
|
791
|
+
[k: string]: unknown;
|
|
792
|
+
}
|
|
793
|
+
|
|
794
|
+
/**
|
|
795
|
+
* Error response. Default v1 returns a legacy string code. Send
|
|
796
|
+
* `xquik-api-contract: 2026-04-29` for the structured best-practice error object.
|
|
797
|
+
*/
|
|
798
|
+
export interface Error {
|
|
799
|
+
error: Error.Code | Error.StructuredError;
|
|
800
|
+
|
|
801
|
+
/**
|
|
802
|
+
* With unknown_field: the valid names where the first unknown name in fields or
|
|
803
|
+
* omit stopped.
|
|
804
|
+
*/
|
|
805
|
+
allowedFields?: Array<string>;
|
|
806
|
+
|
|
807
|
+
/**
|
|
808
|
+
* With unknown_field: each unknown name in fields or omit, with the name it most
|
|
809
|
+
* likely meant.
|
|
810
|
+
*/
|
|
811
|
+
fieldErrors?: Array<Error.FieldError>;
|
|
812
|
+
|
|
813
|
+
/**
|
|
814
|
+
* Human-readable error guidance.
|
|
815
|
+
*/
|
|
816
|
+
message?: string;
|
|
359
817
|
|
|
360
|
-
|
|
818
|
+
/**
|
|
819
|
+
* Machine-readable reason. A login failure names its cause, such as
|
|
820
|
+
* temporary_issue. A user_not_found answer names why X shows no profile: not_found
|
|
821
|
+
* or suspended. A tweet_not_found answer names why X shows no post, when X said:
|
|
822
|
+
* deleted, author_suspended or protected.
|
|
823
|
+
*/
|
|
824
|
+
reason?: string;
|
|
361
825
|
|
|
362
826
|
/**
|
|
363
|
-
*
|
|
827
|
+
* Seconds until the next permitted request.
|
|
364
828
|
*/
|
|
365
|
-
|
|
829
|
+
retryAfter?: number;
|
|
366
830
|
|
|
367
|
-
|
|
831
|
+
/**
|
|
832
|
+
* Required wait in milliseconds.
|
|
833
|
+
*/
|
|
834
|
+
retryAfterMs?: number;
|
|
368
835
|
}
|
|
369
836
|
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
* `xquik-api-contract: 2026-04-29` for the structured best-practice error object.
|
|
373
|
-
*/
|
|
374
|
-
export interface Error {
|
|
375
|
-
error:
|
|
837
|
+
export namespace Error {
|
|
838
|
+
export type Code =
|
|
376
839
|
| 'internal_error'
|
|
377
840
|
| 'account_already_connected'
|
|
378
841
|
| 'account_needs_reauth'
|
|
@@ -413,6 +876,7 @@ export interface Error {
|
|
|
413
876
|
| 'payment_failed'
|
|
414
877
|
| 'rate_limit_exceeded'
|
|
415
878
|
| 'service_unavailable'
|
|
879
|
+
| 'session_required'
|
|
416
880
|
| 'style_not_found'
|
|
417
881
|
| 'subscription_inactive'
|
|
418
882
|
| 'tweet_not_found'
|
|
@@ -425,6 +889,7 @@ export interface Error {
|
|
|
425
889
|
| 'checkout_unavailable'
|
|
426
890
|
| 'connection_challenge_expired'
|
|
427
891
|
| 'connection_challenge_inactive'
|
|
892
|
+
| 'contributor_not_found'
|
|
428
893
|
| 'coverage_cursor_gone'
|
|
429
894
|
| 'coverage_cursor_unavailable'
|
|
430
895
|
| 'cursor_account_unavailable'
|
|
@@ -443,6 +908,7 @@ export interface Error {
|
|
|
443
908
|
| 'invalid_community_id'
|
|
444
909
|
| 'invalid_community_topic'
|
|
445
910
|
| 'invalid_complete_replies_request'
|
|
911
|
+
| 'invalid_contributor_alias'
|
|
446
912
|
| 'invalid_coverage_cursor'
|
|
447
913
|
| 'invalid_coverage_request'
|
|
448
914
|
| 'invalid_cursor'
|
|
@@ -450,6 +916,7 @@ export interface Error {
|
|
|
450
916
|
| 'invalid_job_filter'
|
|
451
917
|
| 'invalid_job_id'
|
|
452
918
|
| 'invalid_list_id'
|
|
919
|
+
| 'invalid_news_id'
|
|
453
920
|
| 'invalid_output_options'
|
|
454
921
|
| 'invalid_payment_amount'
|
|
455
922
|
| 'invalid_range'
|
|
@@ -462,6 +929,7 @@ export interface Error {
|
|
|
462
929
|
| 'missing_idempotency_key'
|
|
463
930
|
| 'missing_ids'
|
|
464
931
|
| 'missing_url'
|
|
932
|
+
| 'news_not_found'
|
|
465
933
|
| 'no_cached_style'
|
|
466
934
|
| 'pagination_stalled'
|
|
467
935
|
| 'passkey_required'
|
|
@@ -479,6 +947,7 @@ export interface Error {
|
|
|
479
947
|
| 'too_many_ids'
|
|
480
948
|
| 'too_many_streams'
|
|
481
949
|
| 'too_many_tweets'
|
|
950
|
+
| 'topup_in_progress'
|
|
482
951
|
| 'unknown_field'
|
|
483
952
|
| 'unsupported_media_combination'
|
|
484
953
|
| 'unsupported_media_type'
|
|
@@ -520,198 +989,12 @@ export interface Error {
|
|
|
520
989
|
| 'x_target_not_found'
|
|
521
990
|
| 'x_transient_error'
|
|
522
991
|
| 'x_user_lookup_failed'
|
|
992
|
+
| 'x_video_too_large'
|
|
523
993
|
| 'x_write_ambiguous'
|
|
524
|
-
| 'x_write_failed'
|
|
525
|
-
| Error.StructuredError;
|
|
526
|
-
|
|
527
|
-
/**
|
|
528
|
-
* With unknown_field: the valid names where the first unknown name in fields or
|
|
529
|
-
* omit stopped.
|
|
530
|
-
*/
|
|
531
|
-
allowedFields?: Array<string>;
|
|
532
|
-
|
|
533
|
-
/**
|
|
534
|
-
* With unknown_field: each unknown name in fields or omit, with the name it most
|
|
535
|
-
* likely meant.
|
|
536
|
-
*/
|
|
537
|
-
fieldErrors?: Array<Error.FieldError>;
|
|
538
|
-
|
|
539
|
-
/**
|
|
540
|
-
* Human-readable error guidance.
|
|
541
|
-
*/
|
|
542
|
-
message?: string;
|
|
543
|
-
|
|
544
|
-
/**
|
|
545
|
-
* Machine-readable reason. A login failure names its cause, such as
|
|
546
|
-
* temporary_issue. A user_not_found answer names why X shows no profile: not_found
|
|
547
|
-
* or suspended. A tweet_not_found answer names why X shows no post, when X said:
|
|
548
|
-
* deleted, author_suspended or protected.
|
|
549
|
-
*/
|
|
550
|
-
reason?: string;
|
|
551
|
-
|
|
552
|
-
/**
|
|
553
|
-
* Seconds until the next permitted request.
|
|
554
|
-
*/
|
|
555
|
-
retryAfter?: number;
|
|
556
|
-
|
|
557
|
-
/**
|
|
558
|
-
* Required wait in milliseconds.
|
|
559
|
-
*/
|
|
560
|
-
retryAfterMs?: number;
|
|
561
|
-
}
|
|
994
|
+
| 'x_write_failed';
|
|
562
995
|
|
|
563
|
-
export namespace Error {
|
|
564
996
|
export interface StructuredError {
|
|
565
|
-
code:
|
|
566
|
-
| 'internal_error'
|
|
567
|
-
| 'account_already_connected'
|
|
568
|
-
| 'account_needs_reauth'
|
|
569
|
-
| 'account_not_found'
|
|
570
|
-
| 'account_required'
|
|
571
|
-
| 'account_restricted'
|
|
572
|
-
| 'api_key_limit_reached'
|
|
573
|
-
| 'article_not_found'
|
|
574
|
-
| 'closed'
|
|
575
|
-
| 'dm_not_permitted'
|
|
576
|
-
| 'invalid_format'
|
|
577
|
-
| 'invalid_id'
|
|
578
|
-
| 'invalid_input'
|
|
579
|
-
| 'invalid_media_url'
|
|
580
|
-
| 'invalid_message_id'
|
|
581
|
-
| 'invalid_params'
|
|
582
|
-
| 'invalid_tool_type'
|
|
583
|
-
| 'invalid_tweet_id'
|
|
584
|
-
| 'invalid_tweet_url'
|
|
585
|
-
| 'invalid_user_id'
|
|
586
|
-
| 'invalid_user_ids'
|
|
587
|
-
| 'invalid_username'
|
|
588
|
-
| 'invalid_json'
|
|
589
|
-
| 'insufficient_credits'
|
|
590
|
-
| 'job_not_found'
|
|
591
|
-
| 'login_cooldown'
|
|
592
|
-
| 'login_failed'
|
|
593
|
-
| 'media_download_failed'
|
|
594
|
-
| 'media_too_large'
|
|
595
|
-
| 'missing_params'
|
|
596
|
-
| 'missing_query'
|
|
597
|
-
| 'monitor_already_exists'
|
|
598
|
-
| 'monitor_profile_unavailable'
|
|
599
|
-
| 'no_media'
|
|
600
|
-
| 'no_credits'
|
|
601
|
-
| 'no_subscription'
|
|
602
|
-
| 'not_found'
|
|
603
|
-
| 'payment_failed'
|
|
604
|
-
| 'rate_limit_exceeded'
|
|
605
|
-
| 'service_unavailable'
|
|
606
|
-
| 'style_not_found'
|
|
607
|
-
| 'subscription_inactive'
|
|
608
|
-
| 'tweet_not_found'
|
|
609
|
-
| 'unauthenticated'
|
|
610
|
-
| 'unsupported_field'
|
|
611
|
-
| 'user_not_found'
|
|
612
|
-
| 'body_too_large'
|
|
613
|
-
| 'bookmark_folders_unavailable'
|
|
614
|
-
| 'broadcast_not_found'
|
|
615
|
-
| 'checkout_unavailable'
|
|
616
|
-
| 'connection_challenge_expired'
|
|
617
|
-
| 'connection_challenge_inactive'
|
|
618
|
-
| 'coverage_cursor_gone'
|
|
619
|
-
| 'coverage_cursor_unavailable'
|
|
620
|
-
| 'cursor_account_unavailable'
|
|
621
|
-
| 'draft_not_found'
|
|
622
|
-
| 'draw_too_large'
|
|
623
|
-
| 'expired'
|
|
624
|
-
| 'favoriters_unavailable'
|
|
625
|
-
| 'forbidden'
|
|
626
|
-
| 'guest_wallet_unavailable'
|
|
627
|
-
| 'guest_wallets_disabled'
|
|
628
|
-
| 'guest_wallets_unavailable'
|
|
629
|
-
| 'idempotency_conflict'
|
|
630
|
-
| 'idempotency_in_progress'
|
|
631
|
-
| 'idempotency_key_conflict'
|
|
632
|
-
| 'invalid_broadcast_id'
|
|
633
|
-
| 'invalid_community_id'
|
|
634
|
-
| 'invalid_community_topic'
|
|
635
|
-
| 'invalid_complete_replies_request'
|
|
636
|
-
| 'invalid_coverage_cursor'
|
|
637
|
-
| 'invalid_coverage_request'
|
|
638
|
-
| 'invalid_cursor'
|
|
639
|
-
| 'invalid_idempotency_key'
|
|
640
|
-
| 'invalid_job_filter'
|
|
641
|
-
| 'invalid_job_id'
|
|
642
|
-
| 'invalid_list_id'
|
|
643
|
-
| 'invalid_output_options'
|
|
644
|
-
| 'invalid_payment_amount'
|
|
645
|
-
| 'invalid_range'
|
|
646
|
-
| 'invalid_reply_options'
|
|
647
|
-
| 'invalid_space_id'
|
|
648
|
-
| 'likes_unavailable'
|
|
649
|
-
| 'list_not_found'
|
|
650
|
-
| 'login_rate_limited'
|
|
651
|
-
| 'login_service_unavailable'
|
|
652
|
-
| 'missing_idempotency_key'
|
|
653
|
-
| 'missing_ids'
|
|
654
|
-
| 'missing_url'
|
|
655
|
-
| 'no_cached_style'
|
|
656
|
-
| 'pagination_stalled'
|
|
657
|
-
| 'passkey_required'
|
|
658
|
-
| 'rate_limited'
|
|
659
|
-
| 'read_request_timeout'
|
|
660
|
-
| 'replay_unavailable'
|
|
661
|
-
| 'replies_incomplete'
|
|
662
|
-
| 'retweeters_incomplete'
|
|
663
|
-
| 'search_unavailable'
|
|
664
|
-
| 'space_canceled'
|
|
665
|
-
| 'space_not_ended'
|
|
666
|
-
| 'support_media_rate_limit'
|
|
667
|
-
| 'support_request_rate_limit'
|
|
668
|
-
| 'telegram_unavailable'
|
|
669
|
-
| 'too_many_ids'
|
|
670
|
-
| 'too_many_streams'
|
|
671
|
-
| 'too_many_tweets'
|
|
672
|
-
| 'unknown_field'
|
|
673
|
-
| 'unsupported_media_combination'
|
|
674
|
-
| 'unsupported_media_type'
|
|
675
|
-
| 'webhook_inactive'
|
|
676
|
-
| 'write_tracking_unavailable'
|
|
677
|
-
| 'x_write_unconfirmed'
|
|
678
|
-
| 'x_account_feature_required'
|
|
679
|
-
| 'x_account_protected'
|
|
680
|
-
| 'x_account_suspended'
|
|
681
|
-
| 'x_api_rate_limited'
|
|
682
|
-
| 'x_api_unavailable'
|
|
683
|
-
| 'x_api_unauthorized'
|
|
684
|
-
| 'x_auth_failure'
|
|
685
|
-
| 'x_automation_refused'
|
|
686
|
-
| 'x_community_not_joined'
|
|
687
|
-
| 'x_community_not_selectable'
|
|
688
|
-
| 'x_community_post_public'
|
|
689
|
-
| 'x_community_post_removed'
|
|
690
|
-
| 'x_content_too_long'
|
|
691
|
-
| 'x_daily_limit'
|
|
692
|
-
| 'x_dm_not_allowed'
|
|
693
|
-
| 'x_dm_not_deleted'
|
|
694
|
-
| 'x_dm_not_sent'
|
|
695
|
-
| 'x_duplicate_action'
|
|
696
|
-
| 'x_login_auth_failed'
|
|
697
|
-
| 'x_login_challenge'
|
|
698
|
-
| 'x_login_denied'
|
|
699
|
-
| 'x_login_failed'
|
|
700
|
-
| 'x_login_rate_limited'
|
|
701
|
-
| 'x_login_service_unavailable'
|
|
702
|
-
| 'x_login_suspended'
|
|
703
|
-
| 'x_image_invalid'
|
|
704
|
-
| 'x_media_rejected'
|
|
705
|
-
| 'x_post_not_sent'
|
|
706
|
-
| 'x_rate_limited'
|
|
707
|
-
| 'x_rejected'
|
|
708
|
-
| 'x_reply_not_allowed'
|
|
709
|
-
| 'x_reply_target_unavailable'
|
|
710
|
-
| 'x_target_not_found'
|
|
711
|
-
| 'x_transient_error'
|
|
712
|
-
| 'x_user_lookup_failed'
|
|
713
|
-
| 'x_write_ambiguous'
|
|
714
|
-
| 'x_write_failed';
|
|
997
|
+
code: Code;
|
|
715
998
|
|
|
716
999
|
message: string;
|
|
717
1000
|
|
|
@@ -832,6 +1115,18 @@ export interface MonitorFollow {
|
|
|
832
1115
|
[k: string]: unknown;
|
|
833
1116
|
}
|
|
834
1117
|
|
|
1118
|
+
/**
|
|
1119
|
+
* 1 page of public X Lists. Follow next_cursor while the response reports more
|
|
1120
|
+
* pages. Each returned List costs 1 credit.
|
|
1121
|
+
*/
|
|
1122
|
+
export interface PaginatedLists {
|
|
1123
|
+
has_next_page: boolean;
|
|
1124
|
+
|
|
1125
|
+
lists: Array<XList>;
|
|
1126
|
+
|
|
1127
|
+
next_cursor: string;
|
|
1128
|
+
}
|
|
1129
|
+
|
|
835
1130
|
/**
|
|
836
1131
|
* Follow next_cursor while the response reports more pages. A page can hold fewer
|
|
837
1132
|
* rows than its limit & still report more. That report decides, not the row count.
|
|
@@ -909,6 +1204,21 @@ export namespace PaginatedTweets {
|
|
|
909
1204
|
}
|
|
910
1205
|
}
|
|
911
1206
|
|
|
1207
|
+
/**
|
|
1208
|
+
* A page of user IDs without profiles. Follow next_cursor while the response
|
|
1209
|
+
* reports more pages.
|
|
1210
|
+
*/
|
|
1211
|
+
export interface PaginatedUserIds {
|
|
1212
|
+
has_next_page: boolean;
|
|
1213
|
+
|
|
1214
|
+
/**
|
|
1215
|
+
* X user IDs, newest relationship first.
|
|
1216
|
+
*/
|
|
1217
|
+
ids: Array<string>;
|
|
1218
|
+
|
|
1219
|
+
next_cursor: string;
|
|
1220
|
+
}
|
|
1221
|
+
|
|
912
1222
|
/**
|
|
913
1223
|
* Profile coverage preserves shape, billing, aliases, and filters. Follow
|
|
914
1224
|
* next_cursor while the response reports more pages. Unprefixed cursors remain
|
|
@@ -1160,6 +1470,12 @@ export interface SearchTweet {
|
|
|
1160
1470
|
*/
|
|
1161
1471
|
scopes?: { [key: string]: unknown };
|
|
1162
1472
|
|
|
1473
|
+
/**
|
|
1474
|
+
* The label X shows under a post whose reach it limits. It links to the page that
|
|
1475
|
+
* explains it.
|
|
1476
|
+
*/
|
|
1477
|
+
softIntervention?: SoftIntervention;
|
|
1478
|
+
|
|
1163
1479
|
/**
|
|
1164
1480
|
* The app the post was sent from, as X labels it. X sends it for some posts only.
|
|
1165
1481
|
*/
|
|
@@ -1195,6 +1511,13 @@ export interface SearchTweet {
|
|
|
1195
1511
|
*/
|
|
1196
1512
|
unavailableAuthorId?: string;
|
|
1197
1513
|
|
|
1514
|
+
/**
|
|
1515
|
+
* X did not send these counts, so each 0 means unknown.
|
|
1516
|
+
*/
|
|
1517
|
+
unknownCounts?: Array<
|
|
1518
|
+
'retweetCount' | 'replyCount' | 'likeCount' | 'quoteCount' | 'viewCount' | 'bookmarkCount'
|
|
1519
|
+
>;
|
|
1520
|
+
|
|
1198
1521
|
/**
|
|
1199
1522
|
* User IDs that left this conversation.
|
|
1200
1523
|
*/
|
|
@@ -2322,6 +2645,87 @@ export namespace SearchTweet {
|
|
|
2322
2645
|
}
|
|
2323
2646
|
}
|
|
2324
2647
|
|
|
2648
|
+
/**
|
|
2649
|
+
* The label X shows under a post whose reach it limits. It links to the page that
|
|
2650
|
+
* explains it.
|
|
2651
|
+
*/
|
|
2652
|
+
export interface SoftIntervention {
|
|
2653
|
+
/**
|
|
2654
|
+
* The label's kind. `Fosnr` marks a post X keeps up but shows to fewer people.
|
|
2655
|
+
*/
|
|
2656
|
+
displayType?: string;
|
|
2657
|
+
|
|
2658
|
+
/**
|
|
2659
|
+
* Whether X prompts readers before they engage with the post.
|
|
2660
|
+
*/
|
|
2661
|
+
engagementNudge?: boolean;
|
|
2662
|
+
|
|
2663
|
+
text?: SoftIntervention.Text;
|
|
2664
|
+
|
|
2665
|
+
/**
|
|
2666
|
+
* The page that explains the label.
|
|
2667
|
+
*/
|
|
2668
|
+
url?: SoftIntervention.URL;
|
|
2669
|
+
}
|
|
2670
|
+
|
|
2671
|
+
export namespace SoftIntervention {
|
|
2672
|
+
export interface Text {
|
|
2673
|
+
/**
|
|
2674
|
+
* Links inside the label, by character range.
|
|
2675
|
+
*/
|
|
2676
|
+
entities?: Array<Text.Entity>;
|
|
2677
|
+
|
|
2678
|
+
/**
|
|
2679
|
+
* Whether the label reads right to left.
|
|
2680
|
+
*/
|
|
2681
|
+
rtl?: boolean;
|
|
2682
|
+
|
|
2683
|
+
/**
|
|
2684
|
+
* The label's text.
|
|
2685
|
+
*/
|
|
2686
|
+
text?: string;
|
|
2687
|
+
}
|
|
2688
|
+
|
|
2689
|
+
export namespace Text {
|
|
2690
|
+
export interface Entity {
|
|
2691
|
+
/**
|
|
2692
|
+
* Position in the label's text where the entity starts, counted from 0.
|
|
2693
|
+
*/
|
|
2694
|
+
fromIndex?: number;
|
|
2695
|
+
|
|
2696
|
+
ref?: Entity.Ref;
|
|
2697
|
+
|
|
2698
|
+
/**
|
|
2699
|
+
* Position in the label's text where the entity ends, counted from 0.
|
|
2700
|
+
*/
|
|
2701
|
+
toIndex?: number;
|
|
2702
|
+
}
|
|
2703
|
+
|
|
2704
|
+
export namespace Entity {
|
|
2705
|
+
export interface Ref {
|
|
2706
|
+
screenName?: string;
|
|
2707
|
+
|
|
2708
|
+
text?: string;
|
|
2709
|
+
|
|
2710
|
+
type?: string;
|
|
2711
|
+
|
|
2712
|
+
url?: string;
|
|
2713
|
+
|
|
2714
|
+
urlType?: string;
|
|
2715
|
+
}
|
|
2716
|
+
}
|
|
2717
|
+
}
|
|
2718
|
+
|
|
2719
|
+
/**
|
|
2720
|
+
* The page that explains the label.
|
|
2721
|
+
*/
|
|
2722
|
+
export interface URL {
|
|
2723
|
+
url?: string;
|
|
2724
|
+
|
|
2725
|
+
urlType?: string;
|
|
2726
|
+
}
|
|
2727
|
+
}
|
|
2728
|
+
|
|
2325
2729
|
/**
|
|
2326
2730
|
* Tweet media.
|
|
2327
2731
|
*/
|
|
@@ -3084,6 +3488,11 @@ export namespace UserProfile {
|
|
|
3084
3488
|
*/
|
|
3085
3489
|
isIdentityVerified?: boolean;
|
|
3086
3490
|
|
|
3491
|
+
/**
|
|
3492
|
+
* The year X shows as the start of verification, in place of verifiedSinceMsec.
|
|
3493
|
+
*/
|
|
3494
|
+
overrideVerifiedYear?: number;
|
|
3495
|
+
|
|
3087
3496
|
/**
|
|
3088
3497
|
* When X verified the account, in milliseconds since 1970, as text.
|
|
3089
3498
|
*/
|
|
@@ -3158,3 +3567,167 @@ export namespace UserProfile {
|
|
|
3158
3567
|
}
|
|
3159
3568
|
}
|
|
3160
3569
|
}
|
|
3570
|
+
|
|
3571
|
+
/**
|
|
3572
|
+
* Public X List with its owner's public profile. Leaves out what X tells the
|
|
3573
|
+
* reading account, such as whether it follows the List.
|
|
3574
|
+
*/
|
|
3575
|
+
export interface XList {
|
|
3576
|
+
/**
|
|
3577
|
+
* Numeric ID of the List.
|
|
3578
|
+
*/
|
|
3579
|
+
id: string;
|
|
3580
|
+
|
|
3581
|
+
/**
|
|
3582
|
+
* Name the owner gave the List.
|
|
3583
|
+
*/
|
|
3584
|
+
name: string;
|
|
3585
|
+
|
|
3586
|
+
/**
|
|
3587
|
+
* URL of the banner the owner uploaded. Absent when the owner uploaded none.
|
|
3588
|
+
*/
|
|
3589
|
+
bannerUrl?: string;
|
|
3590
|
+
|
|
3591
|
+
/**
|
|
3592
|
+
* When the owner made the List.
|
|
3593
|
+
*/
|
|
3594
|
+
createdAt?: string;
|
|
3595
|
+
|
|
3596
|
+
/**
|
|
3597
|
+
* Banner the owner uploaded.
|
|
3598
|
+
*/
|
|
3599
|
+
customBanner?: XListBanner;
|
|
3600
|
+
|
|
3601
|
+
/**
|
|
3602
|
+
* Banner X shows when the owner uploaded none. X picks it per reading account, so
|
|
3603
|
+
* 2 calls can return different ones.
|
|
3604
|
+
*/
|
|
3605
|
+
defaultBanner?: XListBanner;
|
|
3606
|
+
|
|
3607
|
+
/**
|
|
3608
|
+
* About text of the List. Empty when the owner wrote none.
|
|
3609
|
+
*/
|
|
3610
|
+
description?: string;
|
|
3611
|
+
|
|
3612
|
+
/**
|
|
3613
|
+
* Avatar URLs of a few List members, which X may pick per request.
|
|
3614
|
+
*/
|
|
3615
|
+
facepileUrls?: Array<string>;
|
|
3616
|
+
|
|
3617
|
+
/**
|
|
3618
|
+
* Accounts on the List.
|
|
3619
|
+
*/
|
|
3620
|
+
memberCount?: number;
|
|
3621
|
+
|
|
3622
|
+
/**
|
|
3623
|
+
* Member count as X words it, such as 35 members.
|
|
3624
|
+
*/
|
|
3625
|
+
membersContext?: string;
|
|
3626
|
+
|
|
3627
|
+
/**
|
|
3628
|
+
* Public profile of the account that owns the List.
|
|
3629
|
+
*/
|
|
3630
|
+
owner?: UserProfile;
|
|
3631
|
+
|
|
3632
|
+
/**
|
|
3633
|
+
* Accounts that follow the List, which X calls followers.
|
|
3634
|
+
*/
|
|
3635
|
+
subscriberCount?: number;
|
|
3636
|
+
|
|
3637
|
+
/**
|
|
3638
|
+
* List page on x.com.
|
|
3639
|
+
*/
|
|
3640
|
+
url?: string;
|
|
3641
|
+
}
|
|
3642
|
+
|
|
3643
|
+
/**
|
|
3644
|
+
* Banner image of an X List.
|
|
3645
|
+
*/
|
|
3646
|
+
export interface XListBanner {
|
|
3647
|
+
/**
|
|
3648
|
+
* Banner image URL.
|
|
3649
|
+
*/
|
|
3650
|
+
url: string;
|
|
3651
|
+
|
|
3652
|
+
/**
|
|
3653
|
+
* Banner height in pixels.
|
|
3654
|
+
*/
|
|
3655
|
+
height?: number;
|
|
3656
|
+
|
|
3657
|
+
/**
|
|
3658
|
+
* Media ID of an uploaded banner.
|
|
3659
|
+
*/
|
|
3660
|
+
mediaId?: string;
|
|
3661
|
+
|
|
3662
|
+
/**
|
|
3663
|
+
* Stable media key of an uploaded banner.
|
|
3664
|
+
*/
|
|
3665
|
+
mediaKey?: string;
|
|
3666
|
+
|
|
3667
|
+
/**
|
|
3668
|
+
* Dominant colors of an uploaded banner and their shares.
|
|
3669
|
+
*/
|
|
3670
|
+
palette?: Array<XListBanner.Palette>;
|
|
3671
|
+
|
|
3672
|
+
/**
|
|
3673
|
+
* Area X marks as the subject of the banner, in pixels.
|
|
3674
|
+
*/
|
|
3675
|
+
salientRect?: XListBanner.SalientRect;
|
|
3676
|
+
|
|
3677
|
+
/**
|
|
3678
|
+
* Banner width in pixels.
|
|
3679
|
+
*/
|
|
3680
|
+
width?: number;
|
|
3681
|
+
}
|
|
3682
|
+
|
|
3683
|
+
export namespace XListBanner {
|
|
3684
|
+
export interface Palette {
|
|
3685
|
+
/**
|
|
3686
|
+
* Share of the banner, from 0 to 100.
|
|
3687
|
+
*/
|
|
3688
|
+
percentage?: number;
|
|
3689
|
+
|
|
3690
|
+
/**
|
|
3691
|
+
* The color's red, green and blue values.
|
|
3692
|
+
*/
|
|
3693
|
+
rgb?: Palette.Rgb;
|
|
3694
|
+
}
|
|
3695
|
+
|
|
3696
|
+
export namespace Palette {
|
|
3697
|
+
/**
|
|
3698
|
+
* The color's red, green and blue values.
|
|
3699
|
+
*/
|
|
3700
|
+
export interface Rgb {
|
|
3701
|
+
blue?: number;
|
|
3702
|
+
|
|
3703
|
+
green?: number;
|
|
3704
|
+
|
|
3705
|
+
red?: number;
|
|
3706
|
+
}
|
|
3707
|
+
}
|
|
3708
|
+
|
|
3709
|
+
/**
|
|
3710
|
+
* Area X marks as the subject of the banner, in pixels.
|
|
3711
|
+
*/
|
|
3712
|
+
export interface SalientRect {
|
|
3713
|
+
/**
|
|
3714
|
+
* Height of the marked area.
|
|
3715
|
+
*/
|
|
3716
|
+
height?: number;
|
|
3717
|
+
|
|
3718
|
+
/**
|
|
3719
|
+
* Pixels from the banner's left.
|
|
3720
|
+
*/
|
|
3721
|
+
left?: number;
|
|
3722
|
+
|
|
3723
|
+
/**
|
|
3724
|
+
* Pixels from the banner's top.
|
|
3725
|
+
*/
|
|
3726
|
+
top?: number;
|
|
3727
|
+
|
|
3728
|
+
/**
|
|
3729
|
+
* Width of the marked area.
|
|
3730
|
+
*/
|
|
3731
|
+
width?: number;
|
|
3732
|
+
}
|
|
3733
|
+
}
|