x-twitter-scraper 0.6.1 → 0.8.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 +38 -0
- package/README.md +6 -0
- package/package.json +1 -1
- package/resources/compose.d.mts +23 -4
- package/resources/compose.d.mts.map +1 -1
- package/resources/compose.d.ts +23 -4
- package/resources/compose.d.ts.map +1 -1
- package/resources/compose.js +4 -4
- package/resources/compose.mjs +4 -4
- package/resources/radar.d.mts +72 -5
- package/resources/radar.d.mts.map +1 -1
- package/resources/radar.d.ts +72 -5
- package/resources/radar.d.ts.map +1 -1
- package/resources/shared.d.mts +382 -15
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +382 -15
- package/resources/shared.d.ts.map +1 -1
- package/resources/support/tickets.d.mts +19 -19
- package/resources/support/tickets.d.mts.map +1 -1
- package/resources/support/tickets.d.ts +19 -19
- package/resources/support/tickets.d.ts.map +1 -1
- package/resources/trends.d.mts +12 -0
- package/resources/trends.d.mts.map +1 -1
- package/resources/trends.d.ts +12 -0
- package/resources/trends.d.ts.map +1 -1
- package/resources/x/account-connection-attempts.d.mts +70 -0
- package/resources/x/account-connection-attempts.d.mts.map +1 -0
- package/resources/x/account-connection-attempts.d.ts +70 -0
- package/resources/x/account-connection-attempts.d.ts.map +1 -0
- package/resources/x/account-connection-attempts.js +27 -0
- package/resources/x/account-connection-attempts.js.map +1 -0
- package/resources/x/account-connection-attempts.mjs +23 -0
- package/resources/x/account-connection-attempts.mjs.map +1 -0
- package/resources/x/account-connection-challenges.d.mts +1 -1
- package/resources/x/account-connection-challenges.d.mts.map +1 -1
- package/resources/x/account-connection-challenges.d.ts +1 -1
- package/resources/x/account-connection-challenges.d.ts.map +1 -1
- package/resources/x/accounts.d.mts +45 -18
- package/resources/x/accounts.d.mts.map +1 -1
- package/resources/x/accounts.d.ts +45 -18
- package/resources/x/accounts.d.ts.map +1 -1
- package/resources/x/accounts.js +1 -1
- package/resources/x/accounts.mjs +1 -1
- package/resources/x/communities/communities.d.mts +2 -12
- package/resources/x/communities/communities.d.mts.map +1 -1
- package/resources/x/communities/communities.d.ts +2 -12
- package/resources/x/communities/communities.d.ts.map +1 -1
- package/resources/x/communities/communities.js.map +1 -1
- package/resources/x/communities/communities.mjs.map +1 -1
- package/resources/x/communities/tweets.d.mts +4 -8
- package/resources/x/communities/tweets.d.mts.map +1 -1
- package/resources/x/communities/tweets.d.ts +4 -8
- package/resources/x/communities/tweets.d.ts.map +1 -1
- package/resources/x/index.d.mts +2 -1
- package/resources/x/index.d.mts.map +1 -1
- package/resources/x/index.d.ts +2 -1
- 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/lists.d.mts +2 -4
- package/resources/x/lists.d.mts.map +1 -1
- package/resources/x/lists.d.ts +2 -4
- package/resources/x/lists.d.ts.map +1 -1
- package/resources/x/tweets/index.d.mts +1 -1
- package/resources/x/tweets/index.d.mts.map +1 -1
- package/resources/x/tweets/index.d.ts +1 -1
- package/resources/x/tweets/index.d.ts.map +1 -1
- package/resources/x/tweets/index.js.map +1 -1
- package/resources/x/tweets/index.mjs.map +1 -1
- package/resources/x/tweets/tweets.d.mts +301 -22
- package/resources/x/tweets/tweets.d.mts.map +1 -1
- package/resources/x/tweets/tweets.d.ts +301 -22
- package/resources/x/tweets/tweets.d.ts.map +1 -1
- package/resources/x/tweets/tweets.js +5 -8
- package/resources/x/tweets/tweets.js.map +1 -1
- package/resources/x/tweets/tweets.mjs +5 -8
- package/resources/x/tweets/tweets.mjs.map +1 -1
- package/resources/x/users/users.d.mts +10 -20
- package/resources/x/users/users.d.mts.map +1 -1
- package/resources/x/users/users.d.ts +10 -20
- 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 +18 -3
- package/resources/x/x.d.mts.map +1 -1
- package/resources/x/x.d.ts +18 -3
- 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/SKILL.md +8 -4
- package/skills/x-twitter-scraper/metadata.json +1 -1
- package/skills/x-twitter-scraper/references/mcp-setup.md +12 -5
- package/skills/x-twitter-scraper/references/mcp-tools.md +7 -1
- package/skills/x-twitter-scraper/references/types-x-api.md +62 -12
- package/skills/x-twitter-scraper/skill-card.md +2 -2
- package/skills/x-twitter-scraper/skillspector-report.md +4 -1
- package/src/resources/compose.ts +28 -4
- package/src/resources/radar.ts +83 -3
- package/src/resources/shared.ts +514 -16
- package/src/resources/support/tickets.ts +19 -19
- package/src/resources/trends.ts +15 -0
- package/src/resources/x/account-connection-attempts.ts +100 -0
- package/src/resources/x/account-connection-challenges.ts +1 -1
- package/src/resources/x/accounts.ts +59 -18
- package/src/resources/x/communities/communities.ts +2 -14
- package/src/resources/x/communities/tweets.ts +4 -8
- package/src/resources/x/index.ts +5 -0
- package/src/resources/x/lists.ts +2 -4
- package/src/resources/x/tweets/index.ts +1 -0
- package/src/resources/x/tweets/tweets.ts +393 -22
- package/src/resources/x/users/users.ts +10 -20
- package/src/resources/x/x.ts +30 -2
- 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
|
@@ -76,19 +76,19 @@ export declare namespace TicketCreateResponse {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
export interface TicketRetrieveResponse {
|
|
79
|
-
createdAt
|
|
80
|
-
messages
|
|
81
|
-
publicId
|
|
82
|
-
status
|
|
83
|
-
subject
|
|
84
|
-
updatedAt
|
|
79
|
+
createdAt: string;
|
|
80
|
+
messages: Array<TicketRetrieveResponse.Message>;
|
|
81
|
+
publicId: string;
|
|
82
|
+
status: 'open' | 'in_progress' | 'resolved' | 'closed';
|
|
83
|
+
subject: string;
|
|
84
|
+
updatedAt: string;
|
|
85
85
|
}
|
|
86
86
|
export declare namespace TicketRetrieveResponse {
|
|
87
87
|
interface Message {
|
|
88
|
-
attachments
|
|
89
|
-
body
|
|
90
|
-
createdAt
|
|
91
|
-
sender
|
|
88
|
+
attachments: Array<Message.Attachment>;
|
|
89
|
+
body: string;
|
|
90
|
+
createdAt: string;
|
|
91
|
+
sender: 'user' | 'support' | 'system';
|
|
92
92
|
}
|
|
93
93
|
namespace Message {
|
|
94
94
|
/**
|
|
@@ -115,20 +115,20 @@ export declare namespace TicketRetrieveResponse {
|
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
117
|
export interface TicketUpdateResponse {
|
|
118
|
-
publicId
|
|
119
|
-
status
|
|
118
|
+
publicId: string;
|
|
119
|
+
status: 'open' | 'resolved' | 'closed';
|
|
120
120
|
}
|
|
121
121
|
export interface TicketListResponse {
|
|
122
|
-
tickets
|
|
122
|
+
tickets: Array<TicketListResponse.Ticket>;
|
|
123
123
|
}
|
|
124
124
|
export declare namespace TicketListResponse {
|
|
125
125
|
interface Ticket {
|
|
126
|
-
createdAt
|
|
127
|
-
messageCount
|
|
128
|
-
publicId
|
|
129
|
-
status
|
|
130
|
-
subject
|
|
131
|
-
updatedAt
|
|
126
|
+
createdAt: string;
|
|
127
|
+
messageCount: number;
|
|
128
|
+
publicId: string;
|
|
129
|
+
status: 'open' | 'in_progress' | 'resolved' | 'closed';
|
|
130
|
+
subject: string;
|
|
131
|
+
updatedAt: string;
|
|
132
132
|
}
|
|
133
133
|
}
|
|
134
134
|
export interface TicketReplyResponse {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tickets.d.ts","sourceRoot":"","sources":["../../src/resources/support/tickets.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,kCAA+B;AAEpD,O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W,EAAE,KAAK,CAAC,mBAAmB,CAAC,UAAU,CAAC,CAAC;IAEnD,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,yBAAiB,mBAAmB,CAAC;IACnC;;OAEG;IACH,UAAiB,UAAU;QACzB,QAAQ,EAAE,MAAM,CAAC;QAEjB,MAAM,EAAE,SAAS,GAAG,OAAO,GAAG,QAAQ,CAAC;KACxC;CACF;AAED,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,OAAO,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,MAAM,GAAG,UAAU,GAAG,QAAQ,CAAC;CACxC;AAED,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EACL,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,kBAAkB,IAAI,kBAAkB,EAC7C,KAAK,iBAAiB,IAAI,iBAAiB,GAC5C,CAAC;CACH"}
|
package/resources/trends.d.mts
CHANGED
|
@@ -19,8 +19,20 @@ export declare namespace TrendListResponse {
|
|
|
19
19
|
interface Trend {
|
|
20
20
|
name: string;
|
|
21
21
|
description?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Promotion identifier from X. Null for organic trends.
|
|
24
|
+
*/
|
|
25
|
+
promotedContent?: string | null;
|
|
22
26
|
query?: string;
|
|
23
27
|
rank?: number;
|
|
28
|
+
/**
|
|
29
|
+
* Approximate public post volume when X supplies it.
|
|
30
|
+
*/
|
|
31
|
+
tweetVolume?: number | null;
|
|
32
|
+
/**
|
|
33
|
+
* X search URL for the trend.
|
|
34
|
+
*/
|
|
35
|
+
url?: string;
|
|
24
36
|
}
|
|
25
37
|
}
|
|
26
38
|
export interface TrendListParams {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trends.d.mts","sourceRoot":"","sources":["../src/resources/trends.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,gCAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,wCAAoC;AAE7D;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CACF,KAAK,GAAE,eAAe,GAAG,IAAI,GAAG,SAAc,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,iBAAiB,CAAC;CAGjC;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IAEd,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEvC,KAAK,EAAE,MAAM,CAAC;CACf;AAED,yBAAiB,iBAAiB,CAAC;IACjC,UAAiB,KAAK;QACpB,IAAI,EAAE,MAAM,CAAC;QAEb,WAAW,CAAC,EAAE,MAAM,CAAC;QAErB,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf,IAAI,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"trends.d.mts","sourceRoot":"","sources":["../src/resources/trends.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,6BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,gCAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,wCAAoC;AAE7D;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CACF,KAAK,GAAE,eAAe,GAAG,IAAI,GAAG,SAAc,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,iBAAiB,CAAC;CAGjC;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IAEd,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEvC,KAAK,EAAE,MAAM,CAAC;CACf;AAED,yBAAiB,iBAAiB,CAAC;IACjC,UAAiB,KAAK;QACpB,IAAI,EAAE,MAAM,CAAC;QAEb,WAAW,CAAC,EAAE,MAAM,CAAC;QAErB;;WAEG;QACH,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;QAEhC,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;WAEG;QACH,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;QAE5B;;WAEG;QACH,GAAG,CAAC,EAAE,MAAM,CAAC;KACd;CACF;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CACjG"}
|
package/resources/trends.d.ts
CHANGED
|
@@ -19,8 +19,20 @@ export declare namespace TrendListResponse {
|
|
|
19
19
|
interface Trend {
|
|
20
20
|
name: string;
|
|
21
21
|
description?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Promotion identifier from X. Null for organic trends.
|
|
24
|
+
*/
|
|
25
|
+
promotedContent?: string | null;
|
|
22
26
|
query?: string;
|
|
23
27
|
rank?: number;
|
|
28
|
+
/**
|
|
29
|
+
* Approximate public post volume when X supplies it.
|
|
30
|
+
*/
|
|
31
|
+
tweetVolume?: number | null;
|
|
32
|
+
/**
|
|
33
|
+
* X search URL for the trend.
|
|
34
|
+
*/
|
|
35
|
+
url?: string;
|
|
24
36
|
}
|
|
25
37
|
}
|
|
26
38
|
export interface TrendListParams {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trends.d.ts","sourceRoot":"","sources":["../src/resources/trends.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAE7D;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CACF,KAAK,GAAE,eAAe,GAAG,IAAI,GAAG,SAAc,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,iBAAiB,CAAC;CAGjC;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IAEd,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEvC,KAAK,EAAE,MAAM,CAAC;CACf;AAED,yBAAiB,iBAAiB,CAAC;IACjC,UAAiB,KAAK;QACpB,IAAI,EAAE,MAAM,CAAC;QAEb,WAAW,CAAC,EAAE,MAAM,CAAC;QAErB,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf,IAAI,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"trends.d.ts","sourceRoot":"","sources":["../src/resources/trends.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,4BAAyB;AAC/C,OAAO,EAAE,UAAU,EAAE,+BAA4B;AACjD,OAAO,EAAE,cAAc,EAAE,uCAAoC;AAE7D;;GAEG;AACH,qBAAa,MAAO,SAAQ,WAAW;IACrC;;OAEG;IACH,IAAI,CACF,KAAK,GAAE,eAAe,GAAG,IAAI,GAAG,SAAc,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,iBAAiB,CAAC;CAGjC;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IAEd,MAAM,EAAE,KAAK,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEvC,KAAK,EAAE,MAAM,CAAC;CACf;AAED,yBAAiB,iBAAiB,CAAC;IACjC,UAAiB,KAAK;QACpB,IAAI,EAAE,MAAM,CAAC;QAEb,WAAW,CAAC,EAAE,MAAM,CAAC;QAErB;;WAEG;QACH,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;QAEhC,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;WAEG;QACH,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;QAE5B;;WAEG;QACH,GAAG,CAAC,EAAE,MAAM,CAAC;KACd;CACF;AAED,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EAAE,KAAK,iBAAiB,IAAI,iBAAiB,EAAE,KAAK,eAAe,IAAI,eAAe,EAAE,CAAC;CACjG"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
2
|
+
import { APIPromise } from "../../core/api-promise.mjs";
|
|
3
|
+
import { RequestOptions } from "../../internal/request-options.mjs";
|
|
4
|
+
/**
|
|
5
|
+
* Connected X account management
|
|
6
|
+
*/
|
|
7
|
+
export declare class AccountConnectionAttempts extends APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Get X account connection status
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const accountConnectionAttempt =
|
|
14
|
+
* await client.x.accountConnectionAttempts.retrieve(
|
|
15
|
+
* 'xatt_0123456789abcdef0123456789abcdef',
|
|
16
|
+
* );
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
retrieve(id: string, options?: RequestOptions): APIPromise<AccountConnectionAttemptRetrieveResponse>;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The connection is still in progress.
|
|
23
|
+
*/
|
|
24
|
+
export type AccountConnectionAttemptRetrieveResponse = AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptPending | AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptSuccess | AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptFailed | AccountConnectionAttemptRetrieveResponse.XAccountConnectionChallenge;
|
|
25
|
+
export declare namespace AccountConnectionAttemptRetrieveResponse {
|
|
26
|
+
/**
|
|
27
|
+
* The connection is still in progress.
|
|
28
|
+
*/
|
|
29
|
+
interface XAccountConnectionAttemptPending {
|
|
30
|
+
id: string;
|
|
31
|
+
object: 'x_account_connection_attempt';
|
|
32
|
+
pollAfterMs: number;
|
|
33
|
+
status: 'pending';
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* The account connected successfully.
|
|
37
|
+
*/
|
|
38
|
+
interface XAccountConnectionAttemptSuccess {
|
|
39
|
+
id: string;
|
|
40
|
+
object: 'x_account_connection_attempt';
|
|
41
|
+
status: 'success';
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* The connection reached a final failure.
|
|
45
|
+
*/
|
|
46
|
+
interface XAccountConnectionAttemptFailed {
|
|
47
|
+
id: string;
|
|
48
|
+
error: string;
|
|
49
|
+
object: 'x_account_connection_attempt';
|
|
50
|
+
retryable: boolean;
|
|
51
|
+
status: 'failed';
|
|
52
|
+
reason?: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Resumable account connection challenge. Submit the email code to finish the same
|
|
56
|
+
* connection attempt.
|
|
57
|
+
*/
|
|
58
|
+
interface XAccountConnectionChallenge {
|
|
59
|
+
id: string;
|
|
60
|
+
expiresAt: string;
|
|
61
|
+
message: string;
|
|
62
|
+
object: 'x_account_connection_challenge';
|
|
63
|
+
status: 'requires_email_code';
|
|
64
|
+
username: string;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
export declare namespace AccountConnectionAttempts {
|
|
68
|
+
export { type AccountConnectionAttemptRetrieveResponse as AccountConnectionAttemptRetrieveResponse };
|
|
69
|
+
}
|
|
70
|
+
//# sourceMappingURL=account-connection-attempts.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account-connection-attempts.d.mts","sourceRoot":"","sources":["../../src/resources/x/account-connection-attempts.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE;;GAEG;AACH,qBAAa,yBAA0B,SAAQ,WAAW;IACxD;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wCAAwC,CAAC;CAGrG;AAED;;GAEG;AACH,MAAM,MAAM,wCAAwC,GAChD,wCAAwC,CAAC,gCAAgC,GACzE,wCAAwC,CAAC,gCAAgC,GACzE,wCAAwC,CAAC,+BAA+B,GACxE,wCAAwC,CAAC,2BAA2B,CAAC;AAEzE,yBAAiB,wCAAwC,CAAC;IACxD;;OAEG;IACH,UAAiB,gCAAgC;QAC/C,EAAE,EAAE,MAAM,CAAC;QAEX,MAAM,EAAE,8BAA8B,CAAC;QAEvC,WAAW,EAAE,MAAM,CAAC;QAEpB,MAAM,EAAE,SAAS,CAAC;KACnB;IAED;;OAEG;IACH,UAAiB,gCAAgC;QAC/C,EAAE,EAAE,MAAM,CAAC;QAEX,MAAM,EAAE,8BAA8B,CAAC;QAEvC,MAAM,EAAE,SAAS,CAAC;KACnB;IAED;;OAEG;IACH,UAAiB,+BAA+B;QAC9C,EAAE,EAAE,MAAM,CAAC;QAEX,KAAK,EAAE,MAAM,CAAC;QAEd,MAAM,EAAE,8BAA8B,CAAC;QAEvC,SAAS,EAAE,OAAO,CAAC;QAEnB,MAAM,EAAE,QAAQ,CAAC;QAEjB,MAAM,CAAC,EAAE,MAAM,CAAC;KACjB;IAED;;;OAGG;IACH,UAAiB,2BAA2B;QAC1C,EAAE,EAAE,MAAM,CAAC;QAEX,SAAS,EAAE,MAAM,CAAC;QAElB,OAAO,EAAE,MAAM,CAAC;QAEhB,MAAM,EAAE,gCAAgC,CAAC;QAEzC,MAAM,EAAE,qBAAqB,CAAC;QAE9B,QAAQ,EAAE,MAAM,CAAC;KAClB;CACF;AAED,MAAM,CAAC,OAAO,WAAW,yBAAyB,CAAC;IACjD,OAAO,EAAE,KAAK,wCAAwC,IAAI,wCAAwC,EAAE,CAAC;CACtG"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { APIResource } from "../../core/resource.js";
|
|
2
|
+
import { APIPromise } from "../../core/api-promise.js";
|
|
3
|
+
import { RequestOptions } from "../../internal/request-options.js";
|
|
4
|
+
/**
|
|
5
|
+
* Connected X account management
|
|
6
|
+
*/
|
|
7
|
+
export declare class AccountConnectionAttempts extends APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Get X account connection status
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const accountConnectionAttempt =
|
|
14
|
+
* await client.x.accountConnectionAttempts.retrieve(
|
|
15
|
+
* 'xatt_0123456789abcdef0123456789abcdef',
|
|
16
|
+
* );
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
retrieve(id: string, options?: RequestOptions): APIPromise<AccountConnectionAttemptRetrieveResponse>;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* The connection is still in progress.
|
|
23
|
+
*/
|
|
24
|
+
export type AccountConnectionAttemptRetrieveResponse = AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptPending | AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptSuccess | AccountConnectionAttemptRetrieveResponse.XAccountConnectionAttemptFailed | AccountConnectionAttemptRetrieveResponse.XAccountConnectionChallenge;
|
|
25
|
+
export declare namespace AccountConnectionAttemptRetrieveResponse {
|
|
26
|
+
/**
|
|
27
|
+
* The connection is still in progress.
|
|
28
|
+
*/
|
|
29
|
+
interface XAccountConnectionAttemptPending {
|
|
30
|
+
id: string;
|
|
31
|
+
object: 'x_account_connection_attempt';
|
|
32
|
+
pollAfterMs: number;
|
|
33
|
+
status: 'pending';
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* The account connected successfully.
|
|
37
|
+
*/
|
|
38
|
+
interface XAccountConnectionAttemptSuccess {
|
|
39
|
+
id: string;
|
|
40
|
+
object: 'x_account_connection_attempt';
|
|
41
|
+
status: 'success';
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* The connection reached a final failure.
|
|
45
|
+
*/
|
|
46
|
+
interface XAccountConnectionAttemptFailed {
|
|
47
|
+
id: string;
|
|
48
|
+
error: string;
|
|
49
|
+
object: 'x_account_connection_attempt';
|
|
50
|
+
retryable: boolean;
|
|
51
|
+
status: 'failed';
|
|
52
|
+
reason?: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Resumable account connection challenge. Submit the email code to finish the same
|
|
56
|
+
* connection attempt.
|
|
57
|
+
*/
|
|
58
|
+
interface XAccountConnectionChallenge {
|
|
59
|
+
id: string;
|
|
60
|
+
expiresAt: string;
|
|
61
|
+
message: string;
|
|
62
|
+
object: 'x_account_connection_challenge';
|
|
63
|
+
status: 'requires_email_code';
|
|
64
|
+
username: string;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
export declare namespace AccountConnectionAttempts {
|
|
68
|
+
export { type AccountConnectionAttemptRetrieveResponse as AccountConnectionAttemptRetrieveResponse };
|
|
69
|
+
}
|
|
70
|
+
//# sourceMappingURL=account-connection-attempts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account-connection-attempts.d.ts","sourceRoot":"","sources":["../../src/resources/x/account-connection-attempts.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,kCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,0CAAuC;AAGhE;;GAEG;AACH,qBAAa,yBAA0B,SAAQ,WAAW;IACxD;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wCAAwC,CAAC;CAGrG;AAED;;GAEG;AACH,MAAM,MAAM,wCAAwC,GAChD,wCAAwC,CAAC,gCAAgC,GACzE,wCAAwC,CAAC,gCAAgC,GACzE,wCAAwC,CAAC,+BAA+B,GACxE,wCAAwC,CAAC,2BAA2B,CAAC;AAEzE,yBAAiB,wCAAwC,CAAC;IACxD;;OAEG;IACH,UAAiB,gCAAgC;QAC/C,EAAE,EAAE,MAAM,CAAC;QAEX,MAAM,EAAE,8BAA8B,CAAC;QAEvC,WAAW,EAAE,MAAM,CAAC;QAEpB,MAAM,EAAE,SAAS,CAAC;KACnB;IAED;;OAEG;IACH,UAAiB,gCAAgC;QAC/C,EAAE,EAAE,MAAM,CAAC;QAEX,MAAM,EAAE,8BAA8B,CAAC;QAEvC,MAAM,EAAE,SAAS,CAAC;KACnB;IAED;;OAEG;IACH,UAAiB,+BAA+B;QAC9C,EAAE,EAAE,MAAM,CAAC;QAEX,KAAK,EAAE,MAAM,CAAC;QAEd,MAAM,EAAE,8BAA8B,CAAC;QAEvC,SAAS,EAAE,OAAO,CAAC;QAEnB,MAAM,EAAE,QAAQ,CAAC;QAEjB,MAAM,CAAC,EAAE,MAAM,CAAC;KACjB;IAED;;;OAGG;IACH,UAAiB,2BAA2B;QAC1C,EAAE,EAAE,MAAM,CAAC;QAEX,SAAS,EAAE,MAAM,CAAC;QAElB,OAAO,EAAE,MAAM,CAAC;QAEhB,MAAM,EAAE,gCAAgC,CAAC;QAEzC,MAAM,EAAE,qBAAqB,CAAC;QAE9B,QAAQ,EAAE,MAAM,CAAC;KAClB;CACF;AAED,MAAM,CAAC,OAAO,WAAW,yBAAyB,CAAC;IACjD,OAAO,EAAE,KAAK,wCAAwC,IAAI,wCAAwC,EAAE,CAAC;CACtG"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.AccountConnectionAttempts = void 0;
|
|
5
|
+
const resource_1 = require("../../core/resource.js");
|
|
6
|
+
const path_1 = require("../../internal/utils/path.js");
|
|
7
|
+
/**
|
|
8
|
+
* Connected X account management
|
|
9
|
+
*/
|
|
10
|
+
class AccountConnectionAttempts extends resource_1.APIResource {
|
|
11
|
+
/**
|
|
12
|
+
* Get X account connection status
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* const accountConnectionAttempt =
|
|
17
|
+
* await client.x.accountConnectionAttempts.retrieve(
|
|
18
|
+
* 'xatt_0123456789abcdef0123456789abcdef',
|
|
19
|
+
* );
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
retrieve(id, options) {
|
|
23
|
+
return this._client.get((0, path_1.path) `/x/account-connection-attempts/${id}`, options);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
exports.AccountConnectionAttempts = AccountConnectionAttempts;
|
|
27
|
+
//# sourceMappingURL=account-connection-attempts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account-connection-attempts.js","sourceRoot":"","sources":["../../src/resources/x/account-connection-attempts.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,qDAAkD;AAGlD,uDAAiD;AAEjD;;GAEG;AACH,MAAa,yBAA0B,SAAQ,sBAAW;IACxD;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,EAAU,EAAE,OAAwB;QAC3C,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,kCAAkC,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;CACF;AAfD,8DAeC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
import { APIResource } from "../../core/resource.mjs";
|
|
3
|
+
import { path } from "../../internal/utils/path.mjs";
|
|
4
|
+
/**
|
|
5
|
+
* Connected X account management
|
|
6
|
+
*/
|
|
7
|
+
export class AccountConnectionAttempts extends APIResource {
|
|
8
|
+
/**
|
|
9
|
+
* Get X account connection status
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const accountConnectionAttempt =
|
|
14
|
+
* await client.x.accountConnectionAttempts.retrieve(
|
|
15
|
+
* 'xatt_0123456789abcdef0123456789abcdef',
|
|
16
|
+
* );
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
retrieve(id, options) {
|
|
20
|
+
return this._client.get(path `/x/account-connection-attempts/${id}`, options);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=account-connection-attempts.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"account-connection-attempts.mjs","sourceRoot":"","sources":["../../src/resources/x/account-connection-attempts.ts"],"names":[],"mappings":"AAAA,sFAAsF;AAEtF,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAGlD,OAAO,EAAE,IAAI,EAAE,sCAAkC;AAEjD;;GAEG;AACH,MAAM,OAAO,yBAA0B,SAAQ,WAAW;IACxD;;;;;;;;;;OAUG;IACH,QAAQ,CAAC,EAAU,EAAE,OAAwB;QAC3C,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAA,kCAAkC,EAAE,EAAE,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;CACF"}
|
|
@@ -25,7 +25,7 @@ export interface AccountConnectionChallengeSubmitResponse {
|
|
|
25
25
|
id: string;
|
|
26
26
|
createdAt: string;
|
|
27
27
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
28
|
-
status:
|
|
28
|
+
status: 'active';
|
|
29
29
|
xUserId: string;
|
|
30
30
|
xUsername: string;
|
|
31
31
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account-connection-challenges.d.mts","sourceRoot":"","sources":["../../src/resources/x/account-connection-challenges.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE;;GAEG;AACH,qBAAa,2BAA4B,SAAQ,WAAW;IAC1D;;;;;;;;;;OAUG;IACH,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,sCAAsC,EAC5C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;CAGxD;AAED;;GAEG;AACH,MAAM,WAAW,wCAAwC;IACvD,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,gBAAgB,CAAC;IAE7F,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"account-connection-challenges.d.mts","sourceRoot":"","sources":["../../src/resources/x/account-connection-challenges.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE;;GAEG;AACH,qBAAa,2BAA4B,SAAQ,WAAW;IAC1D;;;;;;;;;;OAUG;IACH,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,sCAAsC,EAC5C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;CAGxD;AAED;;GAEG;AACH,MAAM,WAAW,wCAAwC;IACvD,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,gBAAgB,CAAC;IAE7F,MAAM,EAAE,QAAQ,CAAC;IAEjB,OAAO,EAAE,MAAM,CAAC;IAEhB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,sCAAsC;IACrD;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,2BAA2B,CAAC;IACnD,OAAO,EACL,KAAK,wCAAwC,IAAI,wCAAwC,EACzF,KAAK,sCAAsC,IAAI,sCAAsC,GACtF,CAAC;CACH"}
|
|
@@ -25,7 +25,7 @@ export interface AccountConnectionChallengeSubmitResponse {
|
|
|
25
25
|
id: string;
|
|
26
26
|
createdAt: string;
|
|
27
27
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
28
|
-
status:
|
|
28
|
+
status: 'active';
|
|
29
29
|
xUserId: string;
|
|
30
30
|
xUsername: string;
|
|
31
31
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account-connection-challenges.d.ts","sourceRoot":"","sources":["../../src/resources/x/account-connection-challenges.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,kCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,0CAAuC;AAGhE;;GAEG;AACH,qBAAa,2BAA4B,SAAQ,WAAW;IAC1D;;;;;;;;;;OAUG;IACH,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,sCAAsC,EAC5C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;CAGxD;AAED;;GAEG;AACH,MAAM,WAAW,wCAAwC;IACvD,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,gBAAgB,CAAC;IAE7F,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"account-connection-challenges.d.ts","sourceRoot":"","sources":["../../src/resources/x/account-connection-challenges.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,kCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,0CAAuC;AAGhE;;GAEG;AACH,qBAAa,2BAA4B,SAAQ,WAAW;IAC1D;;;;;;;;;;OAUG;IACH,MAAM,CACJ,EAAE,EAAE,MAAM,EACV,IAAI,EAAE,sCAAsC,EAC5C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,wCAAwC,CAAC;CAGxD;AAED;;GAEG;AACH,MAAM,WAAW,wCAAwC;IACvD,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,gBAAgB,CAAC;IAE7F,MAAM,EAAE,QAAQ,CAAC;IAEjB,OAAO,EAAE,MAAM,CAAC;IAEhB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,sCAAsC;IACrD;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,2BAA2B,CAAC;IACnD,OAAO,EACL,KAAK,wCAAwC,IAAI,wCAAwC,EACzF,KAAK,sCAAsC,IAAI,sCAAsC,GACtF,CAAC;CACH"}
|
|
@@ -13,8 +13,8 @@ export declare class Accounts extends APIResource {
|
|
|
13
13
|
* const account = await client.x.accounts.create({
|
|
14
14
|
* email: 'account@example.invalid',
|
|
15
15
|
* password: '<ACCOUNT_PASSWORD>',
|
|
16
|
-
* username: 'your_x_username',
|
|
17
16
|
* totp_secret: '<TOTP_SECRET>',
|
|
17
|
+
* username: 'your_x_username',
|
|
18
18
|
* });
|
|
19
19
|
* ```
|
|
20
20
|
*/
|
|
@@ -79,11 +79,11 @@ export interface XAccount {
|
|
|
79
79
|
id: string;
|
|
80
80
|
createdAt: string;
|
|
81
81
|
/**
|
|
82
|
-
* Derived connection health. `healthy` =
|
|
82
|
+
* Derived connection health. `healthy` = ready to use. `needsReauth` = user must
|
|
83
83
|
* submit fresh credentials. `locked` = X locked the account; unlock on x.com
|
|
84
|
-
* first. `suspended` = X banned the account. `recovering` =
|
|
85
|
-
*
|
|
86
|
-
*
|
|
84
|
+
* first. `suspended` = X banned the account. `recovering` = cooldown ended; the
|
|
85
|
+
* account can reconnect on its next use. `temporaryIssue` = temporary connection
|
|
86
|
+
* problem; wait before the next use.
|
|
87
87
|
*/
|
|
88
88
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
89
89
|
status: string;
|
|
@@ -108,13 +108,40 @@ export interface XAccountDetail {
|
|
|
108
108
|
/**
|
|
109
109
|
* Sanitized X account summary returned by connect and reauth.
|
|
110
110
|
*/
|
|
111
|
-
export
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
111
|
+
export type AccountCreateResponse = AccountCreateResponse.SanitizedXAccount | AccountCreateResponse.XAccountConnectionAttemptPending | AccountCreateResponse.XAccountConnectionChallenge;
|
|
112
|
+
export declare namespace AccountCreateResponse {
|
|
113
|
+
/**
|
|
114
|
+
* Sanitized X account summary returned by connect and reauth.
|
|
115
|
+
*/
|
|
116
|
+
interface SanitizedXAccount {
|
|
117
|
+
id: string;
|
|
118
|
+
createdAt: string;
|
|
119
|
+
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
120
|
+
status: 'active';
|
|
121
|
+
xUserId: string;
|
|
122
|
+
xUsername: string;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* The connection is still in progress.
|
|
126
|
+
*/
|
|
127
|
+
interface XAccountConnectionAttemptPending {
|
|
128
|
+
id: string;
|
|
129
|
+
object: 'x_account_connection_attempt';
|
|
130
|
+
pollAfterMs: number;
|
|
131
|
+
status: 'pending';
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Resumable account connection challenge. Submit the email code to finish the same
|
|
135
|
+
* connection attempt.
|
|
136
|
+
*/
|
|
137
|
+
interface XAccountConnectionChallenge {
|
|
138
|
+
id: string;
|
|
139
|
+
expiresAt: string;
|
|
140
|
+
message: string;
|
|
141
|
+
object: 'x_account_connection_challenge';
|
|
142
|
+
status: 'requires_email_code';
|
|
143
|
+
username: string;
|
|
144
|
+
}
|
|
118
145
|
}
|
|
119
146
|
export interface AccountListResponse {
|
|
120
147
|
accounts: Array<XAccount>;
|
|
@@ -135,7 +162,7 @@ export interface AccountReauthResponse {
|
|
|
135
162
|
id: string;
|
|
136
163
|
createdAt: string;
|
|
137
164
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
138
|
-
status:
|
|
165
|
+
status: 'active';
|
|
139
166
|
xUserId: string;
|
|
140
167
|
xUsername: string;
|
|
141
168
|
}
|
|
@@ -149,13 +176,13 @@ export interface AccountCreateParams {
|
|
|
149
176
|
*/
|
|
150
177
|
password: string;
|
|
151
178
|
/**
|
|
152
|
-
*
|
|
179
|
+
* Authenticator App TOTP secret required for durable login
|
|
153
180
|
*/
|
|
154
|
-
|
|
181
|
+
totp_secret: string;
|
|
155
182
|
/**
|
|
156
|
-
*
|
|
183
|
+
* X username
|
|
157
184
|
*/
|
|
158
|
-
|
|
185
|
+
username: string;
|
|
159
186
|
}
|
|
160
187
|
export interface AccountReauthParams {
|
|
161
188
|
/**
|
|
@@ -167,7 +194,7 @@ export interface AccountReauthParams {
|
|
|
167
194
|
*/
|
|
168
195
|
email?: string;
|
|
169
196
|
/**
|
|
170
|
-
* TOTP secret
|
|
197
|
+
* Replacement Authenticator App TOTP secret. Omit it to reuse the saved secret.
|
|
171
198
|
*/
|
|
172
199
|
totp_secret?: string;
|
|
173
200
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accounts.d.mts","sourceRoot":"","sources":["../../src/resources/x/accounts.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,gCAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,mCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,2CAAuC;AAGhE;;GAEG;AACH,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;OAYG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI9F;;;;;;;;;OASG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;IAI1E;;;;;;;OAOG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,mBAAmB,CAAC;IAI/D;;;;;;;OAOG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI/E;;;;;;;;OAQG;IACH,SAAS,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wBAAwB,CAAC;IAIzE;;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AW,qBAAqB;IACpC,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aAAa,GAAG,YAAY,GAAG,WAAW,GAAG,gBAAgB,CAAC;IAE7F,MAAM,EAAE,QAAQ,CAAC;IAEjB,OAAO,EAAE,MAAM,CAAC;IAEhB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,CAAC,OAAO,WAAW,QAAQ,CAAC;IAChC,OAAO,EACL,KAAK,QAAQ,IAAI,QAAQ,EACzB,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,mBAAmB,IAAI,mBAAmB,GAChD,CAAC;CACH"}
|
|
@@ -13,8 +13,8 @@ export declare class Accounts extends APIResource {
|
|
|
13
13
|
* const account = await client.x.accounts.create({
|
|
14
14
|
* email: 'account@example.invalid',
|
|
15
15
|
* password: '<ACCOUNT_PASSWORD>',
|
|
16
|
-
* username: 'your_x_username',
|
|
17
16
|
* totp_secret: '<TOTP_SECRET>',
|
|
17
|
+
* username: 'your_x_username',
|
|
18
18
|
* });
|
|
19
19
|
* ```
|
|
20
20
|
*/
|
|
@@ -79,11 +79,11 @@ export interface XAccount {
|
|
|
79
79
|
id: string;
|
|
80
80
|
createdAt: string;
|
|
81
81
|
/**
|
|
82
|
-
* Derived connection health. `healthy` =
|
|
82
|
+
* Derived connection health. `healthy` = ready to use. `needsReauth` = user must
|
|
83
83
|
* submit fresh credentials. `locked` = X locked the account; unlock on x.com
|
|
84
|
-
* first. `suspended` = X banned the account. `recovering` =
|
|
85
|
-
*
|
|
86
|
-
*
|
|
84
|
+
* first. `suspended` = X banned the account. `recovering` = cooldown ended; the
|
|
85
|
+
* account can reconnect on its next use. `temporaryIssue` = temporary connection
|
|
86
|
+
* problem; wait before the next use.
|
|
87
87
|
*/
|
|
88
88
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
89
89
|
status: string;
|
|
@@ -108,13 +108,40 @@ export interface XAccountDetail {
|
|
|
108
108
|
/**
|
|
109
109
|
* Sanitized X account summary returned by connect and reauth.
|
|
110
110
|
*/
|
|
111
|
-
export
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
111
|
+
export type AccountCreateResponse = AccountCreateResponse.SanitizedXAccount | AccountCreateResponse.XAccountConnectionAttemptPending | AccountCreateResponse.XAccountConnectionChallenge;
|
|
112
|
+
export declare namespace AccountCreateResponse {
|
|
113
|
+
/**
|
|
114
|
+
* Sanitized X account summary returned by connect and reauth.
|
|
115
|
+
*/
|
|
116
|
+
interface SanitizedXAccount {
|
|
117
|
+
id: string;
|
|
118
|
+
createdAt: string;
|
|
119
|
+
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
120
|
+
status: 'active';
|
|
121
|
+
xUserId: string;
|
|
122
|
+
xUsername: string;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* The connection is still in progress.
|
|
126
|
+
*/
|
|
127
|
+
interface XAccountConnectionAttemptPending {
|
|
128
|
+
id: string;
|
|
129
|
+
object: 'x_account_connection_attempt';
|
|
130
|
+
pollAfterMs: number;
|
|
131
|
+
status: 'pending';
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Resumable account connection challenge. Submit the email code to finish the same
|
|
135
|
+
* connection attempt.
|
|
136
|
+
*/
|
|
137
|
+
interface XAccountConnectionChallenge {
|
|
138
|
+
id: string;
|
|
139
|
+
expiresAt: string;
|
|
140
|
+
message: string;
|
|
141
|
+
object: 'x_account_connection_challenge';
|
|
142
|
+
status: 'requires_email_code';
|
|
143
|
+
username: string;
|
|
144
|
+
}
|
|
118
145
|
}
|
|
119
146
|
export interface AccountListResponse {
|
|
120
147
|
accounts: Array<XAccount>;
|
|
@@ -135,7 +162,7 @@ export interface AccountReauthResponse {
|
|
|
135
162
|
id: string;
|
|
136
163
|
createdAt: string;
|
|
137
164
|
health: 'healthy' | 'locked' | 'needsReauth' | 'recovering' | 'suspended' | 'temporaryIssue';
|
|
138
|
-
status:
|
|
165
|
+
status: 'active';
|
|
139
166
|
xUserId: string;
|
|
140
167
|
xUsername: string;
|
|
141
168
|
}
|
|
@@ -149,13 +176,13 @@ export interface AccountCreateParams {
|
|
|
149
176
|
*/
|
|
150
177
|
password: string;
|
|
151
178
|
/**
|
|
152
|
-
*
|
|
179
|
+
* Authenticator App TOTP secret required for durable login
|
|
153
180
|
*/
|
|
154
|
-
|
|
181
|
+
totp_secret: string;
|
|
155
182
|
/**
|
|
156
|
-
*
|
|
183
|
+
* X username
|
|
157
184
|
*/
|
|
158
|
-
|
|
185
|
+
username: string;
|
|
159
186
|
}
|
|
160
187
|
export interface AccountReauthParams {
|
|
161
188
|
/**
|
|
@@ -167,7 +194,7 @@ export interface AccountReauthParams {
|
|
|
167
194
|
*/
|
|
168
195
|
email?: string;
|
|
169
196
|
/**
|
|
170
|
-
* TOTP secret
|
|
197
|
+
* Replacement Authenticator App TOTP secret. Omit it to reuse the saved secret.
|
|
171
198
|
*/
|
|
172
199
|
totp_secret?: string;
|
|
173
200
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accounts.d.ts","sourceRoot":"","sources":["../../src/resources/x/accounts.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,+BAA4B;AAClD,OAAO,EAAE,UAAU,EAAE,kCAA+B;AACpD,OAAO,EAAE,cAAc,EAAE,0CAAuC;AAGhE;;GAEG;AACH,qBAAa,QAAS,SAAQ,WAAW;IACvC;;;;;;;;;;;;OAYG;IACH,MAAM,CAAC,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI9F;;;;;;;;;OASG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;IAI1E;;;;;;;OAOG;IACH,IAAI,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,mBAAmB,CAAC;IAI/D;;;;;;;OAOG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;IAI/E;;;;;;;;OAQG;IACH,SAAS,CAAC,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,wBAAwB,CAAC;IAIzE;;;;;;;;;;;OAWG;IACH,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,qBAAqB,CAAC;CAG3G;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,MAAM,CAAC;IAEX,SAAS,EAAE,MAAM,CAAC;IAElB;;;;;;OAMG;IACH,MAAM,EAAE,SAAS,GAAG,QAAQ,GAAG,aA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